]> git.mxchange.org Git - friendica.git/blobdiff - mod/dfrn_confirm.php
The first queries are replaced with the new functions. More to come ...
[friendica.git] / mod / dfrn_confirm.php
index 7e14610e3397c15106a28caa5e586d44df154bb4..6ebde734e6ace3dfae9c610c521371afcaab1300 100644 (file)
@@ -18,6 +18,8 @@
  *    https://github.com/friendica/friendica/blob/master/spec/dfrn2_contact_confirmation.png
  */
 
+use Friendica\App;
+
 require_once('include/enotify.php');
 require_once('include/group.php');
 require_once('include/Probe.php');
@@ -185,10 +187,10 @@ function dfrn_confirm_post(App $a, $handsfree = null) {
                         *
                         */
 
-                       $src_aes_key = random_string();
+                       $src_aes_key = openssl_random_pseudo_bytes(64);
 
                        $result = '';
-                       openssl_private_encrypt($dfrn_id,$result,$user[0]['prvkey']);
+                       openssl_private_encrypt($dfrn_id, $result, $user[0]['prvkey']);
 
                        $params['dfrn_id'] = bin2hex($result);
                        $params['public_key'] = $public_key;