mirror of
https://github.com/Obfuscator-Collections/VMProtect.git
synced 2025-08-02 12:10:11 +03:00
first commit
Version 3.x.x
This commit is contained in:
31
examples/scripts/Delphi Resources/Project1.exe.vmp
Normal file
31
examples/scripts/Delphi Resources/Project1.exe.vmp
Normal file
@@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<Document>
|
||||
<Protection InputFileName="Project1.exe" Options="32768" RunParameters="">
|
||||
<Folders />
|
||||
<Procedures>
|
||||
<Procedure MapAddress='VMProtectMarker "Test marker"' Options="1" />
|
||||
<Procedure MapAddress='string "Correct password"' Options="1" />
|
||||
<Procedure MapAddress='string "Incorrect password"' Options="1" />
|
||||
</Procedures>
|
||||
<Messages />
|
||||
</Protection>
|
||||
<DLLBox />
|
||||
<Script>
|
||||
<![CDATA[function OnBeforeSaveFile()
|
||||
local file = vmprotect:core():outputArchitecture()
|
||||
local rc_data = file:resources():itemByType(PE.RT_RCDATA)
|
||||
if (rc_data) then
|
||||
local names = {}
|
||||
table.insert(names, "PACKAGEINFO")
|
||||
table.insert(names, "DVCLAL")
|
||||
for _, line in ipairs(names) do
|
||||
local resource = rc_data:itemByName(line)
|
||||
if (resource) then
|
||||
print(string.format("Resource \"%s\" is deleted", line))
|
||||
resource:destroy()
|
||||
end
|
||||
end
|
||||
end
|
||||
end]]>
|
||||
</Script>
|
||||
</Document>
|
20
examples/scripts/Environment Variables/Project1.exe.vmp
Normal file
20
examples/scripts/Environment Variables/Project1.exe.vmp
Normal file
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<Document Version="2">
|
||||
<Protection InputFileName="Project1.exe" Options="819200" RunParameters="" OutputFileName="%MYVAR%.exe">
|
||||
<Folders />
|
||||
<Procedures>
|
||||
<Procedure MapAddress='VMProtectMarker "Test marker"' Options="1" />
|
||||
<Procedure MapAddress='string "Correct password"' Options="1" />
|
||||
<Procedure MapAddress='string "Incorrect password"' Options="1" />
|
||||
</Procedures>
|
||||
<Messages />
|
||||
<Objects />
|
||||
</Protection>
|
||||
<DLLBox>
|
||||
<Folders />
|
||||
</DLLBox>
|
||||
<Script>
|
||||
<![CDATA[vmprotect.setEnvironmentVariable("MYVAR", "output")]]>
|
||||
</Script>
|
||||
<LicenseManager />
|
||||
</Document>
|
26
examples/scripts/External DLL/Project1.exe.vmp
Normal file
26
examples/scripts/External DLL/Project1.exe.vmp
Normal file
@@ -0,0 +1,26 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<Document>
|
||||
<Protection InputFileName="Project1.exe" Options="32768" RunParameters="">
|
||||
<Folders />
|
||||
<Procedures>
|
||||
<Procedure MapAddress='VMProtectMarker "Test marker"' Options="1" />
|
||||
<Procedure MapAddress='string "Correct password"' Options="1" />
|
||||
<Procedure MapAddress='string "Incorrect password"' Options="1" />
|
||||
</Procedures>
|
||||
<Messages />
|
||||
</Protection>
|
||||
<DLLBox />
|
||||
<Script>
|
||||
<![CDATA[function OnBeforeCompilation()
|
||||
MessageBox(0, 'OnBeforeCompilation', 'MessageBox from user32.dll', 0x40)
|
||||
end
|
||||
|
||||
function OnAfterCompilation()
|
||||
MessageBox(0, 'OnAfterCompilation', 'MessageBox from user32.dll', 0x40)
|
||||
end
|
||||
|
||||
user32 = vmprotect.openLib('user32.dll')
|
||||
MessageBox = user32:getFunction('MessageBoxA', {ret = 'int', 'size_t', 'string', 'string', 'uint'})]]>
|
||||
</Script>
|
||||
<LicenseManager />
|
||||
</Document>
|
32
examples/scripts/Random Section Names/Project1.exe.vmp
Normal file
32
examples/scripts/Random Section Names/Project1.exe.vmp
Normal file
@@ -0,0 +1,32 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<Document>
|
||||
<Protection InputFileName="Project1.exe" Options="32768" RunParameters="">
|
||||
<Folders />
|
||||
<Procedures>
|
||||
<Procedure MapAddress='VMProtectMarker "Test marker"' Options="1" />
|
||||
<Procedure MapAddress='string "Correct password"' Options="1" />
|
||||
<Procedure MapAddress='string "Incorrect password"' Options="1" />
|
||||
</Procedures>
|
||||
<Messages />
|
||||
</Protection>
|
||||
<DLLBox />
|
||||
<Script>
|
||||
<![CDATA[function GetRandomSectionName()
|
||||
local res = ""
|
||||
for i = 1, 8 do
|
||||
res = res .. string.char(32 + math.random(string.byte("z") - 32))
|
||||
end
|
||||
return res
|
||||
end
|
||||
|
||||
function OnAfterSaveFile()
|
||||
local file = vmprotect.core():outputArchitecture()
|
||||
for i = 1, file:segments():count() do
|
||||
segment = file:segments():item(i)
|
||||
name = GetRandomSectionName()
|
||||
print(string.format("Section \"%s\" is renamed to \"%s\"", segment:name(), name))
|
||||
segment:setName(name)
|
||||
end
|
||||
end]]>
|
||||
</Script>
|
||||
</Document>
|
26
examples/scripts/Script Events/Project1.exe.vmp
Normal file
26
examples/scripts/Script Events/Project1.exe.vmp
Normal file
@@ -0,0 +1,26 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<Document>
|
||||
<Protection InputFileName="Project1.exe" Options="32768" RunParameters="">
|
||||
<Folders />
|
||||
<Procedures>
|
||||
<Procedure MapAddress='VMProtectMarker "Test marker"' Options="1" />
|
||||
<Procedure MapAddress='string "Correct password"' Options="1" />
|
||||
<Procedure MapAddress='string "Incorrect password"' Options="1" />
|
||||
</Procedures>
|
||||
<Messages />
|
||||
</Protection>
|
||||
<DLLBox />
|
||||
<Script>
|
||||
<![CDATA[function OnBeforeCompilation()
|
||||
print("OnBeforeCompilation")
|
||||
end
|
||||
|
||||
function OnAfterCompilation()
|
||||
print("OnAfterCompilation")
|
||||
end
|
||||
|
||||
function OnAfterSaveFile()
|
||||
print("OnAfterSaveFile")
|
||||
end]]>
|
||||
</Script>
|
||||
</Document>
|
Reference in New Issue
Block a user