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

how to prove this example #773

Closed
kanigsson opened this issue Sep 16, 2021 · 2 comments
Closed

how to prove this example #773

kanigsson opened this issue Sep 16, 2021 · 2 comments

Comments

@kanigsson
Copy link
Collaborator

chat.rflx.txt
main.adb.txt
server.rflx.txt

The attached example generates and compiles fine, but doesn't prove. The first unproved VC is when accessing the Payload_Size field of the Msg (in the Send state). Intuitively this is clear to me, as there is no code which carries the info that the Msg is Valid over to the Send state. How to solve this issue?

By the way, I have introduced the Send state because I don't know how to check for validity of a message in the middle of a state. Maybe there is another solution.

@treiher treiher added this to To do in RecordFlux 0.6 via automation Sep 20, 2021
@treiher
Copy link
Collaborator

treiher commented Sep 20, 2021

We discussed various options to address similar issues in #691. We considered adding state contracts to carry information from one state to another and a mechanism to check for properties inside a state, but we decided against both solutions, as the specification would become more complex and less readable. In the future, checks that ensure the provability of all VCs will be automatically generated (e.g., if a message field is accessed, a check ensuring the validity of the message before the field access is automatically added). If such a check fails, the exception transition is taken. For some cases this is already done, but many cases are still missing. We plan to solve that issue soon (we will most probably need it for SPDM). Until this is done, the generated code for several examples will be unprovable.

@treiher treiher removed their assignment Sep 20, 2021
@kanigsson
Copy link
Collaborator Author

Thanks Tobias. I will close this as a duplicate of #691.

RecordFlux 0.6 automation moved this from To do to Merged Sep 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
Development

No branches or pull requests

2 participants