mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-07-04 01:07:49 +02:00
Only set OS header value for query from router itself
So queries from clients won't be mis-recognized as query from router in case of client metadata is in progress of collecting.
This commit is contained in:
committed by
Cuong Manh Le
parent
b002dff624
commit
6f12667e8c
@@ -165,7 +165,6 @@ func addHeader(ctx context.Context, req *http.Request, uc *UpstreamConfig) {
|
|||||||
// newControlDHeaders returns DoH/Doh3 HTTP request headers for ControlD upstream.
|
// newControlDHeaders returns DoH/Doh3 HTTP request headers for ControlD upstream.
|
||||||
func newControlDHeaders(ci *ClientInfo) http.Header {
|
func newControlDHeaders(ci *ClientInfo) http.Header {
|
||||||
header := make(http.Header)
|
header := make(http.Header)
|
||||||
header.Set(dohOsHeader, dohOsHeaderValue)
|
|
||||||
if ci.Mac != "" {
|
if ci.Mac != "" {
|
||||||
header.Set(dohMacHeader, ci.Mac)
|
header.Set(dohMacHeader, ci.Mac)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user