Свойство | Тип | Описание | |
---|---|---|---|
$_gnupg | array | GnuPG program location/common options. | |
$_privateKeyring | string | Filename of the temporary private keyring. | |
$_publicKeyring | string | Filename of the temporary public keyring. | |
$_tempdir | string | The temporary directory to use. |
Метод | Описание | |
---|---|---|
__construct ( string $gnupg, string $temp = null ) | Constructor. | |
_callGpg ( array $options, string $mode, array $input = [], boolean $output = false, boolean $stderr = false, boolean $parseable = false, boolean $verbose = false ) : stdClass | Function that handles interfacing with the GnuPG binary. | |
decryptMessage ( $text, $params ) | ||
decryptSignature ( $text, $params ) | ||
encryptMessage ( $text, $params ) | ||
encryptSignature ( $text, $params ) | ||
generateKey ( $opts ) | ||
getFingerprintsFromKey ( $pgpdata ) | ||
getPublicKeyFromPrivateKey ( $data ) | ||
getSignersKeyID ( $text ) | ||
isEncryptedSymmetrically ( $text ) | ||
packetInfo ( $pgpdata ) | ||
packetInfoMultiple ( $pgpdata ) |
Метод | Описание | |
---|---|---|
_checkSignatureResult ( string $result, string $message = null ) : object | Checks signature result from the GnuPG binary. | |
_createKeyring ( string $type = 'public' ) : string | Creates a temporary gpg keyring. | |
_createTempFile ( string $descrip = 'horde-crypt', boolean $delete = true ) : string | Create a temporary file that will be deleted at the end of this process. | |
_ensureResult ( object $result ) | Checks whether there was some valid output. | |
_putInKeyring ( mixed $keys = [], string $type = 'public' ) : string | Adds PGP keys to the keyring. |
public __construct ( string $gnupg, string $temp = null ) | ||
$gnupg | string | The path to the GnuPG binary. |
$temp | string | Location of temporary directory. |
public _callGpg ( array $options, string $mode, array $input = [], boolean $output = false, boolean $stderr = false, boolean $parseable = false, boolean $verbose = false ) : stdClass | ||
$options | array | Options and commands to pass to GnuPG. |
$mode | string | 'r' to read from stdout, 'w' to write to stdin. |
$input | array | Input to write to stdin. |
$output | boolean | Collect and store output in object returned? |
$stderr | boolean | Collect and store stderr in object returned? |
$parseable | boolean | Is parseable output required? The gpg binary would be executed with C locale then. |
$verbose | boolean | Run GnuPG with verbose flag? |
Результат | stdClass | Class with members output, stderr, and stdout. |
protected _createKeyring ( string $type = 'public' ) : string | ||
$type | string | The type of key to analyze. 'public' or 'private'. |
Результат | string | Command line keystring option to use with gpg program. |
protected _ensureResult ( object $result ) | ||
$result | object | A result from _callGpg(). |
protected array $_gnupg | ||
Результат | array |
protected string $_privateKeyring | ||
Результат | string |
protected string $_publicKeyring | ||
Результат | string |
protected string $_tempdir | ||
Результат | string |