Skip to content
Open
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 @@ -34,6 +34,7 @@
import hudson.model.Run;
import hudson.model.TaskListener;
import hudson.util.Secret;
import jenkins.util.SystemProperties;
import java.io.ObjectStreamException;
import java.io.OutputStream;
import java.io.Serializable;
Expand Down Expand Up @@ -102,6 +103,7 @@
private static final class Execution2 extends GeneralNonBlockingStepExecution {

private static final long serialVersionUID = 1;
private static final boolean enableMaskLogging = SystemProperties.getBoolean(BindingStep.class.getName() + ".ENABLE_MASK_LOGGING", true);

private transient BindingStep step;

Expand Down Expand Up @@ -137,9 +139,11 @@
}
if (!secretOverrides.isEmpty()) {
boolean unix = launcher == null || launcher.isUnix();
listener.getLogger().println("Masking supported pattern matches of " + secretOverrides.keySet().stream().map(
v -> unix ? "$" + v : "%" + v + "%"
).collect(Collectors.joining(" or ")));
if (enableMaskLogging) {

Check warning on line 142 in src/main/java/org/jenkinsci/plugins/credentialsbinding/impl/BindingStep.java

View check run for this annotation

ci.jenkins.io / Code Coverage

Partially covered line

Line 142 is only partially covered, one branch is missing
listener.getLogger().println("Masking supported pattern matches of " + secretOverrides.keySet().stream().map(
v -> unix ? "$" + v : "%" + v + "%"
).collect(Collectors.joining(" or ")));
}
}

getContext().newBodyInvoker().
Expand Down