summaryrefslogtreecommitdiff
path: root/plugins/OStatus/lib/magicenvelope.php
diff options
context:
space:
mode:
authorJames Walker <walkah@walkah.net>2010-02-22 23:30:21 -0500
committerJames Walker <walkah@walkah.net>2010-02-22 23:30:32 -0500
commit9494b0e5d79601b339bf28967a65ffdfe9458532 (patch)
tree7dfba0f526f43d76ac572f9b37901145d91f84de /plugins/OStatus/lib/magicenvelope.php
parent17b8020d2585ce248d12ad1a2b8f57a4ab250f82 (diff)
magicsig shuffling
Diffstat (limited to 'plugins/OStatus/lib/magicenvelope.php')
-rw-r--r--plugins/OStatus/lib/magicenvelope.php6
1 files changed, 2 insertions, 4 deletions
diff --git a/plugins/OStatus/lib/magicenvelope.php b/plugins/OStatus/lib/magicenvelope.php
index 1ae80d70c..81f4609c5 100644
--- a/plugins/OStatus/lib/magicenvelope.php
+++ b/plugins/OStatus/lib/magicenvelope.php
@@ -27,8 +27,6 @@
* @link http://status.net/
*/
-require_once 'magicsig.php';
-
class MagicEnvelope
{
const ENCODING = 'base64url';
@@ -64,7 +62,7 @@ class MagicEnvelope
return false;
}
- $signature_alg = new MagicsigRsaSha256($this->getKeyPair($signer_uri));
+ $signature_alg = Magicsig::fromString($this->getKeyPair($signer_uri));
$armored_text = base64_encode($text);
return array(
@@ -139,7 +137,7 @@ class MagicEnvelope
$text = base64_decode($env['data']);
$signer_uri = $this->getAuthor($text);
- $verifier = new MagicsigRsaSha256($this->getKeyPair($signer_uri));
+ $verifier = Magicsig::fromString($this->getKeyPair($signer_uri));
return $verifier->verify($env['data'], $env['sig']);
}