3 require_once dirname(__FILE__).'/../lib/openpgp.php';
4 require_once dirname(__FILE__).'/../lib/openpgp_crypt_rsa.php';
6 /* Parse public key from STDIN */
7 $wkey = OpenPGP_Message::parse(file_get_contents('php://stdin'));
9 /* Parse signed message from file named "t" */
10 $m = OpenPGP_Message::parse(file_get_contents('t'));
12 /* Create a verifier for the key */
13 $verify = new OpenPGP_Crypt_RSA($wkey);
15 /* Dump verification information to STDOUT */
16 var_dump($verify->verify($m));