Code Monkey home page Code Monkey logo

panel's Introduction

panel's People

Contributors

1049731887 avatar

Stargazers

 avatar

Watchers

 avatar

panel's Issues

zerotier显示

联通了zerotier就顶部显示zerotier on(绿)
(此时可以跳转et和al页面)

token必须aes

本篇将对 AES 算法在浏览器端的 JavaScript 语言中应用做实战讲解,为什么要强调是浏览器端?因为后面还会对 Node 环境下 AES 算法应用单独做个实战演示,如果你是在 Node 环境中使用的,请移步。

因为 JavaScript 标准库对 AES 算法支持有限,这里会第三方库 https://github.com/brix/crypto-js 做讲解(后面简称 CryptoJS),也推荐在正式环境中使用。由于篇幅限制,所有的演示代码将只展示关键步骤。

首先要在你的页面里引入 CryptoJS :

<script type="text/javascript" src="path-to/bower_components/crypto-js/crypto-js.js"></script>

CryptoJS AES 算法使用的接口非常简单,就如下两个加密/解密两个方法:

// plainData 表示待加密数据
let encrypted = CryptoJS.AES.encrypt(plainData);

// cryptoData 表示待解密数据
let decrypted = CryptoJS.AES.decrypt(cryptoData);
咦?怎么没有我们之前叨叨了半天的密钥

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.