Commit Graph

2 Commits

Author SHA1 Message Date
rna88 967378ae98 SInPacket now tracks decryption/decompression failure.
Previously there was no way to tell if an incoming packet was
incorrectly formatted. The new function SInPacket.isValid()
can be called after decryption/decompression to determine if
the packet wasn't decrypted and/or decompressed properly.

* Added "valid" attribute to SInPacket.
* Decryption routine unsets "valid" if buffer is not divisible by 16.
* Decompression routine unsets "valid" on receiving zlib error code.
2018-03-15 20:12:33 -07:00
rna88 18b7ce6bc9 Initial commit. 2018-03-10 20:07:10 -08:00