dobin / SuperMega

Stealthily inject shellcode into an executable
GNU General Public License v3.0
55 stars 7 forks source link

Exception: Command failed: ml64.exe #1

Open k3lpi3b4nsh33 opened 2 months ago

k3lpi3b4nsh33 commented 2 months ago

Hello, I have this problem on my computer environment, what causes it and how to fix it

raise Exception("Command failed: " + " ".join(args))
Exception: Command failed: ml64.exe projects/BC/main.asm /link /OUT:projects/BC/main.exe /entry:AlignRSP

image

dobin commented 2 months ago

This seem to be like a syntax error in the generated ASM text. Did you modify the source C template files? There seems to be an issue with the symbol __aullshr which i dont know.

Also it seems to be unable to find __imp__VirtualProtect.

Did you use the standard preselected options, if not which one? (e.g. which kind of injection).

k3lpi3b4nsh33 commented 2 months ago
  1. I only modified lines 86 and 87 in the helper.py file by adding error=ignore because sometimes there is an error when decoding base64.
  2. I tried various combinations of exe and bin files in the template, but the same error still occurred.

image

image

image

k3lpi3b4nsh33 commented 2 months ago
  1. I only modified lines 86 and 87 in the helper.py file by adding error=ignore because sometimes there is an error when decoding base64.
  2. I tried various combinations of exe and bin files in the template, but the same error still occurred.

image

image

image

Even though I changed Visual Studio to the English version and removed the ignore from Helper.py, the same error still occurred.

image

dobin commented 2 months ago

Ah sorry. The createfile.bin shellcode is used for testing, which is broken atm. Take literally any other shellcode, and it should work. I recommend messagebox.bin.

dobin commented 2 months ago

Anyway, i cant reproduce really, all works for me on two machines.

If the error persists, click "Build" so the error appears again, and attach a .zip of the complete SuperMega/ folder here.

image

marius-pop0 commented 5 days ago

I can reproduce the OP error on my side when running the application from Powershell directly with all the environment variables set appropriately.

I ran the application from Developer Command Prompt for VS 2022 and this error went away. I would suggest to ensuring you are running from the developer command prompt.

dobin commented 5 days ago

Thanks for the info. Making Visual Studio tools usable outside VS is a bit a pain.