WildBill

PE Tool for creating patches

695 posts in this topic

I updated the file and the link. Bear in mind that it's a split archive: you only have to extract from Windows2000-KB2393802-v17-x86-ENU.zip and it will extract from both files.

0

Share this post


Link to post
Share on other sites

Below is the link to v1 of my kernel32 rewrite. It includes a VS2005 project, full source, and a compiled DLL.

DO NOT INSTALL THIS ON YOUR MAIN SYSTEM

I'm posting this because I've hit a wall on a bug and I need help :(

Windows2000-kernel32-rewrite-v1.zip

0

Share this post


Link to post
Share on other sites

There appear to be multiple problems downloading and unpacking the split archive files for KB2393802-v17. I crawled through MediaFire's knowledge base and found something that is letting me upload the standard .exe installer again. Apparently my browser doesn't like their HTML5 uploader, and there is a setting to disable it. I updated the link on the main listing, and it should let you download a standard installer like earlier versions.

0

Share this post


Link to post
Share on other sites

I have tried your kernel... and I was unable to debug anything using ollydbg... so I pick another way... I'm attaching the olly to explorer process.

here is the LOG file produced by olly.. there are two LOGs files.. the name of the file should be obvious...

I have no idea whether this is useful or not... :blushing:

btw you have done such an impressive work... :thumbup

hope this helps...

log.zip

0

Share this post


Link to post
Share on other sites

Thanks! Every little bit helps. Lately I've been crawling through backup.cpp tp try to fix some reported bugs. I definitely found one, but I haven't finished going through it. I tried fixing the bug when trying to install software and I really need help there. One thing I need to check is all calls to FsRtlxxx routines to make sure I'm using the right structures.

On another note, I just posted KB2479628-v8. It adds stub support for these routines in user32.dll:

RegisterRawInputDevices

GetRawInputData

GetRawInputDeviceInfoA

GetRawInputDeviceInfoW

GetRawInputDeviceList

GetRawInputBuffer

DefRawInputProc

They're just stubs and return zero and/or failure where appropriate, but they let you use programs that import them, like the latest version of FreeCAD.

0

Share this post


Link to post
Share on other sites

I have tried your kernel... and I was unable to debug anything using ollydbg... so I pick another way... I'm attaching the olly to explorer process.

here is the LOG file produced by olly.. there are two LOGs files.. the name of the file should be obvious...

I have no idea whether this is useful or not... :blushing:

btw you have done such an impressive work... :thumbup

hope this helps...

Do you still have those logs? I tried unzipping the file and I can't extract them. 7-zip can't extract it at all and ZipGenius only creates zero-length files :(

0

Share this post


Link to post
Share on other sites

@WildBill 7-Zip works for me. Are you using the newest version? Mine is 7-Zip 9.30 alpha.

0

Share this post


Link to post
Share on other sites

I confirm WildBill's finding: both WinRAR 4.20 and 7-zip 9.20 are unable to open the zip in post # 635.

Since you can do it, please do repack it as a normal zip or a cab and attach it, please.

0

Share this post


Link to post
Share on other sites

l'm really sorry, currently I'm away from my development PC, where I store the logs. I have also confirmed that the file is indeed corrupt. I managed to extract only a single file. here the log I managed to extract.. the log produced while I'm attaching olly into explorer processes..

Loading function descriptions from 'common.arg'

File 'C:\WINNT\explorer.exe'

New process with ID 000003AC created

Main thread with ID 000002D4 created

New thread with ID 0000036C created

New thread with ID 000003B0 created

New thread with ID 000003EC created

New thread with ID 00000450 created

New thread with ID 000002F0 created

New thread with ID 000004A0 created

New thread with ID 000002F4 created

New thread with ID 00000120 created

New thread with ID 000003B4 created

New thread with ID 000003C8 created

New thread with ID 000004A4 created

New thread with ID 00000424 created

New thread with ID 00000278 created

New thread with ID 000002C8 created

New thread with ID 000003E8 created

New thread with ID 0000031C created

New thread with ID 000003A8 created

77F91A76 Debug string: [757500] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

7C584A20 New thread with ID 00000294 created

00400000 Module C:\WINNT\explorer.exe

CRC changed, discarding .udd data

00DC0000 Module C:\WINNT\system32\SHDOCVW.DLL

01080000 Module C:\WINNT\System32\vmhgfs.dll

024D0000 Module C:\WINNT\system32\MSI.DLL

1A400000 Module C:\WINNT\system32\urlmon.dll

23000000 Module C:\WINNT\AppPatch\AcLayers.DLL

63000000 Module C:\WINNT\system32\WININET.dll

63580000 Module C:\WINNT\system32\mshtml.dll

658F0000 Module C:\WINNT\system32\webvw.dll

66650000 Module C:\WINNT\system32\USP10.DLL

6A8F0000 Module C:\WINNT\system32\MSVFW32.DLL

6DE80000 Module C:\WINNT\system32\TxfAux.Dll

70020000 Module C:\WINNT\system32\faxshell.dll

70340000 Module C:\WINNT\system32\webcheck.dll

70440000 Module C:\WINNT\system32\mlang.dll

70510000 Module C:\WINNT\system32\imgutil.dll

70A70000 Module C:\WINNT\system32\SHLWAPI.dll

70F30000 Module C:\WINNT\system32\mshtmled.dll

71500000 Module C:\WINNT\system32\browseui.dll

71710000 Module C:\WINNT\system32\COMCTL32.dll

718C0000 Module C:\WINNT\system32\shdoclc.dll

71960000 Module C:\WINNT\system32\browselc.dll

71F00000 Module C:\WINNT\system32\docprop2.dll

732E0000 Module C:\WINNT\system32\shim.dll

74870000 Module C:\WINNT\system32\AVIFIL32.DLL

75020000 Module C:\WINNT\system32\WS2HELP.DLL

75030000 Module C:\WINNT\system32\WS2_32.DLL

75050000 Module C:\WINNT\system32\WSOCK32.dll

75150000 Module C:\WINNT\system32\SAMLIB.dll

75160000 Module C:\WINNT\System32\ntlanman.dll

751C0000 Module C:\WINNT\system32\NETRAP.dll

751D0000 Module C:\WINNT\System32\NETUI1.dll

75210000 Module C:\WINNT\System32\NETUI0.dll

759B0000 Module C:\WINNT\system32\LZ32.DLL

75AC0000 Module C:\WINNT\system32\MSLS31.DLL

75D40000 Module C:\WINNT\system32\msadp32.acm

75E60000 Module C:\WINNT\system32\IMM32.DLL

76290000 Module C:\WINNT\system32\es.dll

76620000 Module C:\WINNT\system32\MPR.DLL

766D0000 Module C:\WINNT\system32\stobject.dll

766F0000 Module C:\WINNT\system32\POWRPROF.DLL

76710000 Module C:\WINNT\system32\LINKINFO.DLL

76740000 Module C:\WINNT\system32\BATMETER.DLL

76DF0000 Module C:\WINNT\system32\mydocs.dll

76F20000 Module C:\WINNT\system32\NETSHELL.dll

76FA0000 Module C:\WINNT\system32\ntshrui.dll

770B0000 Module C:\WINNT\system32\CfgMgr32.dll

770C0000 Module C:\WINNT\system32\CSCDLL.dll

773E0000 Module C:\WINNT\system32\ATL.DLL

77400000 Module C:\WINNT\system32\msacm32.drv

77410000 Module C:\WINNT\system32\MSACM32.dll

77430000 Module C:\WINNT\system32\MSASN1.dll

77560000 Module C:\WINNT\system32\wdmaud.drv

77570000 Module C:\WINNT\system32\WINMM.DLL

77820000 Module C:\WINNT\system32\VERSION.dll

77840000 Module C:\WINNT\system32\cscui.dll

77880000 Module C:\WINNT\system32\SETUPAPI.DLL

77950000 Module C:\WINNT\system32\WLDAP32.DLL

77980000 Module C:\WINNT\system32\DNSAPI.DLL

779B0000 Module C:\WINNT\system32\OLEAUT32.dll

77BF0000 Module C:\WINNT\system32\NTDSAPI.dll

77D30000 Module C:\WINNT\system32\RPCRT4.dll

77E10000 Module C:\WINNT\system32\USER32.dll

77F40000 Module C:\WINNT\system32\GDI32.dll

77F80000 Module C:\WINNT\system32\ntdll.dll

78000000 Module C:\WINNT\system32\msvcrt.dll

7C0F0000 Module C:\WINNT\system32\USERENV.DLL

7C2D0000 Module C:\WINNT\system32\ADVAPI32.dll

7C340000 Module C:\WINNT\system32\Secur32.dll

7C570000 Module C:\WINNT\system32\KERNEL32.dll

7C740000 Module C:\WINNT\system32\CRYPT32.dll

7C950000 Module C:\WINNT\system32\CLBCATQ.DLL

7CDC0000 Module C:\WINNT\system32\NETAPI32.DLL

7CE20000 Module C:\WINNT\system32\OLE32.DLL

7CF30000 Module C:\WINNT\system32\SHELL32.dll

77F9193C Attached process paused at ntdll.DbgBreakPoint

77F91A76 Debug string: [762593] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [762593] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [762593] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [762609] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

Thread 000003C8 terminated, exit code 0

Thread 00000294 terminated, exit code 0

77F91A76 Debug string: [763515] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [764531] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [764593] FileTimeToDosDateTime(): Year is less than 1980

77F91A76 Debug string: [764593] FileTimeToDosDateTime(): Year is less than 1980

77F91A76 Debug string: [764593] FileTimeToDosDateTime(): Year is less than 1980

77F91A76 Debug string: [764593] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764593] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764593] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764593] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764593] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764593] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764609] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764625] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764625] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [764625] CloseHandle(): NtClose failed, status = 0xC0000008

77F91A76 Debug string: [765546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [766546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [767546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [768546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [769546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [770546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [771546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [772546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [773546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [774546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [775546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [776546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [777546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [778546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [779546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [780546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [781546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [782546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [783546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [784546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [785546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [786546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [787546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [788546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [789546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [790546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [791546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [792546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [793546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [794546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [795546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [796546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [797546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [798546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [799546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

Thread 000004A0 terminated, exit code 0

77F91A76 Debug string: [800546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [801546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [802546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [803546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [804546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [805546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [806546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [807546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [808546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [809546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [810546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [811546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

77F91A76 Debug string: [812546] GetModuleHandleForUnicodeString(): LdrGetDllHandle failed, status = 0xC0000135

Log file closed

hope this helps..

0

Share this post


Link to post
Share on other sites
:hello: I found Bug in your SearchPathA function.. please examine carefully at "result variable" at line 28898, kernel32.cpp, the "result" is initialized with zero thus causes the last param for RtlUnicodeToMultiByteN to zero... maybe you intended to put something else there? :whistle:
0

Share this post


Link to post
Share on other sites

Good catch! I'm going to test it right now and see if this fixes some problems.

0

Share this post


Link to post
Share on other sites

It seems that the rewritten kernel32 causes mshta.exe to consistently crash when running Add/Remove Programs. It also seems to make the Windows Post-install Wizard really unstable and sometimes crash in mshta.exe.

Edited by MacLover
0

Share this post


Link to post
Share on other sites

I finally got sick of Dependency Walker complaining about that one missing 9x API call in mpr.dll and decided to do something about it. Up now is KB2508429 v10, which adds the routine (it actually maps it to an existing one that appears to do the same thing).

I'm still occasionally working on fixing my kernel32 rewrite; I found one tiny bug but that wasn't the one I'm looking for. I captured a big log yesterday from my VM and I'll take a look at it to see what it tells me.

0

Share this post


Link to post
Share on other sites

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.