Skip to content

[CLI] create does not honor --no-password #4307

@Crote

Description

@Crote

Expected Behavior

When I run keepassxc-cli create --no-password --key-file somekey newdb.kdbx, the CLI should create a database without a password. This behaviour would be similar to that of all other cli commands and is heavily implied by the manpage

Current Behavior

The command returns Unknown option 'no-password'

Possible Solution

A current workaround is to use echo '' | keepassxc-cli create --key-file somekey newdb.kdbx instead, but this is very cumbersome.

It seems to be fixable by wrapping the https://github.com/keepassxreboot/keepassxc/blob/develop/src/cli/Create.cpp#L100 part in a if (!parser->isSet(Command::NoPasswordOption)) block and adding that flag to the options parser.

Context

Current behaviour is inconsistent with other commands and contradicts the manpage.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions