Home
last modified time | relevance | path

Searched refs:secret (Results 1 – 25 of 54) sorted by relevance

123

/linux/fs/crypto/
H A Dkeyring.c43 static void wipe_master_key_secret(struct fscrypt_master_key_secret *secret) in wipe_master_key_secret() argument
45 memzero_explicit(secret, sizeof(*secret)); in wipe_master_key_secret()
430 struct fscrypt_master_key_secret *secret, in add_new_master_key() argument
457 move_master_key_secret(&mk->mk_secret, secret); in add_new_master_key()
475 struct fscrypt_master_key_secret *secret) in add_existing_master_key() argument
508 move_master_key_secret(&mk->mk_secret, secret); in add_existing_master_key()
516 struct fscrypt_master_key_secret *secret, in do_add_master_key() argument
530 err = add_new_master_key(sb, secret, mk_spec); in do_add_master_key()
537 err = add_existing_master_key(mk, secret); in do_add_master_key()
546 err = add_new_master_key(sb, secret, mk_spec); in do_add_master_key()
[all …]
/linux/include/crypto/
H A Dcurve25519.h22 const u8 secret[at_least CURVE25519_KEY_SIZE],
27 const u8 secret[at_least CURVE25519_KEY_SIZE]);
30 curve25519_clamp_secret(u8 secret[at_least CURVE25519_KEY_SIZE]) in curve25519_clamp_secret()
32 secret[0] &= 248; in curve25519_clamp_secret()
33 secret[31] = (secret[31] & 127) | 64; in curve25519_clamp_secret()
37 curve25519_generate_secret(u8 secret[at_least CURVE25519_KEY_SIZE]) in curve25519_generate_secret()
39 get_random_bytes_wait(secret, CURVE25519_KEY_SIZE); in curve25519_generate_secret()
40 curve25519_clamp_secret(secret); in curve25519_generate_secret()
/linux/lib/crypto/
H A Dcurve25519.c26 const u8 secret[CURVE25519_KEY_SIZE], in curve25519_arch()
29 curve25519_generic(mypublic, secret, basepoint); in curve25519_arch()
33 const u8 secret[CURVE25519_KEY_SIZE]) in curve25519_base_arch()
35 curve25519_generic(pub, secret, curve25519_base_point); in curve25519_base_arch()
41 const u8 secret[CURVE25519_KEY_SIZE], in curve25519()
44 curve25519_arch(mypublic, secret, basepoint); in curve25519()
52 const u8 secret[CURVE25519_KEY_SIZE]) in curve25519_generate_public()
54 if (unlikely(!crypto_memneq(secret, curve25519_null_point, in curve25519_generate_public()
57 curve25519_base_arch(pub, secret); in curve25519_generate_public()
/linux/crypto/
H A Decdh_helper.c37 struct kpp_secret secret = { in crypto_ecdh_encode_key() local
48 ptr = ecdh_pack_data(ptr, &secret, sizeof(secret)); in crypto_ecdh_encode_key()
60 struct kpp_secret secret; in crypto_ecdh_decode_key() local
65 ptr = ecdh_unpack_data(&secret, ptr, sizeof(secret)); in crypto_ecdh_decode_key()
66 if (secret.type != CRYPTO_KPP_SECRET_TYPE_ECDH) in crypto_ecdh_decode_key()
69 if (unlikely(len < secret.len)) in crypto_ecdh_decode_key()
73 if (secret.len != crypto_ecdh_key_len(params)) in crypto_ecdh_decode_key()
H A Ddh_helper.c44 struct kpp_secret secret = { in crypto_dh_encode_key() local
52 ptr = dh_pack_data(ptr, end, &secret, sizeof(secret)); in crypto_dh_encode_key()
69 struct kpp_secret secret; in __crypto_dh_decode_key() local
74 ptr = dh_unpack_data(&secret, ptr, sizeof(secret)); in __crypto_dh_decode_key()
75 if (secret.type != CRYPTO_KPP_SECRET_TYPE_DH) in __crypto_dh_decode_key()
81 if (secret.len != crypto_dh_key_len(params)) in __crypto_dh_decode_key()
/linux/Documentation/ABI/testing/
H A Dsecurityfs-secrets-coco9 platforms (such as AMD SEV and SEV-ES) for secret injection by
15 secret appears as a file under <securityfs>/secrets/coco,
18 if the EFI secret area is populated.
21 Reading the file returns the content of secret entry.
22 Unlinking the file overwrites the secret data with zeroes and
23 removes the entry from the filesystem. A secret cannot be read
35 Reading the secret data by reading a file::
38 the-content-of-the-secret-data
40 Wiping a secret by unlinking a file::
51 the EFI secret area".
/linux/Documentation/security/secrets/
H A Dcoco.rst7 This document describes how Confidential Computing secret injection is handled
18 secret injection is performed early in the VM launch process, before the
28 The guest firmware may reserve a designated memory area for secret injection,
35 During the VM's launch, the virtual machine manager may inject a secret to that
38 Guest Owner secret data should be a GUIDed table of secret values; the binary
40 "Structure of the EFI secret area".
42 On kernel start, the kernel's EFI driver saves the location of the secret area
44 Later it checks if the secret area is populated: it maps the area and checks
46 (``1e74f542-71dd-4d66-963e-ef4287ff173b``). If the secret area is populated,
56 provides the decryption key (= secret) using the secret injection mechanism.
[all …]
/linux/drivers/virt/coco/efi_secret/
H A DKconfig3 tristate "EFI secret area securityfs support"
8 This is a driver for accessing the EFI secret area via securityfs.
9 The EFI secret area is a memory area designated by the firmware for
10 confidential computing secret injection (for example for AMD SEV
13 a file wipes the secret from memory).
/linux/lib/crypto/arm/
H A Dcurve25519.h18 const u8 secret[CURVE25519_KEY_SIZE],
36 const u8 secret[CURVE25519_KEY_SIZE]) in curve25519_base_arch()
38 curve25519_arch(pub, secret, curve25519_base_point); in curve25519_base_arch()
/linux/security/keys/
H A Ddh.c136 uint8_t *secret; in __keyctl_dh_compute() local
201 secret = kmalloc(secretlen, GFP_KERNEL); in __keyctl_dh_compute()
202 if (!secret) { in __keyctl_dh_compute()
206 ret = crypto_dh_encode_key(secret, secretlen, &dh_inputs); in __keyctl_dh_compute()
216 ret = crypto_kpp_set_secret(tfm, secret, secretlen); in __keyctl_dh_compute()
292 kfree_sensitive(secret); in __keyctl_dh_compute()
/linux/net/ceph/
H A Dauth_x.c57 static int ceph_x_encrypt(struct ceph_crypto_key *secret, void *buf, in ceph_x_encrypt() argument
67 ret = ceph_crypt(secret, true, buf + sizeof(u32), buf_len - sizeof(u32), in ceph_x_encrypt()
77 static int __ceph_x_decrypt(struct ceph_crypto_key *secret, void *p, in __ceph_x_decrypt() argument
84 ret = ceph_crypt(secret, false, p, ciphertext_len, ciphertext_len, in __ceph_x_decrypt()
97 static int ceph_x_decrypt(struct ceph_crypto_key *secret, void **p, void *end) in ceph_x_decrypt() argument
105 ret = __ceph_x_decrypt(secret, *p, ciphertext_len); in ceph_x_decrypt()
161 struct ceph_crypto_key *secret, in process_one_ticket() argument
197 ret = ceph_x_decrypt(secret, p, end); in process_one_ticket()
271 struct ceph_crypto_key *secret, in ceph_x_proc_ticket_reply() argument
286 ret = process_one_ticket(ac, secret, p, end); in ceph_x_proc_ticket_reply()
[all …]
H A Dauth_x.h41 struct ceph_crypto_key secret; member
/linux/net/bluetooth/
H A Decdh_helper.c45 u8 secret[32]) in compute_ecdh_secret()
67 sg_init_one(&dst, secret, 32); in compute_ecdh_secret()
80 swap_digits((u64 *)secret, (u64 *)tmp, 4); in compute_ecdh_secret()
81 memcpy(secret, tmp, 32); in compute_ecdh_secret()
H A Decdh_helper.h27 u8 secret[32]);
/linux/include/net/
H A Dprotocol.h49 u32 secret; member
63 u32 secret; member
73 u32 secret; member
/linux/drivers/nvme/common/
H A Dauth.c164 struct nvme_dhchap_key *nvme_auth_extract_key(unsigned char *secret, in nvme_auth_extract_key() argument
171 size_t allocated_len = strlen(secret); in nvme_auth_extract_key()
174 p = strrchr(secret, ':'); in nvme_auth_extract_key()
176 allocated_len = p - secret; in nvme_auth_extract_key()
181 key_len = base64_decode(secret, allocated_len, key->key, true, BASE64_STD); in nvme_auth_extract_key()
441 int nvme_auth_generate_key(u8 *secret, struct nvme_dhchap_key **ret_key) in nvme_auth_generate_key() argument
446 if (!secret) { in nvme_auth_generate_key()
451 if (sscanf(secret, "DHHC-1:%hhd:%*s:", &key_hash) != 1) in nvme_auth_generate_key()
455 key = nvme_auth_extract_key(secret + 10, key_hash); in nvme_auth_generate_key()
/linux/lib/crypto/powerpc/
H A Dcurve25519.h176 const u8 secret[CURVE25519_KEY_SIZE], in curve25519_arch()
179 curve25519_fe51(mypublic, secret, basepoint); in curve25519_arch()
183 const u8 secret[CURVE25519_KEY_SIZE]) in curve25519_base_arch()
185 curve25519_fe51(pub, secret, curve25519_base_point); in curve25519_base_arch()
/linux/Documentation/translations/zh_CN/process/
H A Dmaintainer-pgp-guide.rst145 运行命令来验证,例如: ``gpg --list-secret-keys``
195 $ gpg --export-secret-key [fpr] | paperkey -o /tmp/key-backup.txt
292 现在,如果你发出命令 ``--list-secret-keys`` ,它将显示证书密钥丢
295 $ gpg --list-secret-keys
471 如果你现在执行 ``--list-secret-keys`` ,你将看到输出中存在细微的差异::
473 $ gpg --list-secret-keys
514 $ gpg --list-secret-keys
/linux/include/linux/
H A Dnvme-auth.h28 struct nvme_dhchap_key *nvme_auth_extract_key(unsigned char *secret,
34 int nvme_auth_generate_key(u8 *secret, struct nvme_dhchap_key **ret_key);
/linux/Documentation/security/keys/
H A Decryptfs.rst70 into the '/secret' directory::
73 ecryptfs_cipher=aes,ecryptfs_key_bytes=32 /secret /secret
/linux/drivers/gpu/drm/nouveau/nvkm/engine/
H A Dfalcon.c141 falcon->secret = (falcon->addr == 0x087000) ? 1 : 0; in nvkm_falcon_oneinit()
145 falcon->secret = (caps & 0x00000030) >> 4; in nvkm_falcon_oneinit()
153 nvkm_debug(subdev, "secret level: %d\n", falcon->secret); in nvkm_falcon_oneinit()
171 if (falcon->secret && falcon->version < 4) { in nvkm_falcon_init()
/linux/lib/crypto/x86/
H A Dcurve25519.h1590 const u8 secret[CURVE25519_KEY_SIZE], in curve25519_arch()
1594 curve25519_ever64(mypublic, secret, basepoint); in curve25519_arch()
1596 curve25519_generic(mypublic, secret, basepoint); in curve25519_arch()
1600 const u8 secret[CURVE25519_KEY_SIZE]) in curve25519_base_arch()
1603 curve25519_ever64_base(pub, secret); in curve25519_base_arch()
1605 curve25519_generic(pub, secret, curve25519_base_point); in curve25519_base_arch()
/linux/drivers/net/wireguard/
H A Dcookie.c24 get_random_bytes(checker->secret, NOISE_HASH_LEN); in wg_cookie_checker_init()
100 get_random_bytes(checker->secret, NOISE_HASH_LEN); in make_cookie()
106 blake2s_init_key(&blake, COOKIE_LEN, checker->secret, NOISE_HASH_LEN); in make_cookie()
H A Dnoise.c349 u8 secret[BLAKE2S_HASH_SIZE]; in kdf() local
360 hmac(secret, data, chaining_key, data_len, NOISE_HASH_LEN); in kdf()
367 hmac(output, output, secret, 1, BLAKE2S_HASH_SIZE); in kdf()
375 hmac(output, output, secret, BLAKE2S_HASH_SIZE + 1, BLAKE2S_HASH_SIZE); in kdf()
383 hmac(output, output, secret, BLAKE2S_HASH_SIZE + 1, BLAKE2S_HASH_SIZE); in kdf()
388 memzero_explicit(secret, BLAKE2S_HASH_SIZE); in kdf()
/linux/drivers/nvme/target/
H A Dauth.c23 int nvmet_auth_set_key(struct nvmet_host *host, const char *secret, in nvmet_auth_set_key() argument
29 if (!strlen(secret)) { in nvmet_auth_set_key()
41 if (sscanf(secret, "DHHC-1:%hhd:%*s", &key_hash) != 1) in nvmet_auth_set_key()
57 dhchap_secret = kstrdup(secret, GFP_KERNEL); in nvmet_auth_set_key()

123