aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Servers/BaseHttpServer.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/Servers/BaseHttpServer.cs')
-rw-r--r--OpenSim/Framework/Servers/BaseHttpServer.cs16
1 files changed, 15 insertions, 1 deletions
diff --git a/OpenSim/Framework/Servers/BaseHttpServer.cs b/OpenSim/Framework/Servers/BaseHttpServer.cs
index aa6d315..81829c4 100644
--- a/OpenSim/Framework/Servers/BaseHttpServer.cs
+++ b/OpenSim/Framework/Servers/BaseHttpServer.cs
@@ -45,6 +45,7 @@ namespace OpenSim.Framework.Servers
45 protected Dictionary<string, XmlRpcMethod> m_rpcHandlers = new Dictionary<string, XmlRpcMethod>(); 45 protected Dictionary<string, XmlRpcMethod> m_rpcHandlers = new Dictionary<string, XmlRpcMethod>();
46 protected Dictionary<string, IRequestHandler> m_streamHandlers = new Dictionary<string, IRequestHandler>(); 46 protected Dictionary<string, IRequestHandler> m_streamHandlers = new Dictionary<string, IRequestHandler>();
47 protected int m_port; 47 protected int m_port;
48 protected bool m_ssl = false;
48 protected bool m_firstcaps = true; 49 protected bool m_firstcaps = true;
49 50
50 public int Port 51 public int Port
@@ -57,6 +58,12 @@ namespace OpenSim.Framework.Servers
57 m_port = port; 58 m_port = port;
58 } 59 }
59 60
61 public BaseHttpServer(int port, bool ssl)
62 {
63 m_ssl = ssl;
64 BaseHttpServer(port);
65 }
66
60 public void AddStreamHandler(IRequestHandler handler) 67 public void AddStreamHandler(IRequestHandler handler)
61 { 68 {
62 string httpMethod = handler.HttpMethod; 69 string httpMethod = handler.HttpMethod;
@@ -252,7 +259,14 @@ namespace OpenSim.Framework.Servers
252 MainLog.Instance.Verbose("HTTPD", "Spawned main thread OK"); 259 MainLog.Instance.Verbose("HTTPD", "Spawned main thread OK");
253 m_httpListener = new HttpListener(); 260 m_httpListener = new HttpListener();
254 261
255 m_httpListener.Prefixes.Add("http://+:" + m_port + "/"); 262 if (!m_ssl)
263 {
264 m_httpListener.Prefixes.Add("http://+:" + m_port + "/");
265 }
266 else
267 {
268 m_httpListener.Prefixes.Add("https://+:" + m_port + "/");
269 }
256 m_httpListener.Start(); 270 m_httpListener.Start();
257 271
258 HttpListenerContext context; 272 HttpListenerContext context;