Skip to content
This repository has been archived by the owner on Feb 8, 2018. It is now read-only.

unicode flub in GitHub API usage #1489

Closed
chadwhitacre opened this issue Sep 22, 2013 · 10 comments
Closed

unicode flub in GitHub API usage #1489

chadwhitacre opened this issue Sep 22, 2013 · 10 comments

Comments

@chadwhitacre
Copy link
Contributor

Or even just in logging?

Traceback (most recent call last):
  File "aspen/website.py", line 76, in handle_safely
    response = self.handle(request)
  File "aspen/website.py", line 109, in handle
    response = request.resource.respond(request)
  File "aspen/resources/dynamic_resource.py", line 47, in respond
    exec self.pages[1] in context
  File "/app/www/on/github/%login/index.html.spt", line 18, in <module>
    user_info = github.get_user_info(path['login'])
  File "gittip/elsewhere/github.py", line 140, in get_user_info
    "GitHub identity '{0}' not found.".format(login))
UnicodeEncodeError: 'ascii' codec can't encode character u'\u200e' in position 4: ordinal not in ...

https://app.getsentry.com/gittip/gittip/group/6850474/

@hashar
Copy link
Contributor

hashar commented Sep 22, 2013

Example: https://www.gittip.com/on/github/atdt%E2%80%8E/

Obtained from the people search box by filling in the input box 'atdt' + something else I have no clue how I inserted it :/

@zbynekwinkler
Copy link
Contributor

Could be fixed by #158. I remember going over the code yesterday and thinking it would blow with unicode 😄

@zbynekwinkler
Copy link
Contributor

Let's block this on #158 and #1520.

@chadwhitacre
Copy link
Contributor Author

Sounds right to me.

@seanlinsley
Copy link
Contributor

How did this ever occur? We don't allow unicode in usernames, and neither does Github

@zbynekwinkler
Copy link
Contributor

You can put anything in the url https://www.gittip.com/on/github/[username]/ and we are not sanitizing that.

@chadwhitacre
Copy link
Contributor Author

Perhaps it was a security researcher?

@hashar
Copy link
Contributor

hashar commented Jan 5, 2014

@seanlinsley I just somehow entered a search for "atdt" and eventually that led to "atdt%E2%80%8E" because I added some additional unicode after my "atdt" search sentence. The server informed me of some error so I have pinged folks on irc and @whit537 grabbed the server side stack trace.

@ghost ghost assigned seanlinsley Jan 5, 2014
@Changaco
Copy link
Contributor

Changaco commented May 2, 2014

This problem has been solved, probably by #1369.

@hashar
Copy link
Contributor

hashar commented May 2, 2014

https://www.gittip.com/on/github/atdt%E2%80%8E/ gives a nice error page now. Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants