QtPass 1.4.0
Multi-platform GUI for pass, the standard unix password manager.
Loading...
Searching...
No Matches
Signals | Public Member Functions | Static Public Member Functions | Protected Types | Protected Slots | Protected Member Functions | Protected Attributes | List of all members
Pass Class Referenceabstract

Acts as an abstraction for pass or pass imitation. More...

#include <pass.h>

+ Inheritance diagram for Pass:
+ Collaboration diagram for Pass:

Signals

void error (QProcess::ProcessError)
 
void startingExecuteWrapper ()
 
void statusMsg (QString, int)
 
void critical (QString, QString)
 
void processErrorExit (int exitCode, const QString &err)
 
void finishedAny (const QString &, const QString &)
 
void finishedGitInit (const QString &, const QString &)
 
void finishedGitPull (const QString &, const QString &)
 
void finishedGitPush (const QString &, const QString &)
 
void finishedShow (const QString &)
 
void finishedOtpGenerate (const QString &)
 
void finishedInsert (const QString &, const QString &)
 
void finishedRemove (const QString &, const QString &)
 
void finishedInit (const QString &, const QString &)
 
void finishedMove (const QString &, const QString &)
 
void finishedCopy (const QString &, const QString &)
 
void finishedGenerate (const QString &, const QString &)
 
void finishedGenerateGPGKeys (const QString &, const QString &)
 

Public Member Functions

 Pass ()
 Pass::Pass wrapper for using either pass or the pass imitation.
 
void init ()
 
virtual ~Pass ()
 
virtual void GitInit ()=0
 
virtual void GitPull ()=0
 
virtual void GitPull_b ()=0
 
virtual void GitPush ()=0
 
virtual void Show (QString file)=0
 
virtual void OtpGenerate (QString file)=0
 
virtual void Insert (QString file, QString value, bool force)=0
 
virtual void Remove (QString file, bool isDir)=0
 
virtual void Move (const QString srcDir, const QString dest, const bool force=false)=0
 
virtual void Copy (const QString srcDir, const QString dest, const bool force=false)=0
 
virtual void Init (QString path, const QList< UserInfo > &users)=0
 
virtual QString Generate_b (unsigned int length, const QString &charset)
 Pass::Generate use either pwgen or internal password generator.
 
void GenerateGPGKeys (QString batch)
 Pass::GenerateGPGKeys internal gpg keypair generator . .
 
QList< UserInfolistKeys (QStringList keystrings, bool secret=false)
 Pass::listKeys list users.
 
QList< UserInfolistKeys (QString keystring="", bool secret=false)
 Pass::listKeys list users.
 
void updateEnv ()
 Pass::updateEnv update the execution environment (used when switching profiles)
 

Static Public Member Functions

static QString getGpgIdPath (QString for_file)
 Pass::getGpgIdPath return gpgid file path for some file (folder).
 
static QStringList getRecipientList (QString for_file)
 Pass::getRecipientList return list of gpg-id's to encrypt for.
 
static QStringList getRecipientString (QString for_file, QString separator=" ", int *count=NULL)
 Pass::getRecipientString formated string for use with GPG.
 

Protected Types

typedef Enums::PROCESS PROCESS
 

Protected Slots

virtual void finished (int id, int exitCode, const QString &out, const QString &err)
 Pass::processFinished reemits specific signal based on what process has finished.
 

Protected Member Functions

void executeWrapper (PROCESS id, const QString &app, const QStringList &args, bool readStdout=true, bool readStderr=true)
 
QString generateRandomPassword (const QString &charset, unsigned int length)
 
quint32 boundedRandom (quint32 bound)
 
virtual void executeWrapper (PROCESS id, const QString &app, const QStringList &args, QString input, bool readStdout=true, bool readStderr=true)
 

Protected Attributes

Executor exec
 

Detailed Description

Acts as an abstraction for pass or pass imitation.

Definition at line 18 of file pass.h.

Member Typedef Documentation

◆ PROCESS

typedef Enums::PROCESS Pass::PROCESS
protected

Definition at line 27 of file pass.h.

Constructor & Destructor Documentation

◆ Pass()

Pass::Pass ( )

Pass::Pass wrapper for using either pass or the pass imitation.

Definition at line 17 of file pass.cpp.

+ Here is the call graph for this function:

◆ ~Pass()

virtual Pass::~Pass ( )
inlinevirtual

Definition at line 33 of file pass.h.

Member Function Documentation

◆ boundedRandom()

quint32 Pass::boundedRandom ( quint32  bound)
protected

Definition at line 349 of file pass.cpp.

+ Here is the caller graph for this function:

◆ Copy()

virtual void Pass::Copy ( const QString  srcDir,
const QString  dest,
const bool  force = false 
)
pure virtual

Implemented in ImitatePass, and RealPass.

+ Here is the caller graph for this function:

◆ critical

void Pass::critical ( QString  ,
QString   
)
signal
+ Here is the caller graph for this function:

◆ error

void Pass::error ( QProcess::ProcessError  )
signal

◆ executeWrapper() [1/2]

void Pass::executeWrapper ( PROCESS  id,
const QString &  app,
const QStringList &  args,
bool  readStdout = true,
bool  readStderr = true 
)
protected

Definition at line 31 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ executeWrapper() [2/2]

void Pass::executeWrapper ( PROCESS  id,
const QString &  app,
const QStringList &  args,
QString  input,
bool  readStdout = true,
bool  readStderr = true 
)
protectedvirtual

Reimplemented in ImitatePass.

Definition at line 37 of file pass.cpp.

+ Here is the call graph for this function:

◆ finished

void Pass::finished ( int  id,
int  exitCode,
const QString &  out,
const QString &  err 
)
protectedvirtualslot

Pass::processFinished reemits specific signal based on what process has finished.

Parameters
idid of Pass process that was scheduled and finished
exitCodereturn code of a process
outoutput generated by process(if capturing was requested, empty otherwise)
errerror output generated by process(if capturing was requested, or error occurred)

Reimplemented in ImitatePass.

Definition at line 195 of file pass.cpp.

+ Here is the caller graph for this function:

◆ finishedAny

void Pass::finishedAny ( const QString &  ,
const QString &   
)
signal

◆ finishedCopy

void Pass::finishedCopy ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedGenerate

void Pass::finishedGenerate ( const QString &  ,
const QString &   
)
signal

◆ finishedGenerateGPGKeys

void Pass::finishedGenerateGPGKeys ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedGitInit

void Pass::finishedGitInit ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedGitPull

void Pass::finishedGitPull ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedGitPush

void Pass::finishedGitPush ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedInit

void Pass::finishedInit ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedInsert

void Pass::finishedInsert ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedMove

void Pass::finishedMove ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedOtpGenerate

void Pass::finishedOtpGenerate ( const QString &  )
signal
+ Here is the caller graph for this function:

◆ finishedRemove

void Pass::finishedRemove ( const QString &  ,
const QString &   
)
signal
+ Here is the caller graph for this function:

◆ finishedShow

void Pass::finishedShow ( const QString &  )
signal
+ Here is the caller graph for this function:

◆ Generate_b()

QString Pass::Generate_b ( unsigned int  length,
const QString &  charset 
)
virtual

Pass::Generate use either pwgen or internal password generator.

Parameters
lengthof the desired password
charsetto use for generation
Returns
the password

Definition at line 71 of file pass.cpp.

+ Here is the call graph for this function:

◆ GenerateGPGKeys()

void Pass::GenerateGPGKeys ( QString  batch)

Pass::GenerateGPGKeys internal gpg keypair generator . .

Parameters
batchGnuPG style configuration string

Definition at line 116 of file pass.cpp.

+ Here is the call graph for this function:

◆ generateRandomPassword()

QString Pass::generateRandomPassword ( const QString &  charset,
unsigned int  length 
)
protected

Definition at line 364 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getGpgIdPath()

QString Pass::getGpgIdPath ( QString  for_file)
static

Pass::getGpgIdPath return gpgid file path for some file (folder).

Parameters
for_filewhich file (folder) would you like the gpgid file path for.
Returns
path to the gpgid file.

Definition at line 290 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getRecipientList()

QStringList Pass::getRecipientList ( QString  for_file)
static

Pass::getRecipientList return list of gpg-id's to encrypt for.

Parameters
for_filewhich file (folder) would you like recepients for
Returns
recepients gpg-id contents

Definition at line 318 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getRecipientString()

QStringList Pass::getRecipientString ( QString  for_file,
QString  separator = " ",
int *  count = NULL 
)
static

Pass::getRecipientString formated string for use with GPG.

Parameters
for_filewhich file (folder) would you like recepients for
separatorformating separator eg: " -r "
count
Returns
recepient string

Definition at line 339 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GitInit()

virtual void Pass::GitInit ( )
pure virtual

Implemented in ImitatePass, and RealPass.

◆ GitPull()

virtual void Pass::GitPull ( )
pure virtual

Implemented in ImitatePass, and RealPass.

◆ GitPull_b()

virtual void Pass::GitPull_b ( )
pure virtual

Implemented in ImitatePass, and RealPass.

◆ GitPush()

virtual void Pass::GitPush ( )
pure virtual

Implemented in ImitatePass, and RealPass.

+ Here is the caller graph for this function:

◆ init()

void Pass::init ( )

Definition at line 47 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Init()

virtual void Pass::Init ( QString  path,
const QList< UserInfo > &  users 
)
pure virtual

Implemented in ImitatePass, and RealPass.

+ Here is the caller graph for this function:

◆ Insert()

virtual void Pass::Insert ( QString  file,
QString  value,
bool  force 
)
pure virtual

Implemented in ImitatePass, and RealPass.

◆ listKeys() [1/2]

QList< UserInfo > Pass::listKeys ( QString  keystring = "",
bool  secret = false 
)

Pass::listKeys list users.

Parameters
keystring
secretlist private keys
Returns
QList<UserInfo> users

Definition at line 181 of file pass.cpp.

+ Here is the call graph for this function:

◆ listKeys() [2/2]

QList< UserInfo > Pass::listKeys ( QStringList  keystrings,
bool  secret = false 
)

Pass::listKeys list users.

Parameters
keystrings
secretlist private keys
Returns
QList<UserInfo> users

Definition at line 130 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Move()

virtual void Pass::Move ( const QString  srcDir,
const QString  dest,
const bool  force = false 
)
pure virtual

Implemented in ImitatePass, and RealPass.

+ Here is the caller graph for this function:

◆ OtpGenerate()

virtual void Pass::OtpGenerate ( QString  file)
pure virtual

Implemented in ImitatePass, and RealPass.

◆ processErrorExit

void Pass::processErrorExit ( int  exitCode,
const QString &  err 
)
signal
+ Here is the caller graph for this function:

◆ Remove()

virtual void Pass::Remove ( QString  file,
bool  isDir 
)
pure virtual

Implemented in ImitatePass, and RealPass.

◆ Show()

virtual void Pass::Show ( QString  file)
pure virtual

Implemented in ImitatePass, and RealPass.

+ Here is the caller graph for this function:

◆ startingExecuteWrapper

void Pass::startingExecuteWrapper ( )
signal
+ Here is the caller graph for this function:

◆ statusMsg

void Pass::statusMsg ( QString  ,
int   
)
signal
+ Here is the caller graph for this function:

◆ updateEnv()

void Pass::updateEnv ( )

Pass::updateEnv update the execution environment (used when switching profiles)

Definition at line 248 of file pass.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ exec

Executor Pass::exec
protected

Definition at line 25 of file pass.h.


The documentation for this class was generated from the following files: