首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >终端中的Argon2命令

终端中的Argon2命令
EN

Unix & Linux用户
提问于 2020-03-24 16:33:56
回答 1查看 3K关注 0票数 2

我一直在我的终端(Debian)中使用Argon2,但我一直在搞砸,也找不到列出命令示例的手册或任何其他文档。

有人能给我一个最重要的命令的基本概述吗?还是指给我一个好的推荐信?

我的用法就在我面前,但这对我没有多大帮助。

代码语言:javascript
复制
Usage:  argon2 [-h] salt [-i|-d|-id] [-t iterations] [-m log2(memory in KiB) | -k memory in KiB] [-p parallelism] [-l hash length] [-e|-r] [-v (10|13)]
    Password is read from stdin
Parameters:
    salt        The salt to use, at least 8 characters
    -i      Use Argon2i (this is the default)
    -d      Use Argon2d instead of Argon2i
    -id     Use Argon2id instead of Argon2i
    -t N        Sets the number of iterations to N (default = 3)
    -m N        Sets the memory usage of 2^N KiB (default 12)
    -k N        Sets the memory usage of N KiB (default 4096)
    -p N        Sets parallelism to N threads (default 1)
    -l N        Sets hash output length to N bytes (default 32)
    -e      Output only encoded hash
    -r      Output only the raw bytes of the hash
    -v (10|13)  Argon2 version (defaults to the most recent version, currently 13)
    -h      Print argon2 usage
EN

回答 1

Unix & Linux用户

回答已采纳

发布于 2020-04-20 18:30:02

你可以跑:

代码语言:javascript
复制
echo -n "hashThis" | argon2 saltItWithSalt -l 32

这将为您提供一个输出,类似于多行关于结果哈希的信息。

要获得编码为单个argon2字符串的相同信息的一行返回,可以在末尾添加-e。如果您只想要原始字节,请使用-r而不是-e

票数 2
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/574667

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档