Skip to content

Conversation

@pluveto
Copy link
Contributor

@pluveto pluveto commented Jun 26, 2024

This PR updates the function signatures in the ext.rs file to use *mut instead of *const for the ssl and cert parameters in the SSL_use_certificate and SSL_use_PrivateKey functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:

Refactor the cvt function to use c_long instead of c_int for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the ssl_set_groups_list function to ensure it handles valid and invalid input correctly.

…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/fips-20180730/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
@pluveto pluveto changed the title chore(openssl): Update OpenSSL function signatures to use *mut instea… chore(openssl): Update OpenSSL function signatures to use *mut instead of *const Jun 26, 2024
@eaufavor eaufavor added the Refactor Code refactor or clean up. No or little functional changes. label Jul 11, 2024
@eaufavor eaufavor self-assigned this Jul 12, 2024
@eaufavor eaufavor added the WIP We are working on this feature internally label Jul 12, 2024
@eaufavor eaufavor added Accepted This change is accepted by us and merged to our internal repo and removed WIP We are working on this feature internally labels Jul 19, 2024
eaufavor pushed a commit that referenced this pull request Jul 26, 2024
…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/~~~/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
---
chore(openssl):fix increase X509 reference count

Includes-commit: 7841271
Includes-commit: e132431
Replicated-from: #308
eaufavor pushed a commit that referenced this pull request Jul 26, 2024
…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/~~~/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
---
chore(openssl):fix increase X509 reference count

Includes-commit: 7841271
Includes-commit: e132431
Replicated-from: #308
eaufavor pushed a commit that referenced this pull request Jul 26, 2024
…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/~~~/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
---
chore(openssl):fix increase X509 reference count

Includes-commit: 7841271
Includes-commit: e132431
Replicated-from: #308
@eaufavor
Copy link
Contributor

synced, thanks!

@eaufavor eaufavor closed this Aug 30, 2024
escoffier pushed a commit to escoffier/pingora that referenced this pull request Sep 6, 2024
…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/~~~/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
---
chore(openssl):fix increase X509 reference count

Includes-commit: 7841271
Includes-commit: e132431
Replicated-from: cloudflare#308
xxargonaut added a commit to xxargonaut/pingora that referenced this pull request Feb 19, 2025
…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/~~~/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
---
chore(openssl):fix increase X509 reference count

Includes-commit: 7841271b4af8d3db800d9c5d7d38a4dd33d32407
Includes-commit: e13243188916617ebb80045895e3582b883126ec
Replicated-from: cloudflare/pingora#308
xxargonaut added a commit to xxargonaut/pingora that referenced this pull request Feb 19, 2025
…d of *const

This PR updates the function signatures in the `ext.rs` file to use `*mut` instead of `*const` for the `ssl` and `cert` parameters in the `SSL_use_certificate` and `SSL_use_PrivateKey` functions. This indicates that the functions can modify the SSL and certificate objects as intended.

Ref:
- https://www.openssl.org/docs/man1.1.1/man3/SSL_use_certificate.html
https://boringssl.googlesource.com/boringssl/+/refs/tags/~~~/ssl/ssl_cert.cc#292

Refactor the `cvt` function to use `c_long` instead of `c_int` for the return type for better compatibility with the types used in the OpenSSL library.

Also, add a test case for the `ssl_set_groups_list` function to ensure it handles valid and invalid input correctly.
---
chore(openssl):fix increase X509 reference count

Includes-commit: 7841271b4af8d3db800d9c5d7d38a4dd33d32407
Includes-commit: e13243188916617ebb80045895e3582b883126ec
Replicated-from: cloudflare/pingora#308
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Accepted This change is accepted by us and merged to our internal repo Refactor Code refactor or clean up. No or little functional changes.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants