Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 364605

Summary: Centralize authentication for Eclipse.org services
Product: Community Reporter: Denis Roy <denis.roy>
Component: ServersAssignee: Eclipse Webmaster <webmaster>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: caniszczyk, cdtdoug, contact, eclipse, eclipse, fiedler.mf, gunnar, irbull, lmandel, nathan, overholt, pwebster, remy.suen, sbouchet, steffen.pingel, wayne.beaton
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:
Bug Depends on: 367984, 367985, 367986    
Bug Blocks: 261202, 363614    

Description Denis Roy CLA 2011-11-23 09:54:02 EST
This is going to be long-winded.

We currently rely on two authentication sources for the various services at eclipse.org:

- LDAP: this source contains Committer accounts only.  It is an open standard, and just avout every service out there supports LDAP auth

- Bugzilla: this application-specific source is used by Bugzilla; however, many other web-based services such as Wiki, Forums, Eclipse Live and Eclipse Marketplace have custom code to query this data source directly for authentication


I'm now at a crossroads for two reasons:

1. While deploying Gerrit, I can choose LDAP or HTTP as auth sources, but not both. Committers and Community must be able to log in, and I must reference Committer groups stored in LDAP, LDAP seems to be the obvious choice, but excludes the user community.  I either choose LDAP, or write some custom auth code.

2. For the new Project Management infra, it is highly desirable to centralize auth.


The most straightforward solution is to
a) import Bugzilla accounts into LDAP
b) Configure Bugzilla itself to use LDAP for auth
c) Configure the Eclipse Site login to use LDAP for auth (that will cover Wiki, Forums, Friends)
d) Alter Live, Marketplace, the current Portal and all other services to use LDAP for auth

Three complications arise from this approach: 
- Bugzilla stores passwords using the SHA-256 hash, which is not (easily) supported by LDAP.  The workaround here would be to import all the user data except the password, and send out an email to all the Bugzilla users to notify them of the new auth configuration and ask them to set a new password via some crafted page.  This is a bit disruptive, but I've seen this type of activity happen before.

- Since we currently rely on the Bugzilla "Create An Account" page to allow users to sign-up for our various services, we would need to disable that and write our own page, which would create an LDAP entry.  This is a highly desirable step towards a single sign-on and an official "Eclipse.org account".

- It may not be possible/easy to migrate a bunch of services over to LDAP auth without causing a large disruption.  To bridge the gap, the "Create an LDAP account/reset my LDAP password" pages we create to solve the two issues above could not only generate LDAP auth info, but also mirror that auth info to the Bugzilla database in SHA-256 format.  That would allow the "legacy" Bugzilla auth source to continue to be used.
Comment 1 Doug Schaefer CLA 2011-11-23 14:34:36 EST
Sounds like something that really needs to be done anyway. There are so many benefits to a single sign-on.
Comment 2 Denis Roy CLA 2011-11-23 15:28:50 EST
After some fiddling around, I think it will be easier to simply NOT import the Bugzilla sha256 password into LDAP, and request users set a new LDAP password (which we will hash sha1 to LDAP and sha256 to BZ).

Here's the plan:

1. Develop a "Create an account/reset my password" page to accompany our site login.  That will enable users to create a new "global" LDAP account.

2. Import existing BZ accounts into LDAP, carefully eliminating committer BZ accounts (their committer account is already ldap-enabled).

3. Test various services for LDAP authentication (mostly BZ)

4. Send out an email to all BZ users asking them to provide a new password (they will need to supply their 'old' password, which we will verify against the existing sha256) before the change is accepted

