From 5f6a93daca647643b98569add1c24f0eac5f51e2 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Wed, 31 Mar 2010 14:25:21 -0500 Subject: [PATCH] Type byte is part of body --- lib/openpgp.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/openpgp.php b/lib/openpgp.php index ab67b71..3216792 100644 --- a/lib/openpgp.php +++ b/lib/openpgp.php @@ -414,12 +414,12 @@ class OpenPGP_SignaturePacket extends OpenPGP_Packet { if($class) { $packet = new $class(); $packet->tag = $tag; - $packet->input = substr($input, 1, $len); - $packet->length = $len; + $packet->input = substr($input, 1, $len-1); + $packet->length = $len-1; $packet->read(); unset($packet->input); } - $input = substr($input, $len+1); // Chop off the data from this packet + $input = substr($input, $len); // Chop off the data from this packet return $packet; }