aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-05-30 13:25:58 -0700
committerredmatrix <git@macgirvin.com>2016-05-30 13:25:58 -0700
commitf35609d26cd9e6fb2c177ca1e422d0f0729f4f2e (patch)
tree416aea395a6c7360c9f87f631e88c336e95d2384 /include
parentf2ebe41a509d6e7f332fdc4cb43d14d555375bdf (diff)
downloadvolse-hubzilla-f35609d26cd9e6fb2c177ca1e422d0f0729f4f2e.tar.gz
volse-hubzilla-f35609d26cd9e6fb2c177ca1e422d0f0729f4f2e.tar.bz2
volse-hubzilla-f35609d26cd9e6fb2c177ca1e422d0f0729f4f2e.zip
redundant dev line from an earlier modification causes issue #404
Diffstat (limited to 'include')
-rw-r--r--include/crypto.php18
-rw-r--r--include/zot.php8
2 files changed, 6 insertions, 20 deletions
diff --git a/include/crypto.php b/include/crypto.php
index 42aa45b72..bc798d919 100644
--- a/include/crypto.php
+++ b/include/crypto.php
@@ -49,26 +49,12 @@ function AES256CBC_encrypt($data,$key,$iv) {
return openssl_encrypt($data,'aes-256-cbc',str_pad($key,32,"\0"),OPENSSL_RAW_DATA,str_pad($iv,16,"\0"));
-/* deprecated in php 7.1
- return mcrypt_encrypt(
- MCRYPT_RIJNDAEL_128,
- str_pad($key,32,"\0"),
- pkcs5_pad($data,16),
- MCRYPT_MODE_CBC,
- str_pad($iv,16,"\0"));
-*/
}
function AES256CBC_decrypt($data,$key,$iv) {
+
return openssl_decrypt($data,'aes-256-cbc',str_pad($key,32,"\0"),OPENSSL_RAW_DATA,str_pad($iv,16,"\0"));
-/* deprecated in php 7.1
- return pkcs5_unpad(mcrypt_decrypt(
- MCRYPT_RIJNDAEL_128,
- str_pad($key,32,"\0"),
- $data,
- MCRYPT_MODE_CBC,
- str_pad($iv,16,"\0")));
-*/
+
}
function crypto_encapsulate($data,$pubkey,$alg='aes256cbc') {
diff --git a/include/zot.php b/include/zot.php
index ecfbfa128..0f48fb0ba 100644
--- a/include/zot.php
+++ b/include/zot.php
@@ -352,8 +352,6 @@ function zot_refresh($them, $channel = null, $force = false) {
}
- $token = random_string();
-
$rhs = '/.well-known/zot-info';
$result = z_post_url($url . $rhs,$postvars);
@@ -1048,8 +1046,9 @@ function zot_process_response($hub, $arr, $outq) {
/**
* @brief
*
- * We received a notification packet (in mod/post.php) that a message is waiting for us, and we've verified the sender.
- * Now send back a pickup message, using our message tracking ID ($arr['secret']), which we will sign with our site private key.
+ * We received a notification packet (in mod_post) that a message is waiting for us, and we've verified the sender.
+ * Now send back a pickup message, using our message tracking ID ($arr['secret']), which we will sign with our site
+ * private key.
* The entire pickup message is encrypted with the remote site's public key.
* If everything checks out on the remote end, we will receive back a packet containing one or more messages,
* which will be processed and delivered before this function ultimately returns.
@@ -1123,6 +1122,7 @@ function zot_fetch($arr) {
* * [1] => \e string $delivery_status
* * [2] => \e string $address
*/
+
function zot_import($arr, $sender_url) {
$data = json_decode($arr['body'], true);