aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Server/Base/HttpServerBase.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Server/Base/HttpServerBase.cs30
1 files changed, 27 insertions, 3 deletions
diff --git a/OpenSim/Server/Base/HttpServerBase.cs b/OpenSim/Server/Base/HttpServerBase.cs
index 44ef124..a18cdc1 100644
--- a/OpenSim/Server/Base/HttpServerBase.cs
+++ b/OpenSim/Server/Base/HttpServerBase.cs
@@ -40,7 +40,7 @@ namespace OpenSim.Server.Base
40{ 40{
41 public class HttpServerBase : ServicesServerBase 41 public class HttpServerBase : ServicesServerBase
42 { 42 {
43// private static readonly ILog m_Log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 43 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
44 44
45 private uint m_consolePort; 45 private uint m_consolePort;
46 46
@@ -70,6 +70,7 @@ namespace OpenSim.Server.Base
70 70
71 bool ssl_main = networkConfig.GetBoolean("https_main",false); 71 bool ssl_main = networkConfig.GetBoolean("https_main",false);
72 bool ssl_listener = networkConfig.GetBoolean("https_listener",false); 72 bool ssl_listener = networkConfig.GetBoolean("https_listener",false);
73 bool ssl_external = networkConfig.GetBoolean("https_external",false);
73 74
74 m_consolePort = (uint)networkConfig.GetInt("ConsolePort", 0); 75 m_consolePort = (uint)networkConfig.GetInt("ConsolePort", 0);
75 76
@@ -115,6 +116,7 @@ namespace OpenSim.Server.Base
115 { 116 {
116 uint https_port = (uint)networkConfig.GetInt("https_port", 0); 117 uint https_port = (uint)networkConfig.GetInt("https_port", 0);
117 118
119<<<<<<< HEAD
118 string cert_path = networkConfig.GetString("cert_path",String.Empty); 120 string cert_path = networkConfig.GetString("cert_path",String.Empty);
119 if (cert_path == String.Empty) 121 if (cert_path == String.Empty)
120 { 122 {
@@ -127,9 +129,31 @@ namespace OpenSim.Server.Base
127 { 129 {
128 System.Console.WriteLine("ERROR: Password for X509 certificate is missing, server can't start."); 130 System.Console.WriteLine("ERROR: Password for X509 certificate is missing, server can't start.");
129 Environment.Exit(1); 131 Environment.Exit(1);
132=======
133 m_log.WarnFormat("[SSL]: External flag is {0}", ssl_external);
134 if (!ssl_external)
135 {
136 string cert_path = networkConfig.GetString("cert_path",String.Empty);
137 if ( cert_path == String.Empty )
138 {
139 System.Console.WriteLine("Path to X509 certificate is missing, server can't start.");
140 Thread.CurrentThread.Abort();
141 }
142 string cert_pass = networkConfig.GetString("cert_pass",String.Empty);
143 if ( cert_pass == String.Empty )
144 {
145 System.Console.WriteLine("Password for X509 certificate is missing, server can't start.");
146 Thread.CurrentThread.Abort();
147 }
148
149 MainServer.AddHttpServer(new BaseHttpServer(https_port, ssl_listener, cert_path, cert_pass));
150 }
151 else
152 {
153 m_log.WarnFormat("[SSL]: SSL port is active but no SSL is used because external SSL was requested.");
154 MainServer.AddHttpServer(new BaseHttpServer(https_port));
155>>>>>>> avn/ubitvar
130 } 156 }
131
132 MainServer.AddHttpServer(new BaseHttpServer(https_port, ssl_listener, cert_path, cert_pass));
133 } 157 }
134 } 158 }
135 159