-
Notifications
You must be signed in to change notification settings - Fork 1
Configuration
Oscar Ruckdeschel edited this page Mar 1, 2016
·
9 revisions
For the KeePass integration you need to edit the following part from the config_template.py (config.py)
with open('<file path to password for KeePass>') as f:
content = f.readlines()
basedir = os.path.abspath(os.path.dirname(__file__)) # <dir path to the keepass file
databasefile = os.path.join(basedir, '<name of keepass file>')
extract = keepass.KeePassExtract(databasefile, content[0])
Either you directly enter your password and replace the both first lines or you read the password from a file on your system. Therefor you need to add the path to the file. (The KeePass library currently only supports passwords and no KeePass keyfiles.)
Further on you have to add the name and path to the KeePass (kdbx) file.
If everything goes well you can access the fields of the key in your KeePass like:
-
entry = extract.get_entry('<name>')- to read the fields of the entry with a given name entry.usernameentry.passwordentry.titleentry.urlentry.notes