通过fxxd -p传递的openssl sha256二进制摘要通过多行输出

问题描述

我使用此命令为我提供openssl的输出,而不以(stdin)=开头。

openssl x509 -noout -modulus -in certfile.crt | openssl sha1 -binary | xxd -p

有输出

7857b35259019acc7484201958ac7e622c227b68

如果我更改openssl以创建sha256摘要,则xxd将其打印在两行上

openssl x509 -noout -modulus -in certfile.crt | openssl sha256 -binary | xxd -p

有输出

b274c19ac31cc7893dc2297804a2ca666fe168d5cd5eb4d4b6c47616bad9
8996

如何在第一行中写出该输出?

b274c19ac31cc7893dc2297804a2ca666fe168d5cd5eb4d4b6c47616bad98996

既然摘要更长,我是否还需要处理xxd?还是需要通过其他命令通过管道传递以获得合并的输出?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)