committed by
Stéphane Nicoll
parent
1710ff4eb5
commit
b9772cd6f1
@@ -79,8 +79,8 @@ public interface SanitizingFunction {
|
||||
* @see #filter()
|
||||
* @see #sanitizeValue()
|
||||
*/
|
||||
default SanitizingFunction ifLikelySenstive() {
|
||||
return ifLikelyCredential().ifLikelyUri().ifLikelySenstiveProperty().ifVcapServices();
|
||||
default SanitizingFunction ifLikelySensitive() {
|
||||
return ifLikelyCredential().ifLikelyUri().ifLikelySensitiveProperty().ifVcapServices();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -121,7 +121,7 @@ public interface SanitizingFunction {
|
||||
* @see #filter()
|
||||
* @see #sanitizeValue()
|
||||
*/
|
||||
default SanitizingFunction ifLikelySenstiveProperty() {
|
||||
default SanitizingFunction ifLikelySensitiveProperty() {
|
||||
return ifKeyMatches("sun.java.command", "^spring[._]application[._]json$");
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2023 the original author or authors.
|
||||
* Copyright 2012-2025 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -95,7 +95,7 @@ class SanitizerTests {
|
||||
|
||||
@Test
|
||||
void overridingDefaultSanitizingFunctionWithFiltered() {
|
||||
Sanitizer sanitizer = new Sanitizer(List.of(SanitizingFunction.sanitizeValue().ifLikelySenstive()));
|
||||
Sanitizer sanitizer = new Sanitizer(List.of(SanitizingFunction.sanitizeValue().ifLikelySensitive()));
|
||||
SanitizableData other = new SanitizableData(null, "other", "123456");
|
||||
SanitizableData password = new SanitizableData(null, "password", "123456");
|
||||
assertThat(sanitizer.sanitize(other, true)).isEqualTo("123456");
|
||||
|
||||
@@ -57,8 +57,8 @@ class SanitizingFunctionTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void ifLikelySenstiveFiltersExpected() {
|
||||
SanitizingFunction function = SanitizingFunction.sanitizeValue().ifLikelySenstive();
|
||||
void ifLikelySensitiveFiltersExpected() {
|
||||
SanitizingFunction function = SanitizingFunction.sanitizeValue().ifLikelySensitive();
|
||||
assertThat(function).satisfies(this::likelyCredentialChecks, this::likelyUriChecks,
|
||||
this::likelySenstivePropertyChecks, this::vcapServicesChecks);
|
||||
}
|
||||
@@ -101,8 +101,8 @@ class SanitizingFunctionTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void ifLikelySenstivePropertyFiltersExpected() {
|
||||
SanitizingFunction function = SanitizingFunction.sanitizeValue().ifLikelySenstiveProperty();
|
||||
void ifLikelySensitivePropertyFiltersExpected() {
|
||||
SanitizingFunction function = SanitizingFunction.sanitizeValue().ifLikelySensitiveProperty();
|
||||
assertThat(function).satisfies(this::likelySenstivePropertyChecks);
|
||||
}
|
||||
|
||||
|
||||
@@ -309,7 +309,7 @@
|
||||
{
|
||||
"name": "logging.structured.json.stacktrace.printer",
|
||||
"type": "java.lang.String",
|
||||
"description": "Name of the printer to use. Can be 'standard', 'logging-system', or the fully-qualified class name of a StackTracePrinter. When not specified 'logging-system' or 'standard' will be used depening if other properties are set."
|
||||
"description": "Name of the printer to use. Can be 'standard', 'logging-system', or the fully-qualified class name of a StackTracePrinter. When not specified 'logging-system' or 'standard' will be used depending if other properties are set."
|
||||
},
|
||||
{
|
||||
"name": "logging.structured.json.stacktrace.root",
|
||||
|
||||
Reference in New Issue
Block a user