mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-02-25 17:01:17 -05:00
fix cli commands, translations and codestyle
This commit is contained in:
parent
6723f4215a
commit
1bfbb9242c
@ -31,15 +31,15 @@
|
|||||||
|
|
||||||
Add::Add()
|
Add::Add()
|
||||||
{
|
{
|
||||||
this->name = QString("add");
|
name = QString("add");
|
||||||
this->description = QObject::tr("Add a new entry to a database.");
|
description = QObject::tr("Add a new entry to a database.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Add::~Add()
|
Add::~Add()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Add::execute(QStringList arguments)
|
int Add::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
|
|
||||||
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
||||||
@ -134,6 +134,7 @@ int Add::execute(QStringList arguments)
|
|||||||
}
|
}
|
||||||
|
|
||||||
passwordGenerator.setCharClasses(PasswordGenerator::DefaultCharset);
|
passwordGenerator.setCharClasses(PasswordGenerator::DefaultCharset);
|
||||||
|
passwordGenerator.setFlags(PasswordGenerator::DefaultFlags);
|
||||||
QString password = passwordGenerator.generatePassword();
|
QString password = passwordGenerator.generatePassword();
|
||||||
entry->setPassword(password);
|
entry->setPassword(password);
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ class Add : public Command
|
|||||||
public:
|
public:
|
||||||
Add();
|
Add();
|
||||||
~Add();
|
~Add();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_ADD_H
|
#endif // KEEPASSXC_ADD_H
|
||||||
|
@ -32,15 +32,15 @@
|
|||||||
|
|
||||||
Clip::Clip()
|
Clip::Clip()
|
||||||
{
|
{
|
||||||
this->name = QString("clip");
|
name = QString("clip");
|
||||||
this->description = QObject::tr("Copy an entry's password to the clipboard.");
|
description = QObject::tr("Copy an entry's password to the clipboard.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Clip::~Clip()
|
Clip::~Clip()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Clip::execute(QStringList arguments)
|
int Clip::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
|
|
||||||
QTextStream out(stdout);
|
QTextStream out(stdout);
|
||||||
|
@ -25,7 +25,7 @@ class Clip : public Command
|
|||||||
public:
|
public:
|
||||||
Clip();
|
Clip();
|
||||||
~Clip();
|
~Clip();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
int clipEntry(Database* database, QString entryPath, QString timeout);
|
int clipEntry(Database* database, QString entryPath, QString timeout);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ Command::~Command()
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Command::execute(QStringList)
|
int Command::execute(const QStringList&)
|
||||||
{
|
{
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
|
@ -29,7 +29,7 @@ class Command
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual ~Command();
|
virtual ~Command();
|
||||||
virtual int execute(QStringList arguments);
|
virtual int execute(const QStringList& arguments);
|
||||||
QString name;
|
QString name;
|
||||||
QString description;
|
QString description;
|
||||||
QString getDescriptionLine();
|
QString getDescriptionLine();
|
||||||
|
@ -27,15 +27,15 @@
|
|||||||
|
|
||||||
Diceware::Diceware()
|
Diceware::Diceware()
|
||||||
{
|
{
|
||||||
this->name = QString("diceware");
|
name = QString("diceware");
|
||||||
this->description = QObject::tr("Generate a new random password.");
|
description = QObject::tr("Generate a new random diceware passphrase.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Diceware::~Diceware()
|
Diceware::~Diceware()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Diceware::execute(QStringList arguments)
|
int Diceware::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
||||||
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
||||||
@ -48,13 +48,13 @@ int Diceware::execute(QStringList arguments)
|
|||||||
parser.addOption(words);
|
parser.addOption(words);
|
||||||
QCommandLineOption wordlistFile(QStringList() << "w"
|
QCommandLineOption wordlistFile(QStringList() << "w"
|
||||||
<< "word-list",
|
<< "word-list",
|
||||||
QObject::tr("Wordlist fot the diceware generator.\n[Default: EFF English]"),
|
QObject::tr("Wordlist for the diceware generator.\n[Default: EFF English]"),
|
||||||
QObject::tr("path"));
|
QObject::tr("path"));
|
||||||
parser.addOption(wordlistFile);
|
parser.addOption(wordlistFile);
|
||||||
parser.process(arguments);
|
parser.process(arguments);
|
||||||
|
|
||||||
const QStringList args = parser.positionalArguments();
|
const QStringList args = parser.positionalArguments();
|
||||||
if (args.size() != 0) {
|
if (!args.isEmpty()) {
|
||||||
outputTextStream << parser.helpText().replace("keepassxc-cli", "keepassxc-cli diceware");
|
outputTextStream << parser.helpText().replace("keepassxc-cli", "keepassxc-cli diceware");
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ class Diceware : public Command
|
|||||||
public:
|
public:
|
||||||
Diceware();
|
Diceware();
|
||||||
~Diceware();
|
~Diceware();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_DICEWARE_H
|
#endif // KEEPASSXC_DICEWARE_H
|
||||||
|
@ -31,15 +31,15 @@
|
|||||||
|
|
||||||
Edit::Edit()
|
Edit::Edit()
|
||||||
{
|
{
|
||||||
this->name = QString("edit");
|
name = QString("edit");
|
||||||
this->description = QObject::tr("Edit an entry.");
|
description = QObject::tr("Edit an entry.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Edit::~Edit()
|
Edit::~Edit()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Edit::execute(QStringList arguments)
|
int Edit::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
|
|
||||||
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
||||||
@ -150,6 +150,7 @@ int Edit::execute(QStringList arguments)
|
|||||||
}
|
}
|
||||||
|
|
||||||
passwordGenerator.setCharClasses(PasswordGenerator::DefaultCharset);
|
passwordGenerator.setCharClasses(PasswordGenerator::DefaultCharset);
|
||||||
|
passwordGenerator.setFlags(PasswordGenerator::DefaultFlags);
|
||||||
QString password = passwordGenerator.generatePassword();
|
QString password = passwordGenerator.generatePassword();
|
||||||
entry->setPassword(password);
|
entry->setPassword(password);
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ class Edit : public Command
|
|||||||
public:
|
public:
|
||||||
Edit();
|
Edit();
|
||||||
~Edit();
|
~Edit();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_EDIT_H
|
#endif // KEEPASSXC_EDIT_H
|
||||||
|
@ -34,8 +34,8 @@
|
|||||||
|
|
||||||
Estimate::Estimate()
|
Estimate::Estimate()
|
||||||
{
|
{
|
||||||
this->name = QString("estimate");
|
name = QString("estimate");
|
||||||
this->description = QObject::tr("Estimate the entropy of a password.");
|
description = QObject::tr("Estimate the entropy of a password.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Estimate::~Estimate()
|
Estimate::~Estimate()
|
||||||
@ -138,7 +138,7 @@ static void estimate(const char* pwd, bool advanced)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int Estimate::execute(QStringList arguments)
|
int Estimate::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
||||||
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
||||||
|
@ -25,7 +25,7 @@ class Estimate : public Command
|
|||||||
public:
|
public:
|
||||||
Estimate();
|
Estimate();
|
||||||
~Estimate();
|
~Estimate();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_ESTIMATE_H
|
#endif // KEEPASSXC_ESTIMATE_H
|
||||||
|
@ -33,15 +33,15 @@
|
|||||||
|
|
||||||
Extract::Extract()
|
Extract::Extract()
|
||||||
{
|
{
|
||||||
this->name = QString("extract");
|
name = QString("extract");
|
||||||
this->description = QObject::tr("Extract and print the content of a database.");
|
description = QObject::tr("Extract and print the content of a database.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Extract::~Extract()
|
Extract::~Extract()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Extract::execute(QStringList arguments)
|
int Extract::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream out(stdout);
|
QTextStream out(stdout);
|
||||||
QTextStream errorTextStream(stderr);
|
QTextStream errorTextStream(stderr);
|
||||||
|
@ -25,7 +25,7 @@ class Extract : public Command
|
|||||||
public:
|
public:
|
||||||
Extract();
|
Extract();
|
||||||
~Extract();
|
~Extract();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_EXTRACT_H
|
#endif // KEEPASSXC_EXTRACT_H
|
||||||
|
@ -27,15 +27,15 @@
|
|||||||
|
|
||||||
Generate::Generate()
|
Generate::Generate()
|
||||||
{
|
{
|
||||||
this->name = QString("generate");
|
name = QString("generate");
|
||||||
this->description = QObject::tr("Generate a new random password.");
|
description = QObject::tr("Generate a new random password.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Generate::~Generate()
|
Generate::~Generate()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Generate::execute(QStringList arguments)
|
int Generate::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
QTextStream inputTextStream(stdin, QIODevice::ReadOnly);
|
||||||
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
||||||
@ -47,10 +47,10 @@ int Generate::execute(QStringList arguments)
|
|||||||
QObject::tr("length"));
|
QObject::tr("length"));
|
||||||
parser.addOption(len);
|
parser.addOption(len);
|
||||||
QCommandLineOption lower(QStringList() << "l",
|
QCommandLineOption lower(QStringList() << "l",
|
||||||
QObject::tr("Use lowercase in the generated password."));
|
QObject::tr("Use lowercase characters in the generated password."));
|
||||||
parser.addOption(lower);
|
parser.addOption(lower);
|
||||||
QCommandLineOption upper(QStringList() << "u",
|
QCommandLineOption upper(QStringList() << "u",
|
||||||
QObject::tr("Use uppercase in the generated password."));
|
QObject::tr("Use uppercase characters in the generated password."));
|
||||||
parser.addOption(upper);
|
parser.addOption(upper);
|
||||||
QCommandLineOption numeric(QStringList() << "n",
|
QCommandLineOption numeric(QStringList() << "n",
|
||||||
QObject::tr("Use numbers in the generated password."));
|
QObject::tr("Use numbers in the generated password."));
|
||||||
@ -59,12 +59,12 @@ int Generate::execute(QStringList arguments)
|
|||||||
QObject::tr("Use special characters in the generated password."));
|
QObject::tr("Use special characters in the generated password."));
|
||||||
parser.addOption(special);
|
parser.addOption(special);
|
||||||
QCommandLineOption extended(QStringList() << "e",
|
QCommandLineOption extended(QStringList() << "e",
|
||||||
QObject::tr("Use extended ascii in the generated password."));
|
QObject::tr("Use extended ASCII in the generated password."));
|
||||||
parser.addOption(extended);
|
parser.addOption(extended);
|
||||||
parser.process(arguments);
|
parser.process(arguments);
|
||||||
|
|
||||||
const QStringList args = parser.positionalArguments();
|
const QStringList args = parser.positionalArguments();
|
||||||
if (args.size() != 0) {
|
if (!args.isEmpty()) {
|
||||||
outputTextStream << parser.helpText().replace("keepassxc-cli", "keepassxc-cli generate");
|
outputTextStream << parser.helpText().replace("keepassxc-cli", "keepassxc-cli generate");
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
@ -97,6 +97,7 @@ int Generate::execute(QStringList arguments)
|
|||||||
}
|
}
|
||||||
|
|
||||||
passwordGenerator.setCharClasses(classes);
|
passwordGenerator.setCharClasses(classes);
|
||||||
|
passwordGenerator.setFlags(PasswordGenerator::DefaultFlags);
|
||||||
|
|
||||||
if (!passwordGenerator.isValid()) {
|
if (!passwordGenerator.isValid()) {
|
||||||
outputTextStream << parser.helpText().replace("keepassxc-cli", "keepassxc-cli generate");
|
outputTextStream << parser.helpText().replace("keepassxc-cli", "keepassxc-cli generate");
|
||||||
|
@ -25,7 +25,7 @@ class Generate : public Command
|
|||||||
public:
|
public:
|
||||||
Generate();
|
Generate();
|
||||||
~Generate();
|
~Generate();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_GENERATE_H
|
#endif // KEEPASSXC_GENERATE_H
|
||||||
|
@ -29,15 +29,15 @@
|
|||||||
|
|
||||||
List::List()
|
List::List()
|
||||||
{
|
{
|
||||||
this->name = QString("ls");
|
name = QString("ls");
|
||||||
this->description = QObject::tr("List database entries.");
|
description = QObject::tr("List database entries.");
|
||||||
}
|
}
|
||||||
|
|
||||||
List::~List()
|
List::~List()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int List::execute(QStringList arguments)
|
int List::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream out(stdout);
|
QTextStream out(stdout);
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class List : public Command
|
|||||||
public:
|
public:
|
||||||
List();
|
List();
|
||||||
~List();
|
~List();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
int listGroup(Database* database, QString groupPath = QString(""));
|
int listGroup(Database* database, QString groupPath = QString(""));
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -31,15 +31,15 @@
|
|||||||
|
|
||||||
Locate::Locate()
|
Locate::Locate()
|
||||||
{
|
{
|
||||||
this->name = QString("locate");
|
name = QString("locate");
|
||||||
this->description = QObject::tr("Find entries quickly.");
|
description = QObject::tr("Find entries quickly.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Locate::~Locate()
|
Locate::~Locate()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Locate::execute(QStringList arguments)
|
int Locate::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
|
|
||||||
QTextStream out(stdout);
|
QTextStream out(stdout);
|
||||||
|
@ -25,7 +25,7 @@ class Locate : public Command
|
|||||||
public:
|
public:
|
||||||
Locate();
|
Locate();
|
||||||
~Locate();
|
~Locate();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
int locateEntry(Database* database, QString searchTerm);
|
int locateEntry(Database* database, QString searchTerm);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -26,15 +26,15 @@
|
|||||||
|
|
||||||
Merge::Merge()
|
Merge::Merge()
|
||||||
{
|
{
|
||||||
this->name = QString("merge");
|
name = QString("merge");
|
||||||
this->description = QObject::tr("Merge two databases.");
|
description = QObject::tr("Merge two databases.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Merge::~Merge()
|
Merge::~Merge()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Merge::execute(QStringList arguments)
|
int Merge::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream out(stdout);
|
QTextStream out(stdout);
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class Merge : public Command
|
|||||||
public:
|
public:
|
||||||
Merge();
|
Merge();
|
||||||
~Merge();
|
~Merge();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_MERGE_H
|
#endif // KEEPASSXC_MERGE_H
|
||||||
|
@ -34,15 +34,15 @@
|
|||||||
|
|
||||||
Remove::Remove()
|
Remove::Remove()
|
||||||
{
|
{
|
||||||
this->name = QString("rm");
|
name = QString("rm");
|
||||||
this->description = QString("Remove an entry from the database.");
|
description = QString("Remove an entry from the database.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Remove::~Remove()
|
Remove::~Remove()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Remove::execute(QStringList arguments)
|
int Remove::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
QTextStream outputTextStream(stdout, QIODevice::WriteOnly);
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ class Remove : public Command
|
|||||||
public:
|
public:
|
||||||
Remove();
|
Remove();
|
||||||
~Remove();
|
~Remove();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
int removeEntry(Database* database, QString databasePath, QString entryPath);
|
int removeEntry(Database* database, QString databasePath, QString entryPath);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -29,15 +29,15 @@
|
|||||||
|
|
||||||
Show::Show()
|
Show::Show()
|
||||||
{
|
{
|
||||||
this->name = QString("show");
|
name = QString("show");
|
||||||
this->description = QObject::tr("Show an entry's information.");
|
description = QObject::tr("Show an entry's information.");
|
||||||
}
|
}
|
||||||
|
|
||||||
Show::~Show()
|
Show::~Show()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
int Show::execute(QStringList arguments)
|
int Show::execute(const QStringList& arguments)
|
||||||
{
|
{
|
||||||
QTextStream out(stdout);
|
QTextStream out(stdout);
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class Show : public Command
|
|||||||
public:
|
public:
|
||||||
Show();
|
Show();
|
||||||
~Show();
|
~Show();
|
||||||
int execute(QStringList arguments);
|
int execute(const QStringList& arguments);
|
||||||
int showEntry(Database* database, QStringList attributes, QString entryPath);
|
int showEntry(Database* database, QStringList attributes, QString entryPath);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -76,7 +76,7 @@ QString Utils::getPassword()
|
|||||||
* A valid and running event loop is needed to use the global QClipboard,
|
* A valid and running event loop is needed to use the global QClipboard,
|
||||||
* so we need to use this from the CLI.
|
* so we need to use this from the CLI.
|
||||||
*/
|
*/
|
||||||
int Utils::clipText(QString text)
|
int Utils::clipText(const QString& text)
|
||||||
{
|
{
|
||||||
|
|
||||||
QString programName = "";
|
QString programName = "";
|
||||||
|
@ -25,7 +25,7 @@ class Utils
|
|||||||
public:
|
public:
|
||||||
static void setStdinEcho(bool enable);
|
static void setStdinEcho(bool enable);
|
||||||
static QString getPassword();
|
static QString getPassword();
|
||||||
static int clipText(QString text);
|
static int clipText(const QString& text);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // KEEPASSXC_UTILS_H
|
#endif // KEEPASSXC_UTILS_H
|
||||||
|
@ -32,7 +32,7 @@ Estimates the entropy of a password. The password to estimate can be provided as
|
|||||||
Extracts and prints the contents of a database to standard output in XML format.
|
Extracts and prints the contents of a database to standard output in XML format.
|
||||||
|
|
||||||
.IP "generate [options]"
|
.IP "generate [options]"
|
||||||
Generate a random password
|
Generate a random password.
|
||||||
|
|
||||||
.IP "locate [options] <database> <term>"
|
.IP "locate [options] <database> <term>"
|
||||||
Locates all the entries that match a specific search term in a database.
|
Locates all the entries that match a specific search term in a database.
|
||||||
@ -139,7 +139,7 @@ Use numbers characters for the generated password. [Default: Enabled]
|
|||||||
Use special characters for the generated password. [Default: Disabled]
|
Use special characters for the generated password. [Default: Disabled]
|
||||||
|
|
||||||
.IP "-e"
|
.IP "-e"
|
||||||
Use extended ascii characters for the generated password. [Default: Disabled]
|
Use extended ASCII characters for the generated password. [Default: Disabled]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -61,13 +61,13 @@ public:
|
|||||||
int getbits() const;
|
int getbits() const;
|
||||||
|
|
||||||
static const int DefaultLength = 16;
|
static const int DefaultLength = 16;
|
||||||
static const bool DefaultLower = (DefaultCharset & LowerLetters) != 0;
|
static constexpr bool DefaultLower = (DefaultCharset & LowerLetters) != 0;
|
||||||
static const bool DefaultUpper = (DefaultCharset & UpperLetters) != 0;
|
static constexpr bool DefaultUpper = (DefaultCharset & UpperLetters) != 0;
|
||||||
static const bool DefaultNumbers = (DefaultCharset & Numbers) != 0;
|
static constexpr bool DefaultNumbers = (DefaultCharset & Numbers) != 0;
|
||||||
static const bool DefaultSpecial = (DefaultCharset & SpecialCharacters) != 0;
|
static constexpr bool DefaultSpecial = (DefaultCharset & SpecialCharacters) != 0;
|
||||||
static const bool DefaultEASCII = (DefaultCharset & EASCII) != 0;
|
static constexpr bool DefaultEASCII = (DefaultCharset & EASCII) != 0;
|
||||||
static const bool DefaultLookAlike = (DefaultFlags & ExcludeLookAlike) != 0;
|
static constexpr bool DefaultLookAlike = (DefaultFlags & ExcludeLookAlike) != 0;
|
||||||
static const bool DefaultFromEveryGroup = (DefaultFlags & CharFromEveryGroup) != 0;
|
static constexpr bool DefaultFromEveryGroup = (DefaultFlags & CharFromEveryGroup) != 0;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QVector<PasswordGroup> passwordGroups() const;
|
QVector<PasswordGroup> passwordGroups() const;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user