Skip to content

Commit

Permalink
Implement & test ECDSA support
Browse files Browse the repository at this point in the history
  • Loading branch information
ctz committed May 3, 2024
1 parent cab679f commit 02d583c
Show file tree
Hide file tree
Showing 12 changed files with 237 additions and 2 deletions.
28 changes: 28 additions & 0 deletions rustls-libssl/src/evp_pkey.rs
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,34 @@ impl EvpScheme for Ed25519 {
}
}

pub fn ecdsa_sha256() -> Box<dyn EvpScheme + Send + Sync> {
Box::new(Ecdsa(unsafe { EVP_sha256() }))
}

pub fn ecdsa_sha384() -> Box<dyn EvpScheme + Send + Sync> {
Box::new(Ecdsa(unsafe { EVP_sha384() }))
}

pub fn ecdsa_sha512() -> Box<dyn EvpScheme + Send + Sync> {
Box::new(Ecdsa(unsafe { EVP_sha512() }))
}

#[derive(Debug)]
struct Ecdsa(*const EVP_MD);

impl EvpScheme for Ecdsa {
fn digest(&self) -> *mut EVP_MD {
self.0 as *mut EVP_MD
}

fn configure_ctx(&self, _: &mut SignCtx) -> Option<()> {
Some(())
}
}

unsafe impl Sync for Ecdsa {}
unsafe impl Send for Ecdsa {}

/// Owning wrapper for a signing `EVP_MD_CTX`
pub(crate) struct SignCtx {
md_ctx: *mut EVP_MD_CTX,
Expand Down
29 changes: 27 additions & 2 deletions rustls-libssl/src/sign.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ use rustls::{SignatureAlgorithm, SignatureScheme};

use crate::error;
use crate::evp_pkey::{
ed25519, rsa_pkcs1_sha256, rsa_pkcs1_sha384, rsa_pkcs1_sha512, rsa_pss_sha256, rsa_pss_sha384,
rsa_pss_sha512, EvpPkey, EvpScheme,
ecdsa_sha256, ecdsa_sha384, ecdsa_sha512, ed25519, rsa_pkcs1_sha256, rsa_pkcs1_sha384,
rsa_pkcs1_sha512, rsa_pss_sha256, rsa_pss_sha384, rsa_pss_sha512, EvpPkey, EvpScheme,
};
use crate::x509::OwnedX509Stack;

Expand Down Expand Up @@ -216,6 +216,31 @@ impl sign::SigningKey for OpenSslKey {

None
}
SignatureAlgorithm::ECDSA => {
if offered.contains(&SignatureScheme::ECDSA_NISTP256_SHA256) {
return Some(Box::new(OpenSslSigner {
pkey: self.0.clone(),
pscheme: ecdsa_sha256(),
scheme: SignatureScheme::ECDSA_NISTP256_SHA256,
}));
}
if offered.contains(&SignatureScheme::ECDSA_NISTP384_SHA384) {
return Some(Box::new(OpenSslSigner {
pkey: self.0.clone(),
pscheme: ecdsa_sha384(),
scheme: SignatureScheme::ECDSA_NISTP384_SHA384,
}));
}
if offered.contains(&SignatureScheme::ECDSA_NISTP521_SHA512) {
return Some(Box::new(OpenSslSigner {
pkey: self.0.clone(),
pscheme: ecdsa_sha512(),
scheme: SignatureScheme::ECDSA_NISTP521_SHA512,
}));
}

None
}
_ => None,
}
}
Expand Down
12 changes: 12 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p256/ca.cert
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
-----BEGIN CERTIFICATE-----
MIIBtzCCAV2gAwIBAgIBBDAKBggqhkjOPQQDAjAhMR8wHQYDVQQDDBZwb255dG93
biBFQ0RTQSBwMjU2IENBMCAXDTc1MDEwMTAwMDAwMFoYDzQwOTYwMTAxMDAwMDAw
WjAhMR8wHQYDVQQDDBZwb255dG93biBFQ0RTQSBwMjU2IENBMFkwEwYHKoZIzj0C
AQYIKoZIzj0DAQcDQgAEt7wL3biRoR6fSefjp0t08cudi2zQUounGCxjHQY1brlh
IVUp2VfP/FhPKBX7VgHRHTJoukAAtg12Aks7cqalEKOBgzCBgDAfBgNVHSMEGDAW
gBRfW6pxJGPHn4+tADqUNDV6Uo8xyDAOBgNVHQ8BAf8EBAMCAf4wHQYDVR0lBBYw
FAYIKwYBBQUHAwEGCCsGAQUFBwMCMB0GA1UdDgQWBBRfW6pxJGPHn4+tADqUNDV6
Uo8xyDAPBgNVHRMBAf8EBTADAQH/MAoGCCqGSM49BAMCA0gAMEUCIFZel8Z3muq9
cA5ZQfnoPyXbPv5yf0aT+VsXDk0mirdoAiEAjzViKYx3OOYAnlRSvlDabDbqXy2f
Vezw14zRbrDN9D4=
-----END CERTIFICATE-----
36 changes: 36 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p256/server.cert
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
-----BEGIN CERTIFICATE-----
MIIBxjCCAW2gAwIBAgIBEjAKBggqhkjOPQQDAjAzMTEwLwYDVQQDDChwb255dG93
biBFQ0RTQSBwMjU2IGxldmVsIDIgaW50ZXJtZWRpYXRlMCAXDTc1MDEwMTAwMDAw
MFoYDzQwOTYwMTAxMDAwMDAwWjAZMRcwFQYDVQQDDA50ZXN0c2VydmVyLmNvbTBZ
MBMGByqGSM49AgEGCCqGSM49AwEHA0IABNjZ6JNt+53aq8bcp33lKeJGPSZZRzHg
fuFuCBQyC1Yx0s8ff4MUQcnzrwqde++6eKiQkwy8oC4v60tsICflmY+jgYkwgYYw
HwYDVR0jBBgwFoAU0jOcpG97skCpDmP1BEpFfjcVnHIwUwYDVR0RBEwwSoIOdGVz
dHNlcnZlci5jb22CFXNlY29uZC50ZXN0c2VydmVyLmNvbYIJbG9jYWxob3N0hwTG
M2QBhxAgAQ24AAAAAAAAAAAAAAABMA4GA1UdDwEB/wQEAwIGwDAKBggqhkjOPQQD
AgNHADBEAiAoZIrzdGAMX4UJ6Nq9pfKk8s95OmY6sPv2cMQX68JmRQIgCkMJNt5R
4tHOCXLj/2duxXss95/Q+r3sXrOJDn/96dk=
-----END CERTIFICATE-----
-----BEGIN CERTIFICATE-----
MIIByDCCAW+gAwIBAgIBCzAKBggqhkjOPQQDAjAhMR8wHQYDVQQDDBZwb255dG93
biBFQ0RTQSBwMjU2IENBMCAXDTc1MDEwMTAwMDAwMFoYDzQwOTYwMTAxMDAwMDAw
WjAzMTEwLwYDVQQDDChwb255dG93biBFQ0RTQSBwMjU2IGxldmVsIDIgaW50ZXJt
ZWRpYXRlMFkwEwYHKoZIzj0CAQY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es: 5 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p256/server.key
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
-----BEGIN PRIVATE KEY-----
MIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQgMyvFQ1aDiQcxbZAT
EtOOXL91NxQ9mwzZojvaJF276kihRANCAATY2eiTbfud2qvG3Kd95SniRj0mWUcx
4H7hbggUMgtWMdLPH3+DFEHJ868KnXvvuniokJMMvKAuL+tLbCAn5ZmP
-----END PRIVATE KEY-----
13 changes: 13 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p384/ca.cert
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
-----BEGIN CERTIFICATE-----
MIIB9DCCAXqgAwIBAgIBBTAKBggqhkjOPQQDAzAhMR8wHQYDVQQDDBZwb255dG93
biBFQ0RTQSBwMzg0IENBMCAXDTc1MDEwMTAwMDAwMFoYDzQwOTYwMTAxMDAwMDAw
WjAhMR8wHQYDVQQDDBZwb255dG93biBFQ0RTQSBwMzg0IENBMHYwEAYHKoZIzj0C
AQYFK4EEACIDYgAEDEC6KiN/ndgCEKUK+opKyRctlbb6R62CMqPF2y/oGfZlIqNT
yfmY6tQ0eqR6fo0KAxinwU6mbfydyu0+pIGW0lqf3NhQENMErSRrdCUDNxh47Xef
StgVMDD+dMI1PwFjo4GDMIGAMB8GA1UdIwQYMBaAFEwlemtPJLok55o6Szy1gNQz
72dpMA4GA1UdDwEB/wQEAwIB/jAdBgNVHSUEFjAUBggrBgEFBQcDAQYIKwYBBQUH
AwIwHQYDVR0OBBYEFEwlemtPJLok55o6Szy1gNQz72dpMA8GA1UdEwEB/wQFMAMB
Af8wCgYIKoZIzj0EAwMDaAAwZQIxALb7BmuYs0vF5QUupqaNhTIUgxNNa39N+1GR
E1QCnUUd6tXj/UawVBBrei3CbUxC2wIwRW5RrYosKIIZtnxkQsPrapY3mxIitRqC
lpd7Vf2wBvi1Kf3LtWLSG6NMIB8TO7Rs
-----END CERTIFICATE-----
39 changes: 39 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p384/server.cert
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
-----BEGIN CERTIFICATE-----
MIICBTCCAYqgAwIBAgIBEzAKBggqhkjOPQQDAzAzMTEwLwYDVQQDDChwb255dG93
biBFQ0RTQSBwMzg0IGxldmVsIDIgaW50ZXJtZWRpYXRlMCAXDTc1MDEwMTAwMDAw
MFoYDzQwOTYwMTAxMDAwMDAwWjAZMRcwFQYDVQQDDA50ZXN0c2VydmVyLmNvbTB2
MBAGByqGSM49AgEGBSuBBAAiA2IABO+9bzwsp+UMJE9q1hZHotYJ6HYIT0wz3nML
54iNzsZlA9f1yIqf2aL+BMfSD2pCHfVgWTEZFp7WEvIhrDu+WcUXHoRQ31p9lw6X
MzJWXihbN0OU5nBOPPcyImL5TIhIWKOBiTCBhjAfBgNVHSMEGDAWgBR7EQhJDBu8
+OtZdw2OB7lPdAz7NDBTBgNVHREETDBKgg50ZXN0c2VydmVyLmNvbYIVc2Vjb25k
LnRlc3RzZXJ2ZXIuY29tgglsb2NhbGhvc3SHBMYzZAGHECABDbgAAAAAAAAAAAAA
AAEwDgYDVR0PAQH/BAQDAgbAMAoGCCqGSM49BAMDA2kAMGYCMQDkM+CEeHnsf4Ww
YNDUjNlodcpJDxEk4PTsIECvu2EdQjLXHt0vrogZeAVvHhUMixcCMQDB/pZCcjsW
ly7qVSS2f9PJE/LY7dLv9Gg2gLQyhAj3hG1zVC8psFK/KRKME6ypVZ0=
-----END CERTIFICATE-----
-----BEGIN CERTIFICATE-----
MIICBjCCAYygAwIBAgIBDDAKBggqhkjOPQQDAzAhMR8wHQYDVQQDDBZwb255dG93
biBFQ0RTQSBwMzg0IENBMCAXDTc1MDEwMTAwMDAwMFoYDzQwOTYwMTAxMDAwMDAw
WjAzMTEwLwYDVQQDDChwb255dG93biBFQ0RTQSBwMzg0IGxldmVsIDIgaW50ZXJt
ZWRpYXRlMHYwEAYH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AAwZQIxALb7BmuYs0vF5QUupqaNhTIUgxNNa39N+1GR
E1QCnUUd6tXj/UawVBBrei3CbUxC2wIwRW5RrYosKIIZtnxkQsPrapY3mxIitRqC
lpd7Vf2wBvi1Kf3LtWLSG6NMIB8TO7Rs
-----END CERTIFICATE-----
6 changes: 6 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p384/server.key
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
-----BEGIN PRIVATE KEY-----
MIG2AgEAMBAGByqGSM49AgEGBSuBBAAiBIGeMIGbAgEBBDA9ijAQuSTgVl10LcJO
f9UA7L8jb9N0bxvCjAvGWzzojcYD6sWFkq9Fyc7YNa0K9YihZANiAATvvW88LKfl
DCRPatYWR6LWCeh2CE9MM95zC+eIjc7GZQPX9ciKn9mi/gTH0g9qQh31YFkxGRae
1hLyIaw7vlnFFx6EUN9afZcOlzMyVl4oWzdDlOZwTjz3MiJi+UyISFg=
-----END PRIVATE KEY-----
15 changes: 15 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p521/ca.cert
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
-----BEGIN CERTIFICATE-----
MIICPjCCAaCgAwIBAgIBBjAKBggqhkjOPQQDBDAhMR8wHQYDVQQDDBZwb255dG93
biBFQ0RTQSBwNTIxIENBMCAXDTc1MDEwMTAwMDAwMFoYDzQwOTYwMTAxMDAwMDAw
WjAhMR8wHQYDVQQDDBZwb255dG93biBFQ0RTQSBwNTIxIENBMIGbMBAGByqGSM49
AgEGBSuBBAAjA4GGAAQBNE6id6TKt03nKiz09bDEM1h1f2JJ0QjWgiCovHNbjEWw
FI5PQ0MqAMjhbeoRBvvOXEQLd41J0XcbCXg0GwZqmdgArcmTlO8IAdoVQCg3jp3w
3s9SHxk/ebZqyd6iNsyYGCwIVr7FtBGUm39ONNS8nxrcIUpP00hpUF9jdhaSbssF
K82jgYMwgYAwHwYDVR0jBBgwFoAUOjnapNNhlEVqJx92t5jbBm9XsMwwDgYDVR0P
AQH/BAQDAgH+MB0GA1UdJQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjAdBgNVHQ4E
FgQUOjnapNNhlEVqJx92t5jbBm9XsMwwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjO
PQQDBAOBiwAwgYcCQRlgAuUKnW527uUTyEjsaZcsssAu37olCWXuduP9tNyhLYPr
lYlu+ltLmR250DdikBXAl3unkpYEAdQam9lc1nMxAkIBVBah69psNw9vjrR9jNtp
Ql22JD6hpeJsWFe0gdDhNZjIS+sKPXrDj3YfmRHLm9JsgVKinMaVMfI8DstuIaET
IzE=
-----END CERTIFICATE-----
45 changes: 45 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p521/server.cert
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
-----BEGIN CERTIFICATE-----
MIICTzCCAbCgAwIBAgIBFDAKBggqhkjOPQQDBDAzMTEwLwYDVQQDDChwb255dG93
biBFQ0RTQSBwNTIxIGxldmVsIDIgaW50ZXJtZWRpYXRlMCAXDTc1MDEwMTAwMDAw
MFoYDzQwOTYwMTAxMDAwMDAwWjAZMRcwFQYDVQQDDA50ZXN0c2VydmVyLmNvbTCB
mzAQBgcqhkjOPQIBBgUrgQQAIwOBhgAEAIeQ9nmRpEKiaPHndWHt+MHk0HhYKJ68
mRNXyqIV2h2PdBRnX2LOMFUG6soS0C+DwY6PJnxggheUAUFfPuj7FO5eABouUuKS
wO7BsOQgWk0tJBPMWpE1M+nqab3Sq79B2bdtZaoMciP1fMO7Y92RMWJHTEWuo+cV
V2TOPN6QsMPA17sno4GJMIGGMB8GA1UdIwQYMBaAFKzEA+eqUyatDn0QF2/CitNP
hRQ0MFMGA1UdEQRMMEqCDnRlc3RzZXJ2ZXIuY29tghVzZWNvbmQudGVzdHNlcnZl
ci5jb22CCWxvY2FsaG9zdIcExjNkAYcQIAENuAAAAAAAAAAAAAAAATAOBgNVHQ8B
Af8EBAMCBsAwCgYIKoZIzj0EAwQDgYwAMIGIAkIA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AwIBAgIBBjAKBggqhkjOPQQDBDAhMR8wHQYDVQQDDBZwb255dG93
biBFQ0RTQSBwNTIxIENBMCAXDTc1MDEwMTAwMDAwMFoYDzQwOTYwMTAxMDAwMDAw
WjAhMR8wHQYDVQQDDBZwb255dG93biBFQ0RTQSBwNTIxIENBMIGbMBAGByqGSM49
AgEGBSuBBAAjA4GGAAQBNE6id6TKt03nKiz09bDEM1h1f2JJ0QjWgiCovHNbjEWw
FI5PQ0MqAMjhbeoRBvvOXEQLd41J0XcbCXg0GwZqmdgArcmTlO8IAdoVQCg3jp3w
3s9SHxk/ebZqyd6iNsyYGCwIVr7FtBGUm39ONNS8nxrcIUpP00hpUF9jdhaSbssF
K82jgYMwgYAwHwYDVR0jBBgwFoAUOjnapNNhlEVqJx92t5jbBm9XsMwwDgYDVR0P
AQH/BAQDAgH+MB0GA1UdJQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjAdBgNVHQ4E
FgQUOjnapNNhlEVqJx92t5jbBm9XsMwwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjO
PQQDBAOBiwAwgYcCQRlgAuUKnW527uUTyEjsaZcsssAu37olCWXuduP9tNyhLYPr
lYlu+ltLmR250DdikBXAl3unkpYEAdQam9lc1nMxAkIBVBah69psNw9vjrR9jNtp
Ql22JD6hpeJsWFe0gdDhNZjIS+sKPXrDj3YfmRHLm9JsgVKinMaVMfI8DstuIaET
IzE=
-----END CERTIFICATE-----
8 changes: 8 additions & 0 deletions rustls-libssl/test-ca/ecdsa-p521/server.key
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
-----BEGIN PRIVATE KEY-----
MIHuAgEAMBAGByqGSM49AgEGBSuBBAAjBIHWMIHTAgEBBEIA2udCT3jmo9pjJThF
nw5rUTOWEUsJqvOSGi9huhY6K4q3vMk7oOdRke3UiR6CebOdv0drE8aYVEJM6+yD
eu8752ihgYkDgYYABACHkPZ5kaRComjx53Vh7fjB5NB4WCievJkTV8qiFdodj3QU
Z19izjBVBurKEtAvg8GOjyZ8YIIXlAFBXz7o+xTuXgAaLlLiksDuwbDkIFpNLSQT
zFqRNTPp6mm90qu/Qdm3bWWqDHIj9XzDu2PdkTFiR0xFrqPnFVdkzjzekLDDwNe7
Jw==
-----END PRIVATE KEY-----
3 changes: 3 additions & 0 deletions rustls-libssl/tests/runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,9 @@ fn server_key_algorithms() {
server_with_key_algorithm("rsa", "rsa_pkcs1_sha384", "-tls1_2");
server_with_key_algorithm("rsa", "rsa_pkcs1_sha512", "-tls1_2");
server_with_key_algorithm("ed25519", "ed25519", "-tls1_3");
server_with_key_algorithm("ecdsa-p256", "ecdsa_secp256r1_sha256", "-tls1_3");
server_with_key_algorithm("ecdsa-p384", "ecdsa_secp384r1_sha384", "-tls1_3");
server_with_key_algorithm("ecdsa-p521", "ecdsa_secp521r1_sha512", "-tls1_3");
}

const NGINX_LOG_LEVEL: &str = "info";
Expand Down

0 comments on commit 02d583c

Please sign in to comment.