@@ -432,7 +432,7 @@ func fetchCaptchaBootstrap(ctx context.Context, redirectURI string, client tlscl
432432 }
433433 domain := parsedURL .Hostname ()
434434
435- req , err := fhttp .NewRequestWithContext (ctx , "GET" , RedirectURI , nil )
435+ req , err := fhttp .NewRequestWithContext (ctx , "GET" , redirectURI , nil )
436436 if err != nil {
437437 return nil , err
438438 }
@@ -936,7 +936,7 @@ func getTokenChain(ctx context.Context, link string, streamID int, creds VKCrede
936936 solveErr = fmt .Errorf ("missing fields for auto solve" )
937937 }
938938 case captchaSolveModeSliderPOC :
939- if captchaErr .SessionToken != "" && captchaErr .RedirectUri != "" {
939+ if captchaErr .SessionToken != "" && captchaErr .RedirectURI != "" {
940940 successToken , solveErr = solveVkCaptcha (ctx , captchaErr , streamID , client , profile , true )
941941 if solveErr != nil {
942942 log .Printf ("[STREAM %d] [Captcha] Auto captcha slider POC failed: %v" , streamID , solveErr )
@@ -2215,14 +2215,13 @@ func createSmuxSession(ctx context.Context, tp *turnParams, peer *net.UDPAddr, i
22152215 return nil , nil , fmt .Errorf ("generate cert: %w" , err )
22162216 }
22172217 dtlsPC := & relayPacketConn {relay : relayConn , peer : peer }
2218- dtlsConfig := & dtls.Config {
2219- Certificates : []tls.Certificate {certificate },
2220- InsecureSkipVerify : true ,
2221- ExtendedMasterSecret : dtls .RequireExtendedMasterSecret ,
2222- CipherSuites : []dtls.CipherSuiteID {dtls .TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 },
2223- ConnectionIDGenerator : dtls .OnlySendCIDGenerator (),
2224- }
2225- dtlsConn , err := dtls .Client (dtlsPC , peer , dtlsConfig )
2218+ dtlsConn , err := dtls .ClientWithOptions (dtlsPC , peer ,
2219+ dtls .WithCertificates (certificate ),
2220+ dtls .WithInsecureSkipVerify (true ),
2221+ dtls .WithExtendedMasterSecret (dtls .RequireExtendedMasterSecret ),
2222+ dtls .WithCipherSuites (dtls .TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 ),
2223+ dtls .WithConnectionIDGenerator (dtls .OnlySendCIDGenerator ()),
2224+ )
22262225 if err != nil {
22272226 cleanup ()
22282227 return nil , nil , fmt .Errorf ("DTLS client create: %w" , err )
0 commit comments