Re:New ransomware written in JavaScript discovered
by colejohnson66 on Monday June 20, 2016 @03:21AM
(#11936583)
It has read and execute. However, the JS file is not _executed_; it's _read_ by the interpreter. So an executable bit wouldn't matter as the file could still be read by any interpreter.
[ Parent
| on HN ]
Re:New ransomware written in JavaScript discovered
by ThisIs_MyName on Monday June 20, 2016 @05:18AM
(#11936963)
The guy you're replying to is probably used to linux where you can interpret a script the same way you run an executable: http://lxr.free-electrons.com/source/fs/binfmt_script.c
You can even add your own executable formats to do stuff like running Java class files by typing `./main.class`: https://www.kernel.org/doc/Documentation/binfmt_misc.txt
Re:New ransomware written in JavaScript discovered
by vertex-four on Monday June 20, 2016 @05:44AM
(#11937047)
Of course, you can run "<interpreter> <file>" anyway and it works, +x or no +x.
Re:New ransomware written in JavaScript discovered
by makomk on Monday June 20, 2016 @05:55AM
(#11937081)
You can do, but because Linux has a mechanism for launching the correct interpreter which honours the +x bit it's unusual for anything to do this automatically, whereas on Windows associating interpreters with scripting formats is exactly the same as associating editors with document formats.
Re:New ransomware written in JavaScript discovered
by Arnavion on Monday June 20, 2016 @11:26AM
(#11938612)
Amusingly this was changed with PowerShell in that .ps1 files do not have powershell.exe registered to run them when double-clicked. As a result people complain about it and resort to writing a .bat wrapper around the script.