5. Gradually update services to use LDAP auth instead of the shadowed BZ auth
Comment 3 Ian Bull CLA 2011-11-23 15:54:51 EST
Will changing bugzilla to LDAP affect tools like Mylyn?  I've CCd Steffen just so he's aware of this.
Comment 4 Denis Roy CLA 2011-11-23 16:13:26 EST
(In reply to comment #3)
> Will changing bugzilla to LDAP affect tools like Mylyn?  I've CCd Steffen just
> so he's aware of this.

Great question.  AFAICT, users will still be submitting their email address and password to the same old web form... It's the underlying auth mechanism that will change.  So I don't think Mylyn will need any code changes.

Mylyn users will have to update their password as I mentioned in my previous comment.  But for that I'll be sending out an email to all the BZ users.
Comment 5 Steffen Pingel CLA 2011-11-23 19:41:18 EST
Thanks Ian. Mylyn relies on the standard post request/cookie for Bugzilla authentication. If that doesn't change I don't foresee any problems.
Comment 6 Lawrence Mandel CLA 2011-11-24 12:14:12 EST
As long as this is going to be an invasive change for users, how about looking at a technology like BrowserID (https://browserid.org/)? AFAIK BrowserID shouldn't stop Eclipse from using the existing LDAP authentication system but should allow for single sign-on for more Eclipse based services without giving all service owners access to LDAP. I can follow-up with some colleagues working on this technology if this of interest.
Comment 7 Denis Roy CLA 2011-12-06 10:35:53 EST
> As long as this is going to be an invasive change for users, how about looking
> at a technology like BrowserID (https://browserid.org/)? 

https://bugs.eclipse.org/bugs/show_bug.cgi?id=243930#c13


s/open id/browserid/g
Comment 8 Lawrence Mandel CLA 2011-12-06 10:46:43 EST
(In reply to comment #7)
> > As long as this is going to be an invasive change for users, how about looking
> > at a technology like BrowserID (https://browserid.org/)? 
> 
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=243930#c13
> 
> 
> s/open id/browserid/g

Some excellent points Denis. Clearly this would be a big undertaking. I spoke directly with one of the guys who works on BrowserID. If you're interested in pursuing a project like moving to BrowserID in the future I can try and set up a meeting so that you can speak directly with the guys who implement the technology (if that's helpful).
Comment 9 Denis Roy CLA 2011-12-16 16:06:03 EST
I have this working on my local dev environment.

- LDAP account creation, account updates (mail, fname, lname) & password reset
- Site login uses email address for auth, then performs LDAP auth
- Site login "logs into Bugzilla for you" to make sure your local BZ account is created, and your local BZ account password is updated.

What's left to do:
1. Test this out with Nathan and Matt
2. Create an import script that dumps bugzilla accounts into ldap
3. Commit changes live, test
4. Upgrade Bugzilla to 4.0 if 3.6.3 ldap auth is borked

I'm planning on doing 3 and 4 before the XMas shutdown.  I'll post dates up shortly.
Comment 10 Denis Roy CLA 2011-12-19 14:06:52 EST
Plan on committing changes Thursday:

http://www.eclipse.org/org/press-release/20111219_eclipse_account_changes.php
Comment 11 CHENG Yuk Pong CLA 2011-12-23 22:41:40 EST
I just found a "Eclipse.org Account Change" email in my spam folder. This email account is hosted by gmail, I guess lots of you may have the same problem.
Comment 12 Gunnar Wagenknecht CLA 2012-01-03 06:27:57 EST
Just noticed that IPzilla is not connected to LDAP. It uses the old Bugzilla email with the old Buzilla password before migration. Did that fall off somehow or is it just my account that isn't synchronized?
Comment 13 Denis Roy CLA 2012-01-03 09:37:52 EST
(In reply to comment #12)
> Just noticed that IPzilla is not connected to LDAP. It uses the old Bugzilla
> email with the old Buzilla password before migration. Did that fall off somehow
> or is it just my account that isn't synchronized?

There are a whole bunch of services that still use the Bugzilla DB to authenticate, and we need to migrate all of those as well.

The mistake I made was claiming committers didn't need to change their LDAP password.  When you "log in" to Bugzilla using LDAP, Bugzilla runs a SHA-256 on your password and stores it locally, which, in fact "syncs" it with LDAP.  But since none of the committers have re-logged into Bugzilla since the auth change, the BZ password is still the old password.
Comment 14 Gunnar Wagenknecht CLA 2012-01-04 02:02:39 EST
Denis, I did re-login to Bugzilla but the IPZilla password is still the old one and not in sync with the LDAP one. Same is true for the portal.

Portal:
  committer ID + LDAP PW: SUCCESS
  email + LDAP PW: FAILED
  email + old Bugzilla PW: SUCCESS

IPZilla:
  committer ID + LDAP PW: FAILED
  email + LDAP PW: FAILED
  email + old Bugzilla PW: SUCCESS

Bugzilla:
  committer ID + LDAP PW: FAILED
  email + LDAP PW: SUCCESS
  email + old Bugzilla PW: FAILED
Comment 15 Paul Webster CLA 2012-01-04 07:15:08 EST
(In reply to comment #14)
> Denis, I did re-login to Bugzilla but the IPZilla password is still the old one
> and not in sync with the LDAP one. Same is true for the portal.

I have the same problem, I can log out and into bugzilla with the email+LDAP, but IPZilla still wants the old bugzilla password.

PW
Comment 16 Andrew Overholt CLA 2012-01-05 12:22:35 EST
I'm in the same boat as Paul.
Comment 17 Denis Roy CLA 2012-01-05 12:58:40 EST
(In reply to comment #15)
> I have the same problem, I can log out and into bugzilla with the email+LDAP,
> but IPZilla still wants the old bugzilla password.

Rats.  I'm on it.
Comment 18 Denis Roy CLA 2012-01-05 14:53:39 EST
> I have the same problem, I can log out and into bugzilla with the email+LDAP,
> but IPZilla still wants the old bugzilla password.

*sigh*

I was under the impression that when you log into Bugzilla with the email+LDAP password, it automatically updated its local database with the correct password hash.  I swear I had tested this to be true, but it is not the case.

rats rats rats rats rats

So I've altered our site login / password reset / password change mechanisms to re-hash the password with SHA-256 and store it in Bugzilla, even at login time. This will allow our sites that still use the BZ db to authenticate correctly.

However, IPZilla won't get the new password has unless people re-login to dev.eclipse.org/site_login again.

I can only think of 1 solution: Put a prominent notice on IPZilla's home page, asking users to re-login to the site login if their IPZilla login doesn't work.

*sigh*   I can't wait for all this auth stuff to be fully centralized.
Comment 19 Andrew Overholt CLA 2012-01-05 14:58:32 EST
After logging in at dev.eclipse.org/site_login I can confirm that the passwords are in sync and I can log into IPZilla using the same password as Bugzilla (which continues to function correctly).

Thanks, Denis.
Comment 20 Denis Roy CLA 2012-01-05 15:09:29 EST
> are in sync and I can log into IPZilla using the same password as Bugzilla

<best Matrix imitation> There is no bugzilla password </>

Thanks for verifying.  I'll plop something up on IPZilla.
Comment 21 Denis Roy CLA 2012-01-05 15:27:49 EST
Removing the blocker for Gerrit, but I want to keep this bug open to track the sub tasks of migrating auth away from the Bugzilla DB.
Comment 22 Frank Becker CLA 2012-01-09 14:06:56 EST
I changed my password using https://dev.eclipse.org/site_login/myaccount.php but when using git.eclipse.org I get the "Your password has expired" error.

Thoughts?
Comment 23 Denis Roy CLA 2012-01-09 14:45:49 EST
> I changed my password using https://dev.eclipse.org/site_login/myaccount.php
> but when using git.eclipse.org I get the "Your password has expired" error.

There could be some attribute caching involved. If I look at your account, it says that your password was changed today.  Since it's already been over 30 minutes, can you confirm (via webmaster@eclipse.org) if it's working or not?  If not, I'll force the caches to clear and we can try to solve this that way.

Thanks
Comment 24 Denis Roy CLA 2013-02-25 11:52:00 EST
This is all done.
Comment 25 Denis Roy CLA 2013-02-25 11:52:22 EST
Fixed is even better.