rustls-client-cert example not working
mforsb opened this issue · 2 comments
mforsb commented
The rustls-client-cert example gives the following logs
$ env RUST_LOG=debug cargo run --quiet
[2022-02-13T23:27:33Z INFO actix_server::builder] Starting 1 workers
[2022-02-13T23:27:33Z INFO actix_server::server] Actix runtime found; starting in Actix runtime
[2022-02-13T23:27:35Z DEBUG rustls::server::hs] decided upon suite Tls13(Tls13CipherSuite { suite: TLS13_AES_256_GCM_SHA384, bulk: Aes256Gcm })
[2022-02-13T23:27:35Z DEBUG rustls::server::hs] Chosen ALPN protocol [104, 116, 116, 112, 47, 49, 46, 49]
[2022-02-13T23:27:35Z INFO rustls_client_cert] TLS on_connect
[2022-02-13T23:27:35Z INFO rustls_client_cert] client certificate found
[2022-02-13T23:27:35Z DEBUG actix_web::request_data] Failed to construct App-level ReqData extractor. Request path: "/" (type: rustls_client_cert::ConnectionInfo)
[2022-02-13T23:27:35Z DEBUG actix_web::request_data] Failed to construct App-level ReqData extractor. Request path: "/" (type: rustls::key::Certificate)
and returns this response
$ http https://127.0.0.1:8443/ --verify=certs/rootCA.pem --cert=certs/client-cert.pem --cert-key=certs/client-key.pem
HTTP/1.1 500 Internal Server Error
content-length: 39
content-type: text/plain; charset=utf-8
date: Sun, 13 Feb 2022 23:27:35 GMT
Missing expected request extension data
mforsb commented
It worked before the upgrade to actix-web 4.0 so either the example is now wrong or there was a regression in 4.0. I tried upgrading to the latest git version of actix-web but that didn't fix it.
robjtede commented
thanks for the report, fixed now