diff options
author | friendica <info@friendica.com> | 2012-07-31 17:55:27 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2012-07-31 17:55:27 -0700 |
commit | 7a0894287268658361c90e2f4d1b77f8ca5739a6 (patch) | |
tree | 34d2de1842f9363be40ec6b27a026df5aa9dc699 /include/zot.php | |
parent | 65160ffd12500260ffd723bcffe721a3cc38d7da (diff) | |
download | volse-hubzilla-7a0894287268658361c90e2f4d1b77f8ca5739a6.tar.gz volse-hubzilla-7a0894287268658361c90e2f4d1b77f8ca5739a6.tar.bz2 volse-hubzilla-7a0894287268658361c90e2f4d1b77f8ca5739a6.zip |
remember that the main thing is to keep the main thing the main thing...
Diffstat (limited to 'include/zot.php')
-rw-r--r-- | include/zot.php | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/include/zot.php b/include/zot.php index 82bd8c7f1..cb57c2d84 100644 --- a/include/zot.php +++ b/include/zot.php @@ -10,7 +10,7 @@ function zot_new_uid($entity_id) { $rawstr = z_root() . '/' . $entity_id . '.' . mt_rand(); - return(base64url_encode(hash('whirlpool',$rawstr,true),true)); + return(base64url_encode(hash('whirlpool',$rawstr,true),true) . '.' . mt_rand()); } @@ -53,4 +53,14 @@ function zot_sign(&$item,$identity) { function zot_verify(&$item,$identity) { return rsa_verify($item[signed'],base64url_decode($item['signature']),$identity['pubkey']); -}
\ No newline at end of file +} + + + +function zot_notify($entity,$url) { + $x = z_post_url($url, + array('zot_uid' => $entity_global_id, 'callback' => z_root() . '/zot', 'spec' => ZOT_REVISION)); + return($x); +} + + |