Skip to content

Commit 5adedcf

Browse files
committed
Add client certificates to push-attestation prototype
This replaces the usage of `default-tls` feature from reqwest with `native-tls`, which uses OpenSSL as backend on Linux. Add 'anyhow' crate as dependency to add context information to user facing errors. This also disables the hostname verification because the certificates generated by the verifier don't have the Subject Alternative Name (SAN) set properly, making the certificates to fail hostname verification Signed-off-by: Anderson Toshiyuki Sasaki <[email protected]>
1 parent 2227423 commit 5adedcf

File tree

5 files changed

+143
-44
lines changed

5 files changed

+143
-44
lines changed

Cargo.lock

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ version = "0.2.7"
1717
[workspace.dependencies]
1818
actix-rt = "2"
1919
actix-web = { version = "4", default-features = false, features = ["macros", "openssl"] }
20+
anyhow = { version = "1.0", features = ["backtrace"] }
2021
assert_cmd = { version = "2.0.16" }
2122
base64 = "0.22"
2223
cfg-if = "1"
@@ -35,7 +36,7 @@ picky-asn1-der = "0.4"
3536
picky-asn1-x509 = "0.12"
3637
predicates = { version = "3.1.3" }
3738
pretty_env_logger = "0.5"
38-
reqwest = {version = "0.12", default-features = false, features = ["json", "default-tls"]}
39+
reqwest = {version = "0.12", default-features = false, features = ["json", "native-tls"]}
3940
serde = "1.0.80"
4041
serde_derive = "1.0.80"
4142
serde_json = { version = "1.0", features = ["raw_value"] }

keylime-push-model-agent/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ version.workspace = true
99

1010
[dependencies]
1111
actix-web.workspace = true
12+
anyhow.workspace = true
1213
assert_cmd.workspace = true
1314
clap.workspace = true
1415
keylime.workspace = true
@@ -24,6 +25,7 @@ tokio.workspace = true
2425

2526
[dev-dependencies]
2627
actix-rt.workspace = true
28+
tempfile.workspace = true
2729

2830
[features]
2931
# The features enabled by default

0 commit comments

Comments
 (0)