auditdrivencrypto / secret-handshake

Mutually authenticating key agreement handshake
MIT License
202 stars 29 forks source link

add deterministic tests and test vectors #5

Closed david415 closed 7 years ago

david415 commented 7 years ago

other language implementations of secret-handshake should share these test vectors. this would give implementers some confidence that they've done it correctly. additionally the binary compatibility among language implementations might prove useful.

dominictarr commented 7 years ago

I was just thinking that actually.

If https://github.com/auditdrivencrypto/secret-handshake/blob/master/state.js was rewritten as pure functions, then we could generate extensive test vectors for each, persisted as, say, base64 strings inside json.

david415 commented 7 years ago

yeah that sounds great... although i would think we could have deterministic tests with only rewriting bits of the tests.

dominictarr commented 7 years ago

done!