Commits

Thomas Kluyver committed cbd7b75

Fix for set_password with unicode on Secret Service backend

Comments (0)

Files changed (1)

keyring/backend.py

             "username": username
             }
         _, session = service_iface.OpenSession("plain", "")
+        
+        if isinstance(password, unicode):
+            password = password.encode('utf-8')
         secret = dbus.Struct(
             (session, "", dbus.ByteArray(password), "text/plain"))
         properties = {