diff options
author | onefang | 2019-08-17 07:05:49 +1000 |
---|---|---|
committer | onefang | 2019-08-17 07:05:49 +1000 |
commit | 9c043cbf4c9adb85acef5c9ffa269d4180f44832 (patch) | |
tree | 16c2be9f8e8b633b974da2718cb59a812fb7f9ef /OpenSim/Server/Handlers/Web | |
parent | Bump build number. (diff) | |
download | opensim-SC_OLD-9c043cbf4c9adb85acef5c9ffa269d4180f44832.zip opensim-SC_OLD-9c043cbf4c9adb85acef5c9ffa269d4180f44832.tar.gz opensim-SC_OLD-9c043cbf4c9adb85acef5c9ffa269d4180f44832.tar.bz2 opensim-SC_OLD-9c043cbf4c9adb85acef5c9ffa269d4180f44832.tar.xz |
Simple web server gets HTTPS.
Diffstat (limited to 'OpenSim/Server/Handlers/Web')
-rw-r--r-- | OpenSim/Server/Handlers/Web/WebServerConnector.cs | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/OpenSim/Server/Handlers/Web/WebServerConnector.cs b/OpenSim/Server/Handlers/Web/WebServerConnector.cs index 06fd892..3a8e906 100644 --- a/OpenSim/Server/Handlers/Web/WebServerConnector.cs +++ b/OpenSim/Server/Handlers/Web/WebServerConnector.cs | |||
@@ -12,6 +12,7 @@ using OpenMetaverse; | |||
12 | using OpenMetaverse.StructuredData; | 12 | using OpenMetaverse.StructuredData; |
13 | using OpenSim.Data.MySQL; | 13 | using OpenSim.Data.MySQL; |
14 | using OpenSim.Framework; | 14 | using OpenSim.Framework; |
15 | using OpenSim.Framework.Servers; | ||
15 | using OpenSim.Framework.Servers.HttpServer; | 16 | using OpenSim.Framework.Servers.HttpServer; |
16 | using OpenSim.Server.Handlers.Base; | 17 | using OpenSim.Server.Handlers.Base; |
17 | 18 | ||
@@ -82,8 +83,20 @@ namespace OpenSim.Server.Handlers.Web | |||
82 | ssi.Add("grid", cfg.GetString("gridname", "my grid")); | 83 | ssi.Add("grid", cfg.GetString("gridname", "my grid")); |
83 | ssi.Add("uri", cfg.GetString("login", HomeURI)); | 84 | ssi.Add("uri", cfg.GetString("login", HomeURI)); |
84 | ssi.Add("version", VersionInfo.Version); | 85 | ssi.Add("version", VersionInfo.Version); |
86 | |||
85 | server.AddHTTPHandler("/web/", WebRequestHandler); | 87 | server.AddHTTPHandler("/web/", WebRequestHandler); |
86 | } | 88 | IConfig networkConfig = m_Config.Configs["Network"]; |
89 | if (null != networkConfig) | ||
90 | { | ||
91 | uint https_port = (uint) networkConfig.GetInt("https_port", 0); | ||
92 | if (0 != https_port) | ||
93 | { | ||
94 | server = MainServer.GetHttpServer(https_port, null); | ||
95 | if (null != server) | ||
96 | server.AddHTTPHandler("/web/", WebRequestHandler); | ||
97 | } | ||
98 | } | ||
99 | } | ||
87 | 100 | ||
88 | private Hashtable WebRequestHandler(Hashtable request) | 101 | private Hashtable WebRequestHandler(Hashtable request) |
89 | { | 102 | { |