Jump to content

Add functions to kernel32.dll


LLXX

Recommended Posts


WIN98UPDT0002

Hello to everyone!

I have been playing with this expansion pack for Windows 98 for the last week.

I have made it possible to add new exports into existing export table and also fixed other function which added modified export table at the end of the file.

Here are the results:

* add GlobalMemoryStatusEx() EXPERIMENTAL!

* removed GetVersionEx modification

- changed the way of checking if patch was previously applied - now checks if UPDATE section exists

Ofcourse it is still open-source :)

Now the bad things:

My implementation of GlobalMemoryStatusEx() seems to be quite buggy ;)

It works nice with NFS:MW and the provided testapp.exe but it does not with Q4 and Doom3 and also causes trouble with GCC.

For this reason there are two exe's inside - one which adds GlobalMemoryStatusEx() and one without it :)

Does anybody here know asm and is able to fix it?

Please test it with .Net apps which caused problems with previous version.

Also tell me whether "Method 1" (recommended) of adding new functions to export table works for you.

Cheers,

Xeno86

win98updt0002.rar

Link to comment
Share on other sites

Very nice! I'm impressed, but I can't test now: i'm falling asleep.

I'll explore into this tomorrow... Also, Xeno86, make sure you're targeting kernel32.dll 4.10.2225: it has significally less space between sections so i'm not sure in Method 1. :wub:

Link to comment
Share on other sites

I'm using kernel version 4.10.2225 myself (SP 2.02) and I think that it shouldn't be a problem - the kernel32.dll I'm using (PL) has 1529 bytes which can be used for new exports (one export needs length of name + 1 [null] + 10 [table enteries]) and if there still isn't enough space I may consider putting export names into other section so one entry will only use 10 bytes then.

But as for now I need some people to test it with kernel versions and/or language versions so that is works for everyone :)

btw. to remove the patch just type in:

win98updt0002 --remove

Link to comment
Share on other sites

Thanks for doing this Xeno86,

Overhere OK too with 4.10.2222A. My problems with version 0001 (.net, GetVersionEx) are fixed!

I hope you keep improving wat LLXX??? started. I think it will make many happy if they can install Doom3 on Win98 without using a hexeditor. And that is just one example.

Edited by noguru
Link to comment
Share on other sites

I found a problem with the last version in Sisoft Sandra Standard version ANSI [win32 x86] 2004.10.9.133. I know this is obsolete software but perhaps the problem is also there in other software.

The program chrashes when I want to open the drive-info module.

it says " This application has requested the Runtime to terminate in a unusual way ".

It also chrashes when opening the summary module and mainboard info:

SANDRA heeft een fout met betrekking tot een ongeldige pagina veroorzaakt in
module <onbekend> op0000:0000e3d2.
Registers:
EAX=00000001 CS=017f EIP=0000e3d2 EFLGS=00210206
EBX=000f0892 SS=0187 ESP=0082b828 EBP=0083fa64
ECX=0082b7d4 DS=0187 ESI=0082ba00 FS=42ef
EDX=000124b8 ES=0187 EDI=00000000 GS=0000
Bytes in CS:EIP:
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Stackdump:
0048d7f9 0082ba00 00000001 01b61820 00000000 00000000 00000000 000000ff 01b602a0 00000000 00000000 00000000 00000000 00000000 00000000 00000000

I hope this info wil be of help with improving. I stay tuned!

Link to comment
Share on other sites

I found a problem with the last version in Sisoft Sandra Standard version ANSI [win32 x86] 2004.10.9.133. I know this is obsolete software but perhaps the problem is also there in other software.

The program chrashes when I want to open the drive-info module.

it says " This application has requested the Runtime to terminate in a unusual way ".

It also chrashes when opening the summary module and mainboard info:

SANDRA heeft een fout met betrekking tot een ongeldige pagina veroorzaakt in
module <onbekend> op0000:0000e3d2.
Registers:
EAX=00000001 CS=017f EIP=0000e3d2 EFLGS=00210206
EBX=000f0892 SS=0187 ESP=0082b828 EBP=0083fa64
ECX=0082b7d4 DS=0187 ESI=0082ba00 FS=42ef
EDX=000124b8 ES=0187 EDI=00000000 GS=0000
Bytes in CS:EIP:
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Stackdump:
0048d7f9 0082ba00 00000001 01b61820 00000000 00000000 00000000 000000ff 01b602a0 00000000 00000000 00000000 00000000 00000000 00000000 00000000

I hope this info wil be of help with improving. I stay tuned!

Are you sure this was caused by the patch? This line:

Bytes in CS:EIP:
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

is especially strange... trying to execute a null buffer? :blink:

The pagefault itself is not in the kernel though.

Link to comment
Share on other sites

To be honest I don't have any clue what is wrong here.

The only thing I am sure about is that Sandra is running fine on the original 4.10.2222 kernel32.dll. I just run the program, not trying to run nul buffers or anything???

It's only the modules I mentioned that cause problems, rest of Sandra functions normal.

Edited by noguru
Link to comment
Share on other sites

  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...