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

+simulate_write_message [doesn't work, don't merge] #89

Closed
wants to merge 2 commits into from
Closed

+simulate_write_message [doesn't work, don't merge] #89

wants to merge 2 commits into from

Conversation

fogti
Copy link
Contributor

@fogti fogti commented Jun 6, 2020

This PR fixes #84, fixes #86, and fixes #88.

@fogti
Copy link
Contributor Author

fogti commented Jun 6, 2020

... and it doesn't work as expected (example codebase). I get the error State(NotTurnToWrite) at the noise.write_message call.

@fogti
Copy link
Contributor Author

fogti commented Jun 6, 2020

now it fails with Decrypt error at noise.read_message call...
currently, all fatal errors seem to happen on server/responder side.
I use the XK pattern, in the following, I marked everything that succeeds with * (every error with !) + r for "read ok" and w for "write ok", after | I write the simulated size.

XK:
<- s
...
-> e, es   *w *r | 48
<- e, ee   *w *r | 48
-> s, se   *w !r | 64

e.g. only the last read fails, and I don't know why. Also, the last message is bigger than the rest...

@fogti
Copy link
Contributor Author

fogti commented Jun 6, 2020

Another possibility to solve this w/o this solution, would be to introduce some simulate_read_message method, similiar to the here-introduced simulate_write_message, but which should report which input size it does expect, so that input can be truncated.

@fogti fogti changed the title +simulate_write_message; fix documentation +simulate_write_message [doesn't work, don't merge] Jun 6, 2020
@fogti
Copy link
Contributor Author

fogti commented Jun 10, 2020

I'm pretty sure that some state change isn't catched by the simulate_write_message method.

@fogti fogti closed this Jun 10, 2020
@fogti fogti mentioned this pull request Jun 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant