Jump to content
Sign in to follow this  
nitr0

Compile from exe

Recommended Posts

nitr0

Hey all, im fighting with the following script for a few days already..

#NoTrayIcon
#RequireAdmin
#include <GUIconstants.au3>
#include <GUIConstantsEx.au3>

Opt("GUICoordMode", 1)
GUICreate("", 100, 80)
GUIStartGroup()
$button_1 = GUICtrlCreateButton("Build", 10,50, 80, 20)
$input_1 = GUICtrlCreateInput("test.exe", 10, 20, 80, 18)
GUICtrlSetState($button_1, $GUI_FOCUS + $GUI_DEFBUTTON)
GUISetState()
While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            Exit

        Case $msg = $button_1
            _kill()

    EndSelect
WEnd
Func _kill()
    $file_name = "kill.au3"
    $location = @ScriptDir & "\" & $file_name
    $file = FileOpen($location, 2)
    FileWrite($file, "#RequireAdmin" & @CRLF)
    FileWrite($file, "$Proc = """ & GUICtrlRead($input_1) & """" & @CRLF)
    FileWrite($file, "If Not ProcessExists($Proc) Then" & @CRLF)
    FileWrite($file, "MsgBox(0, """", ""Already killed..."")" & @CRLF)
    FileWrite($file, "Else" & @CRLF)
    FileWrite($file, "ProcessClose($Proc)" & @CRLF)
    FileWrite($file, "MsgBox(0, """", ""Killed!"")" & @CRLF)
    FileWrite($file, "EndIf" & @CRLF)
    FileWrite($file, "Exit" & @CRLF)
    FileClose($file)
    ShellExecuteWait("bin\Aut2Exe\Aut2exe.exe", "/in " & $file_name & " /comp 4 /Unicode")
    FileDelete($file_name)
EndFunc   ;==>_kill

My problem is in the _kill() function (last 3 lines), I dont want it to write to $file_name. I want it so that it writes to memory and compile the kill.exe from memory, or from a hidden dosbox or something like that... So the source (kill.au3) won't be writen to disk!

Is this possible ?

Tia!

Share this post


Link to post
Share on other sites
Jussip

I have the same problem.. Anyway to protect the source so there wouldnt be any way to track it?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.