Giter Club home page Giter Club logo

saatana's People

Contributors

jellix avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

saatana's Issues

Lemmas package not run through SPARK

Apparently the (unused and private) Lemmas child package is ignored by gnatprove ATM. Probably, because the package is not in any closure of a main subprogram.

Run gnat check automatically

Heaving recently fixed all the coding standards violations (unnamed block statements etc.) I figured that a gnat check run should be done automatically, either as part of the build process or even a commit trigger.

Prove bijectivity of conversion functions

After these declarations in saatana-crypto.ads we should do something like:

pragma Assert (for all W in Word_32'Range =>
                 To_Unsigned (To_Stream (W)) = W);
   --  Prove bijectivity of conversion subprograms.

We cannot do this directly in Saatana.Crypto:

non-static call not allowed in preelaborated unit

as the package is supposed to be Pure and shall remain so.

An idea might be to introduce private proof property child packages for the specific purpose of proving such kind of properties.

Upload gnatprove results upon CI run

If we're running the prover on the CI runs, we could upload the prove results for further analysis.

Right now there are some "might not be initialized" warnings which should be investigated. Most likely cause is that we run a different set of provers than on my local machine (where Z3 and CVC4 are also installed).

Split workflows into build and proof

Proof takes quite some time, especially if this project ever gets larger, so it seems impractical to run the full proof at each repository push.

Instead, we could just do a build (including running the KAT(s)), and do a proof run once or twice a day.

Precondition not proved in Decrypt/Encrypt_Packet

The currently used provers can prove all assertions which have been added prior to calling De/Encrypt_Bytes, yet for some unexplained reason, the actual precondition can not be proven by the tools.

Manual proof run

This issue is a placeholder for manual triggers of proof runs.

If you add the special 'run_proof' label, a proof run on the master branch should be triggered.

Wrong Assume pragmas

As pointed out by Piotr Trojanek in the SPARK discussion mailing list, the Assume pragmas were wrong and not correctly catering for the fact that an empty input array with rather "interesting" bound could be passed to Encrypt/Decrypt_Bytes and Process_AAD, This is a rather serious bug as it would have opened the door to a DoS attack on the implementation if runtime checks were enabled.

The prover was right, after all.

Upload KAT results

We should upload the full results of the Known Answers Test run. These are important artifacts supporting our proof of functional correctness.

Performance test

We should include a performance test, preferably with different optimization options and a comparison between run-time checks enabled and disabled (as we prove there will be none).

Implement more encryption algorithms

Candidates:

Block Ciphers:

  • Blowfish
  • Twofish
  • Threefish, this one is based on Skein, so the SPARKSkein implementation would be a good start
  • AES (PDF)
  • IDEA (the patent expired in 2012, so it should be free to use now, but proper documentation seems scarce)

Stream ciphers:

And then there's the thing that any proper encryption needs a cryptographically secure random number generator, be it for nonce, key, or random seed initializations.

Improve readability of post condition

The post condition on Crypto.Phelix.H isn't very readable, this should be improved.

It would be nice to have it expressed in a form that side-by-side comparison with the algorithm specification would be possible.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.