In this example, we'll be patching /Library/Extensions/NVDAStartupWeb.kext/Contents/Info.plist
, replacing any occurrences of <string>17B1003</string>
with <string>17C88</string>
, allowing us to enable the Nvidia Web Driver on "unsupported" versions of macOS, such as newly released updates, without having to wait for an updated driver to become available.
It's very important to note that there are actually two spaces in the replacement value (Markdown doesn't display them correctly), as the character lengths of both values must always match. In this case it made more sense to add the spaces before rather than after, as they're most likely to already exist in the original Info.plist
.
This shows how you can encode both values to a base64 encoded string, which is the format that'll end up in the patch itself.