mirror of
https://github.com/tailscale/tailscale.git
synced 2025-02-18 02:48:40 +00:00
ipn/ipnlocal: strip origin and referer headers from Taildrive requests
peerapi does not want these, but rclone includes them. Stripping them out allows rclone to work with Taildrive configured as a WebDAV remote. Updates #cleanup Signed-off-by: Percy Wegmann <percy@tailscale.com>
This commit is contained in:
parent
787f8c08ec
commit
94c0403104
@ -4833,6 +4833,10 @@ func (dt *driveTransport) RoundTrip(req *http.Request) (resp *http.Response, err
|
||||
req.Body = bw
|
||||
}
|
||||
|
||||
// Strip origin and referer headers
|
||||
req.Header.Del("origin")
|
||||
req.Header.Del("referer")
|
||||
|
||||
defer func() {
|
||||
contentType := "unknown"
|
||||
switch req.Method {
|
||||
|
Loading…
x
Reference in New Issue
Block a user