Coverage for pass_import/managers/keepassx2.py: 100%
15 statements
« prev ^ index » next coverage.py v7.4.3, created at 2024-02-26 12:11 +0000
« prev ^ index » next coverage.py v7.4.3, created at 2024-02-26 12:11 +0000
1# -*- encoding: utf-8 -*-
2# pass import - Passwords importer swiss army knife
3# Copyright (C) 2017-2024 Alexandre PUJOL <alexandre@pujol.io>.
4#
6from pass_import.core import register_managers
7from pass_import.formats.csv import CSV
8from pass_import.formats.kdbx import KDBX
11class Keepassx2CSV(CSV):
12 """Importer for KeepassX2 in CSV format."""
13 name = 'keepassx2'
14 default = False
15 url = 'https://www.keepassx.org'
16 hexport = 'Database > Export to CSV File'
17 himport = 'pass import keepassx2 file.csv'
18 keys = {
19 'title': 'Title',
20 'password': 'Password',
21 'login': 'Username',
22 'url': 'URL',
23 'comments': 'Notes',
24 'group': 'Group'
25 }
28class Keepassx2KDBX(KDBX):
29 """Importer for KeepassX2 encrypted KDBX format."""
30 name = 'keepassx2'
31 url = 'https://www.keepassx.org'
32 himport = 'pass import keepassx2 file.kdbx'
35register_managers(Keepassx2CSV, Keepassx2KDBX)