What are allowed characters after all

18 views
Skip to first unread message

Marcin Kasperski

unread,
Nov 8, 2012, 12:11:00 PM11/8/12
to python-keyring
I just got the following bug: http://bz.selenic.com/show_bug.cgi?id=3696

In short: somebody tries to use german umlaut in his password, my mercurial_keyring passes it to keyring library, and keyring library (probably WinVault backend) crashes with UnicodeDecodeError

This is not a first time I face similar problems. Keyring does not at all document allowed syntax or even expected datatype for usernames, passwords and services. Some backends accept gladly everything, other are picky (from past issues I remember problem with / in service name for example … if one was unlucky to face file backend).

Really (a) something should be stated about allowed syntaxes and (b) whatever is stated, all backends should comply.

In my personal opinion it would be best to make keyring as permissive as possible (= oblige backends to escape everything they do not handle), I am OK with other ideas, but current situation is unpleasant.

I am strongly considering base32-ing everything before using keyring get_password and set_password but it would be rather strange choice… And I am curious whether it may make me face some length limits.


Jason R. Coombs

unread,
Jun 7, 2013, 6:19:51 PM6/7/13
to python-...@googlegroups.com
Hi Mekk, sorry for the late reply. I'm not sure why I didn't reply to your original message. I probably didn't notice that it was not posted to the issue tracker, so assumed I would get to it eventually. In any case, I've added your issue to the issue tracker as https://bitbucket.org/kang/python-keyring-lib/issue/101.

I'll take more care in the future to ensure mailing list requests get more prompt responses.
Reply all
Reply to author
Forward
0 new messages