diff --git a/src/Prospect.Unreal/Runtime/UWorld.cs b/src/Prospect.Unreal/Runtime/UWorld.cs index fed91c0..381a0cd 100644 --- a/src/Prospect.Unreal/Runtime/UWorld.cs +++ b/src/Prospect.Unreal/Runtime/UWorld.cs @@ -314,22 +314,16 @@ public abstract partial class UWorld : FNetworkNotify, IAsyncDisposable // Chiffrement DTLS-PSK requis par le client. Si on connaît la // PSK de cette identité (user_id), on répond NMT_EncryptionAck et // on établit le DTLS côté serveur (BouncyCastle). Cf. DTLSHandlerComponent. - var psks = DtlsPsks.Value; - if (psks.Get(encryptionToken) != null && connection.DtlsComponent != null) - { - Logger.Information("DTLS-PSK: identité {Token} connue -> EncryptionAck + handshake", encryptionToken); - NMT_EncryptionAck.Send(connection); - connection.FlushNet(); - connection.DtlsComponent.BeginHandshake( - psks, encryptionToken, - rec => connection.LowLevelSend(rec, rec.Length * 8, new FOutPacketTraits())); - connection.SendChallengeControlMessage(); - } - else - { - Logger.Warning("DTLS-PSK requis mais aucune PSK pour {Token} (renseigner PROSPECT_DTLS_PSKS) — le client fermera la connexion", encryptionToken); - connection.SendChallengeControlMessage(); - } + // OBSERVÉ EN LIVE : après NMT_EncryptionAck, le client envoie son + // NMT_Login EN CLAIR (paquet UE de 18o, jamais de ClientHello DTLS + // 16fefd). Hypothèse : l'EncryptionAck suffit à satisfaire son check + // « chiffrement acquitté » et le canal de contrôle reste en clair. + // => on ACQUITTE mais on N'ACTIVE PAS DTLS (sinon on mange le Login), + // et on laisse le flux login se poursuivre normalement. + Logger.Information("DTLS-PSK: identité {Token} — EncryptionAck (canal de contrôle laissé en clair, test)", encryptionToken); + NMT_EncryptionAck.Send(connection); + connection.FlushNet(); + connection.SendChallengeControlMessage(); } } break;