PHP OpenSSL 工具包
This commit is contained in:
parent
c5e7c84dea
commit
068bb79363
@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "chenc/php-openssl-cryptor",
|
||||
"name": "aix/php-openssl-cryptor",
|
||||
"description": "creating/encrypting/decrypting for php open_ssl library",
|
||||
"type": "library",
|
||||
"license": "MIT",
|
||||
@ -11,7 +11,7 @@
|
||||
],
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Chenc\\PhpOpensslCryptor\\": "src/"
|
||||
"Aix\\PhpOpensslCryptor\\": "src/"
|
||||
}
|
||||
},
|
||||
"require": {
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Chenc\PhpOpensslCryptor;
|
||||
namespace Aix\PhpOpensslCryptor;
|
||||
|
||||
class Cryptor
|
||||
{
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Chenc\PhpOpensslCryptor;
|
||||
namespace Aix\PhpOpensslCryptor;
|
||||
/**
|
||||
* Sm4加密解密类
|
||||
* Class Sm4Helper
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
require_once 'vendor/autoload.php';
|
||||
|
||||
use Chenc\PhpOpensslCryptor\Cryptor;
|
||||
use Aix\PhpOpensslCryptor\Cryptor;
|
||||
$x = new Cryptor('aes-256-ctr','sha256',Cryptor::FORMAT_B64);
|
||||
//$x->createCert('123456',true);
|
||||
var_dump($x->encryptString('123456','0987654321'));
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user