Skip to content

Silent exceptions in TcpConnection #1005

@xPaw

Description

@xPaw

Specifically here:

try
{
NetMsgReceived?.Invoke( this, new NetMsgEventArgs( packData, CurrentEndPoint! ) );
}
catch (Exception ex)
{
log.LogDebug( "TcpConnection", "Unexpected exception propogated back to NetLoop: {0}", ex);
}

I'm trying NET6 preview 6, and for whatever reason it's throwing here:

NetFilterEncryptionWithHMAC Unable to decrypt incoming packet: NetFilterEncryption was unable to decrypt packet: HMAC from server did not match computed HMAC.
TcpConnection Unexpected exception propogated back to NetLoop: System.IO.IOException: Unable to decrypt incoming packet
 ---> System.Security.Cryptography.CryptographicException: NetFilterEncryption was unable to decrypt packet: HMAC from server did not match computed HMAC.

The problem is that this exception is being hidden by TcpConnection and only visible in DebugLog. Should it be rethrown/not caught?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions