diff options
author | Von Welch <von@vwelch.com> | 2013-02-11 22:08:30 -0500 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2013-02-23 13:33:02 +0100 |
commit | 5afc207d28f290936dca8fcdcab3157d3056379a (patch) | |
tree | 2702c749449bc9f90362fa4956dc5b1439ce01ad /contrib | |
parent | 7ff656179de5ab3b526dbf5a372ecdfcb0d7fab6 (diff) | |
download | pass-5afc207d28f290936dca8fcdcab3157d3056379a.tar.gz pass-5afc207d28f290936dca8fcdcab3157d3056379a.tar.bz2 pass-5afc207d28f290936dca8fcdcab3157d3056379a.zip |
keepassx2pass.py should handle empty passwords and entry names containing slash ('/') characters
Diffstat (limited to '')
-rwxr-xr-x | contrib/keepassx2pass.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/contrib/keepassx2pass.py b/contrib/keepassx2pass.py index 6043690..1804e33 100755 --- a/contrib/keepassx2pass.py +++ b/contrib/keepassx2pass.py @@ -11,13 +11,14 @@ from xml.etree import ElementTree def path_for(element, path=''): """ Generate path name from elements title and current path """ - title = element.find('title').text + title = element.find('title').text.replace("/", "|") return '/'.join([path, title]) def password_data(element): """ Return password data and additional info if available from password entry element. """ - ret = element.find('password').text + "\n" + passwd = element.find('password').text + ret = passwd + "\n" if passwd else "\n" for field in ['username', 'url', 'comment']: fel = element.find(field) if fel.text is not None: |