Pure Python Data Mangling or Encrypting

Grant Edwards invalid at invalid.invalid
Wed Jun 24 14:23:17 EDT 2015


On 2015-06-24, Chris Angelico <rosuav at gmail.com> wrote:
> On Thu, Jun 25, 2015 at 2:16 AM, Grant Edwards <invalid at invalid.invalid> wrote:
>> On 2015-06-24, Emile van Sebille <emile at fenx.com> wrote:
>>
>>> Mangling would at least prevent it from executing.
>>
>> If you don't want a file to be executed, then don't make it
>> executable.  Or doesn't Windows have any way to control whether a
>> file is executable or not?
>
> Windows doesn't have the Unix file system concept of execute
> permission, no. If a file has the .exe extension and the first 512
> bytes look like an appropriate header (MZ etc), Windows will happily
> run it. With other extensions, similarly - just create a .bat file
> and double-click it, it'll run the commands.

So can prevent execution, just by changing the filename?  Maybe 30
years using Unix has biased me, but that just seems so wrong...

-- 
Grant Edwards               grant.b.edwards        Yow! Here I am in the
                                  at               POSTERIOR OLFACTORY LOBULE
                              gmail.com            but I don't see CARL SAGAN
                                                   anywhere!!



More information about the Python-list mailing list