This project intends to build a verified version of microsoft/RIoT using
- F*: verification system for effectful programs
- KreMLin: a tool for extracting low-level F* programs to readable C code
- HACL*: a formally verified cryptographic library written in F*
- EverParse: a F* library for write secure parser and serializer
ASN.1
/ |
X.509 | C C
\ | / |
RIoT DICE
src/c
: C source filessrc/dice
: F* source files for DICEsrc/riot
: F* source files for RIoTRIoT.Base
: X.509 base definitionsRIoT.Declassify
: Interface for declassification functionsRIoT.X509.*
: X.509 certificate-related definitionsRIoT.Spec.*
: Specification for crypto and X.509 certificate-related functionsRIoT.Impl.*
: Implementation for crypto and X.509 certificate-related functionsRIoT.Core
: RIoT Core functionalitysrc/riot/asn1
: F* source files for ASN.1 serializerASN1.Base
: Base ASN.1 definitionsASN1.Spec.*
: Specification serializers and combinatorsASN1.Low.*
: Implementation serializers and combinators
src/riot/x509
: F* source files for X.509 serializerX509.Base
: X.509 base definitionsX509.Crypto
: Crypto-related serializerX509.BasicFields
: Serializer for X.509 certificate basic fieldsX509.ExtFields
: Serializer for X.509 certificate extension fields
src/test
Test scriptssrc/obj
F* outputs (after build)
Execute the following command and you will be in the project root directory. This Dockerfile depends on the official F* build packaged with Emacs : fstarlang/fstar-emacs:latest.
$ docker build -t verifiedhardware:checkpoint -f .docker/stable/Dockerfile .
$ docker run -it --rm verifiedhardware:checkpoint bash
You can prepend OTHERFLAGS='--admit_smt_queries true'
before any commands below to (largely) speed up the verification process (by assuming SMT queries) if you are sure the F* definitions are correct.
You can verify F* source files for any project (and their dependencies) of DICE
, RIoT
, ASN1
and X509
by entering the corresponding directory and executing
make verify-all -j4
You can test RIoT
or ASN1
by executing
make test-riot -j4
or
make test-asn1 -j4
at the src/test
directory or the root directory. The test executable src/test/test.exe
will be complied and executed. Generated C files lie in src/obj
.
After executing
make test-riot -j4
C files will be generated in src/obj
.