Modify

Opened 12 years ago

Closed 11 years ago

Last modified 11 years ago

#229 closed defect (fixed)

error with unicode usernames

Reported by: anonymous Owned by: Matt Good
Priority: highest Component: AccountManagerPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.10

Description

Python Traceback
Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/trac/web/main.py", line 283, in dispatch_request
    dispatcher.dispatch(req)
  File "/usr/lib/python2.4/site-packages/trac/web/main.py", line 170, in dispatch
    resp = chosen_handler.process_request(req)
  File "build/bdist.linux-i686/egg/acct_mgr/web_ui.py", line 117, in process_request
  File "build/bdist.linux-i686/egg/acct_mgr/web_ui.py", line 124, in _do_create
  File "build/bdist.linux-i686/egg/acct_mgr/api.py", line 85, in has_user
  File "build/bdist.linux-i686/egg/acct_mgr/htfile.py", line 41, in has_user
UnicodeDecodeError: 'ascii' codec can't decode byte 0xec in position 0: ordinal not in range(128)

Attachments (0)

Change History (6)

comment:1 Changed 12 years ago by Alec Thomas

Component: TracHacksAccountManagerPlugin
Owner: changed from Alec Thomas to Matt Good

This looks like an issue in AccountManagerPlugin, brought about by the recent unicode merges in trunk.

Did your username contain characters oustide 7 bit ASCII?

comment:2 Changed 12 years ago by Alec Thomas

I've fixed this on TracHacks by nuking an account in the password file that had unicode characters. See #250.

comment:3 Changed 11 years ago by Motte

Trac Release: 0.8

Errormessage on Windows
Used no char's outside 7Bit-ASCII. Directory /dev/urandom could be the error.

Oops...
Trac detected an internal error: 
[Errno 2] No such file or directory: '/dev/urandom'If you think this really should work and you can reproduce it. Then you should consider to report this problem to the Trac team. 

Go to http://trac.edgewall.com/ and create a new ticket where you describe the problem, how to reproduce it. Don't forget to include the python traceback found below. 

TracGuide — The Trac User and Administration Guide 

Python traceback
Traceback (most recent call last):
  File "C:\Python23\Lib\site-packages\trac\web\cgi_frontend.py", line 130, in run
    dispatch_request(req.path_info, req, env)
  File "C:\Python23\Lib\site-packages\trac\web\main.py", line 139, in dispatch_request
    dispatcher.dispatch(req)
  File "C:\Python23\Lib\site-packages\trac\web\main.py", line 107, in dispatch
    resp = chosen_handler.process_request(req)
  File "build\bdist.win32\egg\acct_mgr\web_ui.py", line 117, in process_request
  File "build\bdist.win32\egg\acct_mgr\web_ui.py", line 138, in _do_create
  File "build\bdist.win32\egg\acct_mgr\api.py", line 88, in set_password
  File "build\bdist.win32\egg\acct_mgr\htfile.py", line 50, in set_password
  File "build\bdist.win32\egg\acct_mgr\htfile.py", line 122, in userline
  File "build\bdist.win32\egg\acct_mgr\htfile.py", line 95, in salt
  File "build\bdist.win32\egg\acct_mgr\htfile.py", line 30, in urandom
IOError: [Errno 2] No such file or directory: '/dev/urandom'

comment:4 Changed 11 years ago by Matt Good

Summary: registering a new user on trac-hacks gives an errorerror with unicode usernames
Trac Release: 0.80.9

Motte: your problem is unrelated to this ticket. Htpasswd is not supported on Windows due to a lack of method for generating cryptographically sound random data. See #63.

comment:5 Changed 11 years ago by Matt Good

Resolution: fixed
Status: newclosed

(In [1069]) support unicode usernames and passwords (fixes #229)

comment:6 Changed 11 years ago by Matt Good

Severity: blockernormal
Trac Release: 0.90.10

The unicode support was added on the trunk for Trac 0.10 support now that all Trac uses unicode natively.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Matt Good.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.