File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -57,21 +57,16 @@ impl CertStore {
5757 fn resolve_cert ( & self , sni : & str ) -> Option < Arc < CertifiedKey > > {
5858 // 1. Try exact match first
5959 if let Some ( cert) = self . exact_certs . get ( sni) {
60- debug ! ( "exact match for {sni}" ) ;
6160 return Some ( cert. clone ( ) ) ;
6261 }
6362
6463 // 2. Try wildcard match (only one level deep per TLS spec)
6564 // For "foo.bar.example.com", only try "bar.example.com"
6665 if let Some ( ( _, parent) ) = sni. split_once ( '.' ) {
67- if let Some ( cert) = self . wildcard_certs . get ( parent) {
68- debug ! ( "wildcard match *.{parent} for {sni}" ) ;
69- return Some ( cert. clone ( ) ) ;
70- }
66+ self . wildcard_certs . get ( parent) . cloned ( )
67+ } else {
68+ None
7169 }
72-
73- debug ! ( "no certificate found for {sni}" ) ;
74- None
7570 }
7671
7772 /// Check if a certificate exists for a domain
You can’t perform that action at this time.
0 commit comments