TL;DR, make this part of PHP 7.1:

   $cipher = new Php\Crypto\Symmetric([
        'driver' => 'openssl'
    ]);
    $key = $cipher->deriveKey(
        $someUserProvidedPasswordString,
       $someHardCodedSalt
    );
    $encrypted = $cipher->encrypt($message, $key);

I'm developing a userland prototype in PHP here, so hopefully anyone
can join in even if you're not fluent in C:
https://github.com/paragonie/pco_prototype

Once we're happy with how the API functions, and what the
default/allowed parameters will be for each driver, we can start
writing the PHP extension and move forward with the RFC to merge it.

Here's an overview of the project:

* The API (what we're discussing)
* The drivers (we don't develop these)
    * Libsodium
    * OpenSSL
    * Room to grow in case we need to adopt for a post-quantum
cryptography library

Scott Arciszewski
Chief Development Officer
Paragon Initiative Enterprises <https://paragonie.com>

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to