-
Improvement
-
Resolution: Won't Do
-
Major
-
Production
We have configured saml authentication on our Bitbucket server. When a user goes to Bitbucket login page(say https://bitbucket.xyz.com), user will be redirected to our IdP page to enter credentials and once authenticated, will be redirected to Bitbucket home page.
Since there is no saml support for Bitbucket branch plugin, I have enabled an option in saml plugin to configure no saml login url (https://bitbucket.xyz.com/login?saml_sso=false) in bitbucket and configured the same in jenkins settings but Bitbucket branch source plugin fails to get repositories in project. Following error can be seen in pipeline scan log
looks like plugin doesn't like characters in URL bitbucket.xyz.com/login?saml_sso=false
error:
org.codehaus.jackson.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')
at [Source: java.io.StringReader@181a2835; line: 1, column: 2]
at org.codehaus.jackson.JsonParser._constructError(JsonParser.java:1433)
at org.codehaus.jackson.impl.JsonParserMinimalBase._reportError(JsonParserMinimalBase.java:521)
at org.codehaus.jackson.impl.JsonParserMinimalBase._reportUnexpectedChar(JsonParserMinimalBase.java:442)
at org.codehaus.jackson.impl.ReaderBasedParser._handleUnexpectedValue(ReaderBasedParser.java:1198)
at org.codehaus.jackson.impl.ReaderBasedParser.nextToken(ReaderBasedParser.java:485)
at org.codehaus.jackson.map.ObjectMapper._initForReading(ObjectMapper.java:2770)
at org.codehaus.jackson.map.ObjectMapper._readMapAndClose(ObjectMapper.java:2718)
at org.codehaus.jackson.map.ObjectMapper.readValue(ObjectMapper.java:1886)
at com.cloudbees.jenkins.plugins.bitbucket.JsonParser.toJava(JsonParser.java:56)
at com.cloudbees.jenkins.plugins.bitbucket.JsonParser.toJava(JsonParser.java:48)
at com.cloudbees.jenkins.plugins.bitbucket.server.client.BitbucketServerAPIClient.getServerBranches(BitbucketServerAPIClient.java:470)
Caused: java.io.IOException: I/O error when accessing URL: /rest/api/1.0/projects/FIF/repos/demo/branches?start=0&limit=200
git source code plugin works fine because it authenticates with GIT_ASKPASS
[JENKINS-54446] support bitbucket non saml url
Description |
Original:
We have configured saml authentication on our Bitbucket server. When a user goes to Bitbucket login page(say [https://bitbucket.xyz.com|https://bitbucket.xyz.com/]), user will be redirected to our IdP page to enter credentials and once authenticated, will be redirected to Bitbucket home page. Since there is no saml support for Bitbucket branch plugin, I have enabled an option in saml plugin to configure no saml login url ([https://bitbucket.xyz.com/login?saml_sso=false)] in bitbucket and configured the same in jenkins settings but Bitbucket branch source plugin fails to get repositories in project. Following error can be seen in pipeline scan log Can you please add support to consider entire url with context root in Jenkins Bitbucket endpoints Server URL. I think currently , this plugin only takes bitbucket.xyz.com as URL as supposed to [bitbucket.xyz.com/login?saml_sso=false|https://bitbucket.xyz.com/login?saml_sso=false)] error: org.codehaus.jackson.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null') at [Source: java.io.StringReader@181a2835; line: 1, column: 2] at org.codehaus.jackson.JsonParser._constructError(JsonParser.java:1433) at org.codehaus.jackson.impl.JsonParserMinimalBase._reportError(JsonParserMinimalBase.java:521) at org.codehaus.jackson.impl.JsonParserMinimalBase._reportUnexpectedChar(JsonParserMinimalBase.java:442) at org.codehaus.jackson.impl.ReaderBasedParser._handleUnexpectedValue(ReaderBasedParser.java:1198) at org.codehaus.jackson.impl.ReaderBasedParser.nextToken(ReaderBasedParser.java:485) at org.codehaus.jackson.map.ObjectMapper._initForReading(ObjectMapper.java:2770) at org.codehaus.jackson.map.ObjectMapper._readMapAndClose(ObjectMapper.java:2718) at org.codehaus.jackson.map.ObjectMapper.readValue(ObjectMapper.java:1886) at com.cloudbees.jenkins.plugins.bitbucket.JsonParser.toJava(JsonParser.java:56) at com.cloudbees.jenkins.plugins.bitbucket.JsonParser.toJava(JsonParser.java:48) at com.cloudbees.jenkins.plugins.bitbucket.server.client.BitbucketServerAPIClient.getServerBranches(BitbucketServerAPIClient.java:470) Caused: java.io.IOException: I/O error when accessing URL: /rest/api/1.0/projects/FIF/repos/demo/branches?start=0&limit=200 git source code plugin works fine because it authenticates with GIT_ASKPASS |
New:
We have configured saml authentication on our Bitbucket server. When a user goes to Bitbucket login page(say [https://bitbucket.xyz.com|https://bitbucket.xyz.com/]), user will be redirected to our IdP page to enter credentials and once authenticated, will be redirected to Bitbucket home page. Since there is no saml support for Bitbucket branch plugin, I have enabled an option in saml plugin to configure no saml login url ([https://bitbucket.xyz.com/login?saml_sso=false)] in bitbucket and configured the same in jenkins settings but Bitbucket branch source plugin fails to get repositories in project. Following error can be seen in pipeline scan log looks like plugin doesn't like characters in URL [bitbucket.xyz.com/login?saml_sso=false|https://bitbucket.xyz.com/login?saml_sso=false)] error: org.codehaus.jackson.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null') at [Source: java.io.StringReader@181a2835; line: 1, column: 2] at org.codehaus.jackson.JsonParser._constructError(JsonParser.java:1433) at org.codehaus.jackson.impl.JsonParserMinimalBase._reportError(JsonParserMinimalBase.java:521) at org.codehaus.jackson.impl.JsonParserMinimalBase._reportUnexpectedChar(JsonParserMinimalBase.java:442) at org.codehaus.jackson.impl.ReaderBasedParser._handleUnexpectedValue(ReaderBasedParser.java:1198) at org.codehaus.jackson.impl.ReaderBasedParser.nextToken(ReaderBasedParser.java:485) at org.codehaus.jackson.map.ObjectMapper._initForReading(ObjectMapper.java:2770) at org.codehaus.jackson.map.ObjectMapper._readMapAndClose(ObjectMapper.java:2718) at org.codehaus.jackson.map.ObjectMapper.readValue(ObjectMapper.java:1886) at com.cloudbees.jenkins.plugins.bitbucket.JsonParser.toJava(JsonParser.java:56) at com.cloudbees.jenkins.plugins.bitbucket.JsonParser.toJava(JsonParser.java:48) at com.cloudbees.jenkins.plugins.bitbucket.server.client.BitbucketServerAPIClient.getServerBranches(BitbucketServerAPIClient.java:470) Caused: java.io.IOException: I/O error when accessing URL: /rest/api/1.0/projects/FIF/repos/demo/branches?start=0&limit=200 git source code plugin works fine because it authenticates with GIT_ASKPASS |
Resolution | New: Won't Do [ 10001 ] | |
Status | Original: Open [ 1 ] | New: Closed [ 6 ] |
Documentation about supported credentials.
https://github.com/jenkinsci/bitbucket-branch-source-plugin/blob/master/docs/USER_GUIDE.adoc#credentials-configuration