gnutls_privkey_import_gost_raw(3)
π gnutls_privkey_import_gost_raw(3) π
okay so bestie, welcome to the gnutls manual, page gnutls_privkey_import_gost_raw(3) β yes that's a whole mouthful, we're gonna get through it together, i promise π«Ά
β¨ NAME β¨
gnutls_privkey_import_gost_raw β it's an API function, and it's giving "let me turn your raw GOST key bits into a real key object" π
πΈ SYNOPSIS πΈ
#include <gnutls/abstract.h>
int gnutls_privkey_import_gost_raw(gnutls_privkey_t key,
gnutls_ecc_curve_t curve, gnutls_digest_algorithm_t digest,
gnutls_gost_paramset_t paramset, const gnutls_datum_t * x, const
gnutls_datum_t * y, const gnutls_datum_t * k);
look at her. seven arguments. she's high maintenance but she's worth it β¨
π ARGUMENTS π
gnutls_privkey_t keyβ the key, literally the main character here πgnutls_ecc_curve_t curveβ holds the curve πgnutls_digest_algorithm_t digestβ holds the digest π§gnutls_gost_paramset_t paramsetβ holds the GOST parameter set ID πconst gnutls_datum_t * xβ holds the x-coordinate, cute lil x πconst gnutls_datum_t * yβ holds the y-coordinate, her partner in crime πconst gnutls_datum_t * kβ holds the k (private key) π€« keep that one secret fr fr
π¦ DESCRIPTION π¦
so what does she actually DO. this function will convert the given GOST private key's parameters to the native gnutls_privkey_t format π the output gets stored in key β yes, that key, the one you passed in, she fills it in for you.
and about digest? bestie, it has to be one of GNUTLS_DIG_GOSR_94, GNUTLS_DIG_STREEBOG_256 or GNUTLS_DIG_STREEBOG_512. those three. no others. don't try it π
and if paramset is set to GNUTLS_GOST_PARAMSET_UNKNOWN, a default one will be selected depending on digest β so she picks for you, no cap β¨
β οΈ NOTE β οΈ
parameters should be stored with least significant byte first. and listen β on version 3.6.3 big-endian format was used incorrectly. yes, incorrectly. we don't talk about 3.6.3. π
π RETURNS π
on success, GNUTLS_E_SUCCESS (0) is returned π otherwise you get a negative error value and honestly? vibe check failed π
β SINCE β
3.6.3 β she's been around, an icon, a legend π
π REPORTING BUGS π
found a bug? don't be shy, report bugs to <bugs@gnutls.org> π«Ά
home page: https://www.gnutls.org π
π COPYRIGHT π
Copyright Β© 2001-2023 Free Software Foundation, Inc., and others.
Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. slay, honestly π
π« SEE ALSO π«
the full documentation for gnutls is maintained as a Texinfo manual π if the /usr/share/doc/gnutls/ directory does not contain the HTML form, visit:
https://www.gnutls.org/manual/
that's the whole page bestie, you ate that π½οΈβ¨ no cap, you now know everything this function has to offer.
gnutls version 3.8.13 β page gnutls_privkey_import_gost_raw(3) β mwah, bye, ily, go import some keys πππ¦
π¦ where this page comes from
- alpine 3.22: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- alpine 3.23: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- alpine 3.24: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- arch rolling: gnutls 3.8.13-3 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: gnutls-devel 3.8.13-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: gnutls-devel 3.8.13-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: gnutls-devel 3.8.13-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: gnutls-devel 3.8.13-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- ubuntu stonking: gnutls-doc 3.8.13-1ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms