|
QtPass 1.6.0
Multi-platform GUI for pass, the standard unix password manager.
|
#include "pass.h"#include "gpgkeystate.h"#include "helpers.h"#include "qtpasssettings.h"#include "util.h"#include <QCoreApplication>#include <QDebug>#include <QDir>#include <QFileInfo>#include <QProcess>#include <QRandomGenerator>#include <QRegularExpression>#include <algorithm>#include <utility>Go to the source code of this file.
Functions | |
| auto | gpgErrorMessage (const QString &err) -> QString |
| Maps GPG stderr (which may include –status-fd 2 tokens) to a translated user-friendly encryption error string. | |
| auto | parseGrepOutput (const QString &rawOut) -> QList< QPair< QString, QStringList > > |
| Parses 'pass grep' raw output into (entry, matches) pairs. | |
| auto gpgErrorMessage | ( | const QString & | err | ) |
Maps GPG stderr (which may include –status-fd 2 tokens) to a translated user-friendly encryption error string.
Checks machine-readable [GNUPG:] status tokens first (locale-independent), then falls back to case-insensitive substring matching for GPG builds that do not emit status tokens. Returns an empty string when no known pattern matches.
Declared here so it can be exercised by unit tests without linking the full Pass object.
| auto parseGrepOutput | ( | const QString & | rawOut | ) | -> QList< QPair< QString, QStringList > > |
Parses 'pass grep' raw output into (entry, matches) pairs.
pass grep emits ANSI blue color (\x1B[94m) at the start of each entry header line. This is checked before stripping ANSI so headers are detected reliably regardless of locale.