MSFN Forum: Kext: DIY KernelEx extensions - MSFN Forum

Jump to content


  • 12 Pages +
  • 1
  • 2
  • 3
  • 4
  • 5
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic

Kext: DIY KernelEx extensions Latest: K452stub (25Feb); Core.ini (2Feb, post#144); Ktree9 (9Jan) Rate Topic: -----

#41 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 22 July 2012 - 09:48 PM

View Postschwups, on 19 July 2012 - 05:28 AM, said:

View Postjds, on 17 July 2012 - 04:10 AM, said:

Another problem child from the update @ post #10 :

;ActivateActCtx=f2e // buggy!

This one prevented Dependency Walker from running (unless I disabled KernelEx for it).

Joe.


Confirmed!

According to Wikipedia, the current stable version is 2.2.6000. I run that version and have had no problems.

What version has problems with ActivateActCtx?


#42 User is offline   jds 

  • -DOS+
  • PipPipPipPip
  • Group: Members
  • Posts: 595
  • Joined: 03-June 08
  • OS:98SE
  • Country: Country Flag

Posted 23 July 2012 - 03:33 AM

View Postjumper, on 22 July 2012 - 09:48 PM, said:

View Postschwups, on 19 July 2012 - 05:28 AM, said:

View Postjds, on 17 July 2012 - 04:10 AM, said:

Another problem child from the update @ post #10 :

;ActivateActCtx=f2e // buggy!

This one prevented Dependency Walker from running (unless I disabled KernelEx for it).

Joe.


Confirmed!

According to Wikipedia, the current stable version is 2.2.6000. I run that version and have had no problems.

What version has problems with ActivateActCtx?

Hi jumper,

Mine says it's 2.2.6000 (MD5 of EXE = b6051fdab7dc811a2d6be64a1579c735, MD5 of DLL = e72eff1b793fe064f068e715efb1b5cd).

Joe.

#43 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 23 July 2012 - 04:08 AM

same version - same checksums

#44 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 24 July 2012 - 01:50 AM

How to install Opera 12.5 alpha for testing.

I added these API's to [Secur32.dll]: Please jumper correct them, I'm not sure. 

LsaEnumerateLogonSessions=z2e
LsaFreeReturnBuffer=z1e
LsaGetLogonSessionData=z2e
InitSecurityInterfaceW=



It doesn't work stable and of course the plugins don't run and I can't add buttons to the toolbars. The comp. mode must be Win2000SP4 for installation and running (the default mode isn't possible anymore). 




[NTDLL.DLL] vsprintf=z3e for latest Sumatra PDF



This post has been edited by schwups: 24 July 2012 - 04:38 PM


#45 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 24 July 2012 - 11:19 PM

View Postschwups, on 24 July 2012 - 01:50 AM, said:

How to install Opera 12.5 alpha for testing.

I added these API's to [Secur32.dll]: Please jumper correct them, I'm not sure.

LsaEnumerateLogonSessions=z2e
LsaFreeReturnBuffer=z1e
LsaGetLogonSessionData=z2e
InitSecurityInterfaceW=

The Lsa functions need to return a negative value to indicate failure, so our only option for now is 'true'. They don't SetLastError, so no 'e'.
InitSecurityInterface[A/W] returns zero on failure, takes no parameters, and doesn't SetLastError.

Sorted and merged:
[Secur32.dll]
GetUserNameExA=z3e
GetUserNameExW=z3e
InitSecurityInterfaceW=z0
LsaEnumerateLogonSessions=t2
LsaFreeReturnBuffer=t1
LsaGetLogonSessionData=t2


Quote

It doesn't work stable and of course the plugins don't run and I can't add buttons to the toolbars. The comp. mode must be Win2000SP4 for installation and running (the default mode isn't possible anymore).

What is your default mode set to? It can be enabled or disabled (registry setting); and any compatibility mode (core.ini setting). I highly recommend Disabled or Enabled/Win98se (for the improved heap management). Only use a higher mode when required, or the app might try to take liberties....


Quote

[NTDLL.DLL] vsprintf=z3e for latest Sumatra PDF

[NTDLL.DLL] vsprintf=z0

