Skip to content

Commit

Permalink
Stub out SSL_CTX_{set,get}_timeout
Browse files Browse the repository at this point in the history
rustls currently could support these with stateless resumption.
  • Loading branch information
ctz committed Apr 5, 2024
1 parent 9391880 commit e2e3b54
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rustls-libssl/MATRIX.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@
| `SSL_CTX_get_security_callback` | | | |
| `SSL_CTX_get_security_level` | | | |
| `SSL_CTX_get_ssl_method` | | | |
| `SSL_CTX_get_timeout` | | :white_check_mark: | |
| `SSL_CTX_get_timeout` | | :white_check_mark: | :exclamation: [^stub] |
| `SSL_CTX_get_verify_callback` | | :white_check_mark: | :white_check_mark: |
| `SSL_CTX_get_verify_depth` | | :white_check_mark: | :white_check_mark: |
| `SSL_CTX_get_verify_mode` | | :white_check_mark: | :white_check_mark: |
Expand Down Expand Up @@ -191,7 +191,7 @@
| `SSL_CTX_set_ssl_version` [^deprecatedin_3_0] | | | |
| `SSL_CTX_set_stateless_cookie_generate_cb` | | | |
| `SSL_CTX_set_stateless_cookie_verify_cb` | | | |
| `SSL_CTX_set_timeout` | | :white_check_mark: | |
| `SSL_CTX_set_timeout` | | :white_check_mark: | :exclamation: [^stub] |
| `SSL_CTX_set_tlsext_max_fragment_length` | | | |
| `SSL_CTX_set_tlsext_ticket_key_evp_cb` | | | |
| `SSL_CTX_set_tlsext_use_srtp` [^srtp] | | | |
Expand Down
2 changes: 2 additions & 0 deletions rustls-libssl/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ const ENTRYPOINTS: &[&str] = &[
"SSL_CTX_get_ex_data",
"SSL_CTX_get_max_early_data",
"SSL_CTX_get_options",
"SSL_CTX_get_timeout",
"SSL_CTX_get_verify_callback",
"SSL_CTX_get_verify_depth",
"SSL_CTX_get_verify_mode",
Expand Down Expand Up @@ -100,6 +101,7 @@ const ENTRYPOINTS: &[&str] = &[
"SSL_CTX_set_session_id_context",
"SSL_CTX_set_srp_password",
"SSL_CTX_set_srp_username",
"SSL_CTX_set_timeout",
"SSL_CTX_set_verify",
"SSL_CTX_set_verify_depth",
"SSL_CTX_up_ref",
Expand Down
8 changes: 8 additions & 0 deletions rustls-libssl/src/entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1724,6 +1724,14 @@ entry_stub! {
) -> c_int;
}

entry_stub! {
pub fn _SSL_CTX_get_timeout(_ctx: *const SSL_CTX) -> c_long;
}

entry_stub! {
pub fn _SSL_CTX_set_timeout(_ctx: *mut SSL_CTX, _t: c_long) -> c_long;
}

// no individual message logging

entry_stub! {
Expand Down

0 comments on commit e2e3b54

Please sign in to comment.