Skip to content

[JENKINS-61738] Session hijacking protection hardening #11446

Closed

Description

@jenkins-infra-bot

After the recent SECURITY-1774 published in https://jenkins.io/security/advisory/2020-03-25/, we are preventing the usage of semicolon in URL. In Jenkins they could potentially have a legitimate (but not really recommended) usage when included in item names.

If you need to activate the escape hatch "jenkins.security.SuspiciousRequestFilter.allowSemicolonsInPath", and you are using a SecurityRealm that does not invalidate the session after authentication, you are vulnerable to a session hijacking attack. Of course, the SecurityRealm issue has to be reported as a vulnerability and then corrected.

The problem is that you can trigger a URL in Jenkins with ";jsessionid=xxx" (only "available" in Tomcat).

This ticket is about adding a "second" level of protection there (think defense in depth) by forcing the session to be tracked as a cookie (from default which is cookie+url).


Originally reported by wfollonier, imported from: Session hijacking protection hardening
  • assignee: wfollonier
  • status: Resolved
  • priority: Minor
  • component(s): core
  • resolution: Fixed
  • resolved: 2020-04-28T00:05:50+00:00
  • votes: 0
  • watchers: 1
  • imported: 2025-11-24
Raw content of original issue

After the recent SECURITY-1774 published in https://jenkins.io/security/advisory/2020-03-25/, we are preventing the usage of semicolon in URL. In Jenkins they could potentially have a legitimate (but not really recommended) usage when included in item names.

If you need to activate the escape hatch "jenkins.security.SuspiciousRequestFilter.allowSemicolonsInPath", and you are using a SecurityRealm that does not invalidate the session after authentication, you are vulnerable to a session hijacking attack. Of course, the SecurityRealm issue has to be reported as a vulnerability and then corrected.

The problem is that you can trigger a URL in Jenkins with ";jsessionid=xxx" (only "available" in Tomcat).

This ticket is about adding a "second" level of protection there (think defense in depth) by forcing the session to be tracked as a cookie (from default which is cookie+url).

Activity

  1. jenkins-infra-bot commented on Mar 30, 2020

    @jenkins-infra-bot
    Author
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions