diff options
author | jsing <> | 2018-11-05 05:45:15 +0000 |
---|---|---|
committer | jsing <> | 2018-11-05 05:45:15 +0000 |
commit | 2ab1af323eb2251dedee9fcb3661f284ae62b640 (patch) | |
tree | 3f0fe5c046ee4d7240d6ea15879199dca6797790 /src/lib/libssl/d1_srvr.c | |
parent | 1747118e379623d86b5f53dcc99d185f9868ce43 (diff) | |
download | openbsd-2ab1af323eb2251dedee9fcb3661f284ae62b640.tar.gz openbsd-2ab1af323eb2251dedee9fcb3661f284ae62b640.tar.bz2 openbsd-2ab1af323eb2251dedee9fcb3661f284ae62b640.zip |
Consolidate all of the SSL method structs/functions into a single file.
Discussed with tb@
Diffstat (limited to 'src/lib/libssl/d1_srvr.c')
-rw-r--r-- | src/lib/libssl/d1_srvr.c | 45 |
1 files changed, 1 insertions, 44 deletions
diff --git a/src/lib/libssl/d1_srvr.c b/src/lib/libssl/d1_srvr.c index c0ee0d00aa..1a1ee5429e 100644 --- a/src/lib/libssl/d1_srvr.c +++ b/src/lib/libssl/d1_srvr.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: d1_srvr.c,v 1.94 2018/08/30 16:56:16 jsing Exp $ */ | 1 | /* $OpenBSD: d1_srvr.c,v 1.95 2018/11/05 05:45:15 jsing Exp $ */ |
2 | /* | 2 | /* |
3 | * DTLS implementation written by Nagendra Modadugu | 3 | * DTLS implementation written by Nagendra Modadugu |
4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. | 4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. |
@@ -125,49 +125,6 @@ | |||
125 | #include <openssl/objects.h> | 125 | #include <openssl/objects.h> |
126 | #include <openssl/x509.h> | 126 | #include <openssl/x509.h> |
127 | 127 | ||
128 | static const SSL_METHOD_INTERNAL DTLSv1_server_method_internal_data = { | ||
129 | .version = DTLS1_VERSION, | ||
130 | .min_version = DTLS1_VERSION, | ||
131 | .max_version = DTLS1_VERSION, | ||
132 | .ssl_new = dtls1_new, | ||
133 | .ssl_clear = dtls1_clear, | ||
134 | .ssl_free = dtls1_free, | ||
135 | .ssl_accept = ssl3_accept, | ||
136 | .ssl_connect = ssl_undefined_function, | ||
137 | .get_ssl_method = dtls1_get_server_method, | ||
138 | .get_timeout = dtls1_default_timeout, | ||
139 | .ssl_version = ssl_undefined_void_function, | ||
140 | .ssl_renegotiate = ssl3_renegotiate, | ||
141 | .ssl_renegotiate_check = ssl3_renegotiate_check, | ||
142 | .ssl_get_message = dtls1_get_message, | ||
143 | .ssl_read_bytes = dtls1_read_bytes, | ||
144 | .ssl_write_bytes = dtls1_write_app_data_bytes, | ||
145 | .ssl3_enc = &DTLSv1_enc_data, | ||
146 | }; | ||
147 | |||
148 | static const SSL_METHOD DTLSv1_server_method_data = { | ||
149 | .ssl_dispatch_alert = dtls1_dispatch_alert, | ||
150 | .num_ciphers = ssl3_num_ciphers, | ||
151 | .get_cipher = dtls1_get_cipher, | ||
152 | .get_cipher_by_char = ssl3_get_cipher_by_char, | ||
153 | .put_cipher_by_char = ssl3_put_cipher_by_char, | ||
154 | .internal = &DTLSv1_server_method_internal_data, | ||
155 | }; | ||
156 | |||
157 | const SSL_METHOD * | ||
158 | DTLSv1_server_method(void) | ||
159 | { | ||
160 | return &DTLSv1_server_method_data; | ||
161 | } | ||
162 | |||
163 | const SSL_METHOD * | ||
164 | dtls1_get_server_method(int ver) | ||
165 | { | ||
166 | if (ver == DTLS1_VERSION) | ||
167 | return (DTLSv1_server_method()); | ||
168 | return (NULL); | ||
169 | } | ||
170 | |||
171 | int | 128 | int |
172 | dtls1_send_hello_verify_request(SSL *s) | 129 | dtls1_send_hello_verify_request(SSL *s) |
173 | { | 130 | { |