@@ -147,6 +147,7 @@ internal set
147
147
/// </summary>
148
148
public event CustomMessageDelegete OnIncommingCustomMessage ;
149
149
public string ConnectedHostname { get ; private set ; }
150
+ internal byte [ ] clientAesKey ;
150
151
internal static event Action OnSingletonReady ;
151
152
152
153
internal void InvokeOnIncommingCustomMessage ( uint clientId , Stream stream )
@@ -194,13 +195,6 @@ public void SendCustomMessage(uint clientId, Stream stream, string channel = "ML
194
195
InternalMessageHandler . Send ( clientId , MLAPIConstants . MLAPI_CUSTOM_MESSAGE , channel , stream , SecuritySendFlags . None ) ;
195
196
}
196
197
197
- internal byte [ ] clientAesKey ;
198
-
199
- /// <summary>
200
- /// An inspector bool that acts as a Trigger for regenerating RSA keys. Should not be used outside Unity editor.
201
- /// </summary>
202
- public bool RegenerateRSAKeys = false ;
203
-
204
198
private void OnValidate ( )
205
199
{
206
200
if ( NetworkConfig == null )
@@ -244,30 +238,7 @@ private void OnValidate()
244
238
if ( LogHelper . CurrentLogLevel <= LogLevel . Normal ) LogHelper . LogWarning ( "Only one networked prefab can be marked as a player prefab" ) ;
245
239
}
246
240
else NetworkConfig . PlayerPrefabName = NetworkConfig . NetworkedPrefabs . Find ( x => x . playerPrefab == true ) . name ;
247
-
248
- }
249
-
250
- /*
251
- if (!NetworkConfig.EnableEncryption)
252
- {
253
- RegenerateRSAKeys = false;
254
- }
255
- else
256
- {
257
- if (RegenerateRSAKeys)
258
- {
259
- #if !DISABLE_CRYPTOGRAPHY
260
- using (RSACryptoServiceProvider rsa = new RSACryptoServiceProvider())
261
- {
262
- rsa.PersistKeyInCsp = false;
263
- NetworkConfig.RSAPrivateKey = rsa.ToXmlString(true);
264
- NetworkConfig.RSAPublicKey = rsa.ToXmlString(false);
265
- }
266
- #endif
267
- RegenerateRSAKeys = false;
268
- }
269
241
}
270
- */
271
242
}
272
243
273
244
private object Init ( bool server )
0 commit comments