Skip to content

Instantly share code, notes, and snippets.

@lamorbidamacchina
Created October 28, 2019 15:35
Show Gist options
  • Save lamorbidamacchina/d8589cccdc1893f2a47e9e25adea7d0a to your computer and use it in GitHub Desktop.
Save lamorbidamacchina/d8589cccdc1893f2a47e9e25adea7d0a to your computer and use it in GitHub Desktop.
<?php
// Generating your encryption key
$private_key = random_bytes(SODIUM_CRYPTO_SECRETBOX_KEYBYTES);
// Generating your blind index key
$index_key = random_bytes(SODIUM_CRYPTO_PWHASH_SALTBYTES);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment