logoalt Hacker News

0xbadcafebeeyesterday at 3:10 AM1 replyview on HN

   t=$(mktemp) && [ -w $t ] && curl foo.sh -o $t && echo "$t lksjdfkljshdkfljhdsklfjhslkdjfhsdlkjfhslkdjhf" | sha256sum -c - && bash $t
Uses standard tmp files, makes sure it's writable (tmp file creation can fail), checks cryptographic hash before executing

Replies

godelskiyesterday at 4:49 AM

Sure, but now we're not playing code golf. There's much better commands than the ones I wrote but good luck getting people to run them

show 1 reply