disable SSL certificate verification on crawler

This commit is contained in:
Milos Pejanovic 2022-09-27 19:14:47 +02:00
parent 5c50c10c9e
commit 6b2b0d344c

View File

@ -2,6 +2,7 @@ package walker
import (
"context"
"crypto/tls"
"errors"
"fmt"
"net"
@ -55,6 +56,10 @@ func newClientPool(concurrency int, agent string, useCookies bool) *clientPool {
IdleConnTimeout: 15 * time.Second,
TLSHandshakeTimeout: 5 * time.Second,
ExpectContinueTimeout: 1 * time.Second,
TLSClientConfig: &tls.Config{
// disable SSL certificate verification
InsecureSkipVerify: true,
},
},
CheckRedirect: func(req *http.Request, via []*http.Request) error {