| /freebsd/crypto/openssh/ |
| H A D | sshkey.h | 112 struct sshkey *signature_key; 117 struct sshkey { struct 151 u_int (*size)(const struct sshkey *); /* optional */ argument 152 int (*alloc)(struct sshkey *); /* optional */ 153 void (*cleanup)(struct sshkey *); /* optional */ 154 int (*equal)(const struct sshkey *, const struct sshkey *); 155 int (*serialize_public)(const struct sshkey *, struct sshbuf *, 158 struct sshkey *); 159 int (*serialize_private)(const struct sshkey *, struct sshbuf *, 162 struct sshkey *); [all …]
|
| H A D | authfile.h | 31 struct sshkey; 36 int sshkey_save_private(struct sshkey *, const char *, 38 int sshkey_load_cert(const char *, struct sshkey **); 39 int sshkey_load_public(const char *, struct sshkey **, char **); 40 int sshkey_load_private(const char *, const char *, struct sshkey **, char **); 42 struct sshkey **); 44 struct sshkey **, char **); 46 struct sshkey **keyp, char **commentp); 48 int sshkey_in_file(struct sshkey *, const char *, int, int); 49 int sshkey_check_revoked(struct sshkey *key, const char *revoked_keys_file); [all …]
|
| H A D | auth.h | 47 struct sshkey; 89 struct sshkey **prev_keys; 93 struct sshkey *auth_method_key; 141 const char *, char *, struct sshkey *); 142 int user_key_allowed(struct ssh *ssh, struct passwd *, struct sshkey *, 144 int auth2_key_already_used(Authctxt *, const struct sshkey *); 151 void auth2_record_key(Authctxt *, int, const struct sshkey *); 196 int auth_key_is_revoked(struct sshkey *); 201 check_key_in_hostfiles(struct passwd *, struct sshkey *, const char *, 205 struct sshkey *get_hostkey_by_index(int); [all …]
|
| H A D | ssh-pkcs11.h | 27 struct sshkey; 31 int pkcs11_add_provider(char *, char *, struct sshkey ***, char ***); 33 int pkcs11_sign(struct sshkey *, u_char **, size_t *, 36 void pkcs11_key_free(struct sshkey *); 39 struct sshkey * 42 struct sshkey * 48 int pkcs11_make_cert(const struct sshkey *, 49 const struct sshkey *, struct sshkey **);
|
| H A D | sshsig.h | 22 struct sshkey; 26 typedef int sshsig_signer(struct sshkey *, u_char **, size_t *, 37 int sshsig_signb(struct sshkey *key, const char *hashalg, 49 struct sshkey **sign_keyp, struct sshkey_sig_details **sig_details); 58 int sshsig_sign_fd(struct sshkey *key, const char *hashalg, 69 const char *sig_namespace, struct sshkey **sign_keyp, 88 int sshsig_check_allowed_keys(const char *path, const struct sshkey *sign_key, 99 int sshsig_get_pubkey(struct sshbuf *signature, struct sshkey **pubkey); 104 int sshsig_find_principals(const char *path, const struct sshkey *sign_key,
|
| H A D | krl.h | 42 struct sshkey; 51 const struct sshkey *ca_key, uint64_t serial); 53 const struct sshkey *ca_key, uint64_t lo, uint64_t hi); 55 const struct sshkey *ca_key, const char *key_id); 56 int ssh_krl_revoke_key_explicit(struct ssh_krl *krl, const struct sshkey *key); 59 int ssh_krl_revoke_key(struct ssh_krl *krl, const struct sshkey *key); 62 int ssh_krl_check_key(struct ssh_krl *krl, const struct sshkey *key); 63 int ssh_krl_file_contains_key(const char *path, const struct sshkey *key);
|
| H A D | authfd.h | 20 struct sshkey; 25 struct sshkey **keys; 35 struct sshkey **keys; 50 int ssh_add_identity_constrained(int sock, struct sshkey *key, 53 int ssh_agent_has_key(int sock, const struct sshkey *key); 54 int ssh_remove_identity(int sock, const struct sshkey *key); 59 int cert_only, struct sshkey **certs, size_t ncerts); 62 int ssh_agent_sign(int sock, const struct sshkey *key, 66 int ssh_agent_bind_hostkey(int sock, const struct sshkey *key,
|
| H A D | authfile.c | 60 sshkey_save_private(struct sshkey *key, const char *filename, in sshkey_save_private() 111 struct sshkey **keyp, char **commentp) in sshkey_load_private_type() 135 struct sshkey **keyp, char **commentp) in sshkey_load_private() 143 struct sshkey **keyp, char **commentp) in sshkey_load_private_type_fd() 164 sshkey_load_pubkey_from_private(const char *filename, struct sshkey **pubkeyp) in sshkey_load_pubkey_from_private() 167 struct sshkey *pubkey = NULL; in sshkey_load_pubkey_from_private() 193 sshkey_try_load_public(struct sshkey **kp, const char *filename, in sshkey_try_load_public() 200 struct sshkey *k = NULL; in sshkey_try_load_public() 253 sshkey_load_public(const char *filename, struct sshkey **keyp, char **commentp) in sshkey_load_public() 289 sshkey_load_cert(const char *filename, struct sshkey **keyp) in sshkey_load_cert() [all …]
|
| H A D | sshconnect.h | 27 struct sshkey; 31 struct sshkey **keys; 82 int verify_host_key(char *, struct sockaddr *, struct sshkey *, 96 void maybe_add_key_to_agent(const char *, struct sshkey *, 101 const struct sshkey *, const char *); 103 int hostkey_accepted_by_hostkeyalgs(const struct sshkey *);
|
| H A D | ssh-ed25519.c | 35 ssh_ed25519_cleanup(struct sshkey *k) in ssh_ed25519_cleanup() 44 ssh_ed25519_equal(const struct sshkey *a, const struct sshkey *b) in ssh_ed25519_equal() 54 ssh_ed25519_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_ed25519_serialize_public() 68 ssh_ed25519_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_ed25519_serialize_private() 81 ssh_ed25519_generate(struct sshkey *k, int bits) in ssh_ed25519_generate() 91 ssh_ed25519_copy_public(const struct sshkey *from, struct sshkey *to) in ssh_ed25519_copy_public() 103 struct sshkey *key) in ssh_ed25519_deserialize_public() 121 struct sshkey *key) in ssh_ed25519_deserialize_private() 145 ssh_ed25519_sign(struct sshkey *key, in ssh_ed25519_sign() 227 ssh_ed25519_verify(const struct sshkey *key, in ssh_ed25519_verify()
|
| H A D | ssh-ed25519-sk.c | 40 ssh_ed25519_sk_cleanup(struct sshkey *k) in ssh_ed25519_sk_cleanup() 47 ssh_ed25519_sk_equal(const struct sshkey *a, const struct sshkey *b) in ssh_ed25519_sk_equal() 57 ssh_ed25519_sk_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_ed25519_sk_serialize_public() 71 ssh_ed25519_sk_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_ed25519_sk_serialize_private() 85 ssh_ed25519_sk_copy_public(const struct sshkey *from, struct sshkey *to) in ssh_ed25519_sk_copy_public() 98 struct sshkey *key) in ssh_ed25519_sk_deserialize_public() 111 struct sshkey *key) in ssh_ed25519_sk_deserialize_private() 123 ssh_ed25519_sk_verify(const struct sshkey *key, in ssh_ed25519_sk_verify()
|
| H A D | kex.h | 168 struct sshkey *initial_hostkey; 174 int (*verify_host_key)(struct sshkey *, struct ssh *); 175 struct sshkey *(*load_host_public_key)(int, int, struct ssh *); 176 struct sshkey *(*load_host_private_key)(int, int, struct ssh *); 177 int (*host_key_index)(struct sshkey *, int, struct ssh *); 178 int (*sign)(struct ssh *, struct sshkey *, struct sshkey *, 218 int kex_load_hostkey(struct ssh *, struct sshkey **, struct sshkey **); 219 int kex_verify_host_key(struct ssh *, struct sshkey *);
|
| H A D | hostfile.h | 29 struct sshkey *key; 45 HostStatus check_key_in_hostkeys(struct hostkeys *, struct sshkey *, 51 int hostfile_read_key(char **, u_int *, struct sshkey *); 53 const struct sshkey *, int); 56 const char *host, const char *ip, struct sshkey **keys, size_t nkeys, 101 struct sshkey *key; /* Key, if parsed ok and HKF_WANT_MATCH_HOST set */
|
| H A D | sshkey.c | 86 struct sshkey **keyp, int allow_cert); 178 sshkey_impl_from_key(const struct sshkey *k) in sshkey_impl_from_key() 186 sshkey_type(const struct sshkey *k) in sshkey_type() 216 sshkey_ssh_name(const struct sshkey *k) in sshkey_ssh_name() 222 sshkey_ssh_name_plain(const struct sshkey *k) in sshkey_ssh_name_plain() 385 sshkey_size(const struct sshkey *k) in sshkey_size() 408 sshkey_is_cert(const struct sshkey *k) in sshkey_is_cert() 416 sshkey_is_sk(const struct sshkey *k) in sshkey_is_sk() 686 struct sshkey * 689 struct sshkey *k; in sshkey_new() [all …]
|
| H A D | monitor_wrap.h | 40 struct sshkey; 50 int mm_sshkey_sign(struct ssh *, struct sshkey *, u_char **, size_t *, 57 int mm_key_allowed(enum mm_keytype, const char *, const char *, struct sshkey *, 59 int mm_user_key_allowed(struct ssh *ssh, struct passwd *, struct sshkey *, int, 62 const char *, struct sshkey *); 63 int mm_sshkey_verify(const struct sshkey *, const u_char *, size_t,
|
| H A D | ssh-ecdsa.c | 102 ssh_ecdsa_size(const struct sshkey *key) in ssh_ecdsa_size() 119 ssh_ecdsa_cleanup(struct sshkey *k) in ssh_ecdsa_cleanup() 126 ssh_ecdsa_equal(const struct sshkey *a, const struct sshkey *b) in ssh_ecdsa_equal() 134 ssh_ecdsa_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_ecdsa_serialize_public() 150 ssh_ecdsa_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_ecdsa_serialize_private() 166 ssh_ecdsa_generate(struct sshkey *k, int bits) in ssh_ecdsa_generate() 195 ssh_ecdsa_copy_public(const struct sshkey *from, struct sshkey *to) in ssh_ecdsa_copy_public() 230 struct sshkey *key) in ssh_ecdsa_deserialize_public() 283 struct sshkey *key) in ssh_ecdsa_deserialize_private() 318 ssh_ecdsa_sign(struct sshkey *key, in ssh_ecdsa_sign() [all …]
|
| H A D | ssh-sk.h | 22 struct sshkey; 35 struct sshkey *key; 53 struct sshkey **keyp, struct sshbuf *attest); 61 int sshsk_sign(const char *provider_path, struct sshkey *key,
|
| H A D | ssh_api.c | 46 int _ssh_verify_host_key(struct sshkey *, struct ssh *); 47 struct sshkey *_ssh_host_public_key(int, int, struct ssh *); 48 struct sshkey *_ssh_host_private_key(int, int, struct ssh *); 49 int _ssh_host_key_sign(struct ssh *, struct sshkey *, struct sshkey *, 55 int mm_sshkey_sign(struct sshkey *, u_char **, u_int *, 63 mm_sshkey_sign(struct sshkey *key, u_char **sigp, u_int *lenp, in mm_sshkey_sign() 203 ssh_add_hostkey(struct ssh *ssh, struct sshkey *key) in ssh_add_hostkey() 205 struct sshkey *pubkey = NULL; in ssh_add_hostkey() 238 int (*cb)(struct sshkey *, struct ssh *)) in ssh_set_verify_host_key_callback() argument 483 struct sshkey * [all …]
|
| H A D | ssh-ecdsa-sk.c | 55 ssh_ecdsa_sk_verify(const struct sshkey *key, in ssh_ecdsa_sk_verify() 68 ssh_ecdsa_sk_cleanup(struct sshkey *k) in ssh_ecdsa_sk_cleanup() 75 ssh_ecdsa_sk_equal(const struct sshkey *a, const struct sshkey *b) in ssh_ecdsa_sk_equal() 85 ssh_ecdsa_sk_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_ecdsa_sk_serialize_public() 99 ssh_ecdsa_sk_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_ecdsa_sk_serialize_private() 116 ssh_ecdsa_sk_copy_public(const struct sshkey *from, struct sshkey *to) in ssh_ecdsa_sk_copy_public() 129 struct sshkey *key) in ssh_ecdsa_sk_deserialize_public() 142 struct sshkey *key) in ssh_ecdsa_sk_deserialize_private() 234 ssh_ecdsa_sk_verify(const struct sshkey *key, in ssh_ecdsa_sk_verify()
|
| H A D | ssh-rsa.c | 38 ssh_rsa_size(const struct sshkey *k) in ssh_rsa_size() 46 ssh_rsa_alloc(struct sshkey *k) in ssh_rsa_alloc() 54 ssh_rsa_cleanup(struct sshkey *k) in ssh_rsa_cleanup() 61 ssh_rsa_equal(const struct sshkey *a, const struct sshkey *b) in ssh_rsa_equal() 69 ssh_rsa_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_rsa_serialize_public() 90 ssh_rsa_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_rsa_serialize_private() 119 ssh_rsa_generate(struct sshkey *k, int bits) in ssh_rsa_generate() 155 ssh_rsa_copy_public(const struct sshkey *from, struct sshkey *to) in ssh_rsa_copy_public() 194 struct sshkey *key) in ssh_rsa_deserialize_public() 233 struct sshkey *key) in ssh_rsa_deserialize_private() [all …]
|
| H A D | ssh-pkcs11-client.c | 75 helper_by_key(const struct sshkey *key) in helper_by_key() 103 helper_add_key(struct helper *helper, struct sshkey *key) in helper_add_key() 227 pkcs11_sign(struct sshkey *key, in pkcs11_sign() 289 pkcs11_make_cert(const struct sshkey *priv, in pkcs11_make_cert() 290 const struct sshkey *certpub, struct sshkey **certprivp) in pkcs11_make_cert() 293 struct sshkey *ret; in pkcs11_make_cert() 383 pkcs11_add_provider(char *name, char *pin, struct sshkey ***keysp, in pkcs11_add_provider() 386 struct sshkey *k; in pkcs11_add_provider() 414 *keysp = xcalloc(nkeys, sizeof(struct sshkey *)); in pkcs11_add_provider() 460 pkcs11_key_free(struct sshkey *key) in pkcs11_key_free()
|
| H A D | sshd-auth.c | 135 struct sshkey **host_pubkeys; /* all public host keys */ 136 struct sshkey **host_certificates; /* all public host certificates */ 235 struct sshkey *key; in list_hostkey_types() 285 struct sshkey * 289 struct sshkey *key; in get_hostkey_public_by_type() 322 struct sshkey * 329 struct sshkey * 335 struct sshkey * 344 get_hostkey_index(struct sshkey *key, int compare, struct ssh *ssh) in get_hostkey_index() 381 struct sshkey *k; in parse_hostkeys() [all …]
|
| /freebsd/crypto/openssh/regress/misc/fuzz-harness/ |
| H A D | sig_fuzz.cc | 15 static struct sshkey *generate_or_die(int type, unsigned bits) { in generate_or_die() 17 struct sshkey *ret; in generate_or_die() 28 static struct sshkey *rsa = generate_or_die(KEY_RSA, 2048); in LLVMFuzzerTestOneInput() 29 static struct sshkey *ecdsa256 = generate_or_die(KEY_ECDSA, 256); in LLVMFuzzerTestOneInput() 30 static struct sshkey *ecdsa384 = generate_or_die(KEY_ECDSA, 384); in LLVMFuzzerTestOneInput() 31 static struct sshkey *ecdsa521 = generate_or_die(KEY_ECDSA, 521); in LLVMFuzzerTestOneInput() 34 static struct sshkey *ed25519 = generate_or_die(KEY_ED25519, 0); in LLVMFuzzerTestOneInput()
|
| /freebsd/crypto/openssh/regress/unittests/sshkey/ |
| H A D | common.h | 18 const BIGNUM *rsa_n(struct sshkey *k); 19 const BIGNUM *rsa_e(struct sshkey *k); 20 const BIGNUM *rsa_p(struct sshkey *k); 21 const BIGNUM *rsa_q(struct sshkey *k);
|
| H A D | common.c | 84 rsa_n(struct sshkey *k) in rsa_n() 95 rsa_e(struct sshkey *k) in rsa_e() 106 rsa_p(struct sshkey *k) in rsa_p() 117 rsa_q(struct sshkey *k) in rsa_q()
|