From 1f7799fd5b1d75ce4648de7e025793038539c1c7 Mon Sep 17 00:00:00 2001 From: JP Dillingham Date: Sun, 1 Feb 2026 22:25:44 -0600 Subject: add required and portforwarding vpn options --- src/slskd/Core/Options.cs | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/slskd/Core/Options.cs b/src/slskd/Core/Options.cs index 545dedac..10aaed3d 100644 --- a/src/slskd/Core/Options.cs +++ b/src/slskd/Core/Options.cs @@ -2315,6 +2315,16 @@ namespace slskd /// public bool Enabled { get; init; } = false; + /// + /// Gets a value indicating whether a VPN connection is required before connecting to the Soulseek network. + /// + public bool Required { get; init; } = false; + + /// + /// Gets a value indicating whether the configured VPN supports port forwarding. + /// + public bool PortForwarding { get; init; } = false; + /// /// Gets Gluetun options. /// @@ -2343,8 +2353,8 @@ namespace slskd /// /// Gets the Gluetun control server authentication method. /// - [Enum(typeof(GluetunClientAuthOptions), ignoreCase: true)] - public string Auth { get; init; } + [Enum(typeof(GluetunClientAuthenticationMethod), ignoreCase: true)] + public string Auth { get; init; } = GluetunClientAuthenticationMethod.None.ToString(); /// /// Gets the username used for basic auth. @@ -2365,7 +2375,7 @@ namespace slskd { var results = new List(); - if (string.Equals(Auth, GluetunClientAuthOptions.Basic.ToString(), StringComparison.OrdinalIgnoreCase)) + if (string.Equals(Auth, GluetunClientAuthenticationMethod.Basic.ToString(), StringComparison.OrdinalIgnoreCase)) { if (string.IsNullOrWhiteSpace(Username) || string.IsNullOrWhiteSpace(Password)) { @@ -2373,7 +2383,7 @@ namespace slskd } } - if (string.Equals(Auth, GluetunClientAuthOptions.ApiKey.ToString(), StringComparison.OrdinalIgnoreCase)) + if (string.Equals(Auth, GluetunClientAuthenticationMethod.ApiKey.ToString(), StringComparison.OrdinalIgnoreCase)) { if (string.IsNullOrWhiteSpace(ApiKey)) { -- cgit v1.2.3