Pluggable Authentication Module

The Pluggable Authentication Module (PAM) is an authentication tool that allows users to use their network password with the sudo command rather than their local password. PAM is included in all installations of Jamf Connect and stored on computers in the following location:


Important: It is recommended that you first test workflows with the PAM in an environment other than your production environment.

Enabling the Pluggable Authentication Module

Complete the following to enable the Pluggable Authentication Module (PAM):

  1. (Okta Only) Execute the following authchanger command to enable PAM authentication with Jamf Connect:

    /usr/local/bin/authchanger -DefaultJCRight
  2. Configure PAM module preferences in your configuration profile. For more information, see the Pluggable Authentication Module (PAM) Settings.

  3. In Terminal, access the PAM configuration profile by executing the following command:

    sudo vi /etc/pam.d/sudo

  4. Enter your local password.

  5. Enter edit mode and do one of the following:

    Note: A warning may display when attempting to edit a read-only file. Continue to edit the file, and then refer to step 6 to save your changes.

    1. To allow (but not require) network authentication for sudo commands, add the following entry:

      auth sufficient


    2. To require network authentication for sudo commands, do the following:

      1. Add the following entry:

        auth required

      2. Comment out the entry by adding a pound symbol (#) at the beginning of that line.


  6. Press the Escape key to exit the editor mode, and then write and quit the read-only file by executing the following command at the bottom of the Terminal window:


    Your cursor should automatically move to the bottom of the Terminal window after you exit editor mode.

The PAM module should now prompt users to authenticate with your IdP any time a sudo command is attempted.

Pluggable Authentication Module User Experience

If the Pluggable Authentication Module (PAM) is enabled, you can use the sudo command to authenticate with your cloud identity provider (IdP).

  1. In Terminal, execute any sudo command, such as the following:

    sudo -s

    Your IdP's login screen should display.


  2. Enter your network username and password to authenticate.

    Note: If you configured network authentication to be sufficient but not required, closing the login window will cause macOS to prompt you to enter your password in Terminal instead. If you configured network authentication to be required, closing the login window will cause authentication to fail.

    Once authenticated, the sudo command should successfully execute in Terminal.

Pluggable Authentication Module (PAM) Settings

Domain: com.jamf.connect.login

Description: Used to enable PAM authentication on computers.





Identity Provider (PAM)

Specifies the identity provider to use for authentication via the Pluggable Authentication Module (PAM)




Client ID (PAM)

The client ID of the created Jamf Connect app in your identity provider used for authentication via PAM




Redirect URI (PAM)

The redirect URI used by the created Jamf Connect app in your identity provider




Tenant ID (PAM)

The tenant in your identity provider used for authentication via PAM

Note: If Okta is your IdP, this key is required.




Client Secret (PAM)

The client secret of your Jamf Connect app in your IdP. This value is only known by Jamf Connect and your IdP.



Copyright     Privacy Policy     Terms of Use     Security
© copyright 2002-2020 Jamf. All rights reserved.