'z' because no characters are outputted (hopefully the buffer is already zero-terminated, because we can't do that!)
'0' because of the "C" calling convention (__cdecl).
No 'e' because this function doesn't SetLastError.

Edit: As of 822, we can use any of these definitions to forward vsprintf to be handled by Msvcrt.dll:
[NTDLL.DLL]
vsprintf=>Msvcrt.dll:vsprintf
vsprintf=>Msvcrt:vsprintf
vsprintf=>Msvcrt.dll:
vsprintf=>Msvcrt:
vsprintf=>

This post has been edited by jumper: 23 August 2012 - 03:05 AM


#46 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 25 July 2012 - 01:47 PM

My default mode: KernelEx is enabled. HKEY_LOCAL_MACHINE\SOFTWARE\KernelEx  "DisableExtensions"=dword:0x00000000 (0). 


Thanks for corrections and explanations. 

#47 User is offline   jds 

  • -DOS+
  • PipPipPipPip
  • Group: Members
  • Posts: 595
  • Joined: 03-June 08
  • OS:98SE
  • Country: Country Flag

Posted 30 July 2012 - 03:44 AM

View Postschwups, on 25 July 2012 - 01:47 PM, said:

My default mode: KernelEx is enabled. HKEY_LOCAL_MACHINE\SOFTWARE\KernelEx  "DisableExtensions"=dword:0x00000000 (0). 


Thanks for corrections and explanations. 

Me too.

That explains why jumper didn't see the Dependency Walker problem ...

Joe.

#48 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 03 August 2012 - 06:43 AM

Kstub730.ini:

[ComDlg32.dll]


PrintDlgExA=>ComDlgKs.dll:PrintDlgExA
PrintDlgExW=>ComDlgKs:PrintDlgExW

I think it should be PrintDlgExW=>ComDlgKs.dll:PrintDlgExW !?




#49 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 03 August 2012 - 02:14 PM

>I think it should be PrintDlgExW=>ComDlgKs.dll:PrintDlgExW !?

Good eye, I hoped it would be noticed. :)
This was an intentional example of how the '.dll' extension is optional:
; =>[[drive:]path]library[.ext]:function

SumatraPDF 2.11 was my test case for this forwarding definition.

#50 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 07 August 2012 - 06:41 AM

After updating to 730 an IE script error occured in windows\web\controlp.htt, if I tried open the control panel. This happened on two of three machines.  

Run => regsvr32 webvw.dll doesn't work. Downgrading to 626 fixed the error.

This post has been edited by schwups: 08 August 2012 - 04:20 AM


#51 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 07 August 2012 - 10:27 PM

View Postschwups, on 07 August 2012 - 06:41 AM, said:

After updating to 730 an IE script error occured in windows\web\controlp.htt, if I tried open the control panel. This happened on two of three machines.

Run => regsvr32 webvw.dll doesn't work. Downgrading to 626 fixed the error.

Probably one of the new definitions. First we need to look at what was reported in the Kstub730.log file. Each action is now logged. :sneaky:

The next thing would be to try the older definitions with Kstub730.dll. You can do this by removing Kstub730.ini--Kstub730 will use Kex stubs.ini if it doesn't find Kstub30.ini. (Kstub626.dll also has this feature.:yes:)

This post has been edited by jumper: 08 August 2012 - 06:09 PM


#52 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 08 August 2012 - 04:35 AM

Kstub730.log file:

= Shlwapi.dll:SHRegisterValidateTemplate=t2 ? =
= Kernel32.dll:GetUserGeoID=t1 =




#53 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 08 August 2012 - 04:59 AM

The next thing would be to try the older definitions with Kstub730.dll. You can do this by removing Kstub730.ini--Kstub730 will use Kexstubs.ini if it doesn't find Kstub30.ini. (Kstub626.dll also has this feature.

Do you mean Kexstubs.ini = stubs.ini of version 626 and I have to paste it in the KernelEx folder? If so, then I always get questions of Kexstub730 before opening a new Explorer window: 

Shlwapi.dll:SHRegisterValidateTemplate=t2?


SetLastError (1/0)    [Yes/No]

more options            [Cancel]

and

Shlwapi.dll:SHRegisterValidateTemplate=t2?

return -1/0                  [Yes/no]

more options            [Cancel]


This post has been edited by schwups: 08 August 2012 - 05:10 AM


#54 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 08 August 2012 - 04:22 PM

View Postschwups, on 08 August 2012 - 04:35 AM, said:

Kstub730.log file:

= Shlwapi.dll:SHRegisterValidateTemplate=t2 ? =
= Kernel32.dll:GetUserGeoID=t1 =

Both of these definitions already existed, so the problem is likely a definition that was removed. I'll address that in the next post.

Using this Table of Geographical Locations, we can now upgrade GetUserGeoID from GEOID_NOT_AVAILABLE (-1), to:
[Kernel32.dll]
GetUserGeoID=r0xF4s1 ;US
; or
GetUserGeoID=r0x5Es1 ;Germany 


#55 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 08 August 2012 - 05:38 PM

View Postschwups, on 08 August 2012 - 04:59 AM, said:

Do you mean Kexstubs.ini = stubs.ini of version 626 and I have to paste it in the KernelEx folder?

Yes, or leave it if it is still there. I'll correct post #51. Thanks!

Quote

If so, then I always get questions of Kexstub730 before opening a new Explorer window:

Shlwapi.dll:SHRegisterValidateTemplate=t2?

SetLastError (1/0) [Yes/No]
more options [Cancel]

and

Shlwapi.dll:SHRegisterValidateTemplate=t2?

return -1/0 [Yes/no]
more options [Cancel]

The prompt occurs because Kstub730 supports the '?' directive (whereas Kstub626 did not):
; =r#s#[e[#]][?]

