Skip to content

Commit 372aa3e

Browse files
committed
Implement SSL_renegotiate_pending
1 parent e11431f commit 372aa3e

4 files changed

Lines changed: 10 additions & 1 deletion

File tree

MATRIX.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@
405405
| `SSL_read_ex` | | | | |
406406
| `SSL_renegotiate` | | | | :exclamation: [^stub] |
407407
| `SSL_renegotiate_abbreviated` | | | | |
408-
| `SSL_renegotiate_pending` | | | :white_check_mark: | |
408+
| `SSL_renegotiate_pending` | | | :white_check_mark: | :white_check_mark: |
409409
| `SSL_rstate_string` | | | | |
410410
| `SSL_rstate_string_long` | | | | |
411411
| `SSL_select_next_proto` | | :white_check_mark: | :white_check_mark: | :white_check_mark: |

build.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,7 @@ const ENTRYPOINTS: &[&str] = &[
199199
"SSL_read",
200200
"SSL_read_early_data",
201201
"SSL_renegotiate",
202+
"SSL_renegotiate_pending",
202203
"SSL_select_next_proto",
203204
"SSL_sendfile",
204205
"SSL_SESSION_free",

src/entry.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1494,6 +1494,13 @@ entry! {
14941494
}
14951495
}
14961496

1497+
entry! {
1498+
pub fn _SSL_renegotiate_pending(_ssl: *mut SSL) -> c_int {
1499+
// rustls does not implement renegotiation, so it is never pending.
1500+
0
1501+
}
1502+
}
1503+
14971504
impl Castable for SSL {
14981505
type Ownership = OwnershipArc;
14991506
type RustType = NotThreadSafe<Self>;

tests/client.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ int main(int argc, char **argv) {
100100
printf("SSL_get_verify_depth default %d\n", SSL_get_verify_depth(ssl));
101101
printf("SSL_get_min_proto_version 0x%lx\n", SSL_get_min_proto_version(ssl));
102102
printf("SSL_get_max_proto_version 0x%lx\n", SSL_get_max_proto_version(ssl));
103+
printf("SSL_renegotiate_pending %d\n", SSL_renegotiate_pending(ssl));
103104
printf("SSL_get_servername: %s (%d)\n",
104105
SSL_get_servername(ssl, TLSEXT_NAMETYPE_host_name),
105106
SSL_get_servername_type(ssl));

0 commit comments

Comments
 (0)