paragonie / halite-legacy
Legacy implementations of Halite (can be loaded alongside Halite to facilitate migrations)
Requires
- php: ^7
- paragonie/halite: ^4.5
- paragonie/sodium_compat: ^1.9
Requires (Dev)
- phpunit/phpunit: ^5|^6|^7
- vimeo/psalm: ^0|^1|^2|^3
This package is auto-updated.
Last update: 2024-12-19 11:02:12 UTC
README
See Halite for documentation, etc.
This library allows you to side-load an unsupported legacy version of Halite into your application in order to migrate data to the newest version.
Important
This library is out of scope for any bug bounty programs!
Please refer to Halite for a library that is in-scope.
Installing
Use Composer.
composer require paragonie/halite-legacy
Migrating Code
Simply use the legacy classes to facilitate decryption, and re-encrypt with the latest version of Halite.
<?php use ParagonIE\Halite\Symmetric\{ Crypto, EncryptionKey }; use ParagonIE\HaliteLegacy\V3\Symmetric\{ Crypto as LegacyCrypto, EncryptionKey as LegacyKey }; use ParagonIE\HaliteLegacy\V3\HiddenString as LegacyHiddenString; use ParagonIE\HiddenString\HiddenString; /** * @var EncryptionKey $encKey * @var LegacyKey $oldKey * @var string $ciphertext * @var LegacyHiddenString $plaintext */ $plaintext = LegacyCrypto::decrypt($ciphertext, $oldKey); $storeMe = Crypto::encrypt( new HiddenString($plaintext->getString()), $encKey );
Support Contracts
If your company uses this library in their products or services, you may be interested in purchasing a support contract from Paragon Initiative Enterprises.
Unpaid support will not be provided for halite-legacy
.