formal-verifiation.yml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. name: Formal verification
  2. on:
  3. push:
  4. branches:
  5. - master
  6. - release-v*
  7. - formal-verification
  8. pull_request: {}
  9. workflow_dispatch: {}
  10. jobs:
  11. list-scripts:
  12. runs-on: ubuntu-latest
  13. outputs:
  14. matrix: ${{ steps.set-matrix.outputs.matrix }}
  15. steps:
  16. - uses: actions/checkout@v2
  17. - id: set-matrix
  18. run: echo ::set-output name=matrix::$(cat certora/matrix.json)
  19. verify:
  20. runs-on: ubuntu-latest
  21. needs: list-scripts
  22. steps:
  23. - uses: actions/checkout@v2
  24. - name: Install python
  25. uses: actions/setup-python@v2
  26. with:
  27. python-version: '3.10'
  28. cache: 'pip'
  29. - name: Install java
  30. uses: actions/setup-java@v1
  31. with:
  32. java-version: '11'
  33. java-package: 'jre'
  34. - name: Install certora
  35. run: pip install certora-cli
  36. - name: Install solc
  37. run: |
  38. wget https://github.com/ethereum/solidity/releases/download/v0.8.17/solc-static-linux
  39. sudo mv solc-static-linux /usr/local/bin/solc
  40. chmod +x /usr/local/bin/solc
  41. - name: Verify rule ${{ matrix.params.spec }}
  42. if: matrix.params.disabled != true
  43. run: |
  44. echo 'file:' ${{ matrix.params.file }}
  45. echo 'name:' ${{ matrix.params.name }}
  46. echo 'spec:' ${{ matrix.params.spec }}
  47. touch certora/applyHarness.patch
  48. make -C certora munged
  49. certoraRun ${{ matrix.params.file }} --verify ${{ matrix.params.name }}:${{ matrix.params.spec }} --solc solc --optimistic_loop --loop_iter 3 --rule_sanity advanced --cloud --debug
  50. env:
  51. CERTORAKEY: ${{ secrets.CERTORAKEY }}
  52. strategy:
  53. fail-fast: false
  54. max-parallel: 4
  55. matrix:
  56. params: ${{ fromJson(needs.list-scripts.outputs.matrix) }}