vmp3 randomize or hide section names

Issues related to VMProtect
Post Reply
ddlmaster
Posts: 3
Joined: Mon Sep 17, 2018 6:18 pm

vmp3 randomize or hide section names

Post by ddlmaster »

hi, ive tried a script i had for 2.x but doesnt work, i see in 3 its changed to lua but this doesn't work either;

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():outputFile()
for i = 1, file:segments():count() do
file:segments():item(i):setName(GetRandomSectionName())
end
end

whats the script to hide section names or randomize them (both examples would be good)

thanks
Admin
Site Admin
Posts: 2584
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: vmp3 randomize or hide section names

Post by Admin »

C:\Users\Public\Documents\VMProtect\Scripts\Random Section Names:

Code: Select all

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
What doesn't work?
ddlmaster
Posts: 3
Joined: Mon Sep 17, 2018 6:18 pm

Re: vmp3 randomize or hide section names

Post by ddlmaster »

thankyou.
Mecanik
Posts: 7
Joined: Fri Sep 28, 2018 11:59 am

Re: vmp3 randomize or hide section names

Post by Mecanik »

Interesting, and very useful. However I don't know how antivirus engines will handle this, as most of them scan section names as well, they might flag it false positive... :(
Post Reply