Skip to content
Snippets Groups Projects
lib.rs.diff 1.12 KiB
Newer Older
  • Learn to ignore specific revisions
  • --- lib.rs.old	2024-12-17 14:28:11.781539625 +0100
    +++ lib.rs	2024-12-17 14:29:12.866862148 +0100
    @@ -848,6 +848,13 @@
             Self::with_tls_ctx(version, tls::Context::from_boring(tls_ctx_builder))
         }
     
    +    /// Sets groups for TLS key exchange.
    +    /// Own patch implementation
    +    // #[cfg(feature = "openssl")]
    +    pub fn set_groups(&mut self, groups: &str) -> Result<()> {
    +        self.tls_ctx.set_groups(groups)
    +    }
    +
         fn with_tls_ctx(version: u32, tls_ctx: tls::Context) -> Result<Config> {
             if !is_reserved_version(version) && !version_is_supported(version) {
                 return Err(Error::UnknownVersion);
    
    @@ -2032,7 +2039,7 @@
             // Derive initial secrets for the client. We can do this here because
             // we already generated the random destination connection ID.
             if !is_server {
    -            let mut dcid = [0; 16];
    +            let mut dcid = [0; 11]; // change to be the same as the length of openssls generated initial dcid minus too long packet number encoding
                 rand::rand_bytes(&mut dcid[..]);
     
                 let (aead_open, aead_seal) = crypto::derive_initial_key_material(