{"id":3295,"date":"2022-12-20T17:02:16","date_gmt":"2022-12-20T20:02:16","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/pam_winbind-man8\/"},"modified":"2022-12-20T17:02:16","modified_gmt":"2022-12-20T20:02:16","slug":"pam_winbind-man8","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/pam_winbind-man8\/","title":{"rendered":"PAM_WINBIND (man8)"},"content":{"rendered":"<h1 align=\"center\">PAM_WINBIND<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#DESCRIPTION\">DESCRIPTION<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#OPTIONS\">OPTIONS<\/a><br \/> <a href=\"#PAM DATA EXPORTS\">PAM DATA EXPORTS<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a><br \/> <a href=\"#VERSION\">VERSION<\/a><br \/> <a href=\"#AUTHOR\">AUTHOR<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">pam_winbind \u2212 PAM module for Winbind<\/p>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">This tool is part of the <b>samba<\/b>(7) suite.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">pam_winbind is a PAM module that can authenticate users against the local domain by talking to the Winbind daemon.<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Edit the PAM system config \/etc\/pam.d\/service and modify it as the following example shows:<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>&#8230;<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>auth required pam_env.so<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>auth sufficient pam_unix2.so<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>+++ auth required pam_winbind.so use_first_pass<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>account requisite pam_unix2.so<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>+++ account required pam_winbind.so use_first_pass<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>+++ password sufficient pam_winbind.so<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>password requisite pam_pwcheck.so cracklib<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>password required pam_unix2.so use_authtok<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>session required pam_unix2.so<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>+++ session required pam_winbind.so<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"8%\"><\/td>\n<td width=\"69%\">\n<p>&#8230;<\/p>\n<\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:11%; margin-top: 1em\">Make sure that pam_winbind is one of the first modules in the session part. It may retrieve kerberos tickets which are needed by other modules.<\/p>\n<h2>OPTIONS <a name=\"OPTIONS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">pam_winbind supports several options which can either be set in the PAM configuration files or in the pam_winbind configuration file situated at \/etc\/security\/pam_winbind.conf. Options from the PAM configuration file take precedence to those from the configuration file. See <b>pam_winbind.conf<\/b>(5) for further details.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">debug<\/p>\n<p style=\"margin-left:17%;\">Gives debugging output to syslog.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">debug_state<\/p>\n<p style=\"margin-left:17%;\">Gives detailed PAM state debugging output to syslog.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">require_membership_of=[SID or NAME]<\/p>\n<p style=\"margin-left:17%;\">If this option is set, pam_winbind will only succeed if the user is a member of the given SID or NAME. A SID can be either a group\u2212SID, an alias\u2212SID or even an user\u2212SID. It is also possible to give a NAME instead of the SID. That name must have the form: <i>MYDOMAINmygroup<\/i> or <i>MYDOMAINmyuser<\/i> (where &#8221; character corresponds to the value of <i>winbind separator<\/i> parameter). It is also possible to use a UPN in the form <i>user@REALM<\/i> or <i>group@REALM<\/i>. pam_winbind will, in that case, lookup the SID internally. Note that NAME may not contain any spaces. It is thus recommended to only use SIDs. You can verify the list of SIDs a user is a member of with wbinfo \u2212\u2212user\u2212sids=SID.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">This option must only be specified on a auth module declaration, as it only operates in conjunction with password authentication.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">use_first_pass<\/p>\n<p style=\"margin-left:17%;\">By default, pam_winbind tries to get the authentication token from a previous module. If no token is available it asks the user for the old password. With this option, pam_winbind aborts with an error if no authentication token from a previous module is available.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">try_first_pass<\/p>\n<p style=\"margin-left:17%;\">Same as the use_first_pass option (previous item), except that if the primary password is not valid, PAM will prompt for a password.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">use_authtok<\/p>\n<p style=\"margin-left:17%;\">Set the new password to the one provided by the previously stacked password module. If this option is not set pam_winbind will ask the user for the new password.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">try_authtok<\/p>\n<p style=\"margin-left:17%;\">Same as the use_authtok option (previous item), except that if the new password is not valid, PAM will prompt for a password.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">krb5_auth<\/p>\n<p style=\"margin-left:17%;\">pam_winbind can authenticate using Kerberos when winbindd is talking to an Active Directory domain controller. Kerberos authentication must be enabled with this parameter. When Kerberos authentication can not succeed (e.g. due to clock skew), winbindd will fallback to samlogon authentication over MSRPC. When this parameter is used in conjunction with <i>winbind refresh tickets<\/i>, winbind will keep your Ticket Granting Ticket (TGT) up\u2212to\u2212date by refreshing it whenever necessary.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">krb5_ccache_type=[type]<\/p>\n<p style=\"margin-left:17%;\">When pam_winbind is configured to try kerberos authentication by enabling the <i>krb5_auth<\/i> option, it can store the retrieved Ticket Granting Ticket (TGT) in a credential cache. The type of credential cache can be controlled with this option. The supported values are: <i>KCM<\/i> or <i>KEYRING<\/i> (when supported by the system&#8217;s Kerberos library and operating system), <i>FILE<\/i> and <i>DIR<\/i> (when the DIR type is supported by the system&#8217;s Kerberos library). In case of FILE a credential cache in the form of \/tmp\/krb5cc_UID will be created \u2212 in case of DIR you NEED to specify a directory which must exist, the UID directory will be created in the specified directory. In all cases UID is replaced with the numeric user id. Check the details of the Kerberos implementation.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">When using the KEYRING type, the supported mechanism is \u201cKEYRING:persistent:UID\u201d, which uses the Linux kernel keyring to store credentials on a per\u2212UID basis. KEYRING has limitations. For example, it is secure kernel memory, so bulk storage of credentials is not possible.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">When using the KCM type, the supported mechanism is \u201cKCM:UID\u201d, which uses a Kerberos credential manager to store credentials on a per\u2212UID basis similar to KEYRING. This is the recommended choice on latest Linux distributions that offer a Kerberos Credential Manager. If not, we suggest to use KEYRING, as those are the most secure and predictable method.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">It is also possible to define custom filepaths and use the &#8220;%u&#8221; pattern in order to substitute the numeric user id. Examples:<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">krb5_ccache_type = DIR:\/run\/user\/%u\/krb5cc<\/p>\n<p style=\"margin-left:23%;\">This will create a credential cache file in the specified directory.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">krb5_ccache_type = FILE:\/tmp\/krb5cc_%u<\/p>\n<p style=\"margin-left:23%;\">This will create a credential cache file.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">Leave empty to just do kerberos authentication without having a ticket cache after the logon has succeeded. This setting is empty by default.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">cached_login<\/p>\n<p style=\"margin-left:17%;\">Winbind allows one to logon using cached credentials when <i>winbind offline logon<\/i> is enabled. To use this feature from the PAM module this option must be set.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">silent<\/p>\n<p style=\"margin-left:17%;\">Do not emit any messages.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">mkhomedir<\/p>\n<p style=\"margin-left:17%;\">Create homedirectory for a user on\u2212the\u2212fly, option is valid in PAM session block.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">warn_pwd_expire<\/p>\n<p style=\"margin-left:17%;\">Defines number of days before pam_winbind starts to warn about passwords that are going to expire. Defaults to 14 days.<\/p>\n<h2>PAM DATA EXPORTS <a name=\"PAM DATA EXPORTS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">This section describes the data exported in the PAM stack which could be used in other PAM modules.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">PAM_WINBIND_HOMEDIR<\/p>\n<p style=\"margin-left:17%;\">This is the Windows Home Directory set in the profile tab in the user settings on the Active Directory Server. This could be a local path or a directory on a share mapped to a drive.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">PAM_WINBIND_LOGONSCRIPT<\/p>\n<p style=\"margin-left:17%;\">The path to the logon script which should be executed if a user logs in. This is normally a relative path to the script stored on the server.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">PAM_WINBIND_LOGONSERVER<\/p>\n<p style=\"margin-left:17%;\">This exports the Active Directory server we are authenticating against. This can be used as a variable later.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">PAM_WINBIND_PROFILEPATH<\/p>\n<p style=\"margin-left:17%;\">This is the profile path set in the profile tab in the user settings. Normally the home directory is synced with this directory on a share.<\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>pam_winbind.conf<\/b>(5), <b>wbinfo<\/b>(1), <b>winbindd<\/b>(8), <b>smb.conf<\/b>(5)<\/p>\n<h2>VERSION <a name=\"VERSION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">This man page is part of version 4.14.14 of Samba.<\/p>\n<h2>AUTHOR <a name=\"AUTHOR\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">The original Samba software and related utilities were created by Andrew Tridgell. Samba is now developed by the Samba Team as an Open Source project similar to the way the Linux kernel is developed.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">This manpage was written by Jelmer Vernooij and Guenther Deschner.<\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  pam_winbind \u2212 PAM module for Winbind <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[5,52,4,428],"class_list":["post-3295","post","type-post","status-publish","format-standard","hentry","category-8-administracion-del-sistema","tag-5","tag-administracion","tag-man8","tag-pam_winbind"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/3295","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=3295"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/3295\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=3295"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=3295"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=3295"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}