Not enough space for the new segment in the file header

Issues related to VMProtect
nobrain90
Posts: 3
Joined: Sat Aug 04, 2018 8:49 pm

Not enough space for the new segment in the file header

Post by nobrain90 »

Hello,

I use the VMProtect demo (v3.2) to test before I buy.

With an exe, then a dll, everything works ! :)

But I encounter an error with a WinDDK driver : "Not enough space for the new segment in the file header".

The error persists even if I change the "DRIVER_ALIGNMENT" value in the sources before recompiling (= 0x1200).

This is my current setup :

Memory Protection : Yes
Import Protection : Yes
Debugger : User-mode + Kernel-mode
Virtualization Tools : No
Strip Debug Information : Yes
Key Pair Algorithm : RSA 4096


Do you have any idea, please ?

Thank you
ovid
Posts: 26
Joined: Fri Jan 26, 2018 3:30 pm

Re: Not enough space for the new segment in the file header

Post by ovid »

The error persists even if I change the "DRIVER_ALIGNMENT" value in the sources before recompiling (= 0x1200).
why you change this from 0x1000 to 0x1200 what reason?

also I think you should use your protection based on hwid inside not use VMP for drivers.

anyway just my opinion, admin is one that solve problems here.
nobrain90
Posts: 3
Joined: Sat Aug 04, 2018 8:49 pm

Re: Not enough space for the new segment in the file header

Post by nobrain90 »

Hello ovid,
why you change this from 0x1000 to 0x1200 what reason?
Only for test :wink:
also I think you should use your protection based on hwid inside not use VMP for drivers.
Why please ?

Thank you
a47
Posts: 21
Joined: Tue Mar 27, 2018 10:31 am

Re: Not enough space for the new segment in the file header

Post by a47 »

Have same issue(not enough space for the new segment in the file header) when trying to protect linux so in ultimate windows version(spirt****@pm.me) and with linux x64 trial too

file example: https://share.riseup.net/#7jm-uu0nAAsIAW9DiCM9Hg (cannot attach here cuz "Invalid file extension: libLLVM-3.9.so")

Does VMP 3.2 support elf64 so shared libs?
Admin
Site Admin
Posts: 2566
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: Not enough space for the new segment in the file header

Post by Admin »

VMProtect supports elf64 binaries.
a47
Posts: 21
Joined: Tue Mar 27, 2018 10:31 am

Re: Not enough space for the new segment in the file header

Post by a47 »

Nice, but what should i do with this compilation error? Where is the root? May be i should use another gcc flags? Will this error fixed?
Admin
Site Admin
Posts: 2566
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: Not enough space for the new segment in the file header

Post by Admin »

Do you use our SDK?
a47
Posts: 21
Joined: Tue Mar 27, 2018 10:31 am

Re: Not enough space for the new segment in the file header

Post by a47 »

No i dont, should i?
I'm trying to protect free as in freedom binary(https://github.com/lwss/fuzion)
Admin
Site Admin
Posts: 2566
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: Not enough space for the new segment in the file header

Post by Admin »

In this case there is not enough free space in the file header.
a47
Posts: 21
Joined: Tue Mar 27, 2018 10:31 am

Re: Not enough space for the new segment in the file header

Post by a47 »

Yes, but is there way for protection this project? After ur question I've tried to include vmprotectsdk.h and set up markers for some functions, but result is the same.
Admin
Site Admin
Posts: 2566
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: Not enough space for the new segment in the file header

Post by Admin »

You can use the following trick with SDK name: "./././././././././././././libVMProtectSDK.so" (many many /./.). This string is placed in the file header and after protection the place of this string will be used for creation of a new segment(s).
a47
Posts: 21
Joined: Tue Mar 27, 2018 10:31 am

Re: Not enough space for the new segment in the file header

Post by a47 »

how to perform it? could u provide an example?
Admin
Site Admin
Posts: 2566
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: Not enough space for the new segment in the file header

Post by Admin »

Try this:
gcc -L././././././././././
a47
Posts: 21
Joined: Tue Mar 27, 2018 10:31 am

Re: Not enough space for the new segment in the file header

Post by a47 »

set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -L ./././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././././src/libVMProtectSDK64.so")
didnt work
Admin
Site Admin
Posts: 2566
Joined: Mon Aug 21, 2006 8:19 pm
Location: Russia, E-burg
Contact:

Re: Not enough space for the new segment in the file header

Post by Admin »

Please read help about "-L" more carefully.
Post Reply