mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-11-22 16:00:38 -05:00
Disable stdin echo when entering passwords on cli
This commit is contained in:
parent
7438d6db18
commit
400073c7cc
6 changed files with 111 additions and 6 deletions
|
|
@ -29,6 +29,7 @@
|
|||
#include "core/Entry.h"
|
||||
#include "core/Group.h"
|
||||
#include "keys/CompositeKey.h"
|
||||
#include "cli/PasswordInput.h"
|
||||
|
||||
int Show::execute(int argc, char** argv)
|
||||
{
|
||||
|
|
@ -50,8 +51,7 @@ int Show::execute(int argc, char** argv)
|
|||
out << "Insert the database password\n> ";
|
||||
out.flush();
|
||||
|
||||
static QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
||||
QString line = inputTextStream.readLine();
|
||||
QString line = PasswordInput::getPassword();
|
||||
CompositeKey key = CompositeKey::readFromLine(line);
|
||||
|
||||
Database* db = Database::openDatabaseFile(args.at(0), key);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue