immense / Remotely

A remote control and remote scripting solution, built with .NET 8, Blazor, and SignalR.
GNU General Public License v3.0
4.28k stars 1.6k forks source link

Add More Modern TLS Support for Install-Remotely.ps1 #899

Closed anedward01 closed 7 hours ago

anedward01 commented 1 week ago

Describe the bug

In the Install-Remotely.ps1 script, there is a hardcode to only support tls1.2 located at line 20:

[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12

My environment only supports tls1.3 connections which was causing the script to error out. To remedy this, I replaced line 20 with the following:

[Net.ServicePointManager]::SecurityProtocol = "tls13, tls12"

This allowed me to successfully download and install the application. It's not the best code, but it works well enough for what it serves.

To Reproduce Steps to reproduce the behavior:

  1. Set up a proxy that only supports TLS1.3 (Cloudflare custom settings in my case)
  2. Attempt to run the script
  3. Run into a generic error on line 107
  4. Run only the line 107 snippet
  5. Get a TLS/SSL error

Remotely Version Server (can be found on about page): 2024.02.23.1927 Agent (can be found in device card): 2024.02.23.1927

Expected Behavior A clear and concise description of what you expected to happen.

When running the install script, the Invoke-WebRequest should successfully process.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Smartphone (please complete the following information):

Additional Context Add any other context about the problem here.

bitbound commented 7 hours ago

Added in the latest release.