nl_tokens: Encode a message
pl_tokens: function ( senderPriv , recipientPub , msg ) { // Errors if ( ! senderPriv || ! recipientPub || ! msg ) throw <mask> Error ( 'Missing argument !' ) ; //if (!Helpers.isPrivateKeyValid(senderPriv)) throw new Error('Private key is not valid !'); //if (!Helpers.isPublicKeyValid(recipientPub)) throw new Error('Public key is not valid !'); // Processing let iv = nacl . randomBytes ( 16 ) //console.log("IV:", convert.uint8ToHex(iv)); let salt = nacl . randomBytes ( 32 ) let encoded = _encode ( senderPriv , recipientPub , msg , iv , salt ) ; // Result return encoded ; }