macOS: sudo with touch ID: survive upgrades
• 86 words • 1 min • updated
⚠️ This post is over one year old. It may no longer be up to date or relevant. Opinions may have changed.
Recent macbooks have a fingerprint reader, which is typically used to unlock the computer and log in.
It is also possible to use it for sudo authentication via PAM.
This was previously covered here.
Now, with macOS Sonoma, it’s also possible to make this setting survive OS upgrades.
shell
% sudo cp /etc/pam.d/sudo_local{.template,}
% sudo $EDITOR /etc/pam.d/sudo_localThen uncomment (or add, if not existing) the following line:
auth sufficient pam_tid.soYou can test it out by opening a new terminal and executing sudo echo.
Credits: https://sixcolors.com/post/2023/08/in-macos-sonoma-touch-id-for-sudo-can-survive-updates/