GithubHelp home page GithubHelp logo

laravel-z5encrypt's Introduction

Z5加密 - Laravel拓展包

Z5加密官方地址:https://z5encrypt.com/,使用本拓展包可以在laravel中直接调用Z5加密的API进行加密PHP文件!

安装

$ composer require zhouzishu/laravel-z5encrypt

添加服务提供者(if laravel < 5.5)

// laravel < 5.5
Zhouzishu\LaravelZ5Encrypt\ServiceProvider::class,

### 添加 alias(optional. if laravel < 5.5)

```PHP
'Z5Encrypt' => Zhouzishu\LaravelZ5Encrypt\Facades\Z5Encrypt::class,

配置API

$ php artisan vendor:publish --provider="Zhouzishu\LaravelZ5Encrypt\ServiceProvider"

.env 文件里面配置

Z5ENCRYPT_SECRET=
Z5ENCRYPT_TOKEN=

使用

$content = '<?php function a () { echo "Hello World"; } a();';
$file_name = 'hello.php';
$ret = \Z5Encrypt::encryptFile($content, $file_name);

dd($ret->data); // 加密后的文件内容,可以通过Storage存储到本地及云端

laravel-z5encrypt's People

Contributors

zhouzishu avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.