(file) Return to cimserver.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Server

Diff for /pegasus/src/Server/cimserver.cpp between version 1.157 and 1.158

version 1.157, 2005/03/23 03:00:44 version 1.158, 2005/04/04 21:27:32
Line 987 
Line 987 
 #endif #endif
     }     }
  
       // Bug 2148 - Here is the order of operations for determining the server HTTP and HTTPS ports.
       // 1) If the user explicitly specified a port, use it.
       // 2) If the user did not specify a port, get the port from the services file.
       // 3) If no value is specified in the services file, use the IANA WBEM default port.
       // Note that 2 and 3 are done within the System::lookupPort method
       // An empty string from the ConfigManager implies that the user did not specify a port.
   
     Uint32 portNumberHttps=0;     Uint32 portNumberHttps=0;
     Uint32 portNumberHttp=0;     Uint32 portNumberHttp=0;
     Uint32 portNumberExportHttps=0;     Uint32 portNumberExportHttps=0;
Line 994 
Line 1001 
     if (enableHttpsConnection)     if (enableHttpsConnection)
     {     {
         String httpsPort = configManager->getCurrentValue("httpsPort");         String httpsPort = configManager->getCurrentValue("httpsPort");
           if (httpsPort == String::EMPTY)
           {
               //
               // Look up the WBEM-HTTPS port number
               //
               portNumberHttps = System::lookupPort(WBEM_HTTPS_SERVICE_NAME, WBEM_DEFAULT_HTTPS_PORT);
   
           } else
           {
               //
               // user-specified
               //
         CString portString = httpsPort.getCString();         CString portString = httpsPort.getCString();
         char* end = 0;         char* end = 0;
         Uint32 port = strtol(portString, &end, 10);              portNumberHttps = strtol(portString, &end, 10);
         if(!(end != 0 && *end == '\0'))         if(!(end != 0 && *end == '\0'))
         {         {
             PEGASUS_STD(cerr) << "Bad HTTPS Port Value" << PEGASUS_STD(endl);             PEGASUS_STD(cerr) << "Bad HTTPS Port Value" << PEGASUS_STD(endl);
             exit(1);             exit(1);
         }         }
           }
   
         //  
         // Look up the WBEM-HTTPS port number  
         //  
         portNumberHttps = System::lookupPort(WBEM_HTTPS_SERVICE_NAME, port);  
     }     }
  
     if (enableHttpConnection)     if (enableHttpConnection)
     {     {
         String httpPort = configManager->getCurrentValue("httpPort");         String httpPort = configManager->getCurrentValue("httpPort");
           if (httpPort == String::EMPTY)
           {
               //
               // Look up the WBEM-HTTP port number
               //
               portNumberHttp = System::lookupPort(WBEM_HTTP_SERVICE_NAME, WBEM_DEFAULT_HTTP_PORT);
   
           } else
           {
               //
               // user-specified
               //
         CString portString = httpPort.getCString();         CString portString = httpPort.getCString();
         char* end = 0;         char* end = 0;
         Uint32 port = strtol(portString, &end, 10);              portNumberHttp = strtol(portString, &end, 10);
         if(!(end != 0 && *end == '\0'))         if(!(end != 0 && *end == '\0'))
         {         {
             PEGASUS_STD(cerr) << "Bad HTTP Port Value" << PEGASUS_STD(endl);             PEGASUS_STD(cerr) << "Bad HTTP Port Value" << PEGASUS_STD(endl);
             exit(1);             exit(1);
         }         }
         //  
         // Look up the WBEM-HTTP port number  
         //  
         portNumberHttp = System::lookupPort(WBEM_HTTP_SERVICE_NAME, port);  
     }     }
       }
   
  
     if (enableSSLExportClientVerification)     if (enableSSLExportClientVerification)
     {     {


Legend:
Removed from v.1.157  
changed lines
  Added in v.1.158

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2