Skip to content
Closed

Polish #44247

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,8 @@ default SanitizableData applyUnlessFiltered(SanitizableData data) {
* @see #filter()
* @see #sanitizeValue()
*/
default SanitizingFunction ifLikelySenstive() {
return ifLikelyCredential().ifLikelyUri().ifLikelySenstiveProperty().ifVcapServices();
default SanitizingFunction ifLikelySensitive() {
return ifLikelyCredential().ifLikelyUri().ifLikelySensitiveProperty().ifVcapServices();
}

/**
Expand Down Expand Up @@ -121,7 +121,7 @@ default SanitizingFunction ifLikelyUri() {
* @see #filter()
* @see #sanitizeValue()
*/
default SanitizingFunction ifLikelySenstiveProperty() {
default SanitizingFunction ifLikelySensitiveProperty() {
return ifKeyMatches("sun.java.command", "^spring[._]application[._]json$");
}

Expand Down
Original file line number Diff line number Diff line change
@@ -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.
Expand Down Expand Up @@ -95,7 +95,7 @@ void overridingDefaultSanitizingFunction() {

@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");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ void applyUnlessFilteredWhenHasFilterTestingFalseReturnsUnfiltered() {
}

@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);
}
Expand Down Expand Up @@ -101,8 +101,8 @@ private void likelyUriChecks(SanitizingFunction function) {
}

@Test
void ifLikelySenstivePropertyFiltersExpected() {
SanitizingFunction function = SanitizingFunction.sanitizeValue().ifLikelySenstiveProperty();
void ifLikelySensitivePropertyFiltersExpected() {
SanitizingFunction function = SanitizingFunction.sanitizeValue().ifLikelySensitiveProperty();
assertThat(function).satisfies(this::likelySenstivePropertyChecks);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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",
Expand Down