Argon2 is a password-hashing function created by by Alex Biryukov, Daniel Dinu, and Dmitry Khovratovich.

Argon2算法曾在2015 年的Password Hashing密码加密大赛中胜出。

Argon2官网:https://www.argon2.com/

------------------------------------------------------------------------

0x00 phc-winner-argon2的安装

git clone https://github.com/P-H-C/phc-winner-argon2
cd phc-winner-argon2
make

使用方法:

echo -n "CTF_110_911" | ./argon2  -d -t  -m  -p  -l 

0x01 argon2-cffi的安装

CFFI: C Foreign Function Interface for Python. Interact with almost any C code from Python, based on C-like declarations that you can often copy-paste from header files or documentation.

pip install argon2_cffi

请不要安装pip install argon2

argon2-cffi的github:https://github.com/hynek/argon2-cffi (由于总更新,不建议从此安装)

argon2-cffi文档:https://argon2-cffi.readthedocs.io/en/stable/

0x02 argon2-cffi的使用

# -*- coding:utf8 -*-
__author__='pcat@chamd5.org' from argon2 import PasswordHasher ph=PasswordHasher()
hash='$argon2d$v=19$m=32768,t=100,p=1$MTIzNDU2Nzg$iuSRO5tkWxBxqgkI5g9O5ZersA//xvgvrKxH8QuxBBI4yKbG4aRFqITP/Rh5giFRuL9PTJP+/0BUfNwZHzx9bQ'
pwd='CTF_110_911'
assert ph.verify(hash,pwd)==True

0x03 argon2的各个版本

  • Argon2d 最大限度地提高了对GPU破解攻击的抵抗力。它以密码相关的顺序访问存储器阵列,这降低了时间 - 存储器权衡(TMTO)攻击的可能性,但是引入了可能的侧面信道攻击。
  • Argon2i 优化了抵御侧向通道攻击的能力。它以密码无关的顺序访问内存阵列。
  • Argon2id 是一个混合版本。它遵循Argon2i方法进行第一次通过内存,Argon2d方法用于后续通过。Internet-Draft建议使用Argon2id,除非有理由选择其他两种模式之一。

phc-winner-argon2、argon2-cffi安装使用方法的更多相关文章

  1. 安装Birt方法

    安装BIRT 方法: 博客地址:http://www.mamicode.com/info-detail-850588.html 注意:在 Install new Software 中输入地址:http ...

  2. linux php安装扩展方法 查找配置文件

    如何在linux中查看nginx.apache.php.mysql配置文件路径了,如果你接收一个别人配置过的环境,但没留下相关文档.这时该怎么判断找到正确的加载文件路径了.可以通过以下来判断 1.判断 ...

  3. node安装插件方法

    node安装插件方法有几种,这里列出常用的两种方法: 方法1: 进入要安装插件的目录,直接用 npm 软件安装包安装,如(安装express): cd /project npm install -g ...

  4. windows server 2008见安装IIS方法(解决)

    windows server 2008见安装IIS方法(解决) 刚开始有点蒙,后来才知道原来如此.! . 右键点击[我的电脑]--[管理]--[字符]--[加入角色]--仅落后win7像.啊! 版权声 ...

  5. elasticsearch+kibana+metricbeat安装部署方法

    elasticsearch+kibana+metricbeat安装部署方法 本文是elasticsearch + kibana + metricbeat,没有涉及到logstash部分.通过beat收 ...

  6. RHEL6下获取安装包(RPM)而不安装的方法

    RHEL6下获取安装包(RPM)而不安装的方法 有时候我们只能在某个机器上网获得RPM安装包,如何将RPM包在不能上网的内网机器安装,就需要能将安装包下载到本地而不安装,然后再把这些包复制到内网机器, ...

  7. 哈希长度扩展攻击(Hash Length Extension Attack)利用工具hexpand安装使用方法

    去年我写了一篇哈希长度扩展攻击的简介以及HashPump安装使用方法,本来已经足够了,但HashPump还不是很完善的哈希长度扩展攻击,HashPump在使用的时候必须提供original_data, ...

  8. windows Sever 2012下Oracle 12c安装配置方法图文教程

    windows Sever 2012下Oracle 12c安装配置方法图文教程 Oracle 12c安装配置方法图文教程,具体内容如下 1.我们开启虚拟机 2.Windows Sever 2012启动 ...

  9. 安装rcssmin方法

    #安装rcssmin方法'''pip install wheelpip install rcssmin --install-option="--without-c-extensions&qu ...

  10. myeclipse安装svn方法汇总

    myeclipse安装svn方法汇总 博客分类: eclipse   MyEclipse6.5安装SVN插件,掌握了几种方法,本节就像大家介绍一下MyEclipse6.5安装SVN插件的三种方法,看完 ...

随机推荐

  1. Linux中强大的top命令

    top命令算是最直观.好用的查看服务器负载的命令了.它实时动态刷新显示服务器状态信息,且可以通过交互式命令自定义显示内容,非常强大. 在终端中输入top,回车后会显示如下内容:   top - 21: ...

  2. Publish site through visual studio

    https://www.c-sharpcorner.com/UploadFile/4b0136/getting-started-with-iis-host-and-publish-in-mvc-5/ ...

  3. PHP使用MongoDB存储经纬度,查询距离

    https://blog.csdn.net/qq_40012295/article/details/84861466 https://docs.mongodb.com/manual/reference ...

  4. SQL-W3School-函数:SQL 函数

    ylbtech-SQL-W3School-函数:SQL 函数 1.返回顶部 1. SQL 拥有很多可用于计数和计算的内建函数. 函数的语法 内建 SQL 函数的语法是: SELECT function ...

  5. python mysql使用问题

    (deeplearning2) userdeMBP:ageAndGender user$ python Python |Anaconda, Inc.| ( , ::) [GCC Compatible ...

  6. vue+php接口

    php: <?php header('Access-Control-Allow-Origin:*'); $date = $_POST['data'];$cars=array("Volv ...

  7. webpack概述——资源、样式、图片的打包工具

    官方地址:https://www.webpackjs.com/ Concepts At its core, webpack is a static module bundler for modern ...

  8. div和span显示在同一行

    div和span标签的区别 div  是块级元素标签,独占一行,后面跟的内容换行显示 span  是内联元素标签,后面可以跟其他显示内容,不独占一行 display属性可以改变内联元素和块级元素的状态 ...

  9. Java使用MyBatis的ScriptRunner执行SQL脚本

    脚本文件D:/test_transaction.sql: start transaction; drop table if exists testdb.test_transaction_table; ...

  10. c#操作json数据使用newtonsoft.json

    开源项目提供的一个读取示例 using System; using System.Collections.Generic; using System.IO; using System.Linq; us ...