plaflamme / gitblit-crowd

Atlassian Crowd authentication and authorization with Gitblit
http://plaflamme.github.com/gitblit-crowd/
Apache License 2.0
3 stars 1 forks source link

SSO not working? #1

Closed riemers closed 11 years ago

riemers commented 12 years ago

Hi,

I've got the plugin working and authentication towards crowd works fine. I can also see all the groups in gitblit when checking the repository. Admins for gitblit are also set just fine.

But SSO does not work, when i log into jira/confluence and then go towards gitblit it wont log me in. If i start using gitblit and then go to jira/confluence it does not log me into those too.

So both ways does not give me a proper sso cookie. Am i missing something? I filled in the crowd.properties like with any other app and the rest does work when i have logged in.

Erik

plaflamme commented 12 years ago

What version are you using? Is SSO working between JIRA and Confluence? Is gitblit on the same domain as JIRA and Confluence (jira.domain.com and git.domain.com)?

riemers commented 12 years ago

Running gitblit-crowd-1.0-0-jar-with-dependencies.jar, SSO is working between jira and confluence. i've setup gitblit to be used via a url that is on the same machine and the url is the same domain.

plaflamme commented 12 years ago

Are you using a reverse proxy?

I had a similar issue early on and it was due to the Crowd configuration when using a reverse proxy.

riemers commented 12 years ago

Yes i am using a reverse proxy for most of my tools, only tool i dont have it for is gitblit (since then the url's for syncing dont really work anymore) at least have not looked into it. But crowd is indeed behind a reverse proxy.

plaflamme commented 12 years ago

Ok, then your problem is due to the Crowd configuration.

You can either setup gitblit to run behind your reverse proxy following what the faq says: http://gitblit.com/faq.html or Fix the crowd configuration by following their documentation: https://confluence.atlassian.com/display/CROWD/Debugging+SSO+in+environments+with+Proxy+Servers

riemers commented 12 years ago

I've setup to run it behind a reverse proxy, so that i can also have it as port 80 :) but it does not change the sso parts. Also double checked the sso part and the correct ips for this url which are present (after all, normal user login/pwd work) but still no luck. Do you need more informatino? i could put crowd on debug and see if something is coming in if that helps.

plaflamme commented 12 years ago

Yes, I suggest using Crowd debug log level to see what's going on.

My gitblit reverse proxy settings include the following:

    ProxyRequests     Off
    ProxyPreserveHost   On
    ProxyVia    Off

I think it's an IP issue: Crowd uses the IP of the user and the requesting app to generate the tokens. Thus, if the IP of the user changes when they hit a different app, then the token is invalidated...

riemers commented 11 years ago

Didn't know this was still open, using stash now though.