[JIRA] [parameterized-remote-trigger-plugin] (JENKINS-28637) Unable to select stored credentials from the credential plug-in

7 views
Skip to first unread message

garlandkr@gmail.com (JIRA)

unread,
May 28, 2015, 9:49:02 PM5/28/15
to jenkinsc...@googlegroups.com
Ken Garland created an issue
 
Jenkins / Bug JENKINS-28637
Unable to select stored credentials from the credential plug-in
Issue Type: Bug Bug
Assignee: Maurice W.
Components: parameterized-remote-trigger-plugin
Created: 29/May/15 1:48 AM
Labels: plugin
Priority: Major Major
Reporter: Ken Garland

Jenkins 1.615
Parameterized Remote Trigger - 2.26
Credentials - 1.22

From the Jenkins Configure System page under Parameterized Remote Trigger Configuration when I add a remote host and choose Use the Credentials Plugin under Authentication none of my stored credentials appear in the dropdown. The list is empty. If I click the button to Add a credential the list still remains empty.

I have tried from Safari and Chrome.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265)
Atlassian logo

hesh@pobox.com (JIRA)

unread,
Jan 7, 2016, 4:23:01 PM1/7/16
to jenkinsc...@googlegroups.com
Chris Steinbroner commented on Bug JENKINS-28637
 
Re: Unable to select stored credentials from the credential plug-in

Also/still a problem for:

Jenkins: 1.643
Parameterized Remote Trigger: 2.2.2
Credentials: 1.24

Configured a credential for a domain with a username and private key, entered directly.
When adding the build step "trigger a remote parameterized job", the "select a remote host" pulldown is empty.

contact@wennysoft.de (JIRA)

unread,
Feb 10, 2016, 1:35:02 PM2/10/16
to jenkinsc...@googlegroups.com

We have the same problem at our side using certificate based credentials. It seems that the plugin is only designed to support Username/passwort via the Credentials Plugin.

We get an exception

Caused by: java.lang.NullPointerException
        at org.jenkinsci.plugins.ParameterizedRemoteTrigger.Auth.getUsername(Auth.java:80)
        ... 238 more

Looking into the code:

        } else if (authType.equals(CREDENTIALS_PLUGIN)) {
            username = this.getCredentials().getUsername();
        }

and

private UsernamePasswordCredentials getCredentials() {
        String credetialId = this.getCreds();
        StandardUsernameCredentials matchedCredentials = null;
        Item item = null;

        List<StandardUsernameCredentials> listOfCredentials = CredentialsProvider.lookupCredentials(
                StandardUsernameCredentials.class, item, ACL.SYSTEM, Collections.<DomainRequirement> emptyList());
        for (StandardUsernameCredentials cred : listOfCredentials) {
            if (credetialId.equals(cred.getId())) {
                matchedCredentials = cred;
                break;
            }
        }

        // now we have matchedCredentials.getPassword() and matchedCredentials.getUsername();
        return (UsernamePasswordCredentials) matchedCredentials;
    }

this will not give anything at our side as we do not have any UserNamePasswortCredentials.

so it seems that certificate based credentials are not supported at the moment

roytinker@gmail.com (JIRA)

unread,
Apr 1, 2016, 2:40:02 PM4/1/16
to jenkinsc...@googlegroups.com

I'm getting this issue also. I'm using the latest Jenkins (1.655), Pipeline, and Credentials plugins.

I used the developer tools to look at the server's response to the ajax request that populates the dropdown. Here is the stack trace:

{{javax.servlet.ServletException: java.lang.IllegalArgumentException: Only non-null SecurityContext instances are permitted
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:796)
at org.kohsuke.stapler.Stapler.invoke(Stapler.java:876)
at org.kohsuke.stapler.MetaClass$5.doDispatch(MetaClass.java:233)
at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:746)
at org.kohsuke.stapler.Stapler.invoke(Stapler.java:876)
at org.kohsuke.stapler.MetaClass$5.doDispatch(MetaClass.java:233)
at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:746)
at org.kohsuke.stapler.Stapler.invoke(Stapler.java:876)
at org.kohsuke.stapler.Stapler.invoke(Stapler.java:649)
at org.kohsuke.stapler.Stapler.service(Stapler.java:238)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:686)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1494)
at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:135)
at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:126)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:49)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:84)
at hudson.security.UnwrapSecurityExceptionFilter.doFilter(UnwrapSecurityExceptionFilter.java:51)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at jenkins.security.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:117)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:125)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:142)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at jenkins.security.BasicHeaderProcessor.doFilter(BasicHeaderProcessor.java:93)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249)
at hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:67)
at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:76)
at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:171)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:49)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:81)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1482)
at org.kohsuke.stapler.DiagnosticThreadNameFilter.doFilter(DiagnosticThreadNameFilter.java:30)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1474)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:499)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:533)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:428)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
at org.eclipse.jetty.server.Server.handle(Server.java:370)
at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:489)
at org.eclipse.jetty.server.AbstractHttpConnection.content(AbstractHttpConnection.java:960)
at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.content(AbstractHttpConnection.java:1021)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:865)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:668)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:52)
at winstone.BoundedExecutorService$1.run(BoundedExecutorService.java:77)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.IllegalArgumentException: Only non-null SecurityContext instances are permitted
at org.springframework.util.Assert.notNull(Assert.java:112)
at org.acegisecurity.context.ThreadLocalSecurityContextHolderStrategy.setContext(ThreadLocalSecurityContextHolderStrategy.java:51)
at org.acegisecurity.context.SecurityContextHolder.setContext(SecurityContextHolder.java:120)
at com.cloudbees.plugins.credentials.UserCredentialsProvider.getCredentials(UserCredentialsProvider.java:156)
at com.cloudbees.plugins.credentials.CredentialsProvider.getCredentials(CredentialsProvider.java:276)
at com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials(CredentialsProvider.java:531)
at com.cloudbees.plugins.credentials.CredentialsParameterDefinition$DescriptorImpl.doFillValueItems(CredentialsParameterDefinition.java:181)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:320)
at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:163)
at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:96)
at org.kohsuke.stapler.MetaClass$1.doDispatch(MetaClass.java:124)
at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:746)
... 67 more}}

Here are the plugins I have installed & enabled:
{{╔════════════════════════════╦════════════════╦════════╗
║ PLUGIN ║ VERSION ║ Pinned ║
╠════════════════════════════╬════════════════╬════════╣
║ ace-editor ║ 1.1 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ active-directory ║ 1.42 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ ant ║ 1.2 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ antisamy-markup-formatter ║ 1.3 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ any-buildstep ║ 0.1 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ build-pipeline-plugin ║ 1.5.2 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ buildresult-trigger ║ 0.17 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ conditional-buildstep ║ 1.3.3 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ config-autorefresh-plugin ║ 1.0 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ credentials ║ 1.26 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ credentials-binding ║ 1.7 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ cvs ║ 2.12 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ dashboard-view ║ 2.9.7 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ durable-task ║ 1.9 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ external-monitor-job ║ 1.4 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ flexible-publish ║ 0.15.2 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ fstrigger ║ 0.39 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ git-client ║ 1.19.6 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ git-server ║ 1.6 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ icon-shim ║ 2.0.3 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ javadoc ║ 1.3 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ job-restrictions ║ 0.4 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ jquery ║ 1.11.2-0 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ jquery-detached ║ 1.2.1 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ junit ║ 1.11 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ ldap ║ 1.11 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ mailer ║ 1.16 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ mapdb-api ║ 1.0.6.0 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ matrix-auth ║ 1.3.2 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ matrix-project ║ 1.6 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ maven-plugin ║ 2.12.1 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ multi-slave-config-plugin ║ 1.2.0 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ nodelabelparameter ║ 1.7.2 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ pam-auth ║ 1.2 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ parameterized-trigger ║ 2.30 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ plain-credentials ║ 1.1 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ powershell ║ 1.3 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ run-condition ║ 1.0 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ scm-api ║ 1.1 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ script-security ║ 1.17 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ ssh-credentials ║ 1.11 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ ssh-slaves ║ 1.10 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ subversion ║ 2.5.7 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ token-macro ║ 1.12.1 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ translation ║ 1.12 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ windows-exe-runner ║ 1.2 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ windows-slaves ║ 1.1 ║ true ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-aggregator ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-api ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-basic-steps ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-cps ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-cps-global-lib ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-durable-task-step ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-job ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-scm-step ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-step-api ║ 1.15 ║ false ║
╠════════════════════════════╬════════════════╬════════╣
║ workflow-support ║ 1.15 ║ false ║
╚════════════════════════════╩════════════════╩════════╝}}

roytinker@gmail.com (JIRA)

unread,
Apr 1, 2016, 2:41:02 PM4/1/16
to jenkinsc...@googlegroups.com
Roy Tinker edited a comment on Bug JENKINS-28637

roytinker@gmail.com (JIRA)

unread,
Apr 1, 2016, 2:44:03 PM4/1/16
to jenkinsc...@googlegroups.com
Roy Tinker edited a comment on Bug JENKINS-28637
I'm getting this issue also. I'm using the latest Jenkins (1.655), Pipeline, and Credentials plugins.

I used the developer tools to look at the server's response to the ajax request that populates the dropdown. Here is the stack trace:

{ { code}
{code } }

Here are the plugins I have installed & enabled:
{ { code}
{code } }

roytinker@gmail.com (JIRA)

unread,
Apr 1, 2016, 2:50:03 PM4/1/16
to jenkinsc...@googlegroups.com
Roy Tinker edited a comment on Bug JENKINS-28637
I'm getting this issue also. I'm using the latest Jenkins (1.655), Pipeline, and Credentials plugins.

UPDATE: this issue went away intermittently, but it's back now. It may be that the Jenkins master needs a reboot...

roytinker@gmail.com (JIRA)

unread,
Apr 1, 2016, 2:53:02 PM4/1/16
to jenkinsc...@googlegroups.com
Roy Tinker edited a comment on Bug JENKINS-28637
I'm getting this issue also. I'm using the latest Jenkins (1.655), Pipeline, and Credentials plugins.

UPDATE: this issue went away intermittently, but it's back now. It This  may be  that the Jenkins master needs a reboot  related to https://issues . jenkins-ci . org/browse/JENKINS-33944 .
Reply all
Reply to author
Forward
0 new messages