mirror of
https://github.com/MercuryWorkshop/epoxy-tls.git
synced 2025-05-12 05:50:01 -04:00
refactor protocol extensions
This commit is contained in:
parent
1ae3986a82
commit
36fddc8943
10 changed files with 289 additions and 190 deletions
|
@ -139,7 +139,7 @@ async fn main() -> Result<(), Box<dyn Error + Send + Sync>> {
|
|||
let split: Vec<_> = auth.split(':').collect();
|
||||
let username = split[0].to_string();
|
||||
let password = split[1..].join(":");
|
||||
PasswordProtocolExtensionBuilder::new_client(username, password)
|
||||
PasswordProtocolExtensionBuilder::new_client(Some((username, password)))
|
||||
});
|
||||
|
||||
println!(
|
||||
|
@ -188,7 +188,7 @@ async fn main() -> Result<(), Box<dyn Error + Send + Sync>> {
|
|||
}
|
||||
if let Some(certauth) = opts.certauth {
|
||||
let key = get_cert(certauth).await?;
|
||||
let extension = CertAuthProtocolExtensionBuilder::new_client(key);
|
||||
let extension = CertAuthProtocolExtensionBuilder::new_client(Some(key));
|
||||
extensions.push(AnyProtocolExtensionBuilder::new(extension));
|
||||
extension_ids.push(CertAuthProtocolExtension::ID);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue