Skip to content

Commit 7bc4d24

Browse files
Merge branch 'develop' into feature/healthcheck
2 parents 6198653 + c97ee53 commit 7bc4d24

32 files changed

Lines changed: 283 additions & 186 deletions

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Changelog
22

3+
## 2.6 (unreleased)
4+
5+
### Added
6+
- Added CLI db-info command [#4231]
7+
8+
### Changed
9+
- Renamed CLI create command to db-create [#4231]
10+
311
## 2.5.3 (2020-01-19)
412

513
### Fixed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# <img src="https://keepassxc.org/logo.png" width="40" height="40"/> KeePassXC
22
[![TeamCity Build Status](https://ci.keepassxc.org/app/rest/builds/buildType:\(project:KeepassXC\)/statusIcon)](https://ci.keepassxc.org/?guest=1) [![codecov](https://codecov.io/gh/keepassxreboot/keepassxc/branch/develop/graph/badge.svg)](https://codecov.io/gh/keepassxreboot/keepassxc)
33

4-
## About KeePassXC
54
[KeePassXC](https://keepassxc.org) is a cross-platform community fork of
65
[KeePassX](https://www.keepassx.org/).
76
Our goal is to extend and improve it with new features and bugfixes

share/docs/man/keepassxc-cli.1

Lines changed: 64 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -7,161 +7,164 @@ keepassxc-cli \- command line interface for the \fBKeePassXC\fP password manager
77
.B keepassxc-cli
88
.I command
99
.B [
10-
-I options
10+
.I options
1111
.B ]
1212

1313
.SH DESCRIPTION
1414
\fBkeepassxc-cli\fP is the command line interface for the \fBKeePassXC\fP password manager. It provides the ability to query and modify the entries of a KeePass database, directly from the command line.
1515

1616
.SH COMMANDS
1717

18-
.IP "add [options] <database> <entry>"
18+
.IP "\fBadd\fP [options] <database> <entry>"
1919
Adds a new entry to a database. A password can be generated (\fI-g\fP option), or a prompt can be displayed to input the password (\fI-p\fP option).
2020
The same password generation options as documented for the generate command can be used when the \fI-g\fP option is set.
2121

22-
.IP "analyze [options] <database>"
22+
.IP "\fBanalyze\fP [options] <database>"
2323
Analyzes passwords in a database for weaknesses.
2424

25-
.IP "clip [options] <database> <entry> [timeout]"
25+
.IP "\fBclip\fP [options] <database> <entry> [timeout]"
2626
Copies the password or the current TOTP (\fI-t\fP option) of a database entry to the clipboard. If multiple entries with the same name exist in different groups, only the password for the first one is going to be copied. For copying the password of an entry in a specific group, the group path to the entry should be specified as well, instead of just the name. Optionally, a timeout in seconds can be specified to automatically clear the clipboard.
2727

28-
.IP "close"
28+
.IP "\fBclose\fP"
2929
In interactive mode, closes the currently opened database (see \fIopen\fP).
3030

31-
.IP "create [options] <database>"
31+
.IP "\fBdb-create\fP [options] <database>"
3232
Creates a new database with a key file and/or password. The key file will be created if the file that is referred to does not exist. If both the key file and password are empty, no database will be created.
3333

34-
.IP "diceware [options]"
34+
.IP "\fBdb-info\fP [options] <database>"
35+
Show a database's information.
36+
37+
.IP "\fBdiceware\fP [options]"
3538
Generates a random diceware passphrase.
3639

37-
.IP "edit [options] <database> <entry>"
40+
.IP "\fBedit\fP [options] <database> <entry>"
3841
Edits a database entry. A password can be generated (\fI-g\fP option), or a prompt can be displayed to input the password (\fI-p\fP option).
3942
The same password generation options as documented for the generate command can be used when the \fI-g\fP option is set.
4043

41-
.IP "estimate [options] [password]"
44+
.IP "\fBestimate\fP [options] [password]"
4245
Estimates the entropy of a password. The password to estimate can be provided as a positional argument, or using the standard input.
4346

44-
.IP "exit"
47+
.IP "\fBexit\fP"
4548
Exits interactive mode. Synonymous with \fIquit\fP.
4649

47-
.IP "export [options] <database>"
50+
.IP "\fBexport\fP [options] <database>"
4851
Exports the content of a database to standard output in the specified format (defaults to XML).
4952

50-
.IP "generate [options]"
53+
.IP "\fBgenerate\fP [options]"
5154
Generates a random password.
5255

53-
.IP "help [command]"
56+
.IP "\fBhelp\fP [command]"
5457
Displays a list of available commands, or detailed information about the specified command.
5558

56-
.IP "import [options] <xml> <database>"
59+
.IP "\fBimport\fP [options] <xml> <database>"
5760
Imports the contents of an XML database to the target database.
5861

59-
.IP "locate [options] <database> <term>"
62+
.IP "\fBlocate\fP [options] <database> <term>"
6063
Locates all the entries that match a specific search term in a database.
6164

62-
.IP "ls [options] <database> [group]"
65+
.IP "\fBls\fP [options] <database> [group]"
6366
Lists the contents of a group in a database. If no group is specified, it will default to the root group.
6467

65-
.IP "merge [options] <database1> <database2>"
68+
.IP "\fBmerge\fP [options] <database1> <database2>"
6669
Merges two databases together. The first database file is going to be replaced by the result of the merge, for that reason it is advisable to keep a backup of the two database files before attempting a merge. In the case that both databases make use of the same credentials, the \fI--same-credentials\fP or \fI-s\fP option can be used.
6770

68-
.IP "mkdir [options] <database> <group>"
71+
.IP "\fBmkdir\fP [options] <database> <group>"
6972
Adds a new group to a database.
7073

71-
.IP "mv [options] <database> <entry> <group>"
74+
.IP "\fBmv\fP [options] <database> <entry> <group>"
7275
Moves an entry to a new group.
7376

74-
.IP "open [options] <database>"
77+
.IP "\fBopen\fP [options] <database>"
7578
Opens the given database in a shell-style interactive mode. This is useful for performing multiple operations on a single database (e.g. \fIls\fP followed by \fIshow\fP).
7679

77-
.IP "quit"
80+
.IP "\fBquit\fP"
7881
Exits interactive mode. Synonymous with \fIexit\fP.
7982

80-
.IP "rm [options] <database> <entry>"
83+
.IP "\fBrm\fP [options] <database> <entry>"
8184
Removes an entry from a database. If the database has a recycle bin, the entry will be moved there. If the entry is already in the recycle bin, it will be removed permanently.
8285

83-
.IP "rmdir [options] <database> <group>"
86+
.IP "\fBrmdir\fP [options] <database> <group>"
8487
Removes a group from a database. If the database has a recycle bin, the group will be moved there. If the group is already in the recycle bin, it will be removed permanently.
8588

86-
.IP "show [options] <database> <entry>"
89+
.IP "\fBshow\fP [options] <database> <entry>"
8790
Shows the title, username, password, URL and notes of a database entry. Can also show the current TOTP. Regarding the occurrence of multiple entries with the same name in different groups, everything stated in the \fIclip\fP command section also applies here.
8891

8992
.SH OPTIONS
9093

9194
.SS "General options"
9295

93-
.IP "--debug-info"
96+
.IP "\fB--debug-info\fP"
9497
Displays debugging information.
9598

96-
.IP "-k, --key-file <path>"
99+
.IP "\fB-k\fP, \fB--key-file\fP <path>"
97100
Specifies a path to a key file for unlocking the database. In a merge operation this option, is used to specify the key file path for the first database.
98101

99-
.IP "--no-password"
102+
.IP "\fB--no-password\fP"
100103
Deactivates the password key for the database.
101104

102-
.IP "-y, --yubikey <slot>"
105+
.IP "\fB-y\fP, \fB--yubikey\fP <slot>"
103106
Specifies a yubikey slot for unlocking the database. In a merge operation this option is used to specify the yubikey slot for the first database.
104107

105-
.IP "-q, --quiet <path>"
108+
.IP "\fB-q\fP, \fB--quiet\fP <path>"
106109
Silences password prompt and other secondary outputs.
107110

108-
.IP "-h, --help"
111+
.IP "\fB-h\fP, \fB--help\fP"
109112
Displays help information.
110113

111-
.IP "-v, --version"
114+
.IP "\fB-v\fP, \fB--version\fP"
112115
Displays the program version.
113116

114117

115118
.SS "Merge options"
116119

117-
.IP "-d, --dry-run <path>"
120+
.IP "\fB-d\fP, \fB--dry-run\fP <path>"
118121
Prints the changes detected by the merge operation without making any changes to the database.
119122

120-
.IP "--key-file-from <path>"
123+
.IP "\fB--key-file-from\fP <path>"
121124
Sets the path of the key file for the second database.
122125

123-
.IP "--no-password-from"
126+
.IP "\fB--no-password-from\fP"
124127
Deactivates password key for the database to merge from.
125128

126-
.IP "--yubikey-from <slot>"
129+
.IP "\fB--yubikey-from\fP <slot>"
127130
Yubikey slot for the second database.
128131

129-
.IP "-s, --same-credentials"
132+
.IP "\fB-s\fP, \fB--same-credentials\fP"
130133
Uses the same credentials for unlocking both databases.
131134

132135

133136
.SS "Add and edit options"
134137
The same password generation options as documented for the generate command can be used
135138
with those 2 commands when the -g option is set.
136139

137-
.IP "-u, --username <username>"
140+
.IP "\fB-u\fP, \fB--username\fP <username>"
138141
Specifies the username of the entry.
139142

140-
.IP "--url <url>"
143+
.IP "\fB--url\fP <url>"
141144
Specifies the URL of the entry.
142145

143-
.IP "-p, --password-prompt"
146+
.IP "\fB-p\fP, \fB--password-prompt\fP"
144147
Uses a password prompt for the entry's password.
145148

146-
.IP "-g, --generate"
149+
.IP "\fB-g\fP, \fB--generate\fP"
147150
Generates a new password for the entry.
148151

149152

150153
.SS "Edit options"
151154

152-
.IP "-t, --title <title>"
155+
.IP "\fB-t\fP, \fB--title\fP <title>"
153156
Specifies the title of the entry.
154157

155158

156159
.SS "Estimate options"
157160

158-
.IP "-a, --advanced"
161+
.IP "\fB-a\fP, \fB--advanced\fP"
159162
Performs advanced analysis on the password.
160163

161164

162165
.SS "Analyze options"
163166

164-
.IP "-H, --hibp <filename>"
167+
.IP "\fB-H\fP, \fB--hibp\fP <filename>"
165168
Checks if any passwords have been publicly leaked, by comparing against the given
166169
list of password SHA-1 hashes, which must be in "Have I Been Pwned" format. Such
167170
files are available from https://haveibeenpwned.com/Passwords; note that they
@@ -171,79 +174,79 @@ hour or so).
171174

172175
.SS "Clip options"
173176

174-
.IP "-t, --totp"
177+
.IP "\fB-t\fP, \fB--totp\fP"
175178
Copies the current TOTP instead of current password to clipboard. Will report
176179
an error if no TOTP is configured for the entry.
177180

178181

179182
.SS "Show options"
180183

181-
.IP "-a, --attributes <attribute>..."
184+
.IP "\fB-a\fP, \fB--attributes\fP <attribute>..."
182185
Shows the named attributes. This option can be specified more than once,
183186
with each attribute shown one-per-line in the given order. If no attributes are
184187
specified and \fI-t\fP is not specified, a summary of the default attributes is given.
185188
Protected attributes will be displayed in clear text if specified explicitly by this option.
186189

187-
.IP "-s, --show-protected"
190+
.IP "\fB-s\fP, \fB--show-protected\fP"
188191
Shows the protected attributes in clear text.
189192

190-
.IP "-t, --totp"
193+
.IP "\fB-t\fP, \fB--totp\fP"
191194
Also shows the current TOTP, reporting an error if no TOTP is configured for
192195
the entry.
193196

194197

195198
.SS "Diceware options"
196199

197-
.IP "-W, --words <count>"
200+
.IP "\fB-W\fP, \fB--words\fP <count>"
198201
Sets the desired number of words for the generated passphrase. [Default: 7]
199202

200-
.IP "-w, --word-list <path>"
203+
.IP "\fB-w\fP, \fB--word-list\fP <path>"
201204
Sets the Path of the wordlist for the diceware generator. The wordlist must
202205
have > 1000 words, otherwise the program will fail. If the wordlist has < 4000
203206
words a warning will be printed to STDERR.
204207

205208

206209
.SS "Export options"
207210

208-
.IP "-f, --format"
211+
.IP "\fB-f\fP, \fB--format\fP"
209212
Format to use when exporting. Available choices are xml or csv. Defaults to xml.
210213

211214

212215
.SS "List options"
213216

214-
.IP "-R, --recursive"
217+
.IP "\fB-R\fP, \fB--recursive\fP"
215218
Recursively lists the elements of the group.
216219

217-
.IP "-f, --flatten"
220+
.IP "\fB-f\fP, \fB--flatten\fP"
218221
Flattens the output to single lines. When this option is enabled, subgroups and subentries will be displayed with a relative group path instead of indentation.
219222

220223
.SS "Generate options"
221224

222-
.IP "-L, --length <length>"
225+
.IP "\fB-L\fP, \fB--length\fP <length>"
223226
Sets the desired length for the generated password. [Default: 16]
224227

225-
.IP "-l --lower"
228+
.IP "\fB-l\fP, \fB--lower\fP"
226229
Uses lowercase characters for the generated password. [Default: Enabled]
227230

228-
.IP "-U --upper"
231+
.IP "\fB-U\fP, \fB--upper\fP"
229232
Uses uppercase characters for the generated password. [Default: Enabled]
230233

231-
.IP "-n --numeric"
234+
.IP "\fB-n\fP, \fB--numeric\fP"
232235
Uses numbers characters for the generated password. [Default: Enabled]
233236

234-
.IP "-s --special"
237+
.IP "\fB-s\fP, \fB--special\fP"
235238
Uses special characters for the generated password. [Default: Disabled]
236239

237-
.IP "-e --extended"
240+
.IP "\fB-e\fP, \fB--extended\fP"
238241
Uses extended ASCII characters for the generated password. [Default: Disabled]
239242

240-
.IP "-x --exclude <chars>"
243+
.IP "\fB-x\fP, \fB--exclude\fP <chars>"
241244
Comma-separated list of characters to exclude from the generated password. None is excluded by default.
242245

243-
.IP "--exclude-similar"
246+
.IP "\fB--exclude-similar\fP"
244247
Exclude similar looking characters. [Default: Disabled]
245248

246-
.IP "--every-group"
249+
.IP "\fB--every-group\fP"
247250
Include characters from every selected group. [Default: Disabled]
248251

249252

share/docs/man/keepassxc.1

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,25 +14,25 @@ keepassxc \- password manager
1414
\fBKeePassXC\fP is a free/open-source password manager or safe which helps you to manage your passwords in a secure way. The complete database is always encrypted with the industry-standard AES (alias Rijndael) encryption algorithm using a 256 bit key. KeePassXC uses a database format that is compatible with KeePass Password Safe. Your wallet works offline and requires no Internet connection.
1515

1616
.SH OPTIONS
17-
.IP "-h, --help"
17+
.IP "\fB-h\fP, \fB--help\fP"
1818
Displays this help.
1919

20-
.IP "-v, --version"
20+
.IP "\fB-v\fP, \fB--version\fP"
2121
Displays version information.
2222

23-
.IP "--config <config>"
23+
.IP "\fB--config\fP <config>"
2424
Path to a custom config file
2525

26-
.IP "--keyfile <keyfile>"
26+
.IP "\fB--keyfile\fP <keyfile>"
2727
Key file of the database
2828

29-
.IP "--pw-stdin"
29+
.IP "\fB--pw-stdin\fP"
3030
Read password of the database from stdin
3131

32-
.IP "--pw, --parent-window <handle>"
32+
.IP "\fB--pw\fP, \fB--parent-window\fP <handle>"
3333
Parent window handle
3434

35-
.IP "--debug-info"
35+
.IP "\fB--debug-info\fP"
3636
Displays debugging information.
3737

3838
.SH AUTHOR

src/cli/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ set(cli_SOURCES
3030
Generate.cpp
3131
Help.cpp
3232
Import.cpp
33+
Info.cpp
3334
List.cpp
3435
Locate.cpp
3536
Merge.cpp

src/cli/Command.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
#include "Generate.h"
3838
#include "Help.h"
3939
#include "Import.h"
40+
#include "Info.h"
4041
#include "List.h"
4142
#include "Locate.h"
4243
#include "Merge.h"
@@ -160,7 +161,8 @@ namespace Commands
160161
s_commands.insert(QStringLiteral("analyze"), QSharedPointer<Command>(new Analyze()));
161162
s_commands.insert(QStringLiteral("clip"), QSharedPointer<Command>(new Clip()));
162163
s_commands.insert(QStringLiteral("close"), QSharedPointer<Command>(new Close()));
163-
s_commands.insert(QStringLiteral("create"), QSharedPointer<Command>(new Create()));
164+
s_commands.insert(QStringLiteral("db-create"), QSharedPointer<Command>(new Create()));
165+
s_commands.insert(QStringLiteral("db-info"), QSharedPointer<Command>(new Info()));
164166
s_commands.insert(QStringLiteral("diceware"), QSharedPointer<Command>(new Diceware()));
165167
s_commands.insert(QStringLiteral("edit"), QSharedPointer<Command>(new Edit()));
166168
s_commands.insert(QStringLiteral("estimate"), QSharedPointer<Command>(new Estimate()));

0 commit comments

Comments
 (0)