承接 tzsk/crypton 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

tzsk/crypton

最新稳定版本:4.0.1

Composer 安装命令:

composer require tzsk/crypton

包简介

Laravel API Request Response Encryption

README 文档

README

Crypton Cover Image

GitHub License Latest Version on Packagist GitHub Tests Action Status Total Downloads

TThis is a simple package for laravel to encrypt decrypt api request & response in both ends, Backend & Javascript.

📦 Installation

Via Composer

$ composer require tzsk/crypton

Publish config file

$ php artisan crypton:publish

Add an environment variable in the .env file

CRYPTON_KEY=your-encryption-key

👀 Keep in Mind

TIP: You can easily generate an encryption key by running php artisan key:generate then copy the generated key. Then again run: php artisan key:generate to make the key used by crypton and the default application key different.

WARNING: DO NOT USE THE SAME APP_KEY AND CRYPTON_KEY

🔥 Usage

Start off by adding a Middleware in the app/Http/Kernel.php file.

$routeMiddleware = [
    'crypton' => \Tzsk\Crypton\Middleware\EncryptRequestResponse::class,
];

Now, add this middleware to any api routes or groups.

Example:

Route::middleware('crypton')->post('some-endpoint', function(Request $request) {
    return Post::paginate($request->per_page ? : 10);
});

That's it.

😍 Javascript adapter

See Laravel Crypton

🔬 Testing

composer test

📅 Changelog

Please see CHANGELOG for more information on what has changed recently.

👑 Contributing

Please see CONTRIBUTING for details.

🔒 Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

❤️ Credits

👮‍♂️ License

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

统计信息

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

GitHub 信息

  • Stars: 41
  • Watchers: 2
  • Forks: 9
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-01-22

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固