Skip to contentSkip to conversation

silly memory question ...

DISCUSSION Josh Fryman 1 participant 1 message Aug 27, 2001

lore
Share & tools
lore
#0 lore raw

hi all,

i'm looking to do something stupid. can anyone tell me why it won't work? (is there some kind of special protection on EXE memory pages?)

i have an application, App1, that has a 64KB function (64KB of NOP) "void funcX(void)". App1 opens a socket to another application, App2, which is going to feed code to App1 to stick in funcX.

that is, i've got some other set of functions i plan on feeding to App1 and they're all going to look like "funcX" to App1. those functions are coming from App2, which is chewing on a bunch of var-things to spit out just the right code for App1.

now, when i try to do this, i get Random Stuff. sometimes, i just get a segfault. sometimes, it seems to work, but the memory at funcX is hosed if i do a hex-dump compared to what i received from App2. either way, it isn't doing what i want...

is there some trick here to make this work? or am i SOL?

[is there a better place to ask this question?]

thanks,

josh