Skip to content

Commit

Permalink
mac sudo touchid
Browse files Browse the repository at this point in the history
  • Loading branch information
Morgan Fouesneau committed Jun 14, 2024
1 parent 3891bff commit 4e83b98
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
5 changes: 4 additions & 1 deletion faq/_toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,14 @@ parts:
- file: chapters/python/parallel-code-slower
- file: chapters/python/fooocus


- caption: Straightline fitting problem
chapters:
- file: chapters/problems/straightline/README
- file: chapters/problems/straightline/straighlinefit_emcee.ipynb
- file: chapters/problems/straightline/straighlinefit_jax.ipynb
- file: chapters/problems/straightline/straighlinefit_pymc3.ipynb
- file: chapters/problems/straightline/straighlinefit_pystan.ipynb

- caption: Computing tips
chapters:
- file: chapters/computing/mac-touchid-sudo
25 changes: 25 additions & 0 deletions faq/chapters/computing/mac-touchid-sudo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Mac OS: How to Configure Touch ID for the `sudo` command

Touch ID can be used on Mac as a convenient way to authenticate without typing in your password. This is also possible in the terminal, especially for `sudo` commands.

To allow Touch ID on your Mac for sudo access instead of using a password, you need to edit the `pam.d` configuration files.

As root, edit `/etc/pam.d/sudo` and add at the top of the file the following line:

`auth sufficient pam_tid.so`

The contents of this file should look like this:

```shell
# sudo: auth account password session
auth sufficient pam_tid.so
auth sufficient pam_smartcard.so
auth required pam_opendirectory.so
account required pam_permit.so
password required pam_deny.so
session required pam_permit.so
```

If you then use `sudo` in the terminal, you should be prompted to authenticate with Touch ID.

**Source: https://apple.stackexchange.com/a/306324/409134**

0 comments on commit 4e83b98

Please sign in to comment.