Contribute
Register

[Solved] NVIDIA Web Driver iBooks Bug

mlg

Joined
Feb 28, 2011
Messages
13
Motherboard
ASUS MAXIMUS VII IMPACT
CPU
Intel Core i7-4790
Graphics
ASUS NVIDIA GTX 1080
Hi everyone. I wrote a kernel extension, which resolves the problem for those of us without the option to enable an internal GPU. It permits iBooks, Little Snitch and other software to do their rendering with the NVIDIA Web Driver.

EDIT 2: Use this new, secure version instead: https://github.com/mologie/NVWebDriverLibValFix/releases

The below information is for the old, insecure patching method.

https://github.com/mologie/macos-disable-library-validation

I'm not releasing a precompiled kext until I got a few confirmations that this works on more than just my machine. I kindly ask you to not distribute precompiled versions of the kext either - there'll be an official release once I get a few OKs. (EDIT: Link to precompiled version added to the end of this post.)

Please only follow these instructions if you're familiar with recovering Hackintosh systems. The kext loads on boot, and you may have to boot an installation disk or attach your disk to another Mac to remove it if things go haywire.

Quick start:
  1. Install Xcode
  2. Open Terminal
  3. Run the commands below
xcode-select --install
git clone https://github.com/mologie/macos-disable-library-validation.git
cd macos-disable-library-validation
./install.sh


You'll be prompted for your passcode for installing the kernel extension. All source code is available for review on GitHub.

EDIT: The precompiled version is available at https://github.com/mologie/macos-disable-library-validation/releases
 
Last edited:

UA3

Joined
May 22, 2013
Messages
13
Motherboard
Asus z97 Deluxe
CPU
i7 4790K
Graphics
GTX 780
Mac
MacBook, MacBook Pro, Mac mini
Mobile Phone
Android, iOS
Thanks @mlg !! worked just fine.

 
Joined
Sep 15, 2015
Messages
151
Motherboard
Gigabyte GA-Z97X-GAMING 3
CPU
i7-4790K
Graphics
Sapphire Nitro RX 480 OC
Mac
MacBook Pro
First of all, thanks for finding the proper function in the kernel. You have more patience and/or stubbornness than I did when I looked at it.

That being said, you can also do it via a clover kernel patch.

Code:
                <key>KernelToPatch</key>
                <array>
                        <dict>
                                <key>Comment</key>
                                <string>Disable Library Validation</string>
                                <key>Disabled</key>
                                <false/>
                                <key>Find</key>
                                <data>
                                VUiJ5VNQuwEAAACDPZInNwAAdR1Ihf8=
                                </data>
                                <key>Replace</key>
                                <data>
                                SDHAw1NQuwAAAACDPZInNwAAdR1Ihf8=
                                </data>
                        </dict>
                </array>
                <key>KextsToPatch</key>
For those that are using clover configurator:
Kernel and Kext Patches -> KernelToPatch
Find: 554889e5 5350bb01 00000083 3d9227370000751d 4885ff
Replace: 4831c0c3 5350bb00 00000083 3d9227370000751d 4885ff

Verified working on my GTX970 and 10.12.6 PB
 

UtterDisbelief

Moderator
Joined
Feb 13, 2012
Messages
2,433
Motherboard
Gigabyte Z370M D3H
CPU
i3-8350K
Graphics
RX 560
Mac
iMac, Mac mini
Classic Mac
eMac, iBook
Mobile Phone
iOS
Hi @mlg and @zakklol :)

Thanks both for your efforts on this ...

Very much appreciated :)

Sadly I'm still getting a transparent window in iBooks. I've double-checked my copy-n-pasting, checked it's in the correct section etc. Rebooted twice ...

Don't currently have Xcode installed so could only try the config.plist method.

Great to be so close at last though :)
 
Last edited:

mlg

Joined
Feb 28, 2011
Messages
13
Motherboard
ASUS MAXIMUS VII IMPACT
CPU
Intel Core i7-4790
Graphics
ASUS NVIDIA GTX 1080
Thanks for testing everyone.

@zakklol, your configuration unfortunately will not work on anything but your specific kernel version (of the preview release), and neither is it possible to create a reliable Clover kernel patcher configuration for our scenario. This is why I chose to write a kernel extension instead (should have mentioned it - sorry.)

The reason why Clover can't handle it is that immediately after the generic function header, you'll find a reference to the global variable _cs_library_val_enable. That variable's address changes per kernel release.

@UtterDisbelief, do you have the option to install Xcode and test the kernel extension instead?
 
Joined
Apr 27, 2014
Messages
4
Motherboard
Asus Z390-A
CPU
i9-9900K
Graphics
UHD 630+RX 580
Mac
MacBook Pro
Mobile Phone
iOS
@mlg
thank you so much, working great!
 

mlg

Joined
Feb 28, 2011
Messages
13
Motherboard
ASUS MAXIMUS VII IMPACT
CPU
Intel Core i7-4790
Graphics
ASUS NVIDIA GTX 1080

UtterDisbelief

Moderator
Joined
Feb 13, 2012
Messages
2,433
Motherboard
Gigabyte Z370M D3H
CPU
i3-8350K
Graphics
RX 560
Mac
iMac, Mac mini
Classic Mac
eMac, iBook
Mobile Phone
iOS
Thanks for testing everyone.

@zakklol, your configuration unfortunately will not work on anything but your specific kernel version (of the preview release), and neither is it possible to create a reliable Clover kernel patcher configuration for our scenario. This is why I chose to write a kernel extension instead (should have mentioned it - sorry.)

The reason why Clover can't handle it is that immediately after the generic function header, you'll find a reference to the global variable _cs_library_val_enable. That variable's address changes per kernel release.

@UtterDisbelief, do you have the option to install Xcode and test the kernel extension instead?
Hello @mlg

Thanks for the beta pre-compiled binary kext. I'll be able to install Xcode tomorrow, however ...

I've just downloaded the kext and YES it works! :thumbup: (I'm running the system as per my profile and macOS 10.12.5)

Great work on this. Really appreciated.

I was a little daring though and have installed it in EFI/CLOVER/kexts/Other instead. However, if that causes problems, I can always move it to /Library/Extensions.

:)
 
Joined
Oct 9, 2016
Messages
12
Motherboard
ASUS Z170I Pro Gaming
CPU
i7-6700
Graphics
Zotac NVIDIA GTX 750
Mac
MacBook Air
Mobile Phone
Android, iOS
Thank you so much! It works perfectly for me.

From the bare source code I could not understand how it works. Would it be possible to build a live switch for this?
 
Top