random_string calls

implement getRandomHex function
This commit is contained in:
Adam Magness 2018-11-08 08:45:46 -05:00
parent fd597472f1
commit 991f259ecb
23 changed files with 47 additions and 29 deletions

View file

@ -11,6 +11,7 @@ use Friendica\Database\DBA;
use Friendica\Model\Contact;
use Friendica\Util\HTTPSignature;
use Friendica\Util\Network;
use Friendica\Util\Strings;
/**
* Magic Auth (remote authentication) module.
@ -74,7 +75,7 @@ class Magic extends BaseModule
$headers = [];
$headers['Accept'] = 'application/x-dfrn+json';
$headers['X-Open-Web-Auth'] = random_string();
$headers['X-Open-Web-Auth'] = Strings::getRandomHex();
// Create a header that is signed with the local users private key.
$headers = HTTPSignature::createSig(