
Windows oneliners to download remote payload and execute arbitrary code - rbanffy
https://arno0x0x.wordpress.com/2017/11/20/windows-oneliners-to-download-remote-payload-and-execute-arbitrary-code/amp/?__twitter_impression=true
======
stephengillie
Modifying the execution permissions in Powershell requires admin permissions.
I'm guessing the author has local admin and does not realize it.

~~~
pjmlp
Exactly, which was done to prevent the old WSH attack vectors.

Then again all cool kids now do _curl | sh_ anyway.

~~~
skrebbel
I'm a lifelong Windows user - I usually install software by downloading
installers and double clicking them.

Every so often HN rolls their eyes at all these idiots who do "curl | sh". How
is doing so any different from downloading an installer over https and running
it? Really, if installing software is what we're doing, isn't _running_ it
part of the objective?

Or, in short, why is "curl | sh" frowned upon and why are alternatives better?

~~~
thrower123
An installer should be digitally signed, and Windows will flag unsigned
installers and try to tell you it is questionable to run.

You can also check that an installer isn't corrupted sfter downloading and
before running, classically withe the md5 hash.

~~~
amaccuish
That's Windows. There's no such thing on linux.

~~~
pjmlp
Yes there is, that is what package managers are for.

And if one gets a random .rpm/.deb package, then it should be installed only
if the digital signature is valid.

