How to remove Windows and hide Tools and have a Clean OpenCore Boot Menu?

How to remove Windows and hide Tools and have a Clean OpenCore Boot Menu?

https://preview.redd.it/2q59a0qw49q61.jpg?width=460&format=pjpg&auto=webp&s=c31e1ce8bb3bc4b04cdbf5d42c2858a2c70a255f

We'll use OpenCore Post-Install guide to achieve what we want. Under Security > ScanPolicy it explains us how OC gets items and lists them in the Boot Picker. It scans Devices and File Systems with the config value we enter. Installation guide recommends us to set it to 0 which scans and lists all possible options. What the guide does not tell us is how to hide Windows for instance but now we know how to exclude it.

Guide says:

By default, ScanPolicy is given a value of 0x10F0103 (17,760,515) which is the combination of the following: OC_SCAN_FILE_SYSTEM_LOCK OC_SCAN_DEVICE_LOCK OC_SCAN_ALLOW_FS_APFS OC_SCAN_ALLOW_DEVICE_SATA OC_SCAN_ALLOW_DEVICE_SASEX OC_SCAN_ALLOW_DEVICE_SCSI OC_SCAN_ALLOW_DEVICE_NVME OC_SCAN_ALLOW_DEVICE_PCI 

And gives us an example how to add more scan options like:

And lets just say for this example that you want to add OC_SCAN_ALLOW_DEVICE_USB: 0x00200000 + 0x10F0103 = 0x12F0103 And converting this to decimal gives us 19,857,667 

So, default value is calculated by adding up all 8 hexadecimal values. And in the example scanning USB device option is added. We should remember to convert hex values to decimal before copying it to the config.plist file.

At this point I wanted to add booting from Time Machine option too and in order to do that we need to add OC_SCAN_ALLOW_FS_HFS:

0x12F0103 + 0x00000200 = 0x12F0303 

0x12F0103 is the hex value we got after adding USB option above. 0x00000200 is HFS value, adding them up gives us 0x12F0303.

For calculations we need hexadecimal calculator, OC guide recommends us using macOS calculator (⌘+3 activates hex mode) but we can use google search for the calculation too. Just search 0x12F0103 + 0x00000200 and it'll list the total for us. As for decimal conversion I used Hackintool calculator. You can do it with online converters as well.

Decimal Conversion:

0x12F0303 = 19858179 

Now we need to add 19858179 in to Misc -> Security -> ScanPolicy and save the config.plist. Once we restart we won't see Windows any longer.

Also, if we want to have a Clean Boot Menu list we can set Misc -> Boot -> HideAuxiliary to True/Yes. With this config only macOS item will be listed and other items like Recovery, Reset NVRAM etc. will be available if we press Space Bar.

We can customize it even more if we like. For instance, if we don't want SASEX, SCSI and PCI to be scanned and therefore excluded as we don't need them, we should only add up the other options.

OC_SCAN_FILE_SYSTEM_LOCK 0x00000001 (bit 0) OC_SCAN_DEVICE_LOCK 0x00000002 (bit 1) OC_SCAN_ALLOW_FS_APFS 0x00000100 (bit 8) OC_SCAN_ALLOW_FS_HFS 0x00000200 (bit 9) OC_SCAN_ALLOW_DEVICE_SATA 0x00010000 (bit 16) OC_SCAN_ALLOW_DEVICE_NVME 0x00080000 (bit 19) OC_SCAN_ALLOW_DEVICE_USB 0x00200000 (bit 21) 

If you don't have SATA you can exclude it too or have SATA but don't have NVME, it can be excluded too. Let's calculate the values above.

0x00000001 + 0x00000002 + 0x00000100 + 0x00000200 + 0x00010000 + 0x00080000 + 0x00200000 = 0x290303 

Decimal Conversion:

0x290303 = 2687747 

You can play with other values by checking the Post-Install Guide by yourself.

Cheers!

submitted by /u/archangelique
[link] [comments]