Remove the '?' to use the 't2' without prompting.

I added the '?' because the function is undocumented and the 't' was a guess. Users can try 'f2' or 'r<n>s2' to change the return value. An 'e' can also be tried. This is the purpose of the prompt sequence: to be able to experiment with different options without restarting the app. When prompted, Cancel+Yes is equivalent to 't2'--what combinations of responses have or haven't worked for you?


SHRegisterValidateTemplate was first introduced in Windows 2000, so you are using a W2K+ file somewhere in your WinMe(?) system. This isn't a bad thing, but it would be good to know what file is making the call. Please search your <WinSys> folder for files containing "SHRegisterValidateTemplate". Also, check what modules are in use by Explorer at the time of this prompt. Does your system that is not having a problem happen to be SE, or not have all the same SP's/upgrades?

Thanks for the report and good followup! :thumbup

#56 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 09 August 2012 - 08:05 AM

what combinations of responses have or haven't worked for you?

All combinations work to open a folder, but no combination work to open the control panel.




Does your system that is not having a problem happen to be SE, or not have all the same SP's/upgrades?

I corrected the post #50. The IE script error occurred on all three Win ME test systems. The SP1 isn't installed.


Installed: 1. IE6 SP1  2. DirectX9c  3. NetFramework 1.1 and 2.0    4. unicows.dll (1.1.3790.0)    5. VisualBasic 6.0 SP6 (vbrun60sp6.exe)    6.  MDAC 2.81 SP1   7.  VisualC++ red 2005 (SP) and 2008  8. MS Win ME Update User / GDI    9. GDIPLUS (WinXP)   

This post has been edited by schwups: 09 August 2012 - 10:18 AM


#57 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 10 August 2012 - 10:31 AM

View Postschwups, on 07 August 2012 - 06:41 AM, said:

After updating to 730 an IE script error occured in windows\web\controlp.htt, if I tried open the control panel. This happened on two of three machines.  

Run => regsvr32 webvw.dll doesn't work. Downgrading to 626 fixed the error.




Alteration of the sequence in the core.ini from "contends=std,kexbases,kexbasen,Kstub730" to "contents=Kstub730,std,kexbases,kexbasen" solves the problem.  :rolleyes:

This post has been edited by schwups: 10 August 2012 - 10:32 AM


#58 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

Posted 10 August 2012 - 03:59 PM

View Postschwups, on 10 August 2012 - 10:31 AM, said:

Alteration of the sequence in the core.ini from "contends=std,kexbases,kexbasen,Kstub730" to "contents=Kstub730,std,kexbases,kexbasen" solves the problem. :rolleyes:

Very good. This means that one of the definitions is colliding with a standard function or one in kexbases or kexbasen. I wasn't aware of any with SE other than the intentional PrintDlgEx, but will recheck.

Testload.exe can be used to detect collisions (load addresses of functions in stubs.ini above 0x10001nnn), but I'll design a better tool.

The reason for increasing the priority of Kstub730 was to override KernelEx on ComDlg32:PrintDlgExA/W. That can also be done with a .names definition in Core.ini:
[NT2K.names]
ComDlg32.PrintDlgExA=Kstub730.0
ComDlg32.PrintDlgExW=Kstub730.0 

I've now rechecked for conflicts using TestLoad and found none on my SE system, but the Msvcr90.dll section would probably be an issue for those with the latest version installed (definitions are meant to augment the original version). Before Kstub730, [Msvcr90.dll] was missing the '0'.

This post has been edited by jumper: 10 August 2012 - 09:03 PM


#59 User is offline   jumper 

  • Masters HJ/TJ'er (back in training)
  • PipPipPip
  • Group: Members
  • Posts: 361
  • Joined: 21-January 11
  • OS:98SE
  • Country: Country Flag

  Posted 17 August 2012 - 03:51 AM

Kstubs816 now posted with better forwarding, better definitions

+ Forwards can now be abbreviated and commented
+ Many new forward definitions providing full function support
+ Complete definitions for all stubbed functions
- Stepload support removed

Note: Full-line comments got broken last week when I was trying a trick to avoid needing system restarts in some cases. The workaround is to remove from Kstub816.ini / stubs.ini all definitions that are commented out. I've posted a new download with the updated Kstub816.ini.

Edit: 822 is what 816 was supposed to be. It has the same features, but without the full-line and end-of-forwards-line comment bugs.

This post has been edited by jumper: 23 August 2012 - 03:16 AM


#60 User is offline   schwups 

  • schwups
  • PipPip
  • Group: Members
  • Posts: 274
  • Joined: 11-November 09
  • OS:ME
  • Country: Country Flag

Posted 21 August 2012 - 09:10 AM

So far I can't see any problems with version 816, if the sequence in the core.ini is: "contents=Kstub816,std,kexbases,kexbasen"

Share this topic:


  • 12 Pages +
  • 1
  • 2
  • 3
  • 4
  • 5
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2013 msfn.org
Privacy Policy