diff --git a/Server/Pages/RemoteControl.cshtml b/Server/Pages/RemoteControl.cshtml
index af7de1fe..1bef723c 100644
--- a/Server/Pages/RemoteControl.cshtml
+++ b/Server/Pages/RemoteControl.cshtml
@@ -96,7 +96,7 @@
-
+
@@ -108,7 +108,7 @@
-
+
diff --git a/Server/Services/ApplicationConfig.cs b/Server/Services/ApplicationConfig.cs
index b103c673..450a8e97 100644
--- a/Server/Services/ApplicationConfig.cs
+++ b/Server/Services/ApplicationConfig.cs
@@ -22,7 +22,7 @@ namespace Remotely.Server.Services
public string[] KnownProxies => Config.GetSection("ApplicationOptions:KnownProxies").Get();
public int MaxOrganizationCount => int.Parse(Config["ApplicationOptions:MaxOrganizationCount"]);
public bool RecordRemoteControlSessions => bool.Parse(Config["ApplicationOptions:RecordRemoteControlSessions"]);
- public bool RedirectToHTTPS => bool.Parse(Config["ApplicationOptions:RedirectToHTTPS"]);
+ public bool RedirectToHttps => bool.Parse(Config["ApplicationOptions:RedirectToHttps"]);
public bool RemoteControlRequiresAuthentication => bool.Parse(Config["ApplicationOptions:RemoteControlRequiresAuthentication"]);
public double RemoteControlSessionLimit => double.Parse(Config["ApplicationOptions:RemoteControlSessionLimit"]);
public string SmtpDisplayName => Config["ApplicationOptions:SmtpDisplayName"];
@@ -34,7 +34,8 @@ namespace Remotely.Server.Services
public string SmtpUserName => Config["ApplicationOptions:SmtpUserName"];
public string Theme => Config["ApplicationOptions:Theme"];
public string[] TrustedCorsOrigins => Config.GetSection("ApplicationOptions:TrustedCorsOrigins").Get();
- public bool UseHSTS => bool.Parse(Config["ApplicationOptions:RedirectToHTTPS"]);
+ public bool UseHsts => bool.Parse(Config["ApplicationOptions:UseHsts"]);
+ public bool UseWebRtc => bool.Parse(Config["ApplicationOptions:UseWebRtc"]);
private IConfiguration Config { get; set; }
}
}
diff --git a/Server/Services/RCDeviceSocketHub.cs b/Server/Services/RCDeviceSocketHub.cs
index 3a1c6261..5041f993 100644
--- a/Server/Services/RCDeviceSocketHub.cs
+++ b/Server/Services/RCDeviceSocketHub.cs
@@ -182,7 +182,10 @@ namespace Remotely.Server.Services
public async Task SendRtcOfferToBrowser(string sdp, string viewerID)
{
- await RCBrowserHub.Clients.Client(viewerID).SendAsync("ReceiveRtcOffer", sdp);
+ if (AppConfig.UseWebRtc)
+ {
+ await RCBrowserHub.Clients.Client(viewerID).SendAsync("ReceiveRtcOffer", sdp);
+ }
}
public async Task SendIceCandidateToBrowser(string candidate, int sdpMlineIndex, string sdpMid, string viewerID)
{
diff --git a/Server/Startup.cs b/Server/Startup.cs
index a734c03e..b8da8a02 100644
--- a/Server/Startup.cs
+++ b/Server/Startup.cs
@@ -169,11 +169,11 @@ namespace Remotely.Server
else
{
app.UseExceptionHandler("/Error");
- if (bool.Parse(Configuration["ApplicationOptions:UseHSTS"]))
+ if (bool.Parse(Configuration["ApplicationOptions:UseHsts"]))
{
app.UseHsts();
}
- if (bool.Parse(Configuration["ApplicationOptions:RedirectToHTTPS"]))
+ if (bool.Parse(Configuration["ApplicationOptions:RedirectToHttps"]))
{
app.UseHttpsRedirection();
}
diff --git a/Server/appsettings.json b/Server/appsettings.json
index a4ad3630..0fdc68fe 100644
--- a/Server/appsettings.json
+++ b/Server/appsettings.json
@@ -18,10 +18,9 @@
"EnableWindowsEventLog": false,
"KnownProxies": [],
"RecordRemoteControlSessions": false,
- "RedirectToHTTPS": false,
+ "RedirectToHttps": false,
"RemoteControlSessionLimit": 1,
"RemoteControlRequiresAuthentication": true,
- "UseHSTS": false,
"SmtpHost": "",
"SmtpPort": 25,
"SmtpUserName": "",
@@ -30,6 +29,8 @@
"SmtpDisplayName": "",
"SmtpEnableSsl": true,
"TrustedCorsOrigins": [],
- "Theme": "Dark"
+ "Theme": "Dark",
+ "UseHsts": false,
+ "UseWebRtc": true
}
}
\ No newline at end of file