Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting a hash of the included types #53

Open
cswiedler opened this issue May 9, 2016 · 1 comment
Open

Getting a hash of the included types #53

cswiedler opened this issue May 9, 2016 · 1 comment

Comments

@cswiedler
Copy link

This may already exist, but I'm not sure where to request/ask about it. Is there a way to get a hash of all of the types that Netserializer knows about? The idea would be to use this as a 'protocol version', meaning that if it changes, the client and server are incompatible with each other. Since Netserializer is already going recursively though all of the types that we would possibly send over the wire, it seems like we could build a unique value that the two sides can use to verify they speak the exact same protocol.

Right now we require the client and server to be from exactly the same build, but it would be very useful to be able to verify that they're compatible without that requirement (while still ensuring that none of the messages / types involved in the protocol have been changed).

@tomba
Copy link
Owner

tomba commented May 10, 2016

There's GetSHA256(). But it only looks for type names and type IDs, so it won't notice things like added fields.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants