sphinx.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-rngmodnameN classnameN refexplicitutagnamehhh ubh)}(hhh]hChinese (Traditional)}hh2sbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/zh_TW/crypto/api-rngmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hItalian}hhFsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/it_IT/crypto/api-rngmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hJapanese}hhZsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/ja_JP/crypto/api-rngmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hKorean}hhnsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/ko_KR/crypto/api-rngmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hSpanish}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget"/translations/sp_SP/crypto/api-rngmodnameN classnameN refexplicituh1hhh ubeh}(h]h ]h"]h$]h&]current_languageEnglishuh1h hh _documenthsourceNlineNubhsection)}(hhh](htitle)}(h#Random Number Algorithm Definitionsh]h#Random Number Algorithm Definitions}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhhh ubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetjC modnameN classnameNjpjs)}jv]jy)}jlj sbc.crypto_rng_generateasbuh1hhj ubh)}(h h]h }(hja hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hjh]h*}(hjo 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)}(h const u8 *srch](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]j)}(hu8h]hu8}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetj modnameN classnameNjpjs)}jv]j] c.crypto_rng_generateasbuh1hhj ubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubj)}(hjh]h*}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(hsrch]hsrc}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubj)}(hunsigned int slenh](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)}(hslenh]hslen}(hj= hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubj)}(hu8 *dsth](h)}(hhh]j)}(hu8h]hu8}(hjY hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjV ubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetj[ modnameN classnameNjpjs)}jv]j] c.crypto_rng_generateasbuh1hhjR ubh)}(h h]h }(hjw hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjR ubj)}(hjh]h*}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjR ubj)}(hdsth]hdst}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjR ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubj)}(hunsigned int dlenh](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)}(hdlenh]hdlen}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubeh}(h]h ]h"]h$]h&]jjuh1jhj 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]j6)}(hget random numberh]hget random number}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj hhubah}(h]h ]h"]h$]h&]uh1j0hj hhhj hKubeh}(h]h ](jOfunctioneh"]h$]h&]jTjOjUj% jVj% jWjXjYuh1hhhhjhNhNubj[)}(hX**Parameters** ``struct crypto_rng *tfm`` cipher handle ``const u8 *src`` Input buffer holding additional data, may be NULL ``unsigned int slen`` Length of additional data ``u8 *dst`` output buffer holding the random numbers ``unsigned int dlen`` length of the output buffer **Description** This function fills the caller-allocated buffer with random numbers using the random number generator referenced by the cipher handle. **Return** 0 function was successful; < 0 if an error occurredh](j6)}(h**Parameters**h]je)}(hj/ h]h Parameters}(hj1 hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhj- ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj) ubj)}(hhh](j)}(h)``struct crypto_rng *tfm`` cipher handle h](j)}(h``struct crypto_rng *tfm``h]j)}(hjN h]hstruct crypto_rng *tfm}(hjP hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjL ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjH ubj)}(hhh]j6)}(h cipher handleh]h cipher handle}(hjg hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjc hKhjd ubah}(h]h ]h"]h$]h&]uh1jhjH ubeh}(h]h ]h"]h$]h&]uh1jhjc hKhjE ubj)}(hD``const u8 *src`` Input buffer holding additional data, may be NULL h](j)}(h``const u8 *src``h]j)}(hj h]h const u8 *src}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj ubj)}(hhh]j6)}(h1Input buffer holding additional data, may be NULLh]h1Input buffer holding additional data, may be NULL}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hj hKhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hKhjE ubj)}(h0``unsigned int slen`` Length of additional data h](j)}(h``unsigned int slen``h]j)}(hj h]hunsigned int slen}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj ubj)}(hhh]j6)}(hLength of additional datah]hLength of additional data}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hj hKhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hKhjE ubj)}(h5``u8 *dst`` output buffer holding the random numbers h](j)}(h ``u8 *dst``h]j)}(hj h]hu8 *dst}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj ubj)}(hhh]j6)}(h(output buffer holding the random numbersh]h(output buffer holding the random numbers}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hj hKhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hKhjE ubj)}(h2``unsigned int dlen`` length of the output buffer h](j)}(h``unsigned int dlen``h]j)}(hj2 h]hunsigned int dlen}(hj4 hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0 ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj, ubj)}(hhh]j6)}(hlength of the output bufferh]hlength of the output buffer}(hjK hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjG hKhjH ubah}(h]h ]h"]h$]h&]uh1jhj, ubeh}(h]h ]h"]h$]h&]uh1jhjG hKhjE ubeh}(h]h ]h"]h$]h&]uh1jhj) ubj6)}(h**Description**h]je)}(hjm h]h Description}(hjo hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhjk ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj) ubj6)}(hThis function fills the caller-allocated buffer with random numbers using the random number generator referenced by the cipher handle.h]hThis function fills the caller-allocated buffer with random numbers using the random number generator referenced by the cipher handle.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj) ubj6)}(h **Return**h]je)}(hj h]hReturn}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhj ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj) ubj6)}(h30 function was successful; < 0 if an error occurredh]h30 function was successful; < 0 if an error occurred}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj) ubeh}(h]h ] kernelindentah"]h$]h&]uh1jZhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ!crypto_rng_get_bytes (C function)c.crypto_rng_get_byteshNtauh1hhjhhhNhNubh)}(hhh](h)}(hOint crypto_rng_get_bytes (struct crypto_rng *tfm, u8 *rdata, unsigned int dlen)h]h)}(hNint crypto_rng_get_bytes(struct crypto_rng *tfm, u8 *rdata, unsigned int dlen)h](j)}(hinth]hint}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKubh)}(h h]h }(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj hhhj hKubh)}(hcrypto_rng_get_bytesh]j)}(hcrypto_rng_get_bytesh]hcrypto_rng_get_bytes}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubah}(h]h ](jjeh"]h$]h&]jjuh1hhj hhhj hKubj)}(h6(struct crypto_rng *tfm, u8 *rdata, unsigned int dlen)h](j)}(hstruct crypto_rng *tfmh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hj#hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h crypto_rngh]h crypto_rng}(hj4hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetj6modnameN classnameNjpjs)}jv]jy)}jlj sbc.crypto_rng_get_bytesasbuh1hhjubh)}(h h]h }(hjThhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjbhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(htfmh]htfm}(hjohhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h u8 *rdatah](h)}(hhh]j)}(hu8h]hu8}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetjmodnameN classnameNjpjs)}jv]jPc.crypto_rng_get_bytesasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hrdatah]hrdata}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hunsigned int dlenh](j)}(hunsignedh]hunsigned}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hdlenh]hdlen}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhj 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]j6)}(hget random numberh]hget random number}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj<hhubah}(h]h ]h"]h$]h&]uh1j0hj hhhj hKubeh}(h]h ](jOfunctioneh"]h$]h&]jTjOjUjWjVjWjWjXjYuh1hhhhjhNhNubj[)}(hX**Parameters** ``struct crypto_rng *tfm`` cipher handle ``u8 *rdata`` output buffer holding the random numbers ``unsigned int dlen`` length of the output buffer **Description** This function fills the caller-allocated buffer with random numbers using the random number generator referenced by the cipher handle. **Return** 0 function was successful; < 0 if an error occurredh](j6)}(h**Parameters**h]je)}(hjah]h Parameters}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1jdhj_ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj[ubj)}(hhh](j)}(h)``struct crypto_rng *tfm`` cipher handle h](j)}(h``struct crypto_rng *tfm``h]j)}(hjh]hstruct crypto_rng *tfm}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj~ubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjzubj)}(hhh]j6)}(h cipher handleh]h cipher handle}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjzubeh}(h]h ]h"]h$]h&]uh1jhjhKhjwubj)}(h7``u8 *rdata`` output buffer holding the random numbers h](j)}(h ``u8 *rdata``h]j)}(hjh]h u8 *rdata}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjubj)}(hhh]j6)}(h(output buffer holding the random numbersh]h(output buffer holding the random numbers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjwubj)}(h2``unsigned int dlen`` length of the output buffer h](j)}(h``unsigned int dlen``h]j)}(hjh]hunsigned int dlen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjubj)}(hhh]j6)}(hlength of the output bufferh]hlength of the output buffer}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjwubeh}(h]h ]h"]h$]h&]uh1jhj[ubj6)}(h**Description**h]je)}(hj-h]h Description}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhj+ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj[ubj6)}(hThis function fills the caller-allocated buffer with random numbers using the random number generator referenced by the cipher handle.h]hThis function fills the caller-allocated buffer with random numbers using the random number generator referenced by the cipher handle.}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj[ubj6)}(h **Return**h]je)}(hjTh]hReturn}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1jdhjRubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj[ubj6)}(h30 function was successful; < 0 if an error occurredh]h30 function was successful; < 0 if an error occurred}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj[ubeh}(h]h ] kernelindentah"]h$]h&]uh1jZhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČcrypto_rng_reset (C function)c.crypto_rng_resethNtauh1hhjhhhNhNubh)}(hhh](h)}(hPint crypto_rng_reset (struct crypto_rng *tfm, const u8 *seed, unsigned int slen)h]h)}(hOint crypto_rng_reset(struct crypto_rng *tfm, const u8 *seed, unsigned int slen)h](j)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhhhjhKubh)}(hcrypto_rng_reseth]j)}(hcrypto_rng_reseth]hcrypto_rng_reset}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ](jjeh"]h$]h&]jjuh1hhjhhhjhKubj)}(h;(struct crypto_rng *tfm, const u8 *seed, unsigned int slen)h](j)}(hstruct crypto_rng *tfmh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h crypto_rngh]h crypto_rng}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetjmodnameN classnameNjpjs)}jv]jy)}jljsbc.crypto_rng_resetasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hj"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(htfmh]htfm}(hj/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hconst u8 *seedh](h)}(hjh]hconst}(hjHhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjDubh)}(h h]h }(hjUhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjDubh)}(hhh]j)}(hu8h]hu8}(hjfhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetjhmodnameN classnameNjpjs)}jv]jc.crypto_rng_resetasbuh1hhjDubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjDubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjDubj)}(hseedh]hseed}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjDubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hunsigned int slenh](j)}(hunsignedh]hunsigned}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hslenh]hslen}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(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]j6)}(hre-initialize the RNGh]hre-initialize the RNG}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j0hjhhhjhKubeh}(h]h ](jOfunctioneh"]h$]h&]jTjOjUj2jVj2jWjXjYuh1hhhhjhNhNubj[)}(hX$**Parameters** ``struct crypto_rng *tfm`` cipher handle ``const u8 *seed`` seed input data ``unsigned int slen`` length of the seed input data **Description** The reset function completely re-initializes the random number generator referenced by the cipher handle by clearing the current state. The new state is initialized with the caller provided seed or automatically, depending on the random number generator type (the ANSI X9.31 RNG requires caller-provided seed, the SP800-90A DRBGs perform an automatic seeding). The seed is provided as a parameter to this function call. The provided seed should have the length of the seed size defined for the random number generator as defined by crypto_rng_seedsize. **Return** 0 if the setting of the key was successful; < 0 if an error occurredh](j6)}(h**Parameters**h]je)}(hj<h]h Parameters}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhj:ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj6ubj)}(hhh](j)}(h)``struct crypto_rng *tfm`` cipher handle h](j)}(h``struct crypto_rng *tfm``h]j)}(hj[h]hstruct crypto_rng *tfm}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjYubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjUubj)}(hhh]j6)}(h cipher handleh]h cipher handle}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjphKhjqubah}(h]h ]h"]h$]h&]uh1jhjUubeh}(h]h ]h"]h$]h&]uh1jhjphKhjRubj)}(h#``const u8 *seed`` seed input data h](j)}(h``const u8 *seed``h]j)}(hjh]hconst u8 *seed}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjubj)}(hhh]j6)}(hseed input datah]hseed input data}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjRubj)}(h4``unsigned int slen`` length of the seed input data h](j)}(h``unsigned int slen``h]j)}(hjh]hunsigned int slen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjubj)}(hhh]j6)}(hlength of the seed input datah]hlength of the seed input data}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjRubeh}(h]h ]h"]h$]h&]uh1jhj6ubj6)}(h**Description**h]je)}(hjh]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhjubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj6ubj6)}(hX(The reset function completely re-initializes the random number generator referenced by the cipher handle by clearing the current state. The new state is initialized with the caller provided seed or automatically, depending on the random number generator type (the ANSI X9.31 RNG requires caller-provided seed, the SP800-90A DRBGs perform an automatic seeding). The seed is provided as a parameter to this function call. The provided seed should have the length of the seed size defined for the random number generator as defined by crypto_rng_seedsize.h]hX(The reset function completely re-initializes the random number generator referenced by the cipher handle by clearing the current state. The new state is initialized with the caller provided seed or automatically, depending on the random number generator type (the ANSI X9.31 RNG requires caller-provided seed, the SP800-90A DRBGs perform an automatic seeding). The seed is provided as a parameter to this function call. The provided seed should have the length of the seed size defined for the random number generator as defined by crypto_rng_seedsize.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj6ubj6)}(h **Return**h]je)}(hj/h]hReturn}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jdhj-ubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj6ubj6)}(hD0 if the setting of the key was successful; < 0 if an error occurredh]hD0 if the setting of the key was successful; < 0 if an error occurred}(hjEhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj6ubeh}(h]h ] kernelindentah"]h$]h&]uh1jZhjhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](hČ crypto_rng_seedsize (C function)c.crypto_rng_seedsizehNtauh1hhjhhhNhNubh)}(hhh](h)}(h0int crypto_rng_seedsize (struct crypto_rng *tfm)h]h)}(h/int crypto_rng_seedsize(struct crypto_rng *tfm)h](j)}(hinth]hint}(hjthhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjphhhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjphhhjhKubh)}(hcrypto_rng_seedsizeh]j)}(hcrypto_rng_seedsizeh]hcrypto_rng_seedsize}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ](jjeh"]h$]h&]jjuh1hhjphhhjhKubj)}(h(struct crypto_rng *tfm)h]j)}(hstruct crypto_rng *tfmh](h)}(hhh]hstruct}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubh)}(hhh]j)}(h crypto_rngh]h crypto_rng}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&] refdomainjOreftypejl reftargetjmodnameN classnameNjpjs)}jv]jy)}jljsbc.crypto_rng_seedsizeasbuh1hhjubh)}(h h]h }(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubj)}(hjh]h*}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(htfmh]htfm}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjphhhjhKubeh}(h]h ]h"]h$]h&]jjj"uh1hj#j$hjlhhhjhKubah}(h]jgah ](j(j)eh"]h$]h&]j-j.)j/huh1hhjhKhjihhubj1)}(hhh]j6)}(hobtain seed size of RNGh]hobtain seed size of RNG}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhj1hhubah}(h]h ]h"]h$]h&]uh1j0hjihhhjhKubeh}(h]h ](jOfunctioneh"]h$]h&]jTjOjUjLjVjLjWjXjYuh1hhhhjhNhNubj[)}(hX**Parameters** ``struct crypto_rng *tfm`` cipher handle **Description** The function returns the seed size for the random number generator referenced by the cipher handle. This value may be zero if the random number generator does not implement or require a reseeding. For example, the SP800-90A DRBGs implement an automated reseeding after reaching a pre-defined threshold. **Return** seed size for the random number generatorh](j6)}(h**Parameters**h]je)}(hjVh]h Parameters}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jdhjTubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjPubj)}(hhh]j)}(h)``struct crypto_rng *tfm`` cipher handle h](j)}(h``struct crypto_rng *tfm``h]j)}(hjuh]hstruct crypto_rng *tfm}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjsubah}(h]h ]h"]h$]h&]uh1jhS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjoubj)}(hhh]j6)}(h cipher handleh]h cipher handle}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjoubeh}(h]h ]h"]h$]h&]uh1jhjhKhjlubah}(h]h ]h"]h$]h&]uh1jhjPubj6)}(h**Description**h]je)}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jdhjubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjPubj6)}(hX.The function returns the seed size for the random number generator referenced by the cipher handle. This value may be zero if the random number generator does not implement or require a reseeding. For example, the SP800-90A DRBGs implement an automated reseeding after reaching a pre-defined threshold.h]hX.The function returns the seed size for the random number generator referenced by the cipher handle. This value may be zero if the random number generator does not implement or require a reseeding. For example, the SP800-90A DRBGs implement an automated reseeding after reaching a pre-defined threshold.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjPubj6)}(h **Return**h]je)}(hjh]hReturn}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jdhjubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjPubj6)}(h)seed size for the random number generatorh]h)seed size for the random number generator}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j5hS/var/lib/git/docbuild/linux/Documentation/crypto/api-rng:13: ./include/crypto/rng.hhKhjPubeh}(h]h ] kernelindentah"]h$]h&]uh1jZhjhhhNhNubeh}(h]crypto-api-random-number-apiah ]h"]crypto api random number apiah$]h&]uh1hhhhhhhhKubeh}(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_handlerj.error_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}(jjjju nametypes}(jjuh}(jhhhjjj*j/jcjhjFjKj j j j jjjgjlu 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.