| /freebsd/crypto/openssh/ |
| H A D | hostfile.c | 215 struct hostkeys * 218 struct hostkeys *ret = xcalloc(1, sizeof(*ret)); in init_hostkeys() 227 struct hostkeys *hostkeys; member 234 struct hostkeys *hostkeys = ctx->hostkeys; in record_hostkey() local 248 if ((tmp = recallocarray(hostkeys->entries, hostkeys->num_entries, in record_hostkey() 249 hostkeys->num_entries + 1, sizeof(*hostkeys->entries))) == NULL) in record_hostkey() 251 hostkeys->entries = tmp; in record_hostkey() 252 hostkeys->entries[hostkeys->num_entries].host = xstrdup(ctx->host); in record_hostkey() 253 hostkeys->entries[hostkeys->num_entries].file = xstrdup(l->path); in record_hostkey() 254 hostkeys->entries[hostkeys->num_entries].line = l->linenum; in record_hostkey() [all …]
|
| H A D | hostfile.h | 33 struct hostkeys { struct 38 struct hostkeys *init_hostkeys(void); argument 39 void load_hostkeys(struct hostkeys *, const char *, 41 void load_hostkeys_file(struct hostkeys *, const char *, 43 void free_hostkeys(struct hostkeys *); 45 HostStatus check_key_in_hostkeys(struct hostkeys *, struct sshkey *, 47 int lookup_key_in_hostkeys_by_type(struct hostkeys *, int, int, 49 int lookup_marker_in_hostkeys(struct hostkeys *, int);
|
| H A D | sshd-session.c | 269 struct sshbuf *keybuf = NULL, *hostkeys = NULL; in pack_hostkeys() local 273 if ((hostkeys = sshbuf_new()) == NULL) in pack_hostkeys() 281 hostkeys)) != 0) in pack_hostkeys() 284 if ((r = sshbuf_put_string(hostkeys, NULL, 0)) != 0) in pack_hostkeys() 291 hostkeys)) != 0) in pack_hostkeys() 294 if ((r = sshbuf_put_string(hostkeys, NULL, 0)) != 0) in pack_hostkeys() 300 return hostkeys; in pack_hostkeys() 587 parse_hostkeys(struct sshbuf *hostkeys) in parse_hostkeys() argument 596 while (sshbuf_len(hostkeys) != 0) { in parse_hostkeys() 610 if ((r = sshbuf_froms(hostkeys, &kbuf)) != 0) in parse_hostkeys() [all …]
|
| H A D | sshd-auth.c | 376 parse_hostkeys(struct sshbuf *hostkeys) in parse_hostkeys() argument 384 while (sshbuf_len(hostkeys) != 0) { in parse_hostkeys() 393 if ((r = sshbuf_get_string_direct(hostkeys, &cp, &len)) != 0) in parse_hostkeys() 402 if ((r = sshbuf_get_string_direct(hostkeys, &cp, &len)) != 0) in parse_hostkeys() 418 struct sshbuf *hostkeys; in recv_privsep_state() local 423 &hostkeys, NULL, NULL, NULL, NULL); in recv_privsep_state() 424 parse_hostkeys(hostkeys); in recv_privsep_state() 426 sshbuf_free(hostkeys); in recv_privsep_state()
|
| H A D | sshconnect.h | 52 struct hostkeys; 99 void load_hostkeys_command(struct hostkeys *, const char *,
|
| H A D | auth.c | 427 struct hostkeys *hostkeys; in check_key_in_hostfiles() local 430 hostkeys = init_hostkeys(); in check_key_in_hostfiles() 431 load_hostkeys(hostkeys, host, sysfile, 0); in check_key_in_hostfiles() 445 load_hostkeys(hostkeys, host, user_hostfile, 0); in check_key_in_hostfiles() 450 host_status = check_key_in_hostkeys(hostkeys, key, &found); in check_key_in_hostfiles() 460 free_hostkeys(hostkeys); in check_key_in_hostfiles()
|
| H A D | ssh-add.c | 702 struct hostkeys *hostkeys; in parse_dest_constraint_hop() local 729 hostkeys = init_hostkeys(); in parse_dest_constraint_hop() 733 load_hostkeys(hostkeys, host, path, 0); in parse_dest_constraint_hop() 738 for (i = 0; i < hostkeys->num_entries; i++) { in parse_dest_constraint_hop() 739 hke = hostkeys->entries + i; in parse_dest_constraint_hop() 759 free_hostkeys(hostkeys); in parse_dest_constraint_hop()
|
| H A D | sshd.c | 677 struct sshbuf *m = NULL, *keybuf = NULL, *hostkeys = NULL; in pack_hostkeys() local 684 (hostkeys = sshbuf_new()) == NULL) in pack_hostkeys() 695 if ((r = sshbuf_put_stringb(hostkeys, keybuf)) != 0) in pack_hostkeys() 700 hostkeys)) != 0) in pack_hostkeys() 703 if ((r = sshbuf_put_string(hostkeys, NULL, 0)) != 0) in pack_hostkeys() 710 hostkeys)) != 0) in pack_hostkeys() 713 if ((r = sshbuf_put_string(hostkeys, NULL, 0)) != 0) in pack_hostkeys() 720 (r = sshbuf_put_stringb(m, hostkeys)) != 0) in pack_hostkeys() 727 sshbuf_free(hostkeys); in pack_hostkeys()
|
| H A D | sshconnect.c | 70 static int show_other_keys(struct hostkeys *, struct sshkey *); 867 load_hostkeys_command(struct hostkeys *hostkeys, const char *command_template, in load_hostkeys_command() argument 926 load_hostkeys_file(hostkeys, hostfile_hostname, tag, f, 1); in load_hostkeys_command() 970 struct hostkeys *host_hostkeys, *ip_hostkeys; in check_host_key() 1639 show_other_keys(struct hostkeys *hostkeys, struct sshkey *key) in show_other_keys() argument 1654 if (!lookup_key_in_hostkeys_by_type(hostkeys, type[i], in show_other_keys()
|
| H A D | sshconnect2.c | 127 struct hostkeys *hostkeys = NULL; in order_hostkeyalgs() local 133 hostkeys = init_hostkeys(); in order_hostkeyalgs() 135 load_hostkeys(hostkeys, hostname, options.user_hostfiles[i], 0); in order_hostkeyalgs() 137 load_hostkeys(hostkeys, hostname, in order_hostkeyalgs() 141 load_hostkeys_command(hostkeys, options.known_hosts_command, in order_hostkeyalgs() 152 if (lookup_key_in_hostkeys_by_type(hostkeys, in order_hostkeyalgs() 186 lookup_marker_in_hostkeys(hostkeys, MRK_CA)) { in order_hostkeyalgs() 191 if (lookup_key_in_hostkeys_by_type(hostkeys, in order_hostkeyalgs() 213 free_hostkeys(hostkeys); in order_hostkeyalgs()
|
| H A D | monitor.c | 605 struct sshbuf *m = NULL, *inc = NULL, *hostkeys = NULL; in mm_answer_state() local 628 hostkeys = pack_hostkeys(); in mm_answer_state() 653 (r = sshbuf_put_stringb(m, hostkeys)) != 0 || in mm_answer_state() 668 sshbuf_free(hostkeys); in mm_answer_state()
|
| H A D | PROTOCOL | 336 2.5. connection: hostkey update and rotation "hostkeys-00@openssh.com" 337 and "hostkeys-prove-00@openssh.com"
|
| H A D | ChangeLog | 3668 upstream: memleaks of request packet and hostkeys blob; ok 7565 hostkeys-prove requests. 10320 load the hostkeys, listen on port 22 and manage MaxStartups only. All
|
| /freebsd/crypto/openssh/regress/ |
| H A D | ssh-com-client.sh | 47 mkdir -p ${OBJ}/${USER}/hostkeys 48 HK=${OBJ}/${USER}/hostkeys/key_${PORT}_127.0.0.1
|
| H A D | Makefile | 307 $$V ${.OBJDIR}/unittests/hostkeys/test_hostkeys \ 308 -d ${.CURDIR}/unittests/hostkeys/testdata $${ARGS}; \
|
| /freebsd/crypto/openssh/regress/unittests/ |
| H A D | Makefile | 3 SUBDIR= test_helper sshbuf sshkey bitmap kex hostkeys utf8 match conversion
|