| /freebsd/crypto/openssh/ |
| H A D | packet.h | 13 * called by a name other than "ssh" or "Secure Shell". 55 struct ssh { struct 94 typedef int (ssh_packet_hook_fn)(struct ssh *, struct sshbuf *, argument 97 struct ssh *ssh_alloc_session_state(void); 98 struct ssh *ssh_packet_set_connection(struct ssh *, int, int); 99 void ssh_packet_set_timeout(struct ssh *, int, int); 100 int ssh_packet_stop_discard(struct ssh *); 101 int ssh_packet_connection_af(struct ssh *); 102 void ssh_packet_set_nonblocking(struct ssh *); 103 int ssh_packet_get_connection_in(struct ssh *); [all …]
|
| H A D | ssh_api.c | 42 int _ssh_exchange_banner(struct ssh *); 43 int _ssh_send_banner(struct ssh *, struct sshbuf *); 44 int _ssh_read_banner(struct ssh *, struct sshbuf *); 45 int _ssh_order_hostkeyalgs(struct ssh *); 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 *, 87 ssh_init(struct ssh **sshp, int is_server, struct kex_params *kex_params) in ssh_init() 91 struct ssh *ssh; in ssh_init() local [all …]
|
| H A D | packet.c | 13 * called by a name other than "ssh" or "Secure Shell". 232 struct ssh * 235 struct ssh *ssh = NULL; in ssh_alloc_session_state() local 238 if ((ssh = calloc(1, sizeof(*ssh))) == NULL || in ssh_alloc_session_state() 240 (ssh->kex = kex_new()) == NULL || in ssh_alloc_session_state() 247 TAILQ_INIT(&ssh->private_keys); in ssh_alloc_session_state() 248 TAILQ_INIT(&ssh->public_keys); in ssh_alloc_session_state() 262 ssh->state = state; in ssh_alloc_session_state() 263 return ssh; in ssh_alloc_session_state() 265 if (ssh) { in ssh_alloc_session_state() [all …]
|
| H A D | serverloop.c | 12 * called by a name other than "ssh" or "Secure Shell". 92 static void server_init_dispatch(struct ssh *); 112 client_alive_check(struct ssh *ssh) in client_alive_check() argument 119 ssh_packet_inc_alive_timeouts(ssh) > in client_alive_check() 121 sshpkt_fmt_connection_id(ssh, remote_id, sizeof(remote_id)); in client_alive_check() 130 if ((channel_id = channel_find_open(ssh)) == -1) { in client_alive_check() 131 if ((r = sshpkt_start(ssh, SSH2_MSG_GLOBAL_REQUEST)) != 0 || in client_alive_check() 132 (r = sshpkt_put_cstring(ssh, "keepalive@openssh.com")) in client_alive_check() 134 (r = sshpkt_put_u8(ssh, 1)) != 0) /* boolean: want reply */ in client_alive_check() 137 channel_request_start(ssh, channel_id, in client_alive_check() [all …]
|
| H A D | channels.h | 12 * called by a name other than "ssh" or "Secure Shell". 89 struct ssh; 93 typedef void channel_open_fn(struct ssh *, int, int, void *); 94 typedef void channel_callback_fn(struct ssh *, int, int, void *); 95 typedef int channel_infilter_fn(struct ssh *, struct Channel *, char *, int); 96 typedef void channel_filter_cleanup_fn(struct ssh *, int, void *); 97 typedef u_char *channel_outfilter_fn(struct ssh *, struct Channel *, 101 typedef void channel_confirm_cb(struct ssh *, int, struct Channel *, void *); 102 typedef void channel_confirm_abandon_cb(struct ssh *, struct Channel *, void *); 119 typedef int mux_callback_fn(struct ssh *, struct Channel *); [all …]
|
| H A D | auth2-gss.c | 48 #include "ssh-gss.h" 56 static int input_gssapi_token(int type, uint32_t plen, struct ssh *ssh); 57 static int input_gssapi_mic(int type, uint32_t plen, struct ssh *ssh); 58 static int input_gssapi_exchange_complete(int type, uint32_t plen, struct ssh *ssh); 59 static int input_gssapi_errtok(int, uint32_t, struct ssh *); 66 userauth_gssapi(struct ssh *ssh, const char *method) in userauth_gssapi() argument 68 Authctxt *authctxt = ssh->authctxt; in userauth_gssapi() 77 if ((r = sshpkt_get_u32(ssh, &mechs)) != 0) in userauth_gssapi() 95 if ((r = sshpkt_get_string(ssh, &doid, &len)) != 0) in userauth_gssapi() 131 if ((r = sshpkt_start(ssh, SSH2_MSG_USERAUTH_GSSAPI_RESPONSE)) != 0 || in userauth_gssapi() [all …]
|
| H A D | channels.c | 14 * called by a name other than "ssh" or "Secure Shell". 68 #include "ssh.h" 94 typedef void chan_fn(struct ssh *, Channel *c); 213 static void port_open_helper(struct ssh *ssh, Channel *c, char *rtype); 219 static Channel *rdynamic_connect_prepare(struct ssh *, char *, char *); 220 static int rdynamic_connect_finish(struct ssh *, Channel *); 228 channel_init_channels(struct ssh *ssh) in channel_init_channels() argument 241 ssh->chanctxt = sc; in channel_init_channels() 245 channel_by_id(struct ssh *ssh, int id) in channel_by_id() argument 249 if (id < 0 || (u_int)id >= ssh->chanctxt->channels_alloc) { in channel_by_id() [all …]
|
| H A D | sshconnect2.c | 49 #include "ssh.h" 71 #include "ssh-sk.h" 75 #include "ssh-gss.h" 91 verify_host_key_callback(struct sshkey *hostkey, struct ssh *ssh) in verify_host_key_callback() argument 219 ssh_kex2(struct ssh *ssh, char *host, struct sockaddr *hostaddr, u_short port, in ssh_kex2() argument 231 ssh_packet_set_rekey_limits(ssh, options.rekey_limit, in ssh_kex2() 254 kex_proposal_populate_entries(ssh, myproposal, in ssh_kex2() 262 if ((r = kex_setup(ssh, myproposal)) != 0) in ssh_kex2() 265 ssh->kex->kex[KEX_DH_GRP1_SHA1] = kex_gen_client; in ssh_kex2() 266 ssh->kex->kex[KEX_DH_GRP14_SHA1] = kex_gen_client; in ssh_kex2() [all …]
|
| H A D | kex.c | 42 #include "ssh.h" 64 static int kex_choose_conf(struct ssh *, uint32_t seq); 65 static int kex_input_newkeys(int, uint32_t, struct ssh *); 87 kex_proposal_populate_entries(struct ssh *ssh, char *prop[PROPOSAL_MAX], in kex_proposal_populate_entries() argument 93 const char **defprop = ssh->kex->server ? defpropserver : defpropclient; in kex_proposal_populate_entries() 103 if ((cp = kex_names_cat(kexalgos, ssh->kex->server ? in kex_proposal_populate_entries() 111 prop[i] = compat_kex_proposal(ssh, cp); in kex_proposal_populate_entries() 232 kex_protocol_error(int type, uint32_t seq, struct ssh *ssh) in kex_protocol_error() argument 237 if ((ssh->kex->flags & KEX_INITIAL) && ssh->kex->kex_strict) { in kex_protocol_error() 238 ssh_packet_disconnect(ssh, "strict KEX violation: " in kex_protocol_error() [all …]
|
| H A D | dispatch.c | 40 dispatch_protocol_error(int type, uint32_t seq, struct ssh *ssh) in dispatch_protocol_error() argument 45 if ((r = sshpkt_start(ssh, SSH2_MSG_UNIMPLEMENTED)) != 0 || in dispatch_protocol_error() 46 (r = sshpkt_put_u32(ssh, seq)) != 0 || in dispatch_protocol_error() 47 (r = sshpkt_send(ssh)) != 0 || in dispatch_protocol_error() 48 (r = ssh_packet_write_wait(ssh)) != 0) in dispatch_protocol_error() 49 sshpkt_fatal(ssh, r, "%s", __func__); in dispatch_protocol_error() 54 dispatch_protocol_ignore(int type, uint32_t seq, struct ssh *ssh) in dispatch_protocol_ignore() argument 61 ssh_dispatch_init(struct ssh *ssh, dispatch_fn *dflt) in ssh_dispatch_init() argument 65 ssh->dispatch[i] = dflt; in ssh_dispatch_init() 69 ssh_dispatch_range(struct ssh *ssh, u_int from, u_int to, dispatch_fn *fn) in ssh_dispatch_range() argument [all …]
|
| H A D | nchan.c | 43 * SSH Protocol 1.5 aka New Channel Protocol 63 * See the debugging output from 'ssh -v' and 'sshd -d' of 64 * ssh-1.2.27 as an example. 75 static void chan_send_eof2(struct ssh *, Channel *); 76 static void chan_send_eow2(struct ssh *, Channel *); 79 static void chan_shutdown_write(struct ssh *, Channel *); 80 static void chan_shutdown_read(struct ssh *, Channel *); 81 static void chan_shutdown_extended_read(struct ssh *, Channel *); 111 chan_read_failed(struct ssh *ssh, Channel *c) in chan_read_failed() argument 116 chan_shutdown_read(ssh, c); in chan_read_failed() [all …]
|
| H A D | ssh_api.h | 28 #include "ssh.h" 36 /* public SSH API functions */ 39 * ssh_init() create a ssh connection object with given (optional) 42 int ssh_init(struct ssh **, int is_server, struct kex_params *kex_params); 45 * release ssh connection state. 47 void ssh_free(struct ssh *); 52 void ssh_set_app_data(struct ssh *, void *); 53 void *ssh_get_app_data(struct ssh *); 56 * ssh_add_hostkey() registers a private/public hostkey for an ssh 63 int ssh_add_hostkey(struct ssh *ssh, struct sshkey *key); [all …]
|
| H A D | clientloop.c | 12 * called by a name other than "ssh" or "Secure Shell". 83 #include "ssh.h" 155 static void client_init_dispatch(struct ssh *ssh); 172 /* XXX move to struct ssh? */ 241 set_control_persist_exit_time(struct ssh *ssh) in set_control_persist_exit_time() argument 247 } else if (channel_still_open(ssh)) { in set_control_persist_exit_time() 285 client_x11_get_proto(struct ssh *ssh, const char *display, in client_x11_get_proto() argument 334 * ssh's willingness to forward X11 connections to in client_x11_get_proto() 380 channel_set_x11_refuse_time(ssh, in client_x11_get_proto() 456 client_check_window_change(struct ssh *ssh) in client_check_window_change() argument [all …]
|
| H A D | Makefile.in | 22 SSH_PROGRAM=@bindir@/ssh 23 ASKPASS_PROGRAM=$(libexecdir)/ssh-askpass 25 SSH_KEYSIGN=$(libexecdir)/ssh-keysign 28 SSH_PKCS11_HELPER=$(libexecdir)/ssh-pkcs11-helper 29 SSH_SK_HELPER=$(libexecdir)/ssh-sk-helper 78 …ssh$(EXEEXT) sshd$(EXEEXT) sshd-session$(EXEEXT) sshd-auth$(EXEEXT) ssh-add$(EXEEXT) ssh-keygen$(E… 99 monitor_fdpass.o rijndael.o ssh-ecdsa.o ssh-ecdsa-sk.o \ 100 ssh-ed25519-sk.o ssh-rsa.o dh.o \ 104 ssh-ed25519.o digest-openssl.o digest-libc.o \ 112 P11OBJS= ssh-pkcs11-client.o [all …]
|
| H A D | kexgexs.c | 49 #include "ssh-gss.h" 57 static int input_kex_dh_gex_request(int, uint32_t, struct ssh *); 58 static int input_kex_dh_gex_init(int, uint32_t, struct ssh *); 61 kexgex_server(struct ssh *ssh) in kexgex_server() argument 63 ssh_dispatch_set(ssh, SSH2_MSG_KEX_DH_GEX_REQUEST, in kexgex_server() 70 input_kex_dh_gex_request(int type, uint32_t seq, struct ssh *ssh) in input_kex_dh_gex_request() argument 72 struct kex *kex = ssh->kex; in input_kex_dh_gex_request() 78 ssh_dispatch_set(ssh, SSH2_MSG_KEX_DH_GEX_REQUEST, &kex_protocol_error); in input_kex_dh_gex_request() 80 if ((r = sshpkt_get_u32(ssh, &min)) != 0 || in input_kex_dh_gex_request() 81 (r = sshpkt_get_u32(ssh, &nbits)) != 0 || in input_kex_dh_gex_request() [all …]
|
| H A D | ssh-add.1 | 1 .\" $OpenBSD: ssh-add.1,v 1.89 2026/03/05 05:44:15 djm Exp $ 11 .\" called by a name other than "ssh" or "Secure Shell". 42 .Nm ssh-add 45 .Nm ssh-add 53 .Nm ssh-add 57 .Nm ssh-add 59 .Nm ssh-add 62 .Nm ssh-add 67 .Xr ssh-agent 1 . 69 .Pa ~/.ssh/id_rsa , [all …]
|
| H A D | ssh-agent.1 | 1 .\" $OpenBSD: ssh-agent.1,v 1.86 2025/10/04 21:41:35 naddy Exp $ 11 .\" called by a name other than "ssh" or "Secure Shell". 41 .Nm ssh-agent 44 .Nm ssh-agent 52 .Nm ssh-agent 60 .Nm ssh-agent 63 .Nm ssh-agent 71 .Xr ssh 1 . 81 .Pa $HOME/.ssh/agent/s.* . 127 .Xr ssh 1 , [all …]
|
| /freebsd/crypto/openssh/contrib/suse/ |
| H A D | openssh.spec | 8 # The version of x11-ssh-askpass to use 14 Summary: OpenSSH, a free Secure Shell (SSH) protocol implementation 20 Source1: x11-ssh-askpass-%{xversion}.tar.gz 22 Group: Productivity/Networking/SSH 25 Obsoletes: ssh 26 Provides: ssh 41 Group: Productivity/Networking/SSH 43 Obsoletes: ssh-extras 44 Provides: openssh:${_libdir}/ssh/ssh-askpass 51 Ssh (Secure Shell) is a program for logging into a remote machine and for [all …]
|
| /freebsd/crypto/openssh/regress/ |
| H A D | agent.sh | 8 fail "ssh-add -l did not fail with exit code 2" 12 eval `${SSHAGENT} ${EXTRA_AGENT_ARGS} -s` >`ssh_logfile ssh-agent` 15 fatal "could not start ssh-agent: exit code $r" 21 fatal "could not start second ssh-agent: exit code $r" 26 fail "ssh-add -l did not fail with exit code 1" 31 || fatal "ssh-keygen failed" 40 fatal "ssh-keygen for $t-agent failed" 50 fail "ssh-add failed exit code $?" 55 fail "ssh-add failed exit code $?" 71 fail "ssh-add -l failed: exit code $r" [all …]
|
| H A D | sshcfgparse.sh | 4 tid="ssh config parse" 26 (${SSH} -G -F $OBJ/ssh_config somehost >$OBJ/ssh_config.1 && 27 ${SSH} -G -F $OBJ/ssh_config.1 somehost >$OBJ/ssh_config.2 && 30 verbose "ssh -W opts" 31 f=`${SSH} -GF $OBJ/ssh_config host | awk '/exitonforwardfailure/{print $2}'` 33 f=`${SSH} -GF $OBJ/ssh_config -W a:1 h | awk '/exitonforwardfailure/{print $2}'` 35 f=`${SSH} -GF $OBJ/ssh_config -W a:1 -o exitonforwardfailure=no h | \ 39 f=`${SSH} -GF $OBJ/ssh_config host | awk '/clearallforwardings/{print $2}'` 41 f=`${SSH} -GF $OBJ/ssh_config -W a:1 h | awk '/clearallforwardings/{print $2}'` 43 f=`${SSH} -GF $OBJ/ssh_config -W a:1 -o clearallforwardings=no h | \ [all …]
|
| H A D | limit-keytype.sh | 18 ssh-rsa) ktype2=rsa ;; 20 sk-ssh-ed25519@openssh.com) ktype5=ed25519-sk ;; 27 fatal "ssh-keygen failed" 31 fatal "ssh-keygen failed" 33 fatal "ssh-keygen failed" 35 fatal "ssh-keygen failed" 37 fatal "ssh-keygen failed" 39 fatal "ssh-keygen failed" 41 fatal "ssh-keygen failed" 76 ed25519) printf "ssh-ed25519" ;; [all …]
|
| H A D | cert-file.sh | 4 tid="ssh with certificates" 11 fatal "ssh-keygen failed" 13 fatal "ssh-keygen failed" 17 fatal "ssh-keygen failed" 19 fatal "ssh-keygen failed" 21 fatal "ssh-keygen failed" 23 fatal "ssh-keygen failed" 25 fatal "ssh-keygen failed" 59 ${SSH} -F $OBJ/no_identity_config -oIdentitiesOnly=yes \ 61 [ $? -ne 52 ] && fail "ssh failed" [all …]
|
| /freebsd/crypto/openssh/regress/unittests/sshkey/ |
| H A D | mktestdata.sh | 68 ssh-keygen -t rsa -b 1024 -C "RSA test key #1" -N "" -f rsa_1 -m PEM 69 ssh-keygen -t ecdsa -b 256 -C "ECDSA test key #1" -N "" -f ecdsa_1 -m PEM 70 ssh-keygen -t ed25519 -C "ED25519 test key #1" -N "" -f ed25519_1 71 ssh-keygen -w "$SK_DUMMY" -t ecdsa-sk -C "ECDSA-SK test key #1" \ 73 ssh-keygen -w "$SK_DUMMY" -t ed25519-sk -C "ED25519-SK test key #1" \ 77 ssh-keygen -t rsa -b 2048 -C "RSA test key #2" -N "" -f rsa_2 -m PEM 78 ssh-keygen -t ecdsa -b 521 -C "ECDSA test key #2" -N "" -f ecdsa_2 -m PEM 79 ssh-keygen -t ed25519 -C "ED25519 test key #2" -N "" -f ed25519_2 80 ssh-keygen -w "$SK_DUMMY" -t ecdsa-sk -C "ECDSA-SK test key #2" \ 82 ssh-keygen -w "$SK_DUMMY" -t ed25519-sk -C "ED25519-SK test key #2" \ [all …]
|
| /freebsd/crypto/openssh/contrib/ |
| H A D | Makefile | 4 @echo "Valid targets: gnome-ssh-askpass1 gnome-ssh-askpass2 gnome-ssk-askpass3 gnome-ssh-askpass4" 6 gnome-ssh-askpass1: gnome-ssh-askpass1.c 8 gnome-ssh-askpass1.c -o gnome-ssh-askpass1 \ 11 gnome-ssh-askpass2: gnome-ssh-askpass2.c 13 gnome-ssh-askpass2.c -o gnome-ssh-askpass2 \ 16 gnome-ssh-askpass3: gnome-ssh-askpass3.c 18 gnome-ssh-askpass3.c -o gnome-ssh-askpass3 \ 21 gnome-ssh-askpass4: gnome-ssh-askpass4.c 23 gnome-ssh-askpass4.c -o gnome-ssh-askpass4 \ 27 rm -f *.o gnome-ssh-askpass gnome-ssh-askpass[123]
|
| H A D | ssh-copy-id.1 | 28 .Nm ssh-copy-id 49 .Xr ssh 1 56 .Xr ssh-agent 1 59 .Xr ssh 1 , 62 .Pa ~/.ssh/authorized_keys 66 .Ql set ssh pka-dsa key ... 75 .Xr ssh-add 1 101 .Pa ~/.ssh/authorized_keys 107 (defaults to ".ssh/authorized_keys") 112 to ssh/sftp, [all …]
|