Stamp hardening: refuse a peer raw put with no stamp in C#, TypeScript and Rust; Python replication (#175)

This commit is contained in:
Libby 2026-11-14 08:51:04 +00:00
commit 75188fdefa
36 changed files with 1043 additions and 45 deletions

View file

@ -475,6 +475,11 @@ namespace GameCult.Networking
_server.Logger.LogWarning($"CultNet raw put refused: {ex.Message}");
Refuse(peer, write, CultNetErrorMessage.ForRemoteWriteRefused(ex.Request, ex.Reason));
}
catch (CultNetStoredAtStampException ex)
{
_server.Logger.LogWarning($"CultNet raw put refused: {ex.Message}");
Refuse(peer, write, CultNetErrorMessage.ForMessageInvalid("document", "document.storedAt is not a stamp"));
}
catch (CultNetShardAuthorityException ex)
{
bool forwarded;