JWT & HMAC-SHA256
2024-08-31 00:48:23
JWT
JSON Web Tokens
https://en.wikipedia.org/wiki/JSON_Web_Token#Structure
HMACSHA256
https://en.wikipedia.org/wiki/HMAC
keyed-hash message authentication code or hash-based message authentication code
密钥哈希消息认证码或基于哈希的消息认证码
https://www.freeformatter.com/hmac-generator.html
http://convertstring.com/Hash/SHA256
HMAC-SHA256(key, data) & SHA256(key + data)
https://stackoverflow.com/questions/11415055/how-to-use-hmac-sha256
Javascript HMAC SHA256
<script src="https://cdnjs.cloudflare.com/ajax/libs/crypto-js/3.1.9-1/crypto-js.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/crypto-js/3.1.9-1/hmac-sha256.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/crypto-js/3.1.9-1/enc-base64.min.js"></script>
<script>
var hash = CryptoJS.HmacSHA256("Message", "secret");
var hashInBase64 = CryptoJS.enc.Base64.stringify(hash);
document.write(hashInBase64);
</script>
最新文章
- [XAF] How to hide individual navigation items and groups for certain users
- windows下安装使用Composer记录
- js实现页面的自动读秒跳转
- MySQL基础 - mysql命令行客户端
- Linux安装Weblogic9.2
- 正式学习 React(三)番外篇 reactjs性能优化之shouldComponentUpdate
- isHiden和isVisible的区别(isVisible更可靠)
- JAVA随笔篇一(Timer源代码分析和scheduleAtFixedRate的使用)
- java jdbc操作数据库通用代码
- jmeter的几种参数化使用方法
- 使用Three.js挖空安装门来解决重叠闪烁的问题
- js跨域交互之jsonp - 看完就能让你了解jsonp原理 (原)
- 深度解读 AlphaGo 算法原理
- 串口.Qt532测试(同步)
- freeswitch笔记
- HDFS高级功能
- Python 学习第二章
- VPC见解
- pycharm pro版本激活
- list_01
热门文章
- bzoj 1034: [ZJOI2008]泡泡堂BNB【贪心】
- BZOJ4543/BZOJ3522 [POI2014]Hotel加强版(长链剖分)
- eccharts-gl 3D立体柱状图
- 【杂文】5亿大质数表(5e8)
- hdu 模拟 贪心 4550
- java dom4j xml生成,解析
- 如何在Ubuntu上安装Wine 2.6
- 贪心 Codeforces Round #135 (Div. 2) C. Color Stripe
- 题解报告:hdu 5695 Gym Class(拓扑排序)
- ACM_校庆素数