Login in a wiki using openid in a page that contains non-ascii chars OOPSes with UnicodeEncodeError

Bug #372208 reported by Ursula Junque
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical SSO provider
Invalid
High
David Owen
Moin OpenID module
New
Undecided
Unassigned

Bug Description

Steps to reproduce:

1) Go to https://wiki.ubuntu.com/CatalanTeam/JauntyJackalope/GTDifusió, for instance. Be sure you're logged out.
2) Click on "Log in", and use Launchpad openid to try to log in into the wiki.
3) Just watch the wiki to do the openid dance. It should oops like OOPS-1221J386:
  UnicodeEncodeError: 'ascii' codec can't encode character u'\\xf3' in position 59: ordinal not in range(128)

More: OOPS-1221J394, OOPS-1220I504, OOPS-1220J1

Tags: oops openid
Ursula Junque (ursinha)
summary: - Log in on Ubuntu wiki using openid on a page that contains non-ascii
- chars OOPSes with UnicodeEncodeError
+ Login in a wiki using openid in a page that contains non-ascii chars
+ OOPSes with UnicodeEncodeError
Revision history for this message
James Henstridge (jamesh) wrote :

Looking at section 4.1 of http://openid.net/specs/openid-authentication-2_0.html, I think it'd be safe to switch that bit of code to encode to UTF-8 rather than US-ASCII. That would remove the possibility of UnicodeEncodeErrors at that point.

Changed in canonical-identity-provider:
milestone: none → 2.7.0
milestone: 2.7.0 → 2.6.0
Changed in canonical-identity-provider:
importance: Undecided → High
status: New → Confirmed
David Owen (dsowen)
Changed in canonical-identity-provider:
assignee: nobody → David Owen (dsowen)
David Owen (dsowen)
Changed in canonical-identity-provider:
status: Confirmed → In Progress
Revision history for this message
David Owen (dsowen) wrote :

(This bug is 1 year old).

I don't get any oopses or tracebacks from the SSO site, but I do get this error from the wiki site. It happens after I authenticate with SSO, I'm redirected back to the wiki, and the wiki is setting up another redirect.

It's traceback indicates it may be a problem with a patch over an older MoinMoin to enable OpenID. See https://bazaar.launchpad.net/~launchpad/moin-openid/moin-openid/annotate/26/moin-1.6-newauth/MoinMoin/request/__init__.py#L654 for the code that I suspect is incorrect. Line 660 is a call to http_redirect. Its docstring states on line 1288 that the URL must be a "relative or absolute url, ascii using url encoding." The traceback shows UTF-8 characters being passed.

David Owen (dsowen)
Changed in canonical-identity-provider:
status: In Progress → Invalid
Changed in canonical-identity-provider:
milestone: 2.6.0 → none
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.