flat assembler
Message board for the users of flat assembler.

Index > Windows > is this possible?

Author
Thread Post new topic Reply to topic
calpol2004



Joined: 16 Dec 2004
Posts: 110
calpol2004 09 Jan 2006, 18:06
ok i want a program to be able to store files in itself, i want to be able to add remove and execute its embedded files, however because i dont rly want to have more files than just the executable,this is guna tricky Very Happy . because an application cant be edited while its running i have this idea: to embed an application inside the application then to execute that, close the application that opened it, then with the new application use that to edit the executable and add/remove the files. this of course is rather dodgy and im not sure it can be done Crying or Very sad . ne ways i would like to know if its possible and maybe some tips on how i could go about it or maybe even suggest a better idea.

calpol.
Post 09 Jan 2006, 18:06
View user's profile Send private message MSN Messenger Reply with quote
okasvi



Joined: 18 Aug 2005
Posts: 382
Location: Finland
okasvi 09 Jan 2006, 19:19
basically you are looking for help to code binder or something related to somekind of interpreter?

in case of binder just write the exe you want to end of file and after that dword which is how much data there is appended into it...
so file would be like:
[STUB][EXE1][dw_LEN1][EXE2][dw_LEN2]...[EXE?][dw_LEN?]

_________________
When We Ride On Our Enemies
support reverse smileys |:
Post 09 Jan 2006, 19:19
View user's profile Send private message MSN Messenger Reply with quote
velox



Joined: 06 Jan 2006
Posts: 14
velox 09 Jan 2006, 19:50
iirc comrade has coded an app called selfsave, this is maybe what you're searching
Post 09 Jan 2006, 19:50
View user's profile Send private message Reply with quote
okasvi



Joined: 18 Aug 2005
Posts: 382
Location: Finland
okasvi 09 Jan 2006, 20:12
when properly tweaked it could be used...
it uses offset for message to edit and if i remember right its max lenght is 100h


so basically only injection part of it could be used to prevent need of external "editor" for stubfile which then again would make stub bloated as editor could would be always present but only used for first time when eg last byte of file is 0...

_________________
When We Ride On Our Enemies
support reverse smileys |:
Post 09 Jan 2006, 20:12
View user's profile Send private message MSN Messenger Reply with quote
chris



Joined: 05 Jan 2006
Posts: 62
Location: China->US->China->?
chris 11 Jan 2006, 08:30
if you are doing this under windows, there is a possible way that is to use the CreateRemoteThread API, I once used it to create a self-deleting/updating application.
Post 11 Jan 2006, 08:30
View user's profile Send private message Reply with quote
shoorick



Joined: 25 Feb 2005
Posts: 1614
Location: Ukraine
shoorick 11 Jan 2006, 10:20
i had no try it, but you can look at this: UpdateResource
Post 11 Jan 2006, 10:20
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.