MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / shouldMaskQueryParam

Function shouldMaskQueryParam

internal/util/provider.go:275–288  ·  view source on GitHub ↗
(key string)

Source from the content-addressed store, hash-verified

273}
274
275func shouldMaskQueryParam(key string) bool {
276 key = strings.ToLower(strings.TrimSpace(key))
277 if key == "" {
278 return false
279 }
280 key = strings.TrimSuffix(key, "[]")
281 if key == "key" || strings.Contains(key, "api-key") || strings.Contains(key, "apikey") || strings.Contains(key, "api_key") {
282 return true
283 }
284 if strings.Contains(key, "token") || strings.Contains(key, "secret") {
285 return true
286 }
287 return false
288}

Callers 1

MaskSensitiveQueryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected