jenkinsci / jenkinsci/gitlab-branch-source-plugin

[JENKINS-65507] Unable to connect to gitlab server (certificate issue)

Open
#694 2 comments 0 reactions 0 assignees View on GitHub
component:gitlab-branch-source-plugin imported-jira-issue priority:major resolution:unresolved
Dominant language
Java
Stars
134
Forks
113
PR merge metrics
No merged PRs in 30d

Description

We updated recently from version 1.5.1 to 1.5.7 of the GitLab Branch Source plugin and since then it is not possible to connect to our internal GitLab anymore.

 

We get this error message:

PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target


Because this is an internal service, we are using self signed certificates which may cause this issue.

In the past this worked perfect but now the plugin is completely unusable for us because there is no option to ignore such certificate issues.

Attached you find the complete stack trace of the error.

 

I check the modifications that where done in the plugin since version 1.5.1 and it seems that the change in file

 src/main/java/io/jenkins/plugins/gitlabbranchsource/GitLabHookCreator.java:204

in the commit "JENKINS-62375">JENKINS-62375 Fix/secret token (#91)" from May 31, 2020 is the root cause.

 

I think a possible solution could be to add an option to disable the SSL verification for such situations.

---
Originally reported by bboehmke, imported from: Unable to connect to gitlab server (certificate issue)


  • assignee: baymac
  • status: Open
  • priority: Major
  • component(s): gitlab-branch-source-plugin
  • resolution: Unresolved
  • votes: 2
  • watchers: 4
  • imported: 20251216-182730

Raw content of original issue

We updated recently from version 1.5.1 to 1.5.7 of the GitLab Branch Source plugin and since then it is not possible to connect to our internal GitLab anymore.

 

We get this error message:



PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target



Because this is an internal service, we are using self signed certificates which may cause this issue.

In the past this worked perfect but now the plugin is completely unusable for us because there is no option to ignore such certificate issues.

Attached you find the complete stack trace of the error.

 

I check the modifications that where done in the plugin since version 1.5.1 and it seems that the change in file

 src/main/java/io/jenkins/plugins/gitlabbranchsource/GitLabHookCreator.java:204

in the commit "JENKINS-62375 Fix/secret token (#91)" from May 31, 2020 is the root cause.

 

I think a possible solution could be to add an option to disable the SSL verification for such situations.

environment

```
Jenkins: 2.263.4

GitLab Branch Source: 1.5.7

GitLab: 13.10.2
```

1 attachment

- [jenkins_gitlab_exception.txt](https://issues.jenkins.io/secure/attachment/54714/jenkins_gitlab_exception.txt)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.