]> arthur.barton.de Git - ngircd-alex.git/blobdiff - src/ngircd/pam.c
Update #include's: remove unused and add missing ones
[ngircd-alex.git] / src / ngircd / pam.c
index 6382c594db0747f5872b7042cb553713d3abd4f1..cfaa508f9a8e34d2b60306b1621b88d7da81fcb1 100644 (file)
 
 /**
  * @file
- * PAM User Authentification
+ * PAM User Authentication
  */
 
-#include "imp.h"
 #include <assert.h>
-
-#include "defines.h"
-#include "log.h"
-#include "conn.h"
-#include "client.h"
-
 #include <stdlib.h>
 #include <string.h>
-
 #ifdef HAVE_SECURITY_PAM_APPL_H
-#include <security/pam_appl.h>
+# include <security/pam_appl.h>
 #endif
-
 #ifdef HAVE_PAM_PAM_APPL_H
-#include <pam/pam_appl.h>
+# include <pam/pam_appl.h>
 #endif
 
-#include "exp.h"
+#include "defines.h"
+#include "log.h"
+#include "conn.h"
+#include "client.h"
+
 #include "pam.h"
 
 static char *password;
@@ -87,7 +82,7 @@ static struct pam_conv conv = {
 };
 
 /**
- * Authenticate a connectiong client using PAM.
+ * Authenticate a connecting client using PAM.
  * @param Client The client to authenticate.
  * @return true when authentication succeeded, false otherwise.
  */
@@ -102,8 +97,8 @@ PAM_Authenticate(CLIENT *Client) {
        /* Set supplied client password */
        if (password)
                free(password);
-       password = strdup(Client_Password(Client));
-       conv.appdata_ptr = Client_Password(Client);
+       password = strdup(Conn_Password(Client_Conn(Client)));
+       conv.appdata_ptr = Conn_Password(Client_Conn(Client));
 
        /* Initialize PAM */
        retval = pam_start("ngircd", Client_OrigUser(Client), &conv, &pam);