Qsphinx.addnodesdocument)}( rawsourcechildren]( translations LanguagesNode)}(hhh](h pending_xref)}(hhh]docutils.nodesTextChinese (Simplified)}parenthsba attributes}(ids]classes]names]dupnames]backrefs] refdomainstdreftypedoc reftarget"/translations/zh_CN/crypto/api-kppmodnameN classnameN refexplicitutagnamehhh ubh)}(hhh]hChinese (Traditional)}hh2sbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/zh_TW/crypto/api-kppmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hItalian}hhFsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/it_IT/crypto/api-kppmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hJapanese}hhZsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/ja_JP/crypto/api-kppmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hKorean}hhnsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/ko_KR/crypto/api-kppmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hSpanish}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/sp_SP/crypto/api-kppmodnameN classnameN refexplicituh1hhh ubeh}(h]h ]h"]h$]h&]current_languageEnglishuh1h hh _documenthsourceNlineNubhsection)}(hhh](htitle)}(hDKey-agreement Protocol Primitives (KPP) Cipher Algorithm Definitionsh]hDKey-agreement Protocol Primitives (KPP) Cipher Algorithm Definitions}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhhhobjtypej?desctypej?noindex noindexentrynocontentsentryuh1hhhhhhNhNubh container)}(hX**Definition**:: struct kpp_request { struct crypto_async_request base; struct scatterlist *src; struct scatterlist *dst; unsigned int src_len; unsigned int dst_len; void *__ctx[] ; }; **Members** ``base`` Common attributes for async crypto requests ``src`` Source data ``dst`` Destination data ``src_len`` Size of the input buffer ``dst_len`` Size of the output buffer. It needs to be at least as big as the expected result depending on the operation After operation it will be updated with the actual size of the result. In case of error where the dst sgl size was insufficient, it will be updated to the size required for the operation. ``__ctx`` Start of private context datah](h paragraph)}(h**Definition**::h](hstrong)}(h**Definition**h]h Definition}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjQubh:}(hjQhhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjKubh literal_block)}(hstruct kpp_request { struct crypto_async_request base; struct scatterlist *src; struct scatterlist *dst; unsigned int src_len; unsigned int dst_len; void *__ctx[] ; };h]hstruct kpp_request { struct crypto_async_request base; struct scatterlist *src; struct scatterlist *dst; unsigned int src_len; unsigned int dst_len; void *__ctx[] ; };}hjrsbah}(h]h ]h"]h$]h&]jjuh1jphR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjKubjP)}(h **Members**h]jV)}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK hjKubhdefinition_list)}(hhh](hdefinition_list_item)}(h5``base`` Common attributes for async crypto requests h](hterm)}(h``base``h]hliteral)}(hjh]hbase}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubh definition)}(hhh]jP)}(h+Common attributes for async crypto requestsh]h+Common attributes for async crypto requests}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubj)}(h``src`` Source data h](j)}(h``src``h]j)}(hjh]hsrc}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(h Source datah]h Source data}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubj)}(h``dst`` Destination data h](j)}(h``dst``h]j)}(hjh]hdst}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hDestination datah]hDestination data}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj3hKhj4ubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhj3hKhjubj)}(h%``src_len`` Size of the input buffer h](j)}(h ``src_len``h]j)}(hjWh]hsrc_len}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjUubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjQubj)}(hhh]jP)}(hSize of the input bufferh]hSize of the input buffer}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjlhKhjmubah}(h]h ]h"]h$]h&]uh1jhjQubeh}(h]h ]h"]h$]h&]uh1jhjlhKhjubj)}(hX4``dst_len`` Size of the output buffer. It needs to be at least as big as the expected result depending on the operation After operation it will be updated with the actual size of the result. In case of error where the dst sgl size was insufficient, it will be updated to the size required for the operation. h](j)}(h ``dst_len``h]j)}(hjh]hdst_len}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hX'Size of the output buffer. It needs to be at least as big as the expected result depending on the operation After operation it will be updated with the actual size of the result. In case of error where the dst sgl size was insufficient, it will be updated to the size required for the operation.h]hX'Size of the output buffer. It needs to be at least as big as the expected result depending on the operation After operation it will be updated with the actual size of the result. In case of error where the dst sgl size was insufficient, it will be updated to the size required for the operation.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubj)}(h'``__ctx`` Start of private context datah](j)}(h ``__ctx``h]j)}(hjh]h__ctx}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hStart of private context datah]hStart of private context data}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubeh}(h]h ]h"]h$]h&]uh1jhjKubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČcrypto_kpp (C struct) c.crypto_kpphNtauh1hhhhhhNhNubh)}(hhh](h)}(h crypto_kpph]h)}(hstruct crypto_kpph](h)}(hhh]hstruct}(hj$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK$ubh)}(h h]h }(hj2hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhj1hK$ubh)}(h crypto_kpph]j)}(hjh]h crypto_kpp}(hjDhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj@ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj hhhj1hK$ubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjhhhj1hK$ubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj1hK$hjhhubj1)}(hhh]jP)}(hOuser-instantiated object which encapsulate algorithms and core processing logich]hOuser-instantiated object which encapsulate algorithms and core processing logic}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK)hjchhubah}(h]h ]h"]h$]h&]uh1j0hjhhhj1hK$ubeh}(h]h ](j>structeh"]h$]h&]jCj>jDj~jEj~jFjGjHuh1hhhhhhNhNubjJ)}(h**Definition**:: struct crypto_kpp { unsigned int reqsize; struct crypto_tfm base; }; **Members** ``reqsize`` Request context size required by algorithm implementation ``base`` Common crypto API algorithm data structureh](jP)}(h**Definition**::h](jV)}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK-hjubjq)}(hLstruct crypto_kpp { unsigned int reqsize; struct crypto_tfm base; };h]hLstruct crypto_kpp { unsigned int reqsize; struct crypto_tfm base; };}hjsbah}(h]h ]h"]h$]h&]jjuh1jphR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK/hjubjP)}(h **Members**h]jV)}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK4hjubj)}(hhh](j)}(hF``reqsize`` Request context size required by algorithm implementation h](j)}(h ``reqsize``h]j)}(hjh]hreqsize}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK.hjubj)}(hhh]jP)}(h9Request context size required by algorithm implementationh]h9Request context size required by algorithm implementation}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK-hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhK.hjubj)}(h3``base`` Common crypto API algorithm data structureh](j)}(h``base``h]j)}(hj h]hbase}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK.hjubj)}(hhh]jP)}(h*Common crypto API algorithm data structureh]h*Common crypto API algorithm data structure}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK/hj#ubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhj"hK.hjubeh}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČkpp_alg (C struct) c.kpp_alghNtauh1hhhhhhNhNubh)}(hhh](h)}(hkpp_algh]h)}(hstruct kpp_algh](h)}(hhh]hstruct}(hjghhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjchhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK5ubh)}(h h]h }(hjuhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjchhhjthK5ubh)}(hkpp_algh]j)}(hjah]hkpp_alg}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ](jjeh"]h$]h&]jjuh1hhjchhhjthK5ubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj_hhhjthK5ubah}(h]jZah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjthK5hj\hhubj1)}(hhh]jP)}(h)generic key-agreement protocol primitivesh]h)generic key-agreement protocol primitives}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK7hjhhubah}(h]h ]h"]h$]h&]uh1j0hj\hhhjthK5ubeh}(h]h ](j>structeh"]h$]h&]jCj>jDjjEjjFjGjHuh1hhhhhhNhNubjJ)}(hXv**Definition**:: struct kpp_alg { int (*set_secret)(struct crypto_kpp *tfm, const void *buffer, unsigned int len); int (*generate_public_key)(struct kpp_request *req); int (*compute_shared_secret)(struct kpp_request *req); unsigned int (*max_size)(struct crypto_kpp *tfm); int (*init)(struct crypto_kpp *tfm); void (*exit)(struct crypto_kpp *tfm); struct crypto_alg base; }; **Members** ``set_secret`` Function invokes the protocol specific function to store the secret private key along with parameters. The implementation knows how to decode the buffer ``generate_public_key`` Function generate the public key to be sent to the counterpart. In case of error, where output is not big enough req->dst_len will be updated to the size required ``compute_shared_secret`` Function compute the shared secret as defined by the algorithm. The result is given back to the user. In case of error, where output is not big enough, req->dst_len will be updated to the size required ``max_size`` Function returns the size of the output buffer ``init`` Initialize the object. This is called only once at instantiation time. In case the cryptographic hardware needs to be initialized. Software fallback should be put in place here. ``exit`` Undo everything **init** did. ``base`` Common crypto API algorithm data structureh](jP)}(h**Definition**::h](jV)}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK;hjubjq)}(hXstruct kpp_alg { int (*set_secret)(struct crypto_kpp *tfm, const void *buffer, unsigned int len); int (*generate_public_key)(struct kpp_request *req); int (*compute_shared_secret)(struct kpp_request *req); unsigned int (*max_size)(struct crypto_kpp *tfm); int (*init)(struct crypto_kpp *tfm); void (*exit)(struct crypto_kpp *tfm); struct crypto_alg base; };h]hXstruct kpp_alg { int (*set_secret)(struct crypto_kpp *tfm, const void *buffer, unsigned int len); int (*generate_public_key)(struct kpp_request *req); int (*compute_shared_secret)(struct kpp_request *req); unsigned int (*max_size)(struct crypto_kpp *tfm); int (*init)(struct crypto_kpp *tfm); void (*exit)(struct crypto_kpp *tfm); struct crypto_alg base; };}hjsbah}(h]h ]h"]h$]h&]jjuh1jphR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK=hjubjP)}(h **Members**h]jV)}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKGhjubj)}(hhh](j)}(h``set_secret`` Function invokes the protocol specific function to store the secret private key along with parameters. The implementation knows how to decode the buffer h](j)}(h``set_secret``h]j)}(hjh]h set_secret}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKdst_len will be updated to the size required h](j)}(h``generate_public_key``h]j)}(hjPh]hgenerate_public_key}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK@hjJubj)}(hhh]jP)}(hFunction generate the public key to be sent to the counterpart. In case of error, where output is not big enough req->dst_len will be updated to the size requiredh]hFunction generate the public key to be sent to the counterpart. In case of error, where output is not big enough req->dst_len will be updated to the size required}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhK=hjfubah}(h]h ]h"]h$]h&]uh1jhjJubeh}(h]h ]h"]h$]h&]uh1jhjehK@hj ubj)}(h``compute_shared_secret`` Function compute the shared secret as defined by the algorithm. The result is given back to the user. In case of error, where output is not big enough, req->dst_len will be updated to the size required h](j)}(h``compute_shared_secret``h]j)}(hjh]hcompute_shared_secret}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKDhjubj)}(hhh]jP)}(hFunction compute the shared secret as defined by the algorithm. The result is given back to the user. In case of error, where output is not big enough, req->dst_len will be updated to the size requiredh]hFunction compute the shared secret as defined by the algorithm. The result is given back to the user. In case of error, where output is not big enough, req->dst_len will be updated to the size required}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKAhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKDhj ubj)}(h<``max_size`` Function returns the size of the output buffer h](j)}(h ``max_size``h]j)}(hjh]hmax_size}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKEhjubj)}(hhh]jP)}(h.Function returns the size of the output bufferh]h.Function returns the size of the output buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKEhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKEhj ubj)}(h``init`` Initialize the object. This is called only once at instantiation time. In case the cryptographic hardware needs to be initialized. Software fallback should be put in place here. h](j)}(h``init``h]j)}(hjh]hinit}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKIhjubj)}(hhh]jP)}(hInitialize the object. This is called only once at instantiation time. In case the cryptographic hardware needs to be initialized. Software fallback should be put in place here.h]hInitialize the object. This is called only once at instantiation time. In case the cryptographic hardware needs to be initialized. Software fallback should be put in place here.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKFhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKIhj ubj)}(h'``exit`` Undo everything **init** did. h](j)}(h``exit``h]j)}(hj7h]hexit}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj5ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKJhj1ubj)}(hhh]jP)}(hUndo everything **init** did.h](hUndo everything }(hjPhhhNhNubjV)}(h**init**h]hinit}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjPubh did.}(hjPhhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhjLhKJhjMubah}(h]h ]h"]h$]h&]uh1jhj1ubeh}(h]h ]h"]h$]h&]uh1jhjLhKJhj ubj)}(h3``base`` Common crypto API algorithm data structureh](j)}(h``base``h]j)}(hjh]hbase}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKKhj|ubj)}(hhh]jP)}(h*Common crypto API algorithm data structureh]h*Common crypto API algorithm data structure}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKLhjubah}(h]h ]h"]h$]h&]uh1jhj|ubeh}(h]h ]h"]h$]h&]uh1jhjhKKhj ubeh}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČkpp_secret (C struct) c.kpp_secrethNtauh1hhhhhhNhNubh)}(hhh](h)}(h kpp_secreth]h)}(hstruct kpp_secreth](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhKubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhjhKubh)}(h kpp_secreth]j)}(hjh]h kpp_secret}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ](jjeh"]h$]h&]jjuh1hhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjhhhjhKubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhKhjhhubj1)}(hhh]jP)}(h&small header for packing secret bufferh]h&small header for packing secret buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhKubeh}(h]h ](j>structeh"]h$]h&]jCj>jDj6jEj6jFjGjHuh1hhhhhhNhNubjJ)}(hX **Definition**:: struct kpp_secret { unsigned short type; unsigned short len; }; **Members** ``type`` define type of secret. Each kpp type will define its own ``len`` specify the len of the secret, include the header, that follows the structh](jP)}(h**Definition**::h](jV)}(h**Definition**h]h Definition}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj>ubh:}(hj>hhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhM hj:ubjq)}(hGstruct kpp_secret { unsigned short type; unsigned short len; };h]hGstruct kpp_secret { unsigned short type; unsigned short len; };}hj[sbah}(h]h ]h"]h$]h&]jjuh1jphR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhMhj:ubjP)}(h **Members**h]jV)}(hjlh]hMembers}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjjubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhMhj:ubj)}(hhh](j)}(hB``type`` define type of secret. Each kpp type will define its own h](j)}(h``type``h]j)}(hjh]htype}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhM hjubj)}(hhh]jP)}(h8define type of secret. Each kpp type will define its ownh]h8define type of secret. Each kpp type will define its own}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhM hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM hjubj)}(hR``len`` specify the len of the secret, include the header, that follows the structh](j)}(h``len``h]j)}(hjh]hlen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:4: ./include/crypto/kpp.hhM hjubj)}(hhh]jP)}(hJspecify the len of the secret, include the header, that follows the structh]hJspecify the len of the secret, include the header, that follows the struct}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhM hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM hjubeh}(h]h ]h"]h$]h&]uh1jhj:ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhhhhhNhNubeh}(h]Bkey-agreement-protocol-primitives-kpp-cipher-algorithm-definitionsah ]h"]Dkey-agreement protocol primitives (kpp) cipher algorithm definitionsah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(h2Key-agreement Protocol Primitives (KPP) Cipher APIh]h2Key-agreement Protocol Primitives (KPP) Cipher API}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hhhhhKubjP)}(hfThe KPP API is used with the algorithm type CRYPTO_ALG_TYPE_KPP (listed as type "kpp" in /proc/crypto)h]hjThe KPP API is used with the algorithm type CRYPTO_ALG_TYPE_KPP (listed as type “kpp” in /proc/crypto)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:10: ./include/crypto/kpp.hhK\hj hhubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČcrypto_alloc_kpp (C function)c.crypto_alloc_kpphNtauh1hhj hhhNhNubh)}(hhh](h)}(hOstruct crypto_kpp * crypto_alloc_kpp (const char *alg_name, u32 type, u32 mask)h]h)}(hMstruct crypto_kpp *crypto_alloc_kpp(const char *alg_name, u32 type, u32 mask)h](h)}(hhh]hstruct}(hjEhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjAhhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKnubh)}(h h]h }(hjShhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjAhhhjRhKnubh)}(hhh]j)}(h crypto_kpph]h crypto_kpp}(hjdhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjaubah}(h]h ]h"]h$]h&] refdomainj>reftype identifier reftargetjfmodnameN classnameN c:parent_keysphinx.domains.c LookupKey)}data]j ASTIdentifier)}jzcrypto_alloc_kppsbc.crypto_alloc_kppasbuh1hhjAhhhjRhKnubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjAhhhjRhKnubhdesc_sig_punctuation)}(h*h]h*}(hjhhhNhNubah}(h]h ]pah"]h$]h&]uh1jhjAhhhjRhKnubh)}(hcrypto_alloc_kpph]j)}(hjh]hcrypto_alloc_kpp}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ](jjeh"]h$]h&]jjuh1hhjAhhhjRhKnubhdesc_parameterlist)}(h*(const char *alg_name, u32 type, u32 mask)h](hdesc_parameter)}(hconst char *alg_nameh](h)}(hconsth]hconst}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubhdesc_sig_keyword_type)}(hcharh]hchar}(hjhhhNhNubah}(h]h ]ktah"]h$]h&]uh1jhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(halg_nameh]halg_name}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hu32 typeh](h)}(hhh]j)}(hu32h]hu32}(hj3 hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0 ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj5 modnameN classnameNj~j)}j]jc.crypto_alloc_kppasbuh1hhj, ubh)}(h h]h }(hjQ hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj, ubj)}(htypeh]htype}(hj_ hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj, ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hu32 maskh](h)}(hhh]j)}(hu32h]hu32}(hj{ hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjx ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj} modnameN classnameNj~j)}j]jc.crypto_alloc_kppasbuh1hhjt ubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjt ubj)}(hmaskh]hmask}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjt ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjAhhhjRhKnubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj=hhhjRhKnubah}(h]j8ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjRhKnhj:hhubj1)}(hhh]jP)}(hallocate KPP tfm handleh]hallocate KPP tfm handle}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKchj hhubah}(h]h ]h"]h$]h&]uh1j0hj:hhhjRhKnubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj jEj jFjGjHuh1hhhhj hNhNubjJ)}(hX**Parameters** ``const char *alg_name`` is the name of the kpp algorithm (e.g. "dh", "ecdh") ``u32 type`` specifies the type of the algorithm ``u32 mask`` specifies the mask for the algorithm **Description** Allocate a handle for kpp algorithm. The returned struct crypto_kpp is required for any following API invocation **Return** allocated handle in case of success; IS_ERR() is true in case of an error, PTR_ERR() returns the error code.h](jP)}(h**Parameters**h]jV)}(hj h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKghj ubj)}(hhh](j)}(hN``const char *alg_name`` is the name of the kpp algorithm (e.g. "dh", "ecdh") h](j)}(h``const char *alg_name``h]j)}(hj h]hconst char *alg_name}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKdhj ubj)}(hhh]jP)}(h4is the name of the kpp algorithm (e.g. "dh", "ecdh")h]hreftypejz reftargetj modnameN classnameNj~j)}j]j)}jzjy sbc.crypto_free_kppasbuh1hhj ubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hjh]h*}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(htfmh]htfm}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubah}(h]h ]h"]h$]h&]jjuh1jhjR hhhjd hKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjN hhhjd hKubah}(h]jI ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjd hKhjK hhubj1)}(hhh]jP)}(hfree KPP tfm handleh]hfree KPP tfm handle}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKhj hhubah}(h]h ]h"]h$]h&]uh1j0hjK hhhjd hKubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj. jEj. jFjGjHuh1hhhhj hNhNubjJ)}(h**Parameters** ``struct crypto_kpp *tfm`` KPP tfm handle allocated with crypto_alloc_kpp() **Description** If **tfm** is a NULL or error pointer, this function does nothing.h](jP)}(h**Parameters**h]jV)}(hj8 h]h Parameters}(hj: hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj6 ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKhj2 ubj)}(hhh]j)}(hL``struct crypto_kpp *tfm`` KPP tfm handle allocated with crypto_alloc_kpp() h](j)}(h``struct crypto_kpp *tfm``h]j)}(hjW h]hstruct crypto_kpp *tfm}(hjY hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjU ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKhjQ ubj)}(hhh]jP)}(h0KPP tfm handle allocated with crypto_alloc_kpp()h]h0KPP tfm handle allocated with crypto_alloc_kpp()}(hjp hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjl hKhjm ubah}(h]h ]h"]h$]h&]uh1jhjQ ubeh}(h]h ]h"]h$]h&]uh1jhjl hKhjN ubah}(h]h ]h"]h$]h&]uh1jhj2 ubjP)}(h**Description**h]jV)}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKhj2 ubjP)}(hBIf **tfm** is a NULL or error pointer, this function does nothing.h](hIf }(hj hhhNhNubjV)}(h**tfm**h]htfm}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj ubh8 is a NULL or error pointer, this function does nothing.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhKhj2 ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ"crypto_kpp_set_secret (C function)c.crypto_kpp_set_secrethNtauh1hhj hhhNhNubh)}(hhh](h)}(hXint crypto_kpp_set_secret (struct crypto_kpp *tfm, const void *buffer, unsigned int len)h]h)}(hWint crypto_kpp_set_secret(struct crypto_kpp *tfm, const void *buffer, unsigned int len)h](j)}(hinth]hint}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM"ubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhj hM"ubh)}(hcrypto_kpp_set_secreth]j)}(hcrypto_kpp_set_secreth]hcrypto_kpp_set_secret}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj hhhj hM"ubj)}(h>(struct crypto_kpp *tfm, const void *buffer, unsigned int len)h](j)}(hstruct crypto_kpp *tfmh](h)}(hhh]hstruct}(hj& hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj" ubh)}(h h]h }(hj3 hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj" ubh)}(hhh]j)}(h crypto_kpph]h crypto_kpp}(hjD hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjA ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjF modnameN classnameNj~j)}j]j)}jzj sbc.crypto_kpp_set_secretasbuh1hhj" ubh)}(h h]h }(hjd hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj" ubj)}(hjh]h*}(hjr hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj" ubj)}(htfmh]htfm}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj" ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubj)}(hconst void *bufferh](h)}(hjh]hconst}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hvoidh]hvoid}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hjh]h*}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(hbufferh]hbuffer}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubj)}(hunsigned int lenh](j)}(hunsignedh]hunsigned}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hlenh]hlen}(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubeh}(h]h ]h"]h$]h&]jjuh1jhj hhhj hM"ubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj hhhj hM"ubah}(h]j ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj hM"hj hhubj1)}(hhh]jP)}(hInvoke kpp operationh]hInvoke kpp operation}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMhjThhubah}(h]h ]h"]h$]h&]uh1j0hj hhhj hM"ubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjojEjojFjGjHuh1hhhhj hNhNubjJ)}(hX&**Parameters** ``struct crypto_kpp *tfm`` tfm handle ``const void *buffer`` Buffer holding the packet representation of the private key. The structure of the packet key depends on the particular KPP implementation. Packing and unpacking helpers are provided for ECDH and DH (see the respective header files for those implementations). ``unsigned int len`` Length of the packet private key buffer. **Description** Function invokes the specific kpp operation for a given alg. **Return** zero on success; error code in case of errorh](jP)}(h**Parameters**h]jV)}(hjyh]h Parameters}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjwubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMhjsubj)}(hhh](j)}(h&``struct crypto_kpp *tfm`` tfm handle h](j)}(h``struct crypto_kpp *tfm``h]j)}(hjh]hstruct crypto_kpp *tfm}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMhjubj)}(hhh]jP)}(h tfm handleh]h tfm handle}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhMhjubj)}(hX``const void *buffer`` Buffer holding the packet representation of the private key. The structure of the packet key depends on the particular KPP implementation. Packing and unpacking helpers are provided for ECDH and DH (see the respective header files for those implementations). h](j)}(h``const void *buffer``h]j)}(hjh]hconst void *buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMhjubj)}(hhh]jP)}(hXBuffer holding the packet representation of the private key. The structure of the packet key depends on the particular KPP implementation. Packing and unpacking helpers are provided for ECDH and DH (see the respective header files for those implementations).h]hXBuffer holding the packet representation of the private key. The structure of the packet key depends on the particular KPP implementation. Packing and unpacking helpers are provided for ECDH and DH (see the respective header files for those implementations).}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhMhjubj)}(h>``unsigned int len`` Length of the packet private key buffer. h](j)}(h``unsigned int len``h]j)}(hj h]hunsigned int len}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMhjubj)}(hhh]jP)}(h(Length of the packet private key buffer.h]h(Length of the packet private key buffer.}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj hMhj!ubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhj hMhjubeh}(h]h ]h"]h$]h&]uh1jhjsubjP)}(h**Description**h]jV)}(hjFh]h Description}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjDubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM hjsubjP)}(hreftypejz reftargetjmodnameN classnameNj~j)}j]j)}jzjsb c.crypto_kpp_generate_public_keyasbuh1hhjubh)}(h h]h }(hj-hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hj;hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hreqh]hreq}(hjHhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM5ubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjhhhjhM5ubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhM5hjhhubj1)}(hhh]jP)}(hInvoke kpp operationh]hInvoke kpp operation}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM)hjohhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhM5ubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjjEjjFjGjHuh1hhhhj hNhNubjJ)}(hXz**Parameters** ``struct kpp_request *req`` kpp key request **Description** Function invokes the specific kpp operation for generating the public part for a given kpp algorithm. To generate a private key, the caller should use a random number generator. The output of the requested length serves as the private key. **Return** zero on success; error code in case of errorh](jP)}(h**Parameters**h]jV)}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM-hjubj)}(hhh]j)}(h,``struct kpp_request *req`` kpp key request h](j)}(h``struct kpp_request *req``h]j)}(hjh]hstruct kpp_request *req}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM1hjubj)}(hhh]jP)}(hkpp key requesth]hkpp key request}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhM1hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM1hjubah}(h]h ]h"]h$]h&]uh1jhjubjP)}(h**Description**h]jV)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM3hjubjP)}(heFunction invokes the specific kpp operation for generating the public part for a given kpp algorithm.h]heFunction invokes the specific kpp operation for generating the public part for a given kpp algorithm.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM*hjubjP)}(hTo generate a private key, the caller should use a random number generator. The output of the requested length serves as the private key.h]hTo generate a private key, the caller should use a random number generator. The output of the requested length serves as the private key.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM-hjubjP)}(h **Return**h]jV)}(hj$h]hReturn}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj"ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM0hjubjP)}(h,zero on success; error code in case of errorh]h,zero on success; error code in case of error}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM3hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ-crypto_kpp_compute_shared_secret (C function)"c.crypto_kpp_compute_shared_secrethNtauh1hhj hhhNhNubh)}(hhh](h)}(h>int crypto_kpp_compute_shared_secret (struct kpp_request *req)h]h)}(h=int crypto_kpp_compute_shared_secret(struct kpp_request *req)h](j)}(hinth]hint}(hjihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjehhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMFubh)}(h h]h }(hjxhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjehhhjwhMFubh)}(h crypto_kpp_compute_shared_secreth]j)}(h crypto_kpp_compute_shared_secreth]h crypto_kpp_compute_shared_secret}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ](jjeh"]h$]h&]jjuh1hhjehhhjwhMFubj)}(h(struct kpp_request *req)h]j)}(hstruct kpp_request *reqh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h kpp_requesth]h kpp_request}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]j)}jzjsb"c.crypto_kpp_compute_shared_secretasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hreqh]hreq}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjehhhjwhMFubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjahhhjwhMFubah}(h]j\ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjwhMFhj^hhubj1)}(hhh]jP)}(hInvoke kpp operationh]hInvoke kpp operation}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM=hj&hhubah}(h]h ]h"]h$]h&]uh1j0hj^hhhjwhMFubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjAjEjAjFjGjHuh1hhhhj hNhNubjJ)}(h**Parameters** ``struct kpp_request *req`` kpp key request **Description** Function invokes the specific kpp operation for computing the shared secret for a given kpp algorithm. **Return** zero on success; error code in case of errorh](jP)}(h**Parameters**h]jV)}(hjKh]h Parameters}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjIubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMAhjEubj)}(hhh]j)}(h,``struct kpp_request *req`` kpp key request h](j)}(h``struct kpp_request *req``h]j)}(hjjh]hstruct kpp_request *req}(hjlhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjhubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMBhjdubj)}(hhh]jP)}(hkpp key requesth]hkpp key request}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhMBhjubah}(h]h ]h"]h$]h&]uh1jhjdubeh}(h]h ]h"]h$]h&]uh1jhjhMBhjaubah}(h]h ]h"]h$]h&]uh1jhjEubjP)}(h**Description**h]jV)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMDhjEubjP)}(hfFunction invokes the specific kpp operation for computing the shared secret for a given kpp algorithm.h]hfFunction invokes the specific kpp operation for computing the shared secret for a given kpp algorithm.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhM>hjEubjP)}(h **Return**h]jV)}(hjh]hReturn}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMAhjEubjP)}(h,zero on success; error code in case of errorh]h,zero on success; error code in case of error}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMDhjEubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČcrypto_kpp_maxsize (C function)c.crypto_kpp_maxsizehNtauh1hhj hhhNhNubh)}(hhh](h)}(h8unsigned int crypto_kpp_maxsize (struct crypto_kpp *tfm)h]h)}(h7unsigned int crypto_kpp_maxsize(struct crypto_kpp *tfm)h](j)}(hunsignedh]hunsigned}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMWubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhjhMWubj)}(hinth]hint}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhjhMWubh)}(h h]h }(hj<hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhjhMWubh)}(hcrypto_kpp_maxsizeh]j)}(hcrypto_kpp_maxsizeh]hcrypto_kpp_maxsize}(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjJubah}(h]h ](jjeh"]h$]h&]jjuh1hhj hhhjhMWubj)}(h(struct crypto_kpp *tfm)h]j)}(hstruct crypto_kpp *tfmh](h)}(hhh]hstruct}(hjjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjfubh)}(h h]h }(hjwhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjfubh)}(hhh]j)}(h crypto_kpph]h crypto_kpp}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]j)}jzjPsbc.crypto_kpp_maxsizeasbuh1hhjfubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjfubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjfubj)}(htfmh]htfm}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjfubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjbubah}(h]h ]h"]h$]h&]jjuh1jhj hhhjhMWubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj hhhjhMWubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhMWhjhhubj1)}(hhh]jP)}(hGet len for output bufferh]hGet len for output buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hNhMNhjhhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhMWubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjjEjjFjGjHuh1hhhhj hNhNubjJ)}(hXa**Parameters** ``struct crypto_kpp *tfm`` KPP tfm handle allocated with crypto_alloc_kpp() **Description** Function returns the output buffer size required for a given key. Function assumes that the key is already set in the transformation. If this function is called without a setkey or with a failed setkey, you will end up in a NULL dereference.h](jP)}(h**Parameters**h]jV)}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMRhj ubj)}(hhh]j)}(hL``struct crypto_kpp *tfm`` KPP tfm handle allocated with crypto_alloc_kpp() h](j)}(h``struct crypto_kpp *tfm``h]j)}(hj.h]hstruct crypto_kpp *tfm}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj,ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMUhj(ubj)}(hhh]jP)}(h0KPP tfm handle allocated with crypto_alloc_kpp()h]h0KPP tfm handle allocated with crypto_alloc_kpp()}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjChMUhjDubah}(h]h ]h"]h$]h&]uh1jhj(ubeh}(h]h ]h"]h$]h&]uh1jhjChMUhj%ubah}(h]h ]h"]h$]h&]uh1jhj ubjP)}(h**Description**h]jV)}(hjih]h Description}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjgubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMWhj ubjP)}(hFunction returns the output buffer size required for a given key. Function assumes that the key is already set in the transformation. If this function is called without a setkey or with a failed setkey, you will end up in a NULL dereference.h]hFunction returns the output buffer size required for a given key. Function assumes that the key is already set in the transformation. If this function is called without a setkey or with a failed setkey, you will end up in a NULL dereference.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:13: ./include/crypto/kpp.hhMOhj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubeh}(h]0key-agreement-protocol-primitives-kpp-cipher-apiah ]h"]2key-agreement protocol primitives (kpp) cipher apiah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(h=Key-agreement Protocol Primitives (KPP) Cipher Request Handleh]h=Key-agreement Protocol Primitives (KPP) Cipher Request Handle}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČkpp_request_alloc (C function)c.kpp_request_allochNtauh1hhjhhhNhNubh)}(hhh](h)}(hJstruct kpp_request * kpp_request_alloc (struct crypto_kpp *tfm, gfp_t gfp)h]h)}(hHstruct kpp_request *kpp_request_alloc(struct crypto_kpp *tfm, gfp_t gfp)h](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhjhKubh)}(hhh]j)}(h kpp_requesth]h kpp_request}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]j)}jzkpp_request_allocsbc.kpp_request_allocasbuh1hhjhhhjhKubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhjhKubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjhKubh)}(hkpp_request_alloch]j)}(hjh]hkpp_request_alloc}(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj"ubah}(h]h ](jjeh"]h$]h&]jjuh1hhjhhhjhKubj)}(h#(struct crypto_kpp *tfm, gfp_t gfp)h](j)}(hstruct crypto_kpp *tfmh](h)}(hhh]hstruct}(hjAhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubh)}(h h]h }(hjNhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubh)}(hhh]j)}(h crypto_kpph]h crypto_kpp}(hj_hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjamodnameN classnameNj~j)}j]jc.kpp_request_allocasbuh1hhj=ubh)}(h h]h }(hj}hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubj)}(htfmh]htfm}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj9ubj)}(h gfp_t gfph](h)}(hhh]j)}(hgfp_th]hgfp_t}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]jc.kpp_request_allocasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hgfph]hgfp}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj9ubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjhhhjhKubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhKhjhhubj1)}(hhh]jP)}(hallocates kpp requesth]hallocates kpp request}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhKubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj"jEj"jFjGjHuh1hhhhjhNhNubjJ)}(h**Parameters** ``struct crypto_kpp *tfm`` KPP tfm handle allocated with crypto_alloc_kpp() ``gfp_t gfp`` allocation flags **Return** allocated handle in case of success or NULL in case of an error.h](jP)}(h**Parameters**h]jV)}(hj,h]h Parameters}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj*ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj&ubj)}(hhh](j)}(hL``struct crypto_kpp *tfm`` KPP tfm handle allocated with crypto_alloc_kpp() h](j)}(h``struct crypto_kpp *tfm``h]j)}(hjKh]hstruct crypto_kpp *tfm}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjEubj)}(hhh]jP)}(h0KPP tfm handle allocated with crypto_alloc_kpp()h]h0KPP tfm handle allocated with crypto_alloc_kpp()}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj`hKhjaubah}(h]h ]h"]h$]h&]uh1jhjEubeh}(h]h ]h"]h$]h&]uh1jhj`hKhjBubj)}(h``gfp_t gfp`` allocation flags h](j)}(h ``gfp_t gfp``h]j)}(hjh]h gfp_t gfp}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj~ubj)}(hhh]jP)}(hallocation flagsh]hallocation flags}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhj~ubeh}(h]h ]h"]h$]h&]uh1jhjhKhjBubeh}(h]h ]h"]h$]h&]uh1jhj&ubjP)}(h **Return**h]jV)}(hjh]hReturn}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj&ubjP)}(h@allocated handle in case of success or NULL in case of an error.h]h@allocated handle in case of success or NULL in case of an error.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj&ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČkpp_request_free (C function)c.kpp_request_freehNtauh1hhjhhhNhNubh)}(hhh](h)}(h/void kpp_request_free (struct kpp_request *req)h]h)}(h.void kpp_request_free(struct kpp_request *req)h](j)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhjhKubh)}(hkpp_request_freeh]j)}(hkpp_request_freeh]hkpp_request_free}(hj%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!ubah}(h]h ](jjeh"]h$]h&]jjuh1hhjhhhjhKubj)}(h(struct kpp_request *req)h]j)}(hstruct kpp_request *reqh](h)}(hhh]hstruct}(hjAhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubh)}(h h]h }(hjNhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubh)}(hhh]j)}(h kpp_requesth]h kpp_request}(hj_hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjamodnameN classnameNj~j)}j]j)}jzj'sbc.kpp_request_freeasbuh1hhj=ubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubj)}(hreqh]hreq}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj9ubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjhhhjhKubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhKhjhhubj1)}(hhh]jP)}(hzeroize and free kpp requesth]hzeroize and free kpp request}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhKubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjjEjjFjGjHuh1hhhhjhNhNubjJ)}(h=**Parameters** ``struct kpp_request *req`` request to freeh](jP)}(h**Parameters**h]jV)}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]j)}(h+``struct kpp_request *req`` request to freeh](j)}(h``struct kpp_request *req``h]j)}(hjh]hstruct kpp_request *req}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hrequest to freeh]hrequest to free}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ%kpp_request_set_callback (C function)c.kpp_request_set_callbackhNtauh1hhjhhhNhNubh)}(hhh](h)}(hgvoid kpp_request_set_callback (struct kpp_request *req, u32 flgs, crypto_completion_t cmpl, void *data)h]h)}(hfvoid kpp_request_set_callback(struct kpp_request *req, u32 flgs, crypto_completion_t cmpl, void *data)h](j)}(hvoidh]hvoid}(hj_hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[hhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKubh)}(h h]h }(hjnhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj[hhhjmhKubh)}(hkpp_request_set_callbackh]j)}(hkpp_request_set_callbackh]hkpp_request_set_callback}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj[hhhjmhKubj)}(hI(struct kpp_request *req, u32 flgs, crypto_completion_t cmpl, void *data)h](j)}(hstruct kpp_request *reqh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h kpp_requesth]h kpp_request}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]j)}jzjsbc.kpp_request_set_callbackasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hreqh]hreq}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hu32 flgsh](h)}(hhh]j)}(hu32h]hu32}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]jc.kpp_request_set_callbackasbuh1hhj ubh)}(h h]h }(hj/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hflgsh]hflgs}(hj=hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hcrypto_completion_t cmplh](h)}(hhh]j)}(hcrypto_completion_th]hcrypto_completion_t}(hjYhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj[modnameN classnameNj~j)}j]jc.kpp_request_set_callbackasbuh1hhjRubh)}(h h]h }(hjwhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjRubj)}(hcmplh]hcmpl}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjRubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h void *datah](j)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hdatah]hdata}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhj[hhhjmhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjWhhhjmhKubah}(h]jRah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjmhKhjThhubj1)}(hhh]jP)}(hSets an asynchronous callback.h]hSets an asynchronous callback.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j0hjThhhjmhKubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj jEj jFjGjHuh1hhhhjhNhNubjJ)}(hXr**Parameters** ``struct kpp_request *req`` request that the callback will be set for ``u32 flgs`` specify for instance if the operation may backlog ``crypto_completion_t cmpl`` callback which will be called ``void *data`` private data used by the caller **Description** Callback will be called when an asynchronous operation on a given request is finished.h](jP)}(h**Parameters**h]jV)}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj ubj)}(hhh](j)}(hF``struct kpp_request *req`` request that the callback will be set for h](j)}(h``struct kpp_request *req``h]j)}(hj2h]hstruct kpp_request *req}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj,ubj)}(hhh]jP)}(h)request that the callback will be set forh]h)request that the callback will be set for}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjGhKhjHubah}(h]h ]h"]h$]h&]uh1jhj,ubeh}(h]h ]h"]h$]h&]uh1jhjGhKhj)ubj)}(h?``u32 flgs`` specify for instance if the operation may backlog h](j)}(h ``u32 flgs``h]j)}(hjkh]hu32 flgs}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjeubj)}(hhh]jP)}(h1specify for instance if the operation may backlogh]h1specify for instance if the operation may backlog}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjeubeh}(h]h ]h"]h$]h&]uh1jhjhKhj)ubj)}(h;``crypto_completion_t cmpl`` callback which will be called h](j)}(h``crypto_completion_t cmpl``h]j)}(hjh]hcrypto_completion_t cmpl}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hcallback which will be calledh]hcallback which will be called}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhj)ubj)}(h/``void *data`` private data used by the caller h](j)}(h``void *data``h]j)}(hjh]h void *data}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hprivate data used by the callerh]hprivate data used by the caller}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhj)ubeh}(h]h ]h"]h$]h&]uh1jhj ubjP)}(h**Description**h]jV)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj ubjP)}(hVCallback will be called when an asynchronous operation on a given request is finished.h]hVCallback will be called when an asynchronous operation on a given request is finished.}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ"kpp_request_set_input (C function)c.kpp_request_set_inputhNtauh1hhjhhhNhNubh)}(hhh](h)}(hgvoid kpp_request_set_input (struct kpp_request *req, struct scatterlist *input, unsigned int input_len)h]h)}(hfvoid kpp_request_set_input(struct kpp_request *req, struct scatterlist *input, unsigned int input_len)h](j)}(hvoidh]hvoid}(hj]hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjYhhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKubh)}(h h]h }(hjlhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjYhhhjkhKubh)}(hkpp_request_set_inputh]j)}(hkpp_request_set_inputh]hkpp_request_set_input}(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjzubah}(h]h ](jjeh"]h$]h&]jjuh1hhjYhhhjkhKubj)}(hL(struct kpp_request *req, struct scatterlist *input, unsigned int input_len)h](j)}(hstruct kpp_request *reqh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h kpp_requesth]h kpp_request}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]j)}jzjsbc.kpp_request_set_inputasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hreqh]hreq}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct scatterlist *inputh](h)}(hhh]hstruct}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h scatterlisth]h scatterlist}(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj,modnameN classnameNj~j)}j]jc.kpp_request_set_inputasbuh1hhjubh)}(h h]h }(hjHhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjVhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hinputh]hinput}(hjchhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hunsigned int input_lenh](j)}(hunsignedh]hunsigned}(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjxubj)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjxubj)}(h input_lenh]h input_len}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjYhhhjkhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjUhhhjkhKubah}(h]jPah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjkhKhjRhhubj1)}(hhh]jP)}(hSets input bufferh]hSets input buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j0hjRhhhjkhKubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjjEjjFjGjHuh1hhhhjhNhNubjJ)}(h**Parameters** ``struct kpp_request *req`` kpp request ``struct scatterlist *input`` ptr to input scatter list ``unsigned int input_len`` size of the input scatter list **Description** Sets parameters required by generate_public_keyh](jP)}(h**Parameters**h]jV)}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh](j)}(h(``struct kpp_request *req`` kpp request h](j)}(h``struct kpp_request *req``h]j)}(hjh]hstruct kpp_request *req}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(h kpp requesth]h kpp request}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj4hKhj5ubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhj4hKhjubj)}(h8``struct scatterlist *input`` ptr to input scatter list h](j)}(h``struct scatterlist *input``h]j)}(hjXh]hstruct scatterlist *input}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjVubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjRubj)}(hhh]jP)}(hptr to input scatter listh]hptr to input scatter list}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjmhKhjnubah}(h]h ]h"]h$]h&]uh1jhjRubeh}(h]h ]h"]h$]h&]uh1jhjmhKhjubj)}(h:``unsigned int input_len`` size of the input scatter list h](j)}(h``unsigned int input_len``h]j)}(hjh]hunsigned int input_len}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(hsize of the input scatter listh]hsize of the input scatter list}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubeh}(h]h ]h"]h$]h&]uh1jhjubjP)}(h**Description**h]jV)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubjP)}(h/Sets parameters required by generate_public_keyh]h/Sets parameters required by generate_public_key}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ#kpp_request_set_output (C function)c.kpp_request_set_outputhNtauh1hhjhhhNhNubh)}(hhh](h)}(hjvoid kpp_request_set_output (struct kpp_request *req, struct scatterlist *output, unsigned int output_len)h]h)}(hivoid kpp_request_set_output(struct kpp_request *req, struct scatterlist *output, unsigned int output_len)h](j)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhjhKubh)}(hkpp_request_set_outputh]j)}(hkpp_request_set_outputh]hkpp_request_set_output}(hj2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj hhhjhKubj)}(hN(struct kpp_request *req, struct scatterlist *output, unsigned int output_len)h](j)}(hstruct kpp_request *reqh](h)}(hhh]hstruct}(hjNhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjJubh)}(h h]h }(hj[hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjJubh)}(hhh]j)}(h kpp_requesth]h kpp_request}(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjiubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjnmodnameN classnameNj~j)}j]j)}jzj4sbc.kpp_request_set_outputasbuh1hhjJubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjJubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjJubj)}(hreqh]hreq}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjJubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjFubj)}(hstruct scatterlist *outputh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h scatterlisth]h scatterlist}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetjmodnameN classnameNj~j)}j]jc.kpp_request_set_outputasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(houtputh]houtput}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjFubj)}(hunsigned int output_lenh](j)}(hunsignedh]hunsigned}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubh)}(h h]h }(hj>hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubj)}(hinth]hint}(hjLhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubh)}(h h]h }(hjZhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubj)}(h output_lenh]h output_len}(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjFubeh}(h]h ]h"]h$]h&]jjuh1jhj hhhjhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj hhhjhKubah}(h]jah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhKhjhhubj1)}(hhh]jP)}(hSets output bufferh]hSets output buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhKubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjjEjjFjGjHuh1hhhhjhNhNubjJ)}(h**Parameters** ``struct kpp_request *req`` kpp request ``struct scatterlist *output`` ptr to output scatter list ``unsigned int output_len`` size of the output scatter list **Description** Sets parameters required by kpp operationh](jP)}(h**Parameters**h]jV)}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh](j)}(h(``struct kpp_request *req`` kpp request h](j)}(h``struct kpp_request *req``h]j)}(hjh]hstruct kpp_request *req}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubj)}(hhh]jP)}(h kpp requesth]h kpp request}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubj)}(h:``struct scatterlist *output`` ptr to output scatter list h](j)}(h``struct scatterlist *output``h]j)}(hj h]hstruct scatterlist *output}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj ubj)}(hhh]jP)}(hptr to output scatter listh]hptr to output scatter list}(hj% hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj! hKhj" ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj! hKhjubj)}(h<``unsigned int output_len`` size of the output scatter list h](j)}(h``unsigned int output_len``h]j)}(hjE h]hunsigned int output_len}(hjG hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjC ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhj? ubj)}(hhh]jP)}(hsize of the output scatter listh]hsize of the output scatter list}(hj^ hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjZ hKhj[ ubah}(h]h ]h"]h$]h&]uh1jhj? ubeh}(h]h ]h"]h$]h&]uh1jhjZ hKhjubeh}(h]h ]h"]h$]h&]uh1jhjubjP)}(h**Description**h]jV)}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj~ ubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubjP)}(h)Sets parameters required by kpp operationh]h)Sets parameters required by kpp operation}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhS/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:19: ./include/crypto/kpp.hhKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhjhhhNhNubeh}(h];key-agreement-protocol-primitives-kpp-cipher-request-handleah ]h"]=key-agreement protocol primitives (kpp) cipher request handleah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(hECDH Helper Functionsh]hECDH Helper Functions}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hhhhhKubjP)}(h_To use ECDH with the KPP cipher API, the following data structure and functions should be used.h]h_To use ECDH with the KPP cipher API, the following data structure and functions should be used.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:25: ./include/crypto/ecdh.hhK hj hhubjP)}(hRThe ECC curves known to the ECDH implementation are specified in this header file.h]hRThe ECC curves known to the ECDH implementation are specified in this header file.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:25: ./include/crypto/ecdh.hhKhj hhubjP)}(hTo use ECDH with KPP, the following functions should be used to operate on an ECDH private key. The packet private key that can be set with the KPP API function call of crypto_kpp_set_secret.h]hTo use ECDH with KPP, the following functions should be used to operate on an ECDH private key. The packet private key that can be set with the KPP API function call of crypto_kpp_set_secret.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:25: ./include/crypto/ecdh.hhKhj hhubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČecdh (C struct)c.ecdhhNtauh1hhj hhhNhNubh)}(hhh](h)}(hecdhh]h)}(h struct ecdhh](h)}(hhh]hstruct}(hj !hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj!hhhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKubh)}(h h]h }(hj!hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj!hhhj!hKubh)}(hecdhh]j)}(hj!h]hecdh}(hj+!hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'!ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj!hhhj!hKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj!hhhj!hKubah}(h]j ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj!hKhj!hhubj1)}(hhh]jP)}(hdefine an ECDH private keyh]hdefine an ECDH private key}(hjM!hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK hjJ!hhubah}(h]h ]h"]h$]h&]uh1j0hj!hhhj!hKubeh}(h]h ](j>structeh"]h$]h&]jCj>jDje!jEje!jFjGjHuh1hhhhj hNhNubjJ)}(h**Definition**:: struct ecdh { char *key; unsigned short key_size; }; **Members** ``key`` Private ECDH key ``key_size`` Size of the private ECDH keyh](jP)}(h**Definition**::h](jV)}(h**Definition**h]h Definition}(hjq!hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjm!ubh:}(hjm!hhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK$hji!ubjq)}(hreftypejz reftargetj"modnameN classnameNj~j)}j]j)}jzj"sbc.crypto_ecdh_key_lenasbuh1hhj"ubh)}(h h]h }(hj"hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj"ubj)}(hjh]h*}(hj #hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj"ubj)}(hparamsh]hparams}(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj"ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj"ubah}(h]h ]h"]h$]h&]jjuh1jhjI"hhhj["hK4ubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjE"hhhj["hK4ubah}(h]j@"ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj["hK4hjB"hhubj1)}(hhh]jP)}(h'Obtain the size of the private ECDH keyh]h'Obtain the size of the private ECDH key}(hjD#hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK+hjA#hhubah}(h]h ]h"]h$]h&]uh1j0hjB"hhhj["hK4ubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj\#jEj\#jFjGjHuh1hhhhj hNhNubjJ)}(hX$**Parameters** ``const struct ecdh *params`` private ECDH key **Description** This function returns the packet ECDH key size. A caller can use that with the provided ECDH private key reference to obtain the required memory size to hold a packet key. **Return** size of the key in bytesh](jP)}(h**Parameters**h]jV)}(hjf#h]h Parameters}(hjh#hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjd#ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK/hj`#ubj)}(hhh]j)}(h/``const struct ecdh *params`` private ECDH key h](j)}(h``const struct ecdh *params``h]j)}(hj#h]hconst struct ecdh *params}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj#ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK,hj#ubj)}(hhh]jP)}(hprivate ECDH keyh]hprivate ECDH key}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj#hK,hj#ubah}(h]h ]h"]h$]h&]uh1jhj#ubeh}(h]h ]h"]h$]h&]uh1jhj#hK,hj|#ubah}(h]h ]h"]h$]h&]uh1jhj`#ubjP)}(h**Description**h]jV)}(hj#h]h Description}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj#ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK.hj`#ubjP)}(hThis function returns the packet ECDH key size. A caller can use that with the provided ECDH private key reference to obtain the required memory size to hold a packet key.h]hThis function returns the packet ECDH key size. A caller can use that with the provided ECDH private key reference to obtain the required memory size to hold a packet key.}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK.hj`#ubjP)}(h **Return**h]jV)}(hj#h]hReturn}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj#ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK2hj`#ubjP)}(hsize of the key in bytesh]hsize of the key in bytes}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK2hj`#ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ#crypto_ecdh_encode_key (C function)c.crypto_ecdh_encode_keyhNtauh1hhj hhhNhNubh)}(hhh](h)}(hNint crypto_ecdh_encode_key (char *buf, unsigned int len, const struct ecdh *p)h]h)}(hMint crypto_ecdh_encode_key(char *buf, unsigned int len, const struct ecdh *p)h](j)}(hinth]hint}(hj,$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj($hhhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKCubh)}(h h]h }(hj;$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj($hhhj:$hKCubh)}(hcrypto_ecdh_encode_keyh]j)}(hcrypto_ecdh_encode_keyh]hcrypto_ecdh_encode_key}(hjM$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjI$ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj($hhhj:$hKCubj)}(h3(char *buf, unsigned int len, const struct ecdh *p)h](j)}(h char *bufh](j)}(hcharh]hchar}(hji$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhje$ubh)}(h h]h }(hjw$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhje$ubj)}(hjh]h*}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhje$ubj)}(hbufh]hbuf}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhje$ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhja$ubj)}(hunsigned int lenh](j)}(hunsignedh]hunsigned}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj$ubh)}(h h]h }(hj$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubj)}(hinth]hint}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj$ubh)}(h h]h }(hj$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubj)}(hlenh]hlen}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj$ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhja$ubj)}(hconst struct ecdh *ph](h)}(hjh]hconst}(hj$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubh)}(h h]h }(hj %hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubh)}(hhh]hstruct}(hj%hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubh)}(h h]h }(hj$%hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubh)}(hhh]j)}(hecdhh]hecdh}(hj5%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj2%ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj7%modnameN classnameNj~j)}j]j)}jzjO$sbc.crypto_ecdh_encode_keyasbuh1hhj$ubh)}(h h]h }(hjU%hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubj)}(hjh]h*}(hjc%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj$ubj)}(hjh]hp}(hjp%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj$ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhja$ubeh}(h]h ]h"]h$]h&]jjuh1jhj($hhhj:$hKCubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj$$hhhj:$hKCubah}(h]j$ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj:$hKChj!$hhubj1)}(hhh]jP)}(hencode the private keyh]hencode the private key}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK7hj%hhubah}(h]h ]h"]h$]h&]uh1j0hj!$hhhj:$hKCubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj%jEj%jFjGjHuh1hhhhj hNhNubjJ)}(hX**Parameters** ``char *buf`` Buffer allocated by the caller to hold the packet ECDH private key. The buffer should be at least crypto_ecdh_key_len bytes in size. ``unsigned int len`` Length of the packet private key buffer ``const struct ecdh *p`` Buffer with the caller-specified private key **Description** The ECDH implementations operate on a packet representation of the private key. **Return** -EINVAL if buffer has insufficient size, 0 on successh](jP)}(h**Parameters**h]jV)}(hj%h]h Parameters}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj%ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK;hj%ubj)}(hhh](j)}(h``char *buf`` Buffer allocated by the caller to hold the packet ECDH private key. The buffer should be at least crypto_ecdh_key_len bytes in size. h](j)}(h ``char *buf``h]j)}(hj%h]h char *buf}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj%ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK:hj%ubj)}(hhh]jP)}(hBuffer allocated by the caller to hold the packet ECDH private key. The buffer should be at least crypto_ecdh_key_len bytes in size.h]hBuffer allocated by the caller to hold the packet ECDH private key. The buffer should be at least crypto_ecdh_key_len bytes in size.}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK8hj%ubah}(h]h ]h"]h$]h&]uh1jhj%ubeh}(h]h ]h"]h$]h&]uh1jhj%hK:hj%ubj)}(h=``unsigned int len`` Length of the packet private key buffer h](j)}(h``unsigned int len``h]j)}(hj&h]hunsigned int len}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj&ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK;hj&ubj)}(hhh]jP)}(h'Length of the packet private key bufferh]h'Length of the packet private key buffer}(hj-&hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj)&hK;hj*&ubah}(h]h ]h"]h$]h&]uh1jhj&ubeh}(h]h ]h"]h$]h&]uh1jhj)&hK;hj%ubj)}(hF``const struct ecdh *p`` Buffer with the caller-specified private key h](j)}(h``const struct ecdh *p``h]j)}(hjM&h]hconst struct ecdh *p}(hjO&hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjK&ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKhj%ubjP)}(hOThe ECDH implementations operate on a packet representation of the private key.h]hOThe ECDH implementations operate on a packet representation of the private key.}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhK>hj%ubjP)}(h **Return**h]jV)}(hj&h]hReturn}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj&ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKAhj%ubjP)}(h5-EINVAL if buffer has insufficient size, 0 on successh]h5-EINVAL if buffer has insufficient size, 0 on success}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKAhj%ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ#crypto_ecdh_decode_key (C function)c.crypto_ecdh_decode_keyhNtauh1hhj hhhNhNubh)}(hhh](h)}(hNint crypto_ecdh_decode_key (const char *buf, unsigned int len, struct ecdh *p)h]h)}(hMint crypto_ecdh_decode_key(const char *buf, unsigned int len, struct ecdh *p)h](j)}(hinth]hint}(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&hhhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKQubh)}(h h]h }(hj'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj&hhhj'hKQubh)}(hcrypto_ecdh_decode_keyh]j)}(hcrypto_ecdh_decode_keyh]hcrypto_ecdh_decode_key}(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj&hhhj'hKQubj)}(h3(const char *buf, unsigned int len, struct ecdh *p)h](j)}(hconst char *bufh](h)}(hjh]hconst}(hj1'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj-'ubh)}(h h]h }(hj>'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj-'ubj)}(hcharh]hchar}(hjL'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-'ubh)}(h h]h }(hjZ'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj-'ubj)}(hjh]h*}(hjh'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-'ubj)}(hbufh]hbuf}(hju'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-'ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj)'ubj)}(hunsigned int lenh](j)}(hunsignedh]hunsigned}(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubh)}(h h]h }(hj'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj'ubj)}(hinth]hint}(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubh)}(h h]h }(hj'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj'ubj)}(hlenh]hlen}(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj)'ubj)}(hstruct ecdh *ph](h)}(hhh]hstruct}(hj'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj'ubh)}(h h]h }(hj'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj'ubh)}(hhh]j)}(hecdhh]hecdh}(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj'modnameN classnameNj~j)}j]j)}jzj'sbc.crypto_ecdh_decode_keyasbuh1hhj'ubh)}(h h]h }(hj(hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj'ubj)}(hjh]h*}(hj+(hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubj)}(hjh]hp}(hj8(hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj)'ubeh}(h]h ]h"]h$]h&]jjuh1jhj&hhhj'hKQubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj&hhhj'hKQubah}(h]j&ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj'hKQhj&hhubj1)}(hhh]jP)}(hdecode a private keyh]hdecode a private key}(hja(hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKFhj^(hhubah}(h]h ]h"]h$]h&]uh1j0hj&hhhj'hKQubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjy(jEjy(jFjGjHuh1hhhhj hNhNubjJ)}(hX**Parameters** ``const char *buf`` Buffer holding a packet key that should be decoded ``unsigned int len`` Length of the packet private key buffer ``struct ecdh *p`` Buffer allocated by the caller that is filled with the unpacked ECDH private key. **Description** The unpacking obtains the private key by pointing **p** to the correct location in **buf**. Thus, both pointers refer to the same memory. **Return** -EINVAL if buffer has insufficient size, 0 on successh](jP)}(h**Parameters**h]jV)}(hj(h]h Parameters}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj(ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKJhj}(ubj)}(hhh](j)}(hG``const char *buf`` Buffer holding a packet key that should be decoded h](j)}(h``const char *buf``h]j)}(hj(h]hconst char *buf}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKGhj(ubj)}(hhh]jP)}(h2Buffer holding a packet key that should be decodedh]h2Buffer holding a packet key that should be decoded}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj(hKGhj(ubah}(h]h ]h"]h$]h&]uh1jhj(ubeh}(h]h ]h"]h$]h&]uh1jhj(hKGhj(ubj)}(h=``unsigned int len`` Length of the packet private key buffer h](j)}(h``unsigned int len``h]j)}(hj(h]hunsigned int len}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKHhj(ubj)}(hhh]jP)}(h'Length of the packet private key bufferh]h'Length of the packet private key buffer}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj(hKHhj(ubah}(h]h ]h"]h$]h&]uh1jhj(ubeh}(h]h ]h"]h$]h&]uh1jhj(hKHhj(ubj)}(he``struct ecdh *p`` Buffer allocated by the caller that is filled with the unpacked ECDH private key. h](j)}(h``struct ecdh *p``h]j)}(hj)h]hstruct ecdh *p}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)ubah}(h]h ]h"]h$]h&]uh1jhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKJhj)ubj)}(hhh]jP)}(hQBuffer allocated by the caller that is filled with the unpacked ECDH private key.h]hQBuffer allocated by the caller that is filled with the unpacked ECDH private key.}(hj-)hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKIhj*)ubah}(h]h ]h"]h$]h&]uh1jhj)ubeh}(h]h ]h"]h$]h&]uh1jhj))hKJhj(ubeh}(h]h ]h"]h$]h&]uh1jhj}(ubjP)}(h**Description**h]jV)}(hjP)h]h Description}(hjR)hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjN)ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKLhj}(ubjP)}(hThe unpacking obtains the private key by pointing **p** to the correct location in **buf**. Thus, both pointers refer to the same memory.h](h2The unpacking obtains the private key by pointing }(hjf)hhhNhNubjV)}(h**p**h]hp}(hjn)hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjf)ubh to the correct location in }(hjf)hhhNhNubjV)}(h**buf**h]hbuf}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjf)ubh/. Thus, both pointers refer to the same memory.}(hjf)hhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKLhj}(ubjP)}(h **Return**h]jV)}(hj)h]hReturn}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj)ubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKOhj}(ubjP)}(h5-EINVAL if buffer has insufficient size, 0 on successh]h5-EINVAL if buffer has insufficient size, 0 on success}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhT/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:28: ./include/crypto/ecdh.hhKOhj}(ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj hhhNhNubeh}(h]ecdh-helper-functionsah ]h"]ecdh helper functionsah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(hDH Helper Functionsh]hDH Helper Functions}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj)hhhhhK ubjP)}(h]To use DH with the KPP cipher API, the following data structure and functions should be used.h]h]To use DH with the KPP cipher API, the following data structure and functions should be used.}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:34: ./include/crypto/dh.hhK hj)hhubjP)}(hTo use DH with KPP, the following functions should be used to operate on a DH private key. The packet private key that can be set with the KPP API function call of crypto_kpp_set_secret.h]hTo use DH with KPP, the following functions should be used to operate on a DH private key. The packet private key that can be set with the KPP API function call of crypto_kpp_set_secret.}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:34: ./include/crypto/dh.hhKhj)hhubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ dh (C struct)c.dhhNtauh1hhj)hhhNhNubh)}(hhh](h)}(hdhh]h)}(h struct dhh](h)}(hhh]hstruct}(hj*hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj*hhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hxhKubh)}(h h]h }(hj%*hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj*hhhj$*hKubh)}(hdhh]j)}(hj*h]hdh}(hj7*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3*ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj*hhhj$*hKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj*hhhj$*hKubah}(h]j *ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj$*hKhj *hhubj1)}(hhh]jP)}(hdefine a DH private keyh]hdefine a DH private key}(hjY*hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhjV*hhubah}(h]h ]h"]h$]h&]uh1j0hj *hhhj$*hKubeh}(h]h ](j>structeh"]h$]h&]jCj>jDjq*jEjq*jFjGjHuh1hhhhj)hNhNubjJ)}(hX**Definition**:: struct dh { const void *key; const void *p; const void *g; unsigned int key_size; unsigned int p_size; unsigned int g_size; }; **Members** ``key`` Private DH key ``p`` Diffie-Hellman parameter P ``g`` Diffie-Hellman generator G ``key_size`` Size of the private DH key ``p_size`` Size of DH parameter P ``g_size`` Size of DH generator Gh](jP)}(h**Definition**::h](jV)}(h**Definition**h]h Definition}(hj}*hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjy*ubh:}(hjy*hhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhju*ubjq)}(hstruct dh { const void *key; const void *p; const void *g; unsigned int key_size; unsigned int p_size; unsigned int g_size; };h]hstruct dh { const void *key; const void *p; const void *g; unsigned int key_size; unsigned int p_size; unsigned int g_size; };}hj*sbah}(h]h ]h"]h$]h&]jjuh1jphR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhju*ubjP)}(h **Members**h]jV)}(hj*h]hMembers}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj*ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK&hju*ubj)}(hhh](j)}(h``key`` Private DH key h](j)}(h``key``h]j)}(hj*h]hkey}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhj*ubj)}(hhh]jP)}(hPrivate DH keyh]hPrivate DH key}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj*hKhj*ubah}(h]h ]h"]h$]h&]uh1jhj*ubeh}(h]h ]h"]h$]h&]uh1jhj*hKhj*ubj)}(h!``p`` Diffie-Hellman parameter P h](j)}(h``p``h]j)}(hj*h]hp}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhj*ubj)}(hhh]jP)}(hDiffie-Hellman parameter Ph]hDiffie-Hellman parameter P}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj+hKhj+ubah}(h]h ]h"]h$]h&]uh1jhj*ubeh}(h]h ]h"]h$]h&]uh1jhj+hKhj*ubj)}(h!``g`` Diffie-Hellman generator G h](j)}(h``g``h]j)}(hj8+h]hg}(hj:+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj6+ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhj2+ubj)}(hhh]jP)}(hDiffie-Hellman generator Gh]hDiffie-Hellman generator G}(hjQ+hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjM+hKhjN+ubah}(h]h ]h"]h$]h&]uh1jhj2+ubeh}(h]h ]h"]h$]h&]uh1jhjM+hKhj*ubj)}(h(``key_size`` Size of the private DH key h](j)}(h ``key_size``h]j)}(hjq+h]hkey_size}(hjs+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjo+ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhjk+ubj)}(hhh]jP)}(hSize of the private DH keyh]hSize of the private DH key}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj+hKhj+ubah}(h]h ]h"]h$]h&]uh1jhjk+ubeh}(h]h ]h"]h$]h&]uh1jhj+hKhj*ubj)}(h"``p_size`` Size of DH parameter P h](j)}(h ``p_size``h]j)}(hj+h]hp_size}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhj+ubj)}(hhh]jP)}(hSize of DH parameter Ph]hSize of DH parameter P}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj+hKhj+ubah}(h]h ]h"]h$]h&]uh1jhj+ubeh}(h]h ]h"]h$]h&]uh1jhj+hKhj*ubj)}(h!``g_size`` Size of DH generator Gh](j)}(h ``g_size``h]j)}(hj+h]hg_size}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhj+ubj)}(hhh]jP)}(hSize of DH generator Gh]hSize of DH generator G}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKhj+ubah}(h]h ]h"]h$]h&]uh1jhj+ubeh}(h]h ]h"]h$]h&]uh1jhj+hKhj*ubeh}(h]h ]h"]h$]h&]uh1jhju*ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj)hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČcrypto_dh_key_len (C function)c.crypto_dh_key_lenhNtauh1hhj)hhhNhNubh)}(hhh](h)}(h8unsigned int crypto_dh_key_len (const struct dh *params)h]h)}(h7unsigned int crypto_dh_key_len(const struct dh *params)h](j)}(hunsignedh]hunsigned}(hj=,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj9,hhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK3ubh)}(h h]h }(hjL,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj9,hhhjK,hK3ubj)}(hinth]hint}(hjZ,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj9,hhhjK,hK3ubh)}(h h]h }(hjh,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj9,hhhjK,hK3ubh)}(hcrypto_dh_key_lenh]j)}(hcrypto_dh_key_lenh]hcrypto_dh_key_len}(hjz,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjv,ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj9,hhhjK,hK3ubj)}(h(const struct dh *params)h]j)}(hconst struct dh *paramsh](h)}(hjh]hconst}(hj,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubh)}(h h]h }(hj,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubh)}(hhh]hstruct}(hj,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubh)}(h h]h }(hj,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubh)}(hhh]j)}(hdhh]hdh}(hj,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj,modnameN classnameNj~j)}j]j)}jzj|,sbc.crypto_dh_key_lenasbuh1hhj,ubh)}(h h]h }(hj,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubj)}(hjh]h*}(hj,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubj)}(hparamsh]hparams}(hj -hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj,ubah}(h]h ]h"]h$]h&]jjuh1jhj9,hhhjK,hK3ubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj5,hhhjK,hK3ubah}(h]j0,ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjK,hK3hj2,hhubj1)}(hhh]jP)}(h%Obtain the size of the private DH keyh]h%Obtain the size of the private DH key}(hj4-hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK*hj1-hhubah}(h]h ]h"]h$]h&]uh1j0hj2,hhhjK,hK3ubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjL-jEjL-jFjGjHuh1hhhhj)hNhNubjJ)}(hX**Parameters** ``const struct dh *params`` private DH key **Description** This function returns the packet DH key size. A caller can use that with the provided DH private key reference to obtain the required memory size to hold a packet key. **Return** size of the key in bytesh](jP)}(h**Parameters**h]jV)}(hjV-h]h Parameters}(hjX-hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjT-ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK.hjP-ubj)}(hhh]j)}(h+``const struct dh *params`` private DH key h](j)}(h``const struct dh *params``h]j)}(hju-h]hconst struct dh *params}(hjw-hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjs-ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK+hjo-ubj)}(hhh]jP)}(hprivate DH keyh]hprivate DH key}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj-hK+hj-ubah}(h]h ]h"]h$]h&]uh1jhjo-ubeh}(h]h ]h"]h$]h&]uh1jhj-hK+hjl-ubah}(h]h ]h"]h$]h&]uh1jhjP-ubjP)}(h**Description**h]jV)}(hj-h]h Description}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj-ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK-hjP-ubjP)}(hThis function returns the packet DH key size. A caller can use that with the provided DH private key reference to obtain the required memory size to hold a packet key.h]hThis function returns the packet DH key size. A caller can use that with the provided DH private key reference to obtain the required memory size to hold a packet key.}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK-hjP-ubjP)}(h **Return**h]jV)}(hj-h]hReturn}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj-ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK1hjP-ubjP)}(hsize of the key in bytesh]hsize of the key in bytes}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK1hjP-ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj)hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ!crypto_dh_encode_key (C function)c.crypto_dh_encode_keyhNtauh1hhj)hhhNhNubh)}(hhh](h)}(hOint crypto_dh_encode_key (char *buf, unsigned int len, const struct dh *params)h]h)}(hNint crypto_dh_encode_key(char *buf, unsigned int len, const struct dh *params)h](j)}(hinth]hint}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.hhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKBubh)}(h h]h }(hj+.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.hhhj*.hKBubh)}(hcrypto_dh_encode_keyh]j)}(hcrypto_dh_encode_keyh]hcrypto_dh_encode_key}(hj=.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj9.ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj.hhhj*.hKBubj)}(h6(char *buf, unsigned int len, const struct dh *params)h](j)}(h char *bufh](j)}(hcharh]hchar}(hjY.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjU.ubh)}(h h]h }(hjg.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjU.ubj)}(hjh]h*}(hju.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjU.ubj)}(hbufh]hbuf}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjU.ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjQ.ubj)}(hunsigned int lenh](j)}(hunsignedh]hunsigned}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.ubh)}(h h]h }(hj.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubj)}(hinth]hint}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.ubh)}(h h]h }(hj.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubj)}(hlenh]hlen}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjQ.ubj)}(hconst struct dh *paramsh](h)}(hjh]hconst}(hj.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubh)}(h h]h }(hj.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubh)}(hhh]hstruct}(hj/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubh)}(h h]h }(hj/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubh)}(hhh]j)}(hdhh]hdh}(hj%/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj"/ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj'/modnameN classnameNj~j)}j]j)}jzj?.sbc.crypto_dh_encode_keyasbuh1hhj.ubh)}(h h]h }(hjE/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj.ubj)}(hjh]h*}(hjS/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.ubj)}(hparamsh]hparams}(hj`/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj.ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjQ.ubeh}(h]h ]h"]h$]h&]jjuh1jhj.hhhj*.hKBubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj.hhhj*.hKBubah}(h]j.ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj*.hKBhj.hhubj1)}(hhh]jP)}(hencode the private keyh]hencode the private key}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK6hj/hhubah}(h]h ]h"]h$]h&]uh1j0hj.hhhj*.hKBubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDj/jEj/jFjGjHuh1hhhhj)hNhNubjJ)}(hX**Parameters** ``char *buf`` Buffer allocated by the caller to hold the packet DH private key. The buffer should be at least crypto_dh_key_len bytes in size. ``unsigned int len`` Length of the packet private key buffer ``const struct dh *params`` Buffer with the caller-specified private key **Description** The DH implementations operate on a packet representation of the private key. **Return** -EINVAL if buffer has insufficient size, 0 on successh](jP)}(h**Parameters**h]jV)}(hj/h]h Parameters}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj/ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK:hj/ubj)}(hhh](j)}(h``char *buf`` Buffer allocated by the caller to hold the packet DH private key. The buffer should be at least crypto_dh_key_len bytes in size. h](j)}(h ``char *buf``h]j)}(hj/h]h char *buf}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK9hj/ubj)}(hhh]jP)}(hBuffer allocated by the caller to hold the packet DH private key. The buffer should be at least crypto_dh_key_len bytes in size.h]hBuffer allocated by the caller to hold the packet DH private key. The buffer should be at least crypto_dh_key_len bytes in size.}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK7hj/ubah}(h]h ]h"]h$]h&]uh1jhj/ubeh}(h]h ]h"]h$]h&]uh1jhj/hK9hj/ubj)}(h=``unsigned int len`` Length of the packet private key buffer h](j)}(h``unsigned int len``h]j)}(hj0h]hunsigned int len}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK:hj/ubj)}(hhh]jP)}(h'Length of the packet private key bufferh]h'Length of the packet private key buffer}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj0hK:hj0ubah}(h]h ]h"]h$]h&]uh1jhj/ubeh}(h]h ]h"]h$]h&]uh1jhj0hK:hj/ubj)}(hI``const struct dh *params`` Buffer with the caller-specified private key h](j)}(h``const struct dh *params``h]j)}(hj>0h]hconst struct dh *params}(hj@0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj<0ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK;hj80ubj)}(hhh]jP)}(h,Buffer with the caller-specified private keyh]h,Buffer with the caller-specified private key}(hjW0hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhjS0hK;hjT0ubah}(h]h ]h"]h$]h&]uh1jhj80ubeh}(h]h ]h"]h$]h&]uh1jhjS0hK;hj/ubeh}(h]h ]h"]h$]h&]uh1jhj/ubjP)}(h**Description**h]jV)}(hjy0h]h Description}(hj{0hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjw0ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK=hj/ubjP)}(hMThe DH implementations operate on a packet representation of the private key.h]hMThe DH implementations operate on a packet representation of the private key.}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK=hj/ubjP)}(h **Return**h]jV)}(hj0h]hReturn}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj0ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK@hj/ubjP)}(h5-EINVAL if buffer has insufficient size, 0 on successh]h5-EINVAL if buffer has insufficient size, 0 on success}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhK@hj/ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj)hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ!crypto_dh_decode_key (C function)c.crypto_dh_decode_keyhNtauh1hhj)hhhNhNubh)}(hhh](h)}(hOint crypto_dh_decode_key (const char *buf, unsigned int len, struct dh *params)h]h)}(hNint crypto_dh_decode_key(const char *buf, unsigned int len, struct dh *params)h](j)}(hinth]hint}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0hhhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKPubh)}(h h]h }(hj0hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj0hhhj0hKPubh)}(hcrypto_dh_decode_keyh]j)}(hcrypto_dh_decode_keyh]hcrypto_dh_decode_key}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj0hhhj0hKPubj)}(h6(const char *buf, unsigned int len, struct dh *params)h](j)}(hconst char *bufh](h)}(hjh]hconst}(hj"1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubh)}(h h]h }(hj/1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubj)}(hcharh]hchar}(hj=1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubh)}(h h]h }(hjK1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubj)}(hjh]h*}(hjY1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubj)}(hbufh]hbuf}(hjf1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj1ubj)}(hunsigned int lenh](j)}(hunsignedh]hunsigned}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj{1ubh)}(h h]h }(hj1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{1ubj)}(hinth]hint}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj{1ubh)}(h h]h }(hj1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{1ubj)}(hlenh]hlen}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj{1ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj1ubj)}(hstruct dh *paramsh](h)}(hhh]hstruct}(hj1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubh)}(h h]h }(hj1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubh)}(hhh]j)}(hdhh]hdh}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubah}(h]h ]h"]h$]h&] refdomainj>reftypejz reftargetj1modnameN classnameNj~j)}j]j)}jzj1sbc.crypto_dh_decode_keyasbuh1hhj1ubh)}(h h]h }(hj2hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubj)}(hjh]h*}(hj2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubj)}(hparamsh]hparams}(hj)2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj1ubeh}(h]h ]h"]h$]h&]jjuh1jhj0hhhj0hKPubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hj0hhhj0hKPubah}(h]j0ah ](j(j)eh"]h$]h&]j-j.)j/huh1hhj0hKPhj0hhubj1)}(hhh]jP)}(hdecode a private keyh]hdecode a private key}(hjS2hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKEhjP2hhubah}(h]h ]h"]h$]h&]uh1j0hj0hhhj0hKPubeh}(h]h ](j>functioneh"]h$]h&]jCj>jDjk2jEjk2jFjGjHuh1hhhhj)hNhNubjJ)}(hX**Parameters** ``const char *buf`` Buffer holding a packet key that should be decoded ``unsigned int len`` Length of the packet private key buffer ``struct dh *params`` Buffer allocated by the caller that is filled with the unpacked DH private key. **Description** The unpacking obtains the private key by pointing **p** to the correct location in **buf**. Thus, both pointers refer to the same memory. **Return** -EINVAL if buffer has insufficient size, 0 on successh](jP)}(h**Parameters**h]jV)}(hju2h]h Parameters}(hjw2hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjs2ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKIhjo2ubj)}(hhh](j)}(hG``const char *buf`` Buffer holding a packet key that should be decoded h](j)}(h``const char *buf``h]j)}(hj2h]hconst char *buf}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj2ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKFhj2ubj)}(hhh]jP)}(h2Buffer holding a packet key that should be decodedh]h2Buffer holding a packet key that should be decoded}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj2hKFhj2ubah}(h]h ]h"]h$]h&]uh1jhj2ubeh}(h]h ]h"]h$]h&]uh1jhj2hKFhj2ubj)}(h=``unsigned int len`` Length of the packet private key buffer h](j)}(h``unsigned int len``h]j)}(hj2h]hunsigned int len}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj2ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKGhj2ubj)}(hhh]jP)}(h'Length of the packet private key bufferh]h'Length of the packet private key buffer}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhj2hKGhj2ubah}(h]h ]h"]h$]h&]uh1jhj2ubeh}(h]h ]h"]h$]h&]uh1jhj2hKGhj2ubj)}(hf``struct dh *params`` Buffer allocated by the caller that is filled with the unpacked DH private key. h](j)}(h``struct dh *params``h]j)}(hj3h]hstruct dh *params}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj3ubah}(h]h ]h"]h$]h&]uh1jhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKIhj3ubj)}(hhh]jP)}(hOBuffer allocated by the caller that is filled with the unpacked DH private key.h]hOBuffer allocated by the caller that is filled with the unpacked DH private key.}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKHhj3ubah}(h]h ]h"]h$]h&]uh1jhj3ubeh}(h]h ]h"]h$]h&]uh1jhj3hKIhj2ubeh}(h]h ]h"]h$]h&]uh1jhjo2ubjP)}(h**Description**h]jV)}(hjB3h]h Description}(hjD3hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj@3ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKKhjo2ubjP)}(hThe unpacking obtains the private key by pointing **p** to the correct location in **buf**. Thus, both pointers refer to the same memory.h](h2The unpacking obtains the private key by pointing }(hjX3hhhNhNubjV)}(h**p**h]hp}(hj`3hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjX3ubh to the correct location in }(hjX3hhhNhNubjV)}(h**buf**h]hbuf}(hjr3hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhjX3ubh/. Thus, both pointers refer to the same memory.}(hjX3hhhNhNubeh}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKKhjo2ubjP)}(h **Return**h]jV)}(hj3h]hReturn}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jUhj3ubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKNhjo2ubjP)}(h5-EINVAL if buffer has insufficient size, 0 on successh]h5-EINVAL if buffer has insufficient size, 0 on success}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jOhR/var/lib/git/docbuild/linux/Documentation/crypto/api-kpp:37: ./include/crypto/dh.hhKNhjo2ubeh}(h]h ] kernelindentah"]h$]h&]uh1jIhj)hhhNhNubeh}(h]dh-helper-functionsah ]h"]dh helper functionsah$]h&]uh1hhhhhhhhK ubeh}(h]h ]h"]h$]h&]sourcehuh1hcurrent_sourceN current_lineNsettingsdocutils.frontendValues)}(hN generatorN datestampN source_linkN source_urlN toc_backlinksentryfootnote_backlinksK sectnum_xformKstrip_commentsNstrip_elements_with_classesN strip_classesN report_levelK halt_levelKexit_status_levelKdebugNwarning_streamN tracebackinput_encoding utf-8-siginput_encoding_error_handlerstrictoutput_encodingutf-8output_encoding_error_handlerj3error_encodingutf-8error_encoding_error_handlerbackslashreplace language_codeenrecord_dependenciesNconfigN id_prefixhauto_id_prefixid dump_settingsNdump_internalsNdump_transformsNdump_pseudo_xmlNexpose_internalsNstrict_visitorN_disable_configN_sourceh _destinationN _config_files]7/var/lib/git/docbuild/linux/Documentation/docutils.confafile_insertion_enabled raw_enabledKline_length_limitM'pep_referencesN pep_base_urlhttps://peps.python.org/pep_file_url_templatepep-%04drfc_referencesN rfc_base_url&https://datatracker.ietf.org/doc/html/ tab_widthKtrim_footnote_reference_spacesyntax_highlightlong smart_quotessmartquotes_locales]character_level_inline_markupdoctitle_xform docinfo_xformKsectsubtitle_xform image_loadinglinkembed_stylesheetcloak_email_addressessection_self_linkenvNubreporterNindirect_targets]substitution_defs}substitution_names}refnames}refids}nameids}(j jjjj j j)j)j3j3u nametypes}(j jj j)j3uh}(jhhhjjjZj_jjjj j8j=jI jN j j jjj\jajj j jjjjjjRjWjPjUjj j)j j j!j@"jE"j$j$$j&j&j3j)j *j*j0,j5,j.j.j0j0u footnote_refs} citation_refs} autofootnotes]autofootnote_refs]symbol_footnotes]symbol_footnote_refs] footnotes] citations]autofootnote_startKsymbol_footnote_startK id_counter collectionsCounter}Rparse_messages]transform_messages] transformerN include_log] decorationNhhub.