|
|
@ -66,16 +66,14 @@ func (f *Filter) Log(level Level, keyvals ...interface{}) error { |
|
|
|
return nil |
|
|
|
return nil |
|
|
|
} |
|
|
|
} |
|
|
|
for i := 0; i < len(keyvals); i += 2 { |
|
|
|
for i := 0; i < len(keyvals); i += 2 { |
|
|
|
k := keyvals[i] |
|
|
|
if _, ok := f.key[keyvals[i]]; ok { |
|
|
|
if _, ok := f.key[k]; ok { |
|
|
|
|
|
|
|
keyvals[i+1] = "***" |
|
|
|
keyvals[i+1] = "***" |
|
|
|
} |
|
|
|
} |
|
|
|
vi := i + 1 |
|
|
|
vi := i + 1 |
|
|
|
if vi >= len(keyvals) { |
|
|
|
if vi >= len(keyvals) { |
|
|
|
continue |
|
|
|
continue |
|
|
|
} |
|
|
|
} |
|
|
|
v := keyvals[vi] |
|
|
|
if _, ok := f.value[keyvals[vi]]; ok { |
|
|
|
if _, ok := f.value[v]; ok { |
|
|
|
|
|
|
|
keyvals[i+1] = "***" |
|
|
|
keyvals[i+1] = "***" |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|