/
usr
/
src
/
kernels
/
4.18.0-553.157.1.el8_10.x86_64
/
include
/
crypto
/
/usr/src/kernels/4.18.0-553.157.1.el8_10.x86_64/include/crypto
mkdir
upload
Name
Size
Mode
Actions
internal/
-
0755
rm
acompress.h
8120
0644
edit
dl
rm
aead.h
18729
0644
edit
dl
rm
aes.h
1058
0644
edit
dl
rm
akcipher.h
11989
0644
edit
dl
rm
algapi.h
12163
0644
edit
dl
rm
arc4.h
484
0644
edit
dl
rm
authenc.h
845
0644
edit
dl
rm
b128ops.h
2471
0644
edit
dl
rm
blowfish.h
415
0644
edit
dl
rm
cast5.h
590
0644
edit
dl
rm
cast6.h
636
0644
edit
dl
rm
cast_common.h
232
0644
edit
dl
rm
cbc.h
3562
0644
edit
dl
rm
chacha20.h
638
0644
edit
dl
rm
cryptd.h
2562
0644
edit
dl
rm
crypto_wq.h
161
0644
edit
dl
rm
ctr.h
1666
0644
edit
dl
rm
des.h
1403
0644
edit
dl
rm
dh.h
2784
0644
edit
dl
rm
drbg.h
9160
0644
edit
dl
rm
ecdh.h
2733
0644
edit
dl
rm
engine.h
4202
0644
edit
dl
rm
gcm.h
140
0644
edit
dl
rm
gf128mul.h
9647
0644
edit
dl
rm
ghash.h
381
0644
edit
dl
rm
hash.h
33386
0644
edit
dl
rm
hash_info.h
1153
0644
edit
dl
rm
hmac.h
173
0644
edit
dl
rm
if_alg.h
7189
0644
edit
dl
rm
kpp.h
9926
0644
edit
dl
rm
md5.h
497
0644
edit
dl
rm
morus640_glue.h
4585
0644
edit
dl
rm
morus1280_glue.h
4647
0644
edit
dl
rm
morus_common.h
720
0644
edit
dl
rm
null.h
346
0644
edit
dl
rm
padlock.h
649
0644
edit
dl
rm
pcrypt.h
1435
0644
edit
dl
rm
pkcs7.h
1388
0644
edit
dl
rm
poly1305.h
920
0644
edit
dl
rm
public_key.h
2126
0644
edit
dl
rm
rng.h
6820
0644
edit
dl
rm
scatterwalk.h
3755
0644
edit
dl
rm
serpent.h
712
0644
edit
dl
rm
sha.h
4350
0644
edit
dl
rm
sha1_base.h
2532
0644
edit
dl
rm
sha3.h
879
0644
edit
dl
rm
sha256_base.h
2629
0644
edit
dl
rm
sha512_base.h
3271
0644
edit
dl
rm
skcipher.h
23381
0644
edit
dl
rm
sm3.h
833
0644
edit
dl
rm
sm3_base.h
3024
0644
edit
dl
rm
sm4.h
754
0644
edit
dl
rm
speck.h
1357
0644
edit
dl
rm
twofish.h
755
0644
edit
dl
rm
xts.h
1385
0644
edit
dl
rm
Edit:
/usr/src/kernels/4.18.0-553.157.1.el8_10.x86_64/include/crypto/dh.h
(2784B)
/* * Diffie-Hellman secret to be used with kpp API along with helper functions * * Copyright (c) 2016, Intel Corporation * Authors: Salvatore Benedetto <salvatore.benedetto@intel.com> * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the Free * Software Foundation; either version 2 of the License, or (at your option) * any later version. * */ #ifndef _CRYPTO_DH_ #define _CRYPTO_DH_ /** * DOC: DH Helper Functions * * To use DH with the KPP cipher API, the following data structure and * functions should be used. * * To 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. */ /** * struct dh - define a DH private key * * @key: Private DH key * @p: Diffie-Hellman parameter P * @q: Diffie-Hellman parameter Q * @g: Diffie-Hellman generator G * @key_size: Size of the private DH key * @p_size: Size of DH parameter P * @q_size: Size of DH parameter Q * @g_size: Size of DH generator G */ struct dh { void *key; void *p; void *q; void *g; unsigned int key_size; unsigned int p_size; unsigned int q_size; unsigned int g_size; }; /** * crypto_dh_key_len() - Obtain the size of the private DH key * @params: private DH key * * 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 bytes */ unsigned int crypto_dh_key_len(const struct dh *params); /** * crypto_dh_encode_key() - encode the private key * @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. * @len: Length of the packet private key buffer * @params: Buffer with the caller-specified private key * * The DH implementations operate on a packet representation of the private * key. * * Return: -EINVAL if buffer has insufficient size, 0 on success */ int crypto_dh_encode_key(char *buf, unsigned int len, const struct dh *params); /** * crypto_dh_decode_key() - decode a private key * @buf: Buffer holding a packet key that should be decoded * @len: Length of the packet private key buffer * @params: Buffer allocated by the caller that is filled with the * unpacked DH private key. * * 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 success */ int crypto_dh_decode_key(const char *buf, unsigned int len, struct dh *params); #endif
Save
cmd:
run