Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I doubt it, and part of me hopes not. This seems like a new possible vector for malware.

Microsoft went to great lengths to disallow these kind of one-liners in PowerShell (you need to explicitly add -executionpolicy bypass to even run a script), so apparently they are concerned about users executing random scripts off the net.

OTOH, yes, being able to assume bash on a user's installation would be amazing of course...



> Microsoft went to great lengths to disallow these kind of one-liners in PowerShell (you need to explicitly add -executionpolicy bypass to even run a script), so apparently they are concerned about users executing random scripts off the net.

Yes and I fucking hate it, way to cut of useful functionality at the knees.


A lot of my PowerShell scripts are accompanied by shortcuts or batch files that do:

    powershell.exe -ExecutionPolicy RemoteSigned -File whatever.ps1




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: