定制 orz14/crypt-php 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

orz14/crypt-php

最新稳定版本:v1.0.0

Composer 安装命令:

composer require orz14/crypt-php

包简介

Simple AES-256-CBC encryption and decryption class for PHP.

README 文档

README

Simple AES-256-CBC encryption and decryption class for PHP.

Installation

You can install the package via Composer.

composer require orz14/crypt-php

Usage

Make sure the CROSS_ENCRYPTION_KEY environment variable is set and contains a base64-encoded key (32 bytes before encoding).

# generate key example
php -r "echo base64_encode(random_bytes(32)) . PHP_EOL;"
use Orz14\Crypt;

// Encryption
$cipher = Crypt::encrypt('hello world');
echo $cipher; // D5kvEf5S4MAKdLNcTbZdWkMGmI34vQt+LOdP4iU7C+w=

// Decryption
$plain = Crypt::decrypt($cipher);
echo $plain; // hello world

Changelog

Please see the GitHub "Releases" page for more information on what has changed recently.

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 11
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-10-06