3 ms·
I don't think running something like /usr/local/bin/notpython ~/Downloads/legit.file will load libraries or execute code in ~/Downloads That seems somethi
by kgwgk 6y ago
I don't think running something like
/usr/local/bin/notpython ~/Downloads/legit.file
will load libraries or execute code in ~/Downloads
That seems something specific to python/jupyter
- quietbritishjim 6y agoBut maybe it's more analogous to ask about running ~/Downloads/legit_program (or maybe ...\Downloads\legit_installer.exe). As I said in my sibling comment, this is safe on Linux (if legit_program really is safe) but they're right that on Windows it's dangerous because the program will pick up zlib.dll etc. in the downloads directory. Maybe this is part of the reason for .msi installers: they end up running the MSI installer executable, which is located in some system directory instead.
- kgwgk 6y agoSure, running executables in random places may be risky. But with python it’s not just the location of the binary program that matters and running scripts or notebooks stored in random places may also be risky.
- masklinn 6y agoComments up thread note that lua will do the exact same thing, Perl used to do it as well (now changed). Ruby apparently does not though (the internet shows many asking how to do it). Good for them.
- kgwgk 6y agoWell, I didn't literally expect it to be unique to python :-)