From a10a5b40cd64d4d6a5f691d5d5a1336c6905271e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Straubmeier?= Date: Thu, 19 Nov 2020 13:57:43 +0100 Subject: [PATCH] Added SteamNetworkingUtils.Unencrypted --- Facepunch.Steamworks/SteamNetworkingUtils.cs | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/Facepunch.Steamworks/SteamNetworkingUtils.cs b/Facepunch.Steamworks/SteamNetworkingUtils.cs index aab70c8..a495bf7 100644 --- a/Facepunch.Steamworks/SteamNetworkingUtils.cs +++ b/Facepunch.Steamworks/SteamNetworkingUtils.cs @@ -204,6 +204,23 @@ namespace Steamworks set => SetConfigInt( NetConfig.IP_AllowWithoutAuth, value ); } + /// + /// Allow unencrypted (and unauthenticated) communication. + /// 0: Not allowed (the default) + /// 1: Allowed, but prefer encrypted + /// 2: Allowed, and preferred + /// 3: Required. (Fail the connection if the peer requires encryption.) + /// + /// This is a dev configuration value, since its purpose is to disable encryption. + /// You should not let users modify it in production. (But note that it requires + /// the peer to also modify their value in order for encryption to be disabled.) + /// + public static int Unencrypted + { + get => GetConfigInt( NetConfig.Unencrypted ); + set => SetConfigInt( NetConfig.Unencrypted, value ); + } + /// /// Get Debug Information via OnDebugOutput event ///