flat assembler
Message board for the users of flat assembler.

Index > Windows > Creating a php extension in assembler

Author
Thread Post new topic Reply to topic
Tycho



Joined: 02 Mar 2008
Posts: 9
Tycho
I'm working on a web-server for some years now and I would like to make a extension for php so you can change the settings in a simple php code. I found out all extensions have a function called 'get_module' exported, this returns a address to a structure with some unknown value's and some pointers to functions (founded with debugger). I can try and guess what those value's are and work for hours, but I hope some of you know how to create a extension for php in assembler!? However, thanks for taking time to read this topic Smile
Post 04 Sep 2008, 18:00
View user's profile Send private message Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4633
Location: Argentina
LocoDelAssembly
Do you have a link to documentation or even an example of this in C or any other high level language? That would greatly help to know how to do the same in Assembly.
Post 04 Sep 2008, 18:11
View user's profile Send private message Reply with quote
Tycho



Joined: 02 Mar 2008
Posts: 9
Tycho
LocoDelAssembly wrote:
Do you have a link to documentation or even an example of this in C or any other high level language? That would greatly help to know how to do the same in Assembly.

The php documentation says how to make a get_module in C, (http://theserverpages.com/php/manual/en/zend.structure.get-module.php) #if COMPILE_DL_FIRSTMOD
ZEND_GET_MODULE(firstmod)
#endif

But I'm not aware with this macro, that's why I started disassembling in the first place. I also download some examples in C but they all use the same macros and fiels like the file config.m4.
A full documentation is on http://talks.php.net/show/extending-php-apachecon2003/0 (change the 0 upwards 1,2,3 to get to the next page) but this one is C to. So my problem is how to those macros works so I can write it in ASM. I'm not really familiar with C (started with ASM right after basic language) so it could just be me that I'm not understanding the macro, I hope somebody else does Smile.
Post 04 Sep 2008, 18:31
View user's profile Send private message 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-2020, Tomasz Grysztar.

Powered by rwasa.