Skip to content

Commit dd6c6ad

Browse files
chore: remove certificate validator (#1730)
* chore: remove signature validation using pub key from certificate code * docs * e2e test * integration test
1 parent ebbf354 commit dd6c6ad

File tree

47 files changed

+159
-1476
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+159
-1476
lines changed

Cargo.lock

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

THIRD_PARTY_NOTICES.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2558,12 +2558,6 @@ Distributed under the following license(s):
25582558
* MIT
25592559
* Apache-2.0
25602560

2561-
## webpki <https://crates.io/crates/webpki>
2562-
2563-
Distributed under the following license(s):
2564-
2565-
* ISC
2566-
25672561
## webpki-roots <https://crates.io/crates/webpki-roots>
25682562

25692563
Distributed under the following license(s):

agent-control/Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,6 @@ opentelemetry-semantic-conventions = { version = "0.31.0", features = [
6262
http-serde = "2.1.1"
6363
config = { version = "0.15.18", features = ["yaml"] }
6464
rustls = { version = "0.23.32", features = ["ring"] }
65-
webpki = { version = "0.22.4", features = ["alloc"] }
6665
x509-parser = "0.18.0"
6766
ring = "0.17.14"
6867
bytes = "1.10.1"
@@ -97,7 +96,6 @@ httpmock = { version = "0.8.0", features = ["proxy"] }
9796
serial_test = "3.2.0"
9897
futures = "0.3.31"
9998
rcgen = { version = "0.14.5", features = ["crypto"] }
100-
rustls-pemfile = { version = "2.2.0" }
10199
rstest = "0.26.1"
102100
tokio-stream = { version = "0.1.17", features = ["net"] }
103101

agent-control/src/agent_control/config.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ impl<'de> Deserialize<'de> for OpAMPClientConfig {
181181
#[serde(default)]
182182
fleet_id: String,
183183
#[serde(default)]
184-
pub signature_validation: SignatureValidatorConfig,
184+
signature_validation: SignatureValidatorConfig,
185185
}
186186

187187
let mut intermediate_spec = IntermediateOpAMPClientConfig::deserialize(deserializer)?;

agent-control/src/agent_control/run.rs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,7 @@ use crate::http::config::ProxyConfig;
1515
use crate::opamp::auth::token_retriever::TokenRetrieverImpl;
1616
use crate::opamp::client_builder::PollInterval;
1717
use crate::opamp::http::builder::OpAMPHttpClientBuilder;
18-
use crate::opamp::remote_config::validators::signature::validator::{
19-
SignatureValidator, build_signature_validator,
20-
};
18+
use crate::opamp::remote_config::validators::signature::validator::SignatureValidator;
2119
use std::error::Error;
2220
use std::fmt::{self, Display, Formatter};
2321
use std::path::PathBuf;
@@ -160,10 +158,10 @@ impl AgentControlRunner {
160158
let signature_validator = config
161159
.opamp
162160
.map(|fleet_config| {
163-
build_signature_validator(fleet_config.signature_validation, config.proxy)
161+
SignatureValidator::new(fleet_config.signature_validation, config.proxy)
164162
})
165163
.transpose()?
166-
.unwrap_or(SignatureValidator::Noop);
164+
.unwrap_or(SignatureValidator::new_noop());
167165

168166
Ok(AgentControlRunner {
169167
http_server_runner,

0 commit comments

Comments
 (0)