Can't log into the Patches.linaro.org admin interface

Bug #1046911 reported by Anmar Oueja
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Linaro patch metrics
Fix Released
High
Deepti B. Kalakeri

Bug Description

When I click on the "My dashboard" link off the patches.linaro.org, I get the usual ubuntu SSO screens then an exception display (attached).

Revision history for this message
Anmar Oueja (anmar) wrote :
Revision history for this message
Deepti B. Kalakeri (deeptik) wrote :

I see that there are 2 user accounts in the name Anmar

 anmar <email address hidden> Anmar Oueja False
 anmar2 <email address hidden> Anmar Oueja False

I guess the error is coming because both the users have the same email id.
I see the second user anmar2 is created yesterday, was this intentional and do you need 2 accounts ?
I would like to see if the problem goes if we change the email information of one of the accounts ?
Can you provide me with a different email address than <email address hidden> so that I can reset that information for account anmar2.

Changed in linaro-patchmetrics:
assignee: nobody → Deepti B. Kalakeri (deeptik)
milestone: none → 2012.09
importance: Undecided → High
Revision history for this message
Milo Casagrande (milo) wrote :

@deepti:
The second account can be removed safely, I did the same yesterday, but it continues to give the same error to him.
The second account looks like is the result of trying to register/login. I do not know if removing the "original" account it will work again. Yesterday I cleaned up as much as possible, but it still gave him that error. We should try to remove also the original account, my only fear with that is that all the "relationships" of that account (if you try to delete it you will see what I mean) with the various teams will be lost, and I couldn't understand from the code if that is an automatic process or what.
The only thing left to try is really that, removing the original account, and try to clean up again as much as possible of what can be associated with that account (in terms of sessions, OpenIDs token, etc...).

Revision history for this message
Anmar Oueja (anmar) wrote : Re: [Bug 1046911] Re: Can't log into the Patches.linaro.org admin interface

Guys,

I just re-tested and it is still the same problem.

Revision history for this message
Deepti B. Kalakeri (deeptik) wrote :

I tried adding a new lp user to p.l.o and it was successful with SSO to login and did not notice any problems.

I also, deleted all the user information of Anmar, seems like we now get the error
"
OpenID failed
OpenID authentication failed: Nonce already used or out of range
"

One difference what we have is anmar uses 2 factor authentication method to login to p.l.o. Am not 100% sure if this would be a problem.

Since it is time consuming to get information from IS for investigation, as a next step am trying to setup a local p.l.o to further investigate.

Revision history for this message
Milo Casagrande (milo) wrote :

On Mon, Sep 10, 2012 at 5:54 PM, Deepti B. Kalakeri
<email address hidden> wrote:
> I tried adding a new lp user to p.l.o and it was successful with SSO to
> login and did not notice any problems.
>
> I also, deleted all the user information of Anmar, seems like we now get the error
> "
> OpenID failed
> OpenID authentication failed: Nonce already used or out of range
> "

You can also delete the "nonces" from the web view, but do not know
what will happen to other users, probably they will be logged out.

--
Milo Casagrande
Infrastructure Engineer
Linaro.org <www.linaro.org> │ Open source software for ARM SoCs

Revision history for this message
Deepti B. Kalakeri (deeptik) wrote :

Initial search on internet suggested that the problem of OpenID auth would be occurring due to time skews.
Here is a reference https://bugs.launchpad.net/lava-deployment-tool/+bug/894571 to a similar problem which was solved using ntpdate.

But, when Anmar tried to "ntpdate ntp.ubuntu.com " on his machine, that did not help either.

I have spoken to IS as well regarding the problem of OpenID failure, and they too mentioned about the ntpupdate thing could help.

Some more hints on the issue can be found in the bug updates(though its an old bug, but has reference to similar problem) https://bugs.launchpad.net/ubuntuone-client/+bug/510866.

It looks like its a bug in the openid side now.

In addition, the following things were suggested by IS:
option 1) clear the cookies for the sso site (login.launchpad.net and login.ubuntu.com)
option 2) 1) disable js, 2) do the login , it should render a button to submit a form (instead of auto-submitting), 3) file a bug (marked as private) including that data (the values for the fields being submitted)

@ Milo,
I spoke to Salgado about the deletion of nonces yesterday, but he is not in favour of it.
I will try your suggestion soon when everything else fails as a last resort.

Changed in linaro-patchmetrics:
status: New → Triaged
Revision history for this message
Deepti B. Kalakeri (deeptik) wrote :

Finally, was able to find the root cause of the problem with some data extraction from the patchwork database by IS.
The error integrity error "duplicate key value violates unique constraint "patchwork_person_email_key" ' is coming because the email id of user anmar is stored in 2 different ways in tables auth_user and patchwork_person.

In auth_user the email is stored as <email address hidden> and in patchwork_person it is stored as <email address hidden>. lp primary email id with which he logs in "<email address hidden>" is converted to lower case by patchwork code before inserting it into the patchwork_person table. So, apparently when anmar tries to login next time, there seems to be a try to update the records for user anmar in auth_user and patchwork_person tables and it fails with integrity error as the record with the same email address already exist.

The initial solution was to make both the email address information stored in tables same. And, when Anmar logged out and logged in he was successful without any problems. But, with this login the email address in the tables seem to get updated back to <email address hidden> ( which comes from lp and we do not have control on this information) in auth_user and as <email address hidden> in patchwork_person. Hence the next time anmar would log in he would hit the error back.

The solution for this is
1) Anmar has to change his email address from <email address hidden> to <email address hidden> if he intends to use it for logging in
2) OR use an alternative email address to login to p.l.o
3) OR change p.l.o to store the email information into patchwork_person matching to auth_user information.

I guess, we should try step 1 and 2 before as it should be easily done, before trying to indulge trying option 3 and changing the p.l.o.

Changed in linaro-patchmetrics:
status: Triaged → In Progress
Revision history for this message
Deepti B. Kalakeri (deeptik) wrote :

One more option suggested by Danilo, to try and change the email information from <email address hidden> to <email address hidden> and make it as preferred email @ https://login.ubuntu.com/+emails.

Once we did that, It seem to have helped and anmar is able to login to the p.l.o without any issues.

@ Anmar,

Can you confirm the behaviour so that we can close the bug ?

Revision history for this message
Deepti B. Kalakeri (deeptik) wrote :

Just for records, previously we had tried to change the email details for anmar on login.launchpad.net from <email address hidden> to <email address hidden>, but it still retained the <email address hidden> email address when trying to login to p.l.o.

Seems like we had to change the same information in https://login.ubuntu.com/+emails as well and yes, by doing the changes it did help as Anmar is able to login successfully now.

Revision history for this message
Anmar Oueja (anmar) wrote :

I want to thank Deepti for an amazing job. Without her help and
tenacity is trying to resolve this problem, it would have never been
resolved.

Thanks Deepti. I really appreciate all the hard work.

Anmar

Changed in linaro-patchmetrics:
status: In Progress → Fix Committed
Changed in linaro-patchmetrics:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.