Are they the same?
Longer version :
Say I wrote, in assembly, on a windows machine, a small app that all it does is add 1+1 and stores it in a register. THEN, I write the exact same code on a Linux machine. Would it work?
Im thinking yes, because at the hardware level, its the same machine, so the ‘language of the hardware’ (forgive the inexactness) would be the same.
So Im thinking a virus targeting windows but written in assembly wouldnt just be a windows virus.
programs written in assembler on windows are not binary compatible with linux… you need to compile(assemble) them again on linux, but keep in mind that there are differences between assemblers.. they differently handle for example parts for declaring code, data, bss
windoes execs don’t run natively on linux (you can run them in wine, but they are gonna be sandboxed)