Skip to content

Instantly share code, notes, and snippets.


Scott paragonie-scott

View GitHub Profile
paragonie-scott / pbkdf2-symfony-polyfill.php
Created Oct 11, 2018 — forked from spaze/pbkdf2-symfony-polyfill.php
Symfony's PBKDF2 polyfill benchmark (TL;DR it's slow) for the thread here
View pbkdf2-symfony-polyfill.php
function hashPbkdf2($algorithm, $password, $salt, $iterations, $length = 0)
// Number of blocks needed to create the derived key
$blocks = ceil($length / strlen(hash($algorithm, null, true)));
$digest = '';
$length = strlen(hash($algorithm, '', true));
if (strlen($password) > $length) {
$password = hash($algorithm, $password, true);
paragonie-scott / spotilocal.priv.pem
Created Jan 23, 2017 — forked from venoms/spotilocal.priv.pem private key
View spotilocal.priv.pem
Private-Key: (4096 bit)
paragonie-scott / WhatsAppSaudi.txt
Created Jul 13, 2016
WhatsApp Blocking Encrypted Calls to All Saudi Numbers
View WhatsAppSaudi.txt
Suppose I have a friend named Alice. Alice has registered to WhatsApp with a
Saudi number but resides in Europe. We chat over WhatsApp regularly. We are both
using the latest version of WhatsApp for Android (2.16.155).
However, Alice is unable to receive or initiate WhatsApp calls, even though she
is in Europe and is using European WiFi. If you can test this, I suggest you do.
Get a Saudi phone number, register to WhatsApp, and then fly to France and make
a call. You will encounter the same result even if you're on French WiFi.
WhatsApp claims that "the Saudis are blocking the initial handshake [for
View gist:c7a73fd0f759e451cf07
function secure_rand(min, max) {
var rval = 0;
var range = max - min;
if (range < 2) {
return min;
var bits_needed = Math.ceil(Math.log2(range));
if (bits_needed > 53) {
throw new Exception("We cannot generate numbers larger than 53 bits.");
paragonie-scott /
Created Feb 19, 2016 — forked from joepie91/
Remove Wired's "ad-blocker veil"


  • February 19, 2016: Initial release.


GitHub Gist doesn't send notifications when people leave a comment, so shoot me an e-mail at I'll gladly fix it. Fuck advertising.