python
文章平均质量分 79
yzt0000000
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
python3 sm3 编码器
import struct IV="7380166f 4914b2b9 172442d7 da8a0600 a96f30bc 163138aa e38dee4d b0fb0e4e" IV = int(IV.replace(" ", ""), 16) a = [] for i in range(0, 8): a.append(0) a[i] = (原创 2017-09-21 10:58:50 · 1899 阅读 · 0 评论 -
Python3 SM3 encoder
引用块内容 参考原始python 2 版本 http://co63oc.blog.51cto.com/904636/954086修改为python3 版本,主要区别是python2-3中struct.pack的返回值的类型不同,python3的返回为byte类型,python2为str 类型。import struct IV="7380166f 4914b2b9 172442d7 da原创 2017-09-21 11:16:36 · 2517 阅读 · 0 评论 -
PYTHON3 SHA256
python3 实现的SHA256 算法算法原型参考: https://en.wikipedia.org/wiki/SHA-2import structdef out_hex(list1): for i in list1: print ("%08x" % i) print ("\n") def rotate_left(a,原创 2017-09-21 11:28:09 · 6305 阅读 · 0 评论
分享