[Fedora-directory-commits] ldapserver/ldap/servers/slapd daemon.c, 1.9, 1.10 globals.c, 1.4, 1.5 libglobs.c, 1.12, 1.13 localhost.c, 1.7, 1.8 main.c, 1.14, 1.15 ntuserpin.c, 1.7, 1.8 plugin_internal_op.c, 1.5, 1.6 pw.c, 1.11, 1.12 result.c, 1.8, 1.9 slap.h, 1.18, 1.19 ssl.c, 1.9, 1.10

Noriko Hosoi (nhosoi) fedora-directory-commits at redhat.com
Fri Nov 10 01:10:59 UTC 2006


Author: nhosoi

Update of /cvs/dirsec/ldapserver/ldap/servers/slapd
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv10781/ldap/servers/slapd

Modified Files:
	daemon.c globals.c libglobs.c localhost.c main.c ntuserpin.c 
	plugin_internal_op.c pw.c result.c slap.h ssl.c 
Log Message:
Resolves: #214728
Summary: Cleaning up obsolete macros in the build
Changes: eliminated macro NET_SSL (Comment #5)



Index: daemon.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/daemon.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- daemon.c	15 Sep 2006 22:45:11 -0000	1.9
+++ daemon.c	10 Nov 2006 01:10:57 -0000	1.10
@@ -83,9 +83,7 @@
 #include "snmp_collator.h"
 #include <private/pprio.h>
 
-#if defined( NET_SSL )
 #include <ssl.h>
-#endif /* defined(NET_SSL) */
 
 #include "fe.h"
 
@@ -1895,7 +1893,6 @@
 		*/
 	}
 
-#if defined(NET_SSL)
 	if( secure && config_get_SSLclientAuth() != SLAPD_SSLCLIENTAUTH_OFF ) { 
 	    /* Prepare to handle the client's certificate (if any): */
 		int rv;
@@ -1917,7 +1914,6 @@
 					conn->c_sd, rv, prerr);
 		}
 	}
-#endif
 
 	connection_reset(conn, ns, &from, sizeof(from), secure);
 


Index: globals.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/globals.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- globals.c	19 Apr 2005 22:07:36 -0000	1.4
+++ globals.c	10 Nov 2006 01:10:57 -0000	1.5
@@ -42,7 +42,6 @@
  *  SLAPD globals.c -- SLAPD library global variables
  */
 
-#if defined(NET_SSL)
 #include "ldap.h"
 #include <sslproto.h> /* cipher suite names */
 #include <ldap_ssl.h>
@@ -50,8 +49,6 @@
 #undef OFF
 #undef LITTLE_ENDIAN
 
-#endif
-
 #include <stdio.h>
 #include <string.h>
 #include <sys/types.h>


Index: libglobs.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/libglobs.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- libglobs.c	6 Nov 2006 19:33:42 -0000	1.12
+++ libglobs.c	10 Nov 2006 01:10:57 -0000	1.13
@@ -45,7 +45,6 @@
 */
 #define DONT_DECLARE_SLAPD_LDAP_DEBUG /* see ldaplog.h */
 
-#if defined(NET_SSL)
 #include "ldap.h"
 #include <sslproto.h>
 #include <ldap_ssl.h>
@@ -53,8 +52,6 @@
 #undef OFF
 #undef LITTLE_ENDIAN
 
-#endif
-
 #include <stdio.h>
 #include <string.h>
 #include <sys/types.h>


Index: localhost.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/localhost.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- localhost.c	19 Apr 2005 22:07:36 -0000	1.7
+++ localhost.c	10 Nov 2006 01:10:57 -0000	1.8
@@ -56,10 +56,8 @@
 #include <unistd.h>
 #endif /* USE_SYSCONF */
 
-#if defined( NET_SSL )
 #include <ssl.h>
 #include "fe.h"
-#endif /* defined(NET_SSL) */
 
 #ifndef _PATH_RESCONF /* usually defined in <resolv.h> */
 #define _PATH_RESCONF "/etc/resolv.conf"


Index: main.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/main.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- main.c	6 Nov 2006 19:33:42 -0000	1.14
+++ main.c	10 Nov 2006 01:10:57 -0000	1.15
@@ -36,11 +36,9 @@
  * All rights reserved.
  * END COPYRIGHT BLOCK **/
 
-#if defined(NET_SSL)
 #include <ldap.h>
 #undef OFF
 #undef LITTLE_ENDIAN
