Weedy writes:
> $ openssl dgst -sha256 ubcd535.iso | awk '/^SHA256/ {
> gsub(/^SHA256\(/,"",$1); gsub(/\)\=/,"",$1); print $2" "$1 }'
Or sed -E 's/.*\((.*)\)= (.*)/\2 \1/'
--
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
$ openssl dgst -sha256 ubcd535.iso | awk '/^SHA256/ {
gsub(/^SHA256\(/,"",$1); gsub(/\)\=/,"",$1); print $2" "$1 }'
f4ad684385845a0dfcd944dc6b6a0aa00886a05a7143efafa8403e01fea49849 ubcd535.iso
$ sha256sum ubcd535.iso
f4ad684385845a0dfcd944dc6b6a0aa00886a05a7143efafa8403e01fea49849 ubcd535.iso
OK, thanks. I build off a local branch either way, with regular rebasing. Easier for me to replace the code :)
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
On 22/03/2016 08:51, Bastian Bittorf wrote:
> * Stijn Segers [22.03.2016 08:47]:
>> Is there a specific reason why OpenSSL is used instead of sha256sum?
>
> it's all about portability. OpenSSL is widely available, and sha256 not.
> maybe you can 'sanitize'
* Stijn Segers [22.03.2016 08:47]:
> Is there a specific reason why OpenSSL is used instead of sha256sum?
it's all about portability. OpenSSL is widely available, and sha256 not.
maybe you can 'sanitize' the output somehow?
bye, bastian
Hi guys,
I have a nice script on my routers that pulls in a new firmware image,
validates the checksum, then flashes it. I switched it to
sha256 (from md5), noticed the format in the sha256sums was different,
but didn't pay it too much mind - except that now, the busybox
sha256sum function