New Feature: Local MDM Bypass for Dual-Boot macOS Setups (with sudo access) - #74
New Feature: Local MDM Bypass for Dual-Boot macOS Setups (with sudo access)#74peterrakolcza wants to merge 1 commit into
Conversation
…with Sudo Privileges
|
Dear @assafdori, Any progress on this PR? |
|
This is awesome Thanks! |
Revisão técnica do PR #74 — Dual-boot@peterrakolcza, ideia útil para o cenário de dual-boot. Porém encontrei alguns problemas no código: Bugs encontrados
Problema conceitualO script é para ser executado do macOS instalado (com sudo), não do Recovery. As opções do menu dizem "Bypass MDM from Recovery" mas a descrição do PR diz que roda com sudo. Inconsistência que confunde o usuário. Sugestões
Conflito de mergeO PR está marcado como CONFLICTING — precisa de rebase com a main atual. |
|
Hey @peterrakolcza, the dual-boot idea is neat — having a separate personal install alongside the company-managed one is something a lot of devs ask for. I found a few bugs when I tested the script locally though: 1. Typo in volume name: you wrote 2. Missing rm -rf "/Volumes/$baseVolume/db/ConfigurationProfiles/Settings/..."Should be: rm -rf "/Volumes/$baseVolume/var/db/ConfigurationProfiles/Settings/..."3. Color code bug: in the error messages you use echo -e "${RED}Error: ... ${RED}" # should be ${NC}4. System volume vs Data volume: This writes to 5. Menu option naming: The option says "Bypass MDM from Recovery" but the script is meant to run from the enrolled macOS (with sudo), not Recovery. Thats confusing. Also heads up — the PR is showing as CONFLICTING with main, so itll need a rebase. Ive got a fixed version if you want me to share it. |
Summary
This update adds a new script and section to the documentation that explains how to bypass MDM locally when you already have access to an enrolled macOS installation with sudo privileges—enabling a dual-boot setup with a personal, unmanaged macOS installation.
Use Case
Imagine you’ve received an MDM-enrolled Mac from your company. As a developer or technical user, you might have been granted sudo privileges to perform necessary tasks. However, you may want to:
Dual-booting is the perfect solution in this scenario.
Problem
When attempting to install a fresh copy of macOS on a new partition and boot into Recovery Mode for that new installation, macOS throws this error:
As a result, you’re unable to access recovery mode on the fresh install and cannot run the MDM bypass script from there.
Solution
This PR introduces a new script and documentation for the new method:
Run the bypass script directly from the enrolled OS, using
sudo, to modify the second, freshly installed macOS volume.This was successfully tested on an Macbook Pro with M4 Pro running macOS Sequoia 15.5.
Benefits