Details
-
Bug
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Not A Defect
-
None
-
Jenkins 2.60.1 on RedHat Enterprise Linux 5
Description
Quite contrary to what is written on https://wiki.jenkins.io/display/JENKINS/Jenkins+SSH, X-SSH-Endpoint header is not provided on the top page when the response is 403.
$ curl -I http://localhost:8440/jenkins/ HTTP/1.1 403 Forbidden Date: Wed, 19 Jul 2017 13:43:33 GMT X-Content-Type-Options: nosniff Set-Cookie: JSESSIONID.32f49371=15lrqwbgqu5jvm4xkf7ulfomu;Path=/jenkins;HttpOnly Expires: Thu, 01 Jan 1970 00:00:00 GMT Content-Type: text/html;charset=UTF-8 X-Hudson: 1.395 X-Jenkins: 2.60.1 X-Jenkins-Session: 567160ff X-Hudson-CLI-Port: 37318 X-Jenkins-CLI-Port: 37318 X-Jenkins-CLI2-Port: 37318 X-You-Are-Authenticated-As: anonymous X-You-Are-In-Group-Disabled: JENKINS-39402: use -Dhudson.security.AccessDeniedException2.REPORT_GROUP_HEADERS=true or use /whoAmI to diagnose X-Required-Permission: hudson.model.Hudson.Read X-Permission-Implied-By: hudson.security.Permission.GenericRead X-Permission-Implied-By: hudson.model.Hudson.Administer Content-Length: 829 Server: Jetty(9.2.z-SNAPSHOT)
One needs to get response 200 (i.e. access login URL) to get the endpoint. Note that CLI ports ARE returned always, only SSH endpoint is missing.
$ curl -I http://localhost:8440/jenkins/login HTTP/1.1 200 OK Date: Wed, 19 Jul 2017 13:43:41 GMT X-Content-Type-Options: nosniff Set-Cookie: JSESSIONID.32f49371=6balu16gxdidrwpc4t258io;Path=/jenkins;HttpOnly Expires: 0 Cache-Control: no-cache,no-store,must-revalidate X-Hudson-Theme: default Content-Type: text/html;charset=UTF-8 X-Hudson: 1.395 X-Jenkins: 2.60.1 X-Jenkins-Session: 567160ff X-Hudson-CLI-Port: 37318 X-Jenkins-CLI-Port: 37318 X-Jenkins-CLI2-Port: 37318 X-Frame-Options: sameorigin X-Instance-Identity: MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlwNEtMd78Uf5V2p+hCgcHOazeDpoo9lKZL7YlqgzpuQeJvHfhMZ+fRCTCoIns/swiE5tG0WttqRL4z7tgA+xF8+KzKFuUtONhar+4kGDIhrJks+MuyePpEpzXplHtcB9OFUymfwTXrOBXExswjdGodqupyG9IBG1Xlx51oRHRXHEci3QgF1f/7+KfsZM3oCTOpyQxNasE5dki4nA33PvvAeZGHwxvdJ0nmLcbAVk8aSCzjuDbJZ+GnjJC+CsLR34AYWHNbxOo8rn9PCiIJid43UX/36HmYweWlUdRsnBfXtHL02/NV6OngWvWAowmFmVz9YzLj5+C4Q9QshZmvhbFwIDAQAB X-SSH-Endpoint: server:55999 Content-Length: 7304 Server: Jetty(9.2.z-SNAPSHOT)
Attachments
Issue Links
- mentioned in
-
Page Loading...
Historically, Jenkins allowed anyone read access, to the top URL wasn't the 403. The wiki is descriptive, open to edit by anyone, and not kept well up to date, so take its content with a grain of salt.
The better maintained Jenkins handbook specifically mentions the login URL: https://jenkins.io/doc/book/managing/cli/