aboutsummaryrefslogtreecommitdiffstats
path: root/internal/safehttp/safehttp.go
diff options
context:
space:
mode:
authorAdam Mathes <adam@adammathes.com>2026-02-18 08:04:41 -0800
committerAdam Mathes <adam@adammathes.com>2026-02-18 08:04:41 -0800
commit20337a80775d81a69d8019430bb1f3b0d450e259 (patch)
treeebc3b93eed5589161bbb5d4e26983bd2ca03d838 /internal/safehttp/safehttp.go
parentee3f5edab92b0ca14dc0b3c98862f721bddaf7d5 (diff)
downloadneko-20337a80775d81a69d8019430bb1f3b0d450e259.tar.gz
neko-20337a80775d81a69d8019430bb1f3b0d450e259.tar.bz2
neko-20337a80775d81a69d8019430bb1f3b0d450e259.zip
Revert "fix: disable HTTP/2 in SafeClient to avoid unhandled response frame errors"
This reverts commit ee3f5edab92b0ca14dc0b3c98862f721bddaf7d5.
Diffstat (limited to 'internal/safehttp/safehttp.go')
-rw-r--r--internal/safehttp/safehttp.go6
1 files changed, 0 insertions, 6 deletions
diff --git a/internal/safehttp/safehttp.go b/internal/safehttp/safehttp.go
index eade405..f2c316b 100644
--- a/internal/safehttp/safehttp.go
+++ b/internal/safehttp/safehttp.go
@@ -2,7 +2,6 @@ package safehttp
import (
"context"
- "crypto/tls"
"fmt"
"net"
"net/http"
@@ -83,11 +82,6 @@ func NewSafeClient(timeout time.Duration) *http.Client {
transport.DialContext = SafeDialer(dialer)
transport.Proxy = nil // Disable proxy to ensure SSRF checks are not bypassed
- // Disable HTTP/2 to avoid "unhandled response frame type" errors from servers with
- // non-standard HTTP/2 implementations, which is common among various RSS feed hosts.
- transport.ForceAttemptHTTP2 = false
- transport.TLSNextProto = make(map[string]func(string, *tls.Conn) http.RoundTripper)
-
return &http.Client{
Timeout: timeout,
Transport: transport,