array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'tr', ), 'this' => array ( 0 => 'function.gnupg-decrypt.php', 1 => 'gnupg_decrypt', ), 'up' => array ( 0 => 'ref.gnupg.php', 1 => 'GnuPG İşlevleri', ), 'prev' => array ( 0 => 'function.gnupg-clearsignkeys.php', 1 => 'gnupg_clearsignkeys', ), 'next' => array ( 0 => 'function.gnupg-decryptverify.php', 1 => 'gnupg_decryptverify', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/gnupg/functions/gnupg-decrypt.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PECL gnupg >= 0.1)
gnupg_decrypt — Decrypts a given text
Decrypts the given text with the keys, which were set with gnupg_adddecryptkey before.
identifier
Gnupg tanıtıcısı, bir gnupg_init() çağrısından veya gnupg nesnesinden elde edilir.
text
The text being decrypted.
On success, this function returns the decrypted text.
On failure, this function returns false
.
Örnek 1 Procedural gnupg_decrypt() example
<?php
$res = gnupg_init();
gnupg_adddecryptkey($res,"8660281B6051D071D94B5B230549F9DC851566DC","test");
$plain = gnupg_decrypt($res,$encrypted_text);
echo $plain;
?>
Örnek 2 OO gnupg_decrypt() example
<?php
$gpg = new gnupg();
$gpg->adddecryptkey("8660281B6051D071D94B5B230549F9DC851566DC","test");
$plain = $gpg->decrypt($encrypted_text);
echo $plain;
?>