-#endif
 
 #include <stdio.h>
 #include <string.h>
@@ -108,9 +106,7 @@
 static int slapd_exemode_db2index();
 static int slapd_exemode_archive2db();
 static int slapd_exemode_db2archive();
-#if defined(UPGRADEDB)
 static int slapd_exemode_upgradedb();
-#endif
 static int slapd_exemode_dbtest();
 static int slapd_exemode_suffix2instance();
 static int slapd_debug_level_string2level( const char *s );
@@ -365,21 +361,15 @@
 	} else if ( strcmp( s, "suffix2instance" ) == 0 ) {
 		exemode = SLAPD_EXEMODE_SUFFIX2INSTANCE;
 	}
-#if defined(UPGRADEDB)
 	else if ( strcmp( s, "upgradedb" ) == 0 )
 	{
 		exemode = SLAPD_EXEMODE_UPGRADEDB;
 	}
-#endif
 	else if ( exit_if_unknown ) {
 		fprintf( stderr, "usage: %s -D configdir "
 				 "[ldif2db | db2ldif | archive2db "
 				 "| db2archive | db2index | refer | suffix2instance"
-#if defined(UPGRADEDB)
 				 " | upgradedb] "
-#else
-				 "] "
-#endif
 				 "[options]\n", progname );
 		exit( 1 );
 	} else {
@@ -436,11 +426,9 @@
     case SLAPD_EXEMODE_SUFFIX2INSTANCE:
 	usagestr = "usage: %s %s%s -D configdir {-s suffix}*\n";
 	break;
-#if defined(UPGRADEDB)
     case SLAPD_EXEMODE_UPGRADEDB:
 	usagestr = "usage: %s %s%s-D configdir [-d debuglevel] [-f] -a archivedir\n";
 	break;
-#endif
 
     default:	/* SLAPD_EXEMODE_SLAPD */
 	usagestr = "usage: %s %s%s-D configdir [-d debuglevel] "
@@ -480,9 +468,7 @@
 static int ldif2db_load_state= 1;
 static char *ldif2db_namespaceid = NULL;
 int importexport_encrypt = 0;
-#if defined(UPGRADEDB)
 static int upgradedb_force = 0;
-#endif
 
 /* taken from idsktune */
 #if defined(__sun)
@@ -956,10 +942,8 @@
 	case SLAPD_EXEMODE_SUFFIX2INSTANCE:
 		return slapd_exemode_suffix2instance();
 
-#if defined(UPGRADEDB)
 	case SLAPD_EXEMODE_UPGRADEDB:
 		return slapd_exemode_upgradedb();
-#endif
 
 	case SLAPD_EXEMODE_PRINTVERSION:
 		slapd_print_version(1);
@@ -1085,9 +1069,7 @@
 		normalize_oc();
 
 		if (n_port) {
-#if defined(NET_SSL)
 		} else if ( config_get_security()) {
-#endif
 		} else {
 #ifdef _WIN32	
 			if( SlapdIsAService() )
@@ -1327,7 +1309,6 @@
 		{"exclude",ArgRequired,'x'},
 		{0,0,0}};
 
-#if defined(UPGRADEDB)
 	char *opts_upgradedb = "vfd:a:D:"; 
 	struct opt_ext long_options_upgradedb[] = {
 		{"version",ArgNone,'v'},
@@ -1336,7 +1317,6 @@
 		{"archive",ArgRequired,'a'},
 		{"configDir",ArgRequired,'D'},
 		{0,0,0}};
-#endif
 
 	char *opts_referral = "vd:p:r:SD:"; 
 	struct opt_ext long_options_referral[] = {
@@ -1430,12 +1410,10 @@
 		opts = opts_suffix2instance;
 		long_opts = long_options_suffix2instance;
 		break;
-#if defined(UPGRADEDB)
 	case SLAPD_EXEMODE_UPGRADEDB:
 		opts = opts_upgradedb;
 		long_opts = long_options_upgradedb;
 		break;
-#endif
 	default:	/* SLAPD_EXEMODE_SLAPD */
 		opts = opts_slapd;
 		long_opts = long_options_slapd;
@@ -1755,7 +1733,6 @@
 			}
 			importexport_encrypt = 1;
 			break;			
-#if defined(UPGRADEDB)
 		case 'f':	/* upgradedb only */
 		    if ( slapd_exemode != SLAPD_EXEMODE_UPGRADEDB ) {
 				usage( myname, *extraname );
@@ -1763,7 +1740,6 @@
 			}
 			upgradedb_force = SLAPI_UPGRADEDB_FORCE;
 			break;			
-#endif
 		case '1':	/* db2ldif only */
 			if ( slapd_exemode != SLAPD_EXEMODE_DB2LDIF ) {
 				usage( myname, *extraname );
@@ -2500,7 +2476,6 @@
 	return return_value;
 }	
 
-#if defined(UPGRADEDB)
 /*
  * functions to convert idl from the old format to the new one
  * (604921) Support a database uprev process any time post-install
@@ -2575,7 +2550,6 @@
     slapi_ch_free((void**)&myname );
     return( return_value );
 }
-#endif
 
 
 static int


Index: ntuserpin.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/ntuserpin.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- ntuserpin.c	19 Apr 2005 22:07:36 -0000	1.7
+++ ntuserpin.c	10 Nov 2006 01:10:57 -0000	1.8
@@ -42,7 +42,7 @@
  *
  ******************************************************/
 
-#if defined( _WIN32 ) && defined ( NET_SSL )
+#if defined( _WIN32 )
 
 #include <windows.h>
 #include "ntwatchdog.h"
@@ -206,4 +206,4 @@
  */
 static const SVRCOREPinMethods vtable =
 { 0, 0, destroyObject, getPin };
-#endif /* defined( _WIN32 ) && defined ( NET_SSL ) */
+#endif /* defined( _WIN32 ) */


Index: plugin_internal_op.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/plugin_internal_op.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- plugin_internal_op.c	19 Apr 2005 22:07:36 -0000	1.5
+++ plugin_internal_op.c	10 Nov 2006 01:10:57 -0000	1.6
@@ -42,9 +42,7 @@
 #include "slapi-plugin.h"
 #include "slap.h"
 
-#if defined(NET_SSL)
 #include <ssl.h>
-#endif
 
 /* entry list node */
 typedef struct Entry_Node{


Index: pw.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/pw.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- pw.c	1 Sep 2006 21:25:08 -0000	1.11
+++ pw.c	10 Nov 2006 01:10:57 -0000	1.12
@@ -43,7 +43,6 @@
 #include <stdio.h>
 #include <string.h>
 #include <sys/types.h>
-#if defined(NET_SSL)
 #include <sechash.h>
 #if defined( _WIN32 )
 #undef DEBUG
@@ -52,8 +51,6 @@
 #undef LDAPDebug
 #endif	/*  _WIN32 */
 
-#endif /* NET_SSL */
-
 #include "slap.h"
 
 


Index: result.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/result.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- result.c	31 Aug 2006 22:52:07 -0000	1.8
+++ result.c	10 Nov 2006 01:10:57 -0000	1.9
@@ -53,10 +53,7 @@
 #include "fe.h"
 #include "vattr_spi.h"
 
-
-#if defined( NET_SSL )
 #include <ssl.h>
-#endif
 
 PRUint64 num_entries_sent;
 PRUint64 num_bytes_sent;


Index: slap.h
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/slap.h,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- slap.h	6 Nov 2006 20:51:31 -0000	1.18
+++ slap.h	10 Nov 2006 01:10:57 -0000	1.19
@@ -61,9 +61,7 @@
 #define SLAPD_EXEMODE_REFERRAL		8
 #define SLAPD_EXEMODE_SUFFIX2INSTANCE	9
 #define SLAPD_EXEMODE_PRINTVERSION     10
-#if defined(UPGRADEDB)
 #define SLAPD_EXEMODE_UPGRADEDB     11
-#endif
 
 #ifdef _WIN32
 #ifndef DONT_DECLARE_SLAPD_LDAP_DEBUG
@@ -119,7 +117,6 @@
 
 #define SLAPD_TYPICAL_ATTRIBUTE_NAME_MAX_LENGTH 256
 
-#if defined(NET_SSL)
 typedef struct symbol_t {
     const char* name;
     unsigned number;
@@ -129,7 +126,6 @@
 #define SLAPD_SSLCLIENTAUTH_ALLOWED  1 /* server asks for cert, but client need not send one */
 #define SLAPD_SSLCLIENTAUTH_REQUIRED 2 /* server will refuse SSL session unless client sends cert */
 #define SLAPD_SSLCLIENTAUTH_DEFAULT  SLAPD_SSLCLIENTAUTH_ALLOWED
-#endif /* NET_SSL */
 
 #define	SLAPD_LOGGING	1
 #define NUM_SNMP_INT_TBL_ROWS 5
@@ -768,9 +764,7 @@
 			IFP	plg_un_db_db2index;	  /* database 2 index */
 			IFP	plg_un_db_archive2db;	  /* ldif 2 database */
 			IFP	plg_un_db_db2archive;	  /* database 2 ldif */
-#if defined(UPGRADEDB)
 			IFP	plg_un_db_upgradedb;	  /* convert old idl to new */
-#endif
 			IFP	plg_un_db_begin;	  /* dbase txn begin */
 			IFP	plg_un_db_commit;	  /* dbase txn commit */
 			IFP	plg_un_db_abort;	  /* dbase txn abort */
@@ -805,9 +799,7 @@
 #define plg_db2index		plg_un.plg_un_db.plg_un_db_db2index
 #define plg_archive2db		plg_un.plg_un_db.plg_un_db_archive2db
 #define plg_db2archive		plg_un.plg_un_db.plg_un_db_db2archive
-#if defined(UPGRADEDB)
 #define plg_upgradedb		plg_un.plg_un_db.plg_un_db_upgradedb
-#endif
 #define plg_dbsize		plg_un.plg_un_db.plg_un_db_dbsize
 #define plg_dbtest		plg_un.plg_un_db.plg_un_db_dbtest
 #define plg_rmdb		plg_un.plg_un_db.plg_un_db_rmdb
@@ -1051,9 +1043,7 @@
 #define be_poststart		be_database->plg_poststart
 #define be_seq			be_database->plg_seq
 #define be_ldif2db		be_database->plg_ldif2db
-#if defined(UPGRADEDB)
 #define be_upgradedb		be_database->plg_upgradedb
-#endif
 #define be_db2ldif		be_database->plg_db2ldif
 #define be_db2index		be_database->plg_db2index
 #define be_archive2db	be_database->plg_archive2db


Index: ssl.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/ssl.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- ssl.c	13 Oct 2006 01:06:28 -0000	1.9
+++ ssl.c	10 Nov 2006 01:10:57 -0000	1.10
@@ -37,8 +37,6 @@
  * END COPYRIGHT BLOCK **/
 /* SSL-related stuff for slapd */
 
-#if defined(NET_SSL)
-
 #if defined( _WINDOWS )
 #include <windows.h>
 #include <winsock.h>
@@ -102,8 +100,6 @@
 /* ----------------------- Multiple cipher support ------------------------ */
 
 
-#ifdef NET_SSL
-
 static char **cipher_names = NULL;
 typedef struct {
 	char *version;
@@ -182,9 +178,7 @@
         if(active && !strcmp(_conf_ciphers[x].name, "rsa_null_md5"))  {
             continue;
         }
-#ifdef NET_SSL
         SSL_CipherPrefSetDefault(_conf_ciphers[x].num, active ? PR_TRUE : PR_FALSE);
-#endif
     }
 }
 
@@ -253,24 +247,12 @@
 
   SECStatus s = 0;
 
-
-#ifdef NS_DOMESTIC
-
-	s = NSS_SetDomesticPolicy();
-
-#else
-	s = NSS_SetExportPolicy();
-
-#endif
-
+  s = NSS_SetDomesticPolicy();
 
   return s?PR_FAILURE:PR_SUCCESS;
 
 }
 
-
-#endif /* NET_SSL */
-
 static void
 slapd_SSL_report(int degree, char *fmt, va_list args)
 {
@@ -1144,11 +1126,7 @@
     SSL_OptionSetDefault(SSL_ENABLE_SSL2, PR_FALSE);
 	SSL_OptionSetDefault(SSL_ENABLE_SSLdirs
 3, PR_TRUE);
-#ifdef NS_DOMESTIC
 	s = NSS_SetDomesticPolicy(); 
-#elif NS_EXPORT
-	s = NSS_SetExportPolicy(); 
-
 We already do pr_init, we don't need pr_setconcurrency, we already do nss_init and the rest
 
 */   
@@ -1511,5 +1489,3 @@
 #endif
 	return ( tmpdir );
 }
-
-#endif /* NET_SSL */




More information about the Fedora-directory-commits mailing list