From a1a3b08e7e6279ae137286a8a447fe95a87e187a Mon Sep 17 00:00:00 2001 From: "Michael P. Soulier" Date: Fri, 7 Oct 2022 12:52:41 -0400 Subject: [PATCH] Adding a doc note on disabling TLS verification --- docs/settings.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/docs/settings.md b/docs/settings.md index 634f8df..39b8ad6 100644 --- a/docs/settings.md +++ b/docs/settings.md @@ -38,6 +38,20 @@ surf.DefaultMetaRefreshHandling = false surf.DefaultFollowRedirects = false ``` +# Disabling TLS validation +For private websites with self-signed certificates, the client will need +to be configured to disable TLS validation. This can be done like so: + +```go +import "crypto/tls" +import "net/http" +tr := &http.Transport{ + TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, + } +bow := surf.NewBrowser() +bow.SetTransport(tr) +``` + # Storage Jars Override the build in cookie jar. Surf uses cookiejar.Jar by default. ```go