Skip to content

Commit

Permalink
Expose brainpool NIDs on libressl
Browse files Browse the repository at this point in the history
  • Loading branch information
alex committed Jan 19, 2024
1 parent a14146f commit ca3f45d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
13 changes: 13 additions & 0 deletions openssl-sys/src/obj_mac.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,14 +94,27 @@ pub const NID_sect409k1: c_int = 731;
pub const NID_sect409r1: c_int = 732;
pub const NID_sect571k1: c_int = 733;
pub const NID_sect571r1: c_int = 734;

#[cfg(ossl110)]
pub const NID_brainpoolP256r1: c_int = 927;
#[cfg(libressl)]
pub const NID_brainpoolP256r1: c_int = 928;

#[cfg(ossl110)]
pub const NID_brainpoolP320r1: c_int = 929;
#[cfg(libressl)]
pub const NID_brainpoolP320r1: c_int = 930;

#[cfg(ossl110)]
pub const NID_brainpoolP384r1: c_int = 931;
#[cfg(libressl)]
pub const NID_brainpoolP384r1: c_int = 932;

#[cfg(ossl110)]
pub const NID_brainpoolP512r1: c_int = 933;
#[cfg(libressl)]
pub const NID_brainpoolP512r1: c_int = 934;

pub const NID_wap_wsg_idm_ecid_wtls1: c_int = 735;
pub const NID_wap_wsg_idm_ecid_wtls3: c_int = 736;
pub const NID_wap_wsg_idm_ecid_wtls4: c_int = 737;
Expand Down
8 changes: 4 additions & 4 deletions openssl/src/nid.rs
Original file line number Diff line number Diff line change
Expand Up @@ -215,13 +215,13 @@ impl Nid {
pub const SECT409R1: Nid = Nid(ffi::NID_sect409r1);
pub const SECT571K1: Nid = Nid(ffi::NID_sect571k1);
pub const SECT571R1: Nid = Nid(ffi::NID_sect571r1);
#[cfg(ossl110)]
#[cfg(any(ossl110, libressl))]
pub const BRAINPOOL_P256R1: Nid = Nid(ffi::NID_brainpoolP256r1);
#[cfg(ossl110)]
#[cfg(any(ossl110, libressl))]
pub const BRAINPOOL_P320R1: Nid = Nid(ffi::NID_brainpoolP320r1);
#[cfg(ossl110)]
#[cfg(any(ossl110, libressl))]
pub const BRAINPOOL_P384R1: Nid = Nid(ffi::NID_brainpoolP384r1);
#[cfg(ossl110)]
#[cfg(any(ossl110, libressl))]
pub const BRAINPOOL_P512R1: Nid = Nid(ffi::NID_brainpoolP512r1);
pub const WAP_WSG_IDM_ECID_WTLS1: Nid = Nid(ffi::NID_wap_wsg_idm_ecid_wtls1);
pub const WAP_WSG_IDM_ECID_WTLS3: Nid = Nid(ffi::NID_wap_wsg_idm_ecid_wtls3);
Expand Down

0 comments on commit ca3f45d

Please sign in to comment.