diff options
Diffstat (limited to 'kex.h')
-rw-r--r-- | kex.h | 20 |
1 files changed, 12 insertions, 8 deletions
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: kex.h,v 1.92 2018/12/07 03:39:40 djm Exp $ */ | 1 | /* $OpenBSD: kex.h,v 1.93 2018/12/27 03:25:25 djm Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 2000, 2001 Markus Friedl. All rights reserved. | 4 | * Copyright (c) 2000, 2001 Markus Friedl. All rights reserved. |
@@ -145,12 +145,12 @@ struct kex { | |||
145 | int ext_info_c; | 145 | int ext_info_c; |
146 | struct sshbuf *my; | 146 | struct sshbuf *my; |
147 | struct sshbuf *peer; | 147 | struct sshbuf *peer; |
148 | struct sshbuf *client_version; | ||
149 | struct sshbuf *server_version; | ||
148 | sig_atomic_t done; | 150 | sig_atomic_t done; |
149 | u_int flags; | 151 | u_int flags; |
150 | int hash_alg; | 152 | int hash_alg; |
151 | int ec_nid; | 153 | int ec_nid; |
152 | char *client_version_string; | ||
153 | char *server_version_string; | ||
154 | char *failed_choice; | 154 | char *failed_choice; |
155 | int (*verify_host_key)(struct sshkey *, struct ssh *); | 155 | int (*verify_host_key)(struct sshkey *, struct ssh *); |
156 | struct sshkey *(*load_host_public_key)(int, int, struct ssh *); | 156 | struct sshkey *(*load_host_public_key)(int, int, struct ssh *); |
@@ -173,7 +173,10 @@ char *kex_alg_list(char); | |||
173 | char *kex_names_cat(const char *, const char *); | 173 | char *kex_names_cat(const char *, const char *); |
174 | int kex_assemble_names(char **, const char *, const char *); | 174 | int kex_assemble_names(char **, const char *, const char *); |
175 | 175 | ||
176 | int kex_new(struct ssh *, char *[PROPOSAL_MAX], struct kex **); | 176 | int kex_exchange_identification(struct ssh *, int, const char *); |
177 | |||
178 | struct kex *kex_new(void); | ||
179 | int kex_ready(struct ssh *, char *[PROPOSAL_MAX]); | ||
177 | int kex_setup(struct ssh *, char *[PROPOSAL_MAX]); | 180 | int kex_setup(struct ssh *, char *[PROPOSAL_MAX]); |
178 | void kex_free_newkeys(struct newkeys *); | 181 | void kex_free_newkeys(struct newkeys *); |
179 | void kex_free(struct kex *); | 182 | void kex_free(struct kex *); |
@@ -199,22 +202,23 @@ int kexecdh_server(struct ssh *); | |||
199 | int kexc25519_client(struct ssh *); | 202 | int kexc25519_client(struct ssh *); |
200 | int kexc25519_server(struct ssh *); | 203 | int kexc25519_server(struct ssh *); |
201 | 204 | ||
202 | int kex_dh_hash(int, const char *, const char *, | 205 | int kex_dh_hash(int, const struct sshbuf *, const struct sshbuf *, |
203 | const u_char *, size_t, const u_char *, size_t, const u_char *, size_t, | 206 | const u_char *, size_t, const u_char *, size_t, const u_char *, size_t, |
204 | const BIGNUM *, const BIGNUM *, const BIGNUM *, u_char *, size_t *); | 207 | const BIGNUM *, const BIGNUM *, const BIGNUM *, u_char *, size_t *); |
205 | 208 | ||
206 | int kexgex_hash(int, const char *, const char *, | 209 | int kexgex_hash(int, const struct sshbuf *, const struct sshbuf *, |
207 | const u_char *, size_t, const u_char *, size_t, const u_char *, size_t, | 210 | const u_char *, size_t, const u_char *, size_t, const u_char *, size_t, |
208 | int, int, int, | 211 | int, int, int, |
209 | const BIGNUM *, const BIGNUM *, const BIGNUM *, | 212 | const BIGNUM *, const BIGNUM *, const BIGNUM *, |
210 | const BIGNUM *, const BIGNUM *, | 213 | const BIGNUM *, const BIGNUM *, |
211 | u_char *, size_t *); | 214 | u_char *, size_t *); |
212 | 215 | ||
213 | int kex_ecdh_hash(int, const EC_GROUP *, const char *, const char *, | 216 | int kex_ecdh_hash(int, const EC_GROUP *, |
217 | const struct sshbuf *, const struct sshbuf *, | ||
214 | const u_char *, size_t, const u_char *, size_t, const u_char *, size_t, | 218 | const u_char *, size_t, const u_char *, size_t, const u_char *, size_t, |
215 | const EC_POINT *, const EC_POINT *, const BIGNUM *, u_char *, size_t *); | 219 | const EC_POINT *, const EC_POINT *, const BIGNUM *, u_char *, size_t *); |
216 | 220 | ||
217 | int kex_c25519_hash(int, const char *, const char *, | 221 | int kex_c25519_hash(int, const struct sshbuf *, const struct sshbuf *, |
218 | const u_char *, size_t, const u_char *, size_t, | 222 | const u_char *, size_t, const u_char *, size_t, |
219 | const u_char *, size_t, const u_char *, const u_char *, | 223 | const u_char *, size_t, const u_char *, const u_char *, |
220 | const u_char *, size_t, u_char *, size_t *); | 224 | const u_char *, size_t, u_char *, size_t *); |