Skip to content

Commit

Permalink
fix(command): do not override subject and san of certificate when loa…
Browse files Browse the repository at this point in the history
…ding configuration from file

Signed-off-by: Florentin Dubois <[email protected]>
  • Loading branch information
FlorentinDUBOIS committed May 29, 2024
1 parent 34d8b93 commit a7eded1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion command/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -919,7 +919,10 @@ impl HttpFrontendConfig {
certificate: self.certificate.clone().unwrap(),
certificate_chain: self.certificate_chain.clone().unwrap_or_default(),
versions: self.tls_versions.iter().map(|v| *v as i32).collect(),
names: vec![self.hostname.clone()],
// This field is used to override the certificate subject and san, we should not set when loading
// the configuration it, as we may provide a wildcard certificate for a specific domain, and it
// will reject legit traffic for others domains.
names: vec![],
},
expired_at: None,
})
Expand Down

0 comments on commit a7eded1

Please sign in to comment.