components/pam_pkcs11/patches/05-upgrade_bug_fix.patch
author Huie-Ying Lee <huieying.lee@oracle.com>
Wed, 02 Nov 2016 20:44:19 -0700
changeset 7240 66893879cb20
permissions -rw-r--r--
24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit 24790022 Fix spelling and grammar errors in pam_pkcs11.c messages 24766229 add module specification requirement to the pam_pkcs11(7) man page 24897765 err_display_time and quiet options are placed incorrectly in pam_pkcs11.conf 24790509 pam_pkcs11 will fail after upgrade to s12 if openldap_mapper.so is used
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
7240
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     1
#
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     2
# In S11U3 releases, two versions of LDAP mapper modules are provided:
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     3
# - ldap_mapper.so (built with Mozilla LDAP)
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     4
# - openldap_mapper.so (built with OpenLDAP)
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     5
#
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     6
# However, on S12, because Mozilla LDAP is EOL'ed, only one LDAP mapper module
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     7
# is provided:
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     8
# - ldap_mapper.so (built with OpenLDAP)
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
     9
#
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    10
# If openldap_mapper.so is used in pam_pkcs11.conf on S11U3, then pam_pkcs11
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    11
# will fail to load the LDAP module after upgrade to S12. 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    12
#
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    13
# To resolve this upgrade issue, on S12, if openldap_mapper.so is specified in 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    14
# pam_pkcs11.conf file, then we will load ldap_mapper.so instead. 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    15
#
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    16
# This patch is Solaris specific and is for S12+ only. 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    17
#
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    18
--- pam_pkcs11-0.6.8_ISA/src/pam_pkcs11/mapper_mgr.c	Thu Oct 13 15:01:46 2016
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    19
+++ pam_pkcs11-0.6.8_NEW/src/pam_pkcs11/mapper_mgr.c	Tue Nov  1 20:09:41 2016
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    20
@@ -42,6 +42,41 @@
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    21
 #include <sys/param.h>
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    22
 #endif
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    23
 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    24
+#ifdef UPGRADE_BUG_FIX
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    25
+#include <sys/utsname.h>
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    26
+#include <strings.h>
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    27
+#include <libgen.h>
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    28
+#include <syslog.h>
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    29
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    30
+#define LDAP_MAPPER_MODULE "ldap_mapper.so"
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    31
+#define OPENLDAP_MAPPER_MODULE "openldap_mapper.so"
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    32
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    33
+/*
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    34
+ * Return 1, if the system is running S12 or later, otherwise return 0.
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    35
+ */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    36
+static int is_S12(void) {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    37
+	struct utsname unstr;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    38
+	struct utsname *un = &unstr;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    39
+	char *ptr;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    40
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    41
+	(void) uname(un);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    42
+	DBG1("System is %s\n", un->release);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    43
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    44
+	/* Make sure the major number is 5 */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    45
+	ptr = un->release;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    46
+	if (strncmp(ptr, "5", 1) != 0)
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    47
+	    return 0;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    48
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    49
+	/* Check the minor number */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    50
+	ptr = ptr + 2; 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    51
+	if (atoi(ptr) >= 12) {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    52
+	    return 1;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    53
+	} else {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    54
+	    return 0;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    55
+	}
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    56
+}
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    57
+#endif /* UPGRADE_BUG_FIX */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    58
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    59
 struct mapper_listitem *root_mapper_list;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    60
 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    61
 /*
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    62
@@ -100,17 +135,49 @@
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    63
 	    }
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    64
 	} else if (blk) { /* assume dynamic module */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    65
 	    DBG1("Loading dynamic module for mapper '%s'",name);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    66
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    67
 #ifdef MODULE_ISA_FIX
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    68
 	    if (expand_isa_path(libname, real_libname, sizeof (real_libname))) {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    69
 	        DBG1("Problem in module path %s", libname);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    70
                 return NULL;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    71
 	    } else {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    72
-	        DBG1("Module path is %s", real_libname);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    73
+		DBG1("Module path is %s", real_libname);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    74
 	    }
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    75
-	    handler= dlopen(real_libname, RTLD_NOW);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    76
-#else
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    77
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    78
+#ifdef UPGRADE_BUG_FIX
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    79
+	    /*
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    80
+	     * If the system is running S12+ and openldap_mapper.so is used
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    81
+	     * for the ldap mapper module, then we will replace it with
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    82
+	     * ldap_mapper.so.
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    83
+	     */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    84
+	    if (is_S12() && (strcmp(name, "ldap") == 0) && 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    85
+	      (strcmp(basename(real_libname), OPENLDAP_MAPPER_MODULE) == 0)) {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    86
+		char tmp_libname[MAXPATHLEN];
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    87
+		int len1, len2;
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    88
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    89
+		len1 = strlen(real_libname);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    90
+		len2 = strlen(OPENLDAP_MAPPER_MODULE);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    91
+		(void) strlcpy(tmp_libname, real_libname, len1 - len2 + 1);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    92
+		(void) strlcat(tmp_libname, LDAP_MAPPER_MODULE, MAXPATHLEN);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    93
+		(void) strncpy(real_libname, tmp_libname, MAXPATHLEN);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    94
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    95
+		syslog(LOG_ERR,"pam_pkcs11: openldap_mapper.so is not "
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    96
+		  "available on S12, so ldap_mapper.so is loaded instead, "
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    97
+		  "because ldap_mapper.so is built with OpenLDAP libraries "
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    98
+		  "on S12.");
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
    99
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   100
+		DBG("Warning: openldap_mapper.so is not available on S12, so "
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   101
+		  "ldap_mapper.so is loaded instead, because ldap_mapper.so "
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   102
+		  "is built with OpenLDAP libraries on S12.");
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   103
+        		
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   104
+		DBG1("Module path is changed to %s", real_libname);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   105
+	    } 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   106
+#endif /* UPGRADE_BUG_FIX */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   107
+	    handler= dlopen(real_libname,RTLD_NOW);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   108
+#else 
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   109
 	    handler= dlopen(libname,RTLD_NOW);
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   110
-#endif
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   111
+#endif /* MODULE_ISA_FIX */
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   112
+
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   113
 	    if (!handler) {
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   114
 		DBG3("dlopen failed for module:  %s path: %s Error: %s",name,libname,dlerror());
66893879cb20 24766235 Change to build PAM_PKCS11 with the pcsclite=yes option for 32 bit
Huie-Ying Lee <huieying.lee@oracle.com>
parents:
diff changeset
   115
 		return NULL;