dtool 0.7.0 发布了
关于 dtool
dtool is a command-line tool collection to assist development.
本次升级内容
- Add SM3 algorithm for hash module
- Add byte array / hex conversion
- Add ECDSA module
- Add SM4 symetric encryption module
示例
Subcommand | Desc | Example |
---|---|---|
hash | Hex to hashSM3v0.7.0 | $ dtool hash -a sm3 0x6162630x66c7f0f462eeedd9d1f2d46bdc10e4e24167c4875cf2f7a2297da02b8f\4ba8e0 |
h2a | Convert hex to byte arrayv0.7.0 | $ dtool h2a 0x61626364[97, 98, 99, 100] |
a2h | Convert byte array to hexv0.7.0 | $ dtool a2h '[97, 98, 99, 100]'0x61626364 |
ec_sign | Elliptic-curve signSecp256k1v0.7.0 | $ dtool ec_sign -c secp256k1 -s 0x9cb4f775e9b67118242cea1528\5555c287a7e3d2f86ba238c1fe87284b898e9a 0x6162630x7c77b65a27984b0e124a0ae2eec6bbf2b338a5c999b943abda576108f9\2e95364b0b983da055493c87fd138fe5673992b2a48ef85d9ad30c98fc1a\fcc5fc7bc0 |
sm4_enc | SM4 encryptCTRv0.6.0 | $ dtool sm4_enc -k 01010101010101010101010101010101 -i 03030\303030303030303030303030303 -m ctr 0x6162630x8cd7ea |
安装方式
$ cargo install dtool
or
$ brew install guoxbin/guoxbin/dtool
(Recommend brew which provides bash/zsh/fish shell completion)
建议和参与
https://github.com/guoxbin/dtool
完整特性列表
- Hex / UTF-8 string / binary / byte array conversion
- Timestamp / date conversion
- Number 10/2/8/16 base conversion
- Hex / base58 conversion
- Hex / base64 conversion
- URL encode / decode
- Number codec
- Hash (MD5, SHA-1, SHA-2, SHA-3, RIPEMD, CRC, Blake2b, SM3)
- UTF-8 string / unicode conversion
- HTML entity encode / decode
- Regex match
- Pbkdf2
- Case conversion (upper, lower, title, camel, pascal, snake, shouty snake, kebab)
- AES encrypt / decrypt
- ECDSA (Secp256k1, NIST P-256, NIST P384, SM2)
- SM4 encrypt / decrypt
1
共 0 条评论, 1 页
评论区
写评论还没有评论