Skip to content

Commit

Permalink
Re-add a lint lost in v0.11.0
Browse files Browse the repository at this point in the history
Resovles #180.
  • Loading branch information
vi committed Mar 2, 2023
1 parent cb4e655 commit b7bb22f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/lints.rs
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,9 @@ impl WebsocatConfiguration2 {
if self.opts.pkcs12_der.is_some() && !self.contains_class("TlsAcceptClass") {
Err("--pkcs12-der makes no sense without an TLS connections acceptor")?;
}
if self.opts.pkcs12_der.is_none() && self.contains_class("TlsAcceptClass") {
Err("You need to specify server key and certificate using the --pkcs12-der option to use the TLS connections acceptor")?;
}
if self.opts.client_pkcs12_der.is_some() && !self.contains_class("WsClientSecureClass") && !self.contains_class("TlsConnectClass") {
Err("--client-pkcs12-der makes no sense without wss:// or ssl: connectors")?;
}
Expand Down

0 comments on commit b7bb22f

Please sign in to comment.