Uploaded image for project: 'Crowd Data Center'
  1. Crowd Data Center
  2. CWD-592

Wrong domain name in cookies when running webapp on localhost with SSO-enabled Crowd

    • Icon: Bug Bug
    • Resolution: Unsolved Mysteries
    • Icon: Medium Medium
    • None
    • 1.1.2
    • SSO
    • None
    • JBoss 4.2-GA

      I have configured Crowd to set the Cookie domain to the corporate domain name. When I installed the demo on my localhost it din't work. The authentication was performed successfully, but the demo just redirected me back to it's login page. The demo's log file stated:

      13:00:24,207 INFO [STDOUT] 13:00:24,207 INFO atlassian.crowd.integration.http.VerifyTokenFilter: Authentication is not valid, redirecting to: http://localhost:8080/demo

      I traced the problem to processClientCookieDomain(Cookie tokenCookie) in the HttpAuthenticator class.

      If the Crowd server has been configured to use f.i. ".domain.com" as cookie domain, this is used in the cookie. The problem is that my browser uses localhost and it probably ignores the cookie completely. It will definitely not sent the cookie back to localhost when the domain is set to ".domain.com", thus the application will handle the user as not authenticated.

      When I removed the ".domain.com" setting from the Crowd configuration, the cookie was created with no domain set and I was able to sign in to the demo application.

          Form Name

            [CWD-592] Wrong domain name in cookies when running webapp on localhost with SSO-enabled Crowd

            set-jac-bot made changes -
            Link New: This issue details CWD-1093 [ CWD-1093 ]
            Monique Khairuliana (Inactive) made changes -
            Workflow Original: Simplified Crowd Development Workflow v2 - restricted [ 1510168 ] New: JAC Bug Workflow v3 [ 3366004 ]
            Mareusz (Inactive) made changes -
            Resolution New: Unsolved Mysteries [ 13 ]
            Status Original: Open [ 1 ] New: Closed [ 6 ]
            Owen made changes -
            Symptom Severity Original: Major [ 14431 ] New: Severity 2 - Major [ 15831 ]
            jonah (Inactive) made changes -
            Symptom Severity New: Major [ 14431 ]
            Owen made changes -
            Workflow Original: Simplified Crowd Development Workflow v2 [ 1393025 ] New: Simplified Crowd Development Workflow v2 - restricted [ 1510168 ]
            Owen made changes -
            Workflow Original: Crowd Development Workflow v2 [ 273421 ] New: Simplified Crowd Development Workflow v2 [ 1393025 ]
            joe made changes -
            Assignee Original: Justen Stepka [Atlassian] [ justen.stepka@atlassian.com ]
            jawong.adm made changes -
            Workflow Original: JIRA Bug Workflow v2 [ 174398 ] New: Crowd Development Workflow v2 [ 273421 ]
            Justin Koke made changes -
            Workflow Original: jira [ 116973 ] New: JIRA Bug Workflow v2 [ 174398 ]

              Unassigned Unassigned
              865f90db8294 Lars Preben Sørsdahl
              Affected customers:
              2 This affects my team
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: