diff --git a/core/src/main/java/hudson/cli/CLICommand.java b/core/src/main/java/hudson/cli/CLICommand.java index a007752b47085b5c3d80ca3133051cd278eb1d6f..bd20963eebba186d69f9e0259b93220439884ef8 100644 --- a/core/src/main/java/hudson/cli/CLICommand.java +++ b/core/src/main/java/hudson/cli/CLICommand.java @@ -215,6 +215,7 @@ public abstract class CLICommand implements ExtensionPoint, Cloneable { Authentication old = sc.getAuthentication(); CliAuthenticator authenticator = Jenkins.getInstance().getSecurityRealm().createCliAuthenticator(this); + sc.setAuthentication(getTransportAuthentication()); new ClassParser().parse(authenticator,p); try {