diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2018-12-27 03:25:26 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2018-12-27 03:25:26 +0000 |
commit | 8b2b36ac27417559f25e726f188a854c758e0afe (patch) | |
tree | d7b2ee4ecb9d6cf7f42d13b68a74139cd10b05a1 /usr.bin/ssh/sshconnect.h | |
parent | 21b4570b87638cbe37af868c56c05dae6c3dcb6b (diff) |
move client/server SSH-* banners to buffers under ssh->kex and factor
out the banner exchange. This eliminates some common code from the
client and server.
Also be more strict about handling \r characters - these should only
be accepted immediately before \n (pointed out by Jann Horn).
Inspired by a patch from Markus Schmidt.
(lots of) feedback and ok markus@
Diffstat (limited to 'usr.bin/ssh/sshconnect.h')
-rw-r--r-- | usr.bin/ssh/sshconnect.h | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/usr.bin/ssh/sshconnect.h b/usr.bin/ssh/sshconnect.h index 890d857330c..44a5071c719 100644 --- a/usr.bin/ssh/sshconnect.h +++ b/usr.bin/ssh/sshconnect.h @@ -1,4 +1,4 @@ -/* $OpenBSD: sshconnect.h,v 1.35 2018/07/19 10:28:47 dtucker Exp $ */ +/* $OpenBSD: sshconnect.h,v 1.36 2018/12/27 03:25:25 djm Exp $ */ /* * Copyright (c) 2000 Markus Friedl. All rights reserved. @@ -37,21 +37,18 @@ int ssh_connect(struct ssh *, const char *, struct addrinfo *, struct sockaddr_storage *, u_short, int, int, int *, int); void ssh_kill_proxy_command(void); -void ssh_login(Sensitive *, const char *, struct sockaddr *, u_short, - struct passwd *, int); - -void ssh_exchange_identification(int); +void ssh_login(struct ssh *, Sensitive *, const char *, + struct sockaddr *, u_short, struct passwd *, int); int verify_host_key(char *, struct sockaddr *, struct sshkey *); void get_hostfile_hostname_ipaddr(char *, struct sockaddr *, u_short, char **, char **); -void ssh_kex(char *, struct sockaddr *); -void ssh_kex2(char *, struct sockaddr *, u_short); +void ssh_kex2(struct ssh *ssh, char *, struct sockaddr *, u_short); -void ssh_userauth1(const char *, const char *, char *, Sensitive *); -void ssh_userauth2(const char *, const char *, char *, Sensitive *); +void ssh_userauth2(struct ssh *ssh, const char *, const char *, + char *, Sensitive *); void ssh_put_password(char *); int ssh_local_cmd(const char *); |