Commit 947de0f
Validation (#151)
* Change nightly version.
The previous nightly version specified (nightly-2019-03-05) had an issue
where components where not supported on Windows. 2018 versions had an
issue with some wasm memory functions not being finalised
(see rust-lang/rust#56292). This could all be
wrong but I found this version worked for me where others didn't.
* Add batch equivalent to build.sh
* Update windows build command
* Rough validation testing
This tests the proofs-of-concept for the validation code. It is not
currently integrated into the test suites or CI.
* Fix contract name
* Add cap9-build to link in sycalls
* Validate syscalls.
* Functioning syscall linking and validation (albeit very messy)
* Change toolchain version
* Use cross platform CWD.
* Use no_std in native validator
* Clean up cap9-build logging
* Add toolchain to native-validator
* Move validation code into separate lib
* Switch to HTTP transport for tests
This is what I'd used previously and it had always worked well for me.
* Experiment with circleci
* Remove SolC
* Only build ewasm
* Change parity command
* Fix directory
* Build wasm-build 0.6.0
* Fix parity url
* Fix directory to run parity
* Fix location of cargo.lock
* Fix parity path
* Don't need to kill database
* Fix Cargo.lock path
* Remove reference to Cargo.lock, which is not commited
* Correct specification of dev dependencies
* Fix no_std build
* Fix std build
* Add get_code_size to the kernel
* Use custom parity node in CI
* Fix installation of parity
* circleci: install cmake
* circleci: use the right package manager
* circleci: needed privileges
* circleci: add more dependencies
* circleci: remove gflags
* circleci: try different gflags package name
* circleci: add perl and yasm
* circleci: see if we can use parity's image
* circleci: remove sudo
* circleci: remove install line
* circleci: try building parity's branch
* Copy example from parity's docker image
* circleci: actually clone parity
* circleci: switch to stable parity
* circleci: build syn first
* circleci: build syn from git
* circleci: dev build
* circleci: build 1 package at a time
* circleci: save cache after parity build
* Revert "circleci: save cache after parity build"
This reverts commit df48168.
* circleci: save cache after parity build
* circleci: checkout code
* circleci: restore cache
* circleci: cache parity builds
* circleci: version bump deps
* circleci: install parity stage
* circleci: don't update rust
* circleci: set default toolchain
* circleci: reorder rustup
* circleci: check for the existence of cargo
* circleci: only install not build then install
* circleci: install this package
* circleci: formatting
* Don't update rust
* circleci: cache rustup
* circleci: update PATH
* circleci: checkout code
* circleci: fix .profile
* circleci: force overwrite of parity node
* circleci: wrong line
* circleci: add log line
* circleci: more log lines
* circleci: fix cache path
* circleci: properly namespace directories
* circleci: fix yaml syntax error
* circleci: install nodejs
* circleci: add repo for nodejs
* circleci: add missing -y
* circleci: install newer version of node
* circleci: use .xz
* circleci: switch parity to master
* Build custom parity as part of ci (#152)
* circleci: add more dependencies
* circleci: remove gflags
* circleci: try different gflags package name
* circleci: add perl and yasm
* circleci: see if we can use parity's image
* circleci: remove sudo
* circleci: remove install line
* circleci: try building parity's branch
* Copy example from parity's docker image
* circleci: actually clone parity
* circleci: switch to stable parity
* circleci: build syn first
* circleci: build syn from git
* circleci: dev build
* circleci: build 1 package at a time
* circleci: save cache after parity build
* Revert "circleci: save cache after parity build"
This reverts commit df48168.
* circleci: save cache after parity build
* circleci: checkout code
* circleci: restore cache
* circleci: cache parity builds
* circleci: version bump deps
* circleci: install parity stage
* circleci: don't update rust
* circleci: set default toolchain
* circleci: reorder rustup
* circleci: check for the existence of cargo
* circleci: only install not build then install
* circleci: install this package
* circleci: formatting
* Don't update rust
* circleci: cache rustup
* circleci: update PATH
* circleci: checkout code
* circleci: fix .profile
* circleci: force overwrite of parity node
* circleci: wrong line
* circleci: add log line
* circleci: more log lines
* circleci: fix cache path
* circleci: properly namespace directories
* circleci: fix yaml syntax error
* circleci: install nodejs
* circleci: add repo for nodejs
* circleci: add missing -y
* circleci: install newer version of node
* circleci: use .xz
* circleci: switch parity to master
* validation: update whitelist and reorder to match parity.
* validation: add EXTCODECOPY and simple test
* Validation merge (#154)
* circleci: add more dependencies
* circleci: remove gflags
* circleci: try different gflags package name
* circleci: add perl and yasm
* circleci: see if we can use parity's image
* circleci: remove sudo
* circleci: remove install line
* circleci: try building parity's branch
* Copy example from parity's docker image
* circleci: actually clone parity
* circleci: switch to stable parity
* circleci: build syn first
* circleci: build syn from git
* circleci: dev build
* circleci: build 1 package at a time
* circleci: save cache after parity build
* Revert "circleci: save cache after parity build"
This reverts commit df48168.
* circleci: save cache after parity build
* circleci: checkout code
* circleci: restore cache
* circleci: cache parity builds
* circleci: version bump deps
* circleci: install parity stage
* circleci: don't update rust
* circleci: set default toolchain
* circleci: reorder rustup
* circleci: check for the existence of cargo
* circleci: only install not build then install
* circleci: install this package
* circleci: formatting
* Don't update rust
* circleci: cache rustup
* circleci: update PATH
* circleci: checkout code
* circleci: fix .profile
* circleci: force overwrite of parity node
* circleci: wrong line
* circleci: add log line
* circleci: more log lines
* circleci: fix cache path
* circleci: properly namespace directories
* circleci: fix yaml syntax error
* circleci: install nodejs
* circleci: add repo for nodejs
* circleci: add missing -y
* circleci: install newer version of node
* circleci: use .xz
* circleci: switch parity to master
* validation: update whitelist and reorder to match parity.
* validation: add EXTCODECOPY and simple test
* cap9-build: increase the amount of available memory in kernel
* kernel: link in basic validation code for testing
* example_contact: expand
* cap9-build: properly pass the number of memory pages
* kernel: LTO needs to be turned off for mem access bug workaround
* kernel: unlock more tests
* kernel: switch to git version of parity-wasm
* kernel: use wasm module type exposed by validator
* kernel: set number of memory pages to 3
* kernel: panic on inability to parse wasm
* kernel: test simple procedure contract
* Switch to manual parsing for validation (#157)
* wasm-parser: remove parity-wasm dependency
* wasm-parser: proof of basic idea
* wasm-parser: import instruction mappings from parity-wasm
* wasm-parser: build and link with kernel
* wasm-parser: fix parsing of import entries
* wasm-parser: add missing file
* kernel: add test script
* wasm-parser: minor cleanup
* circleci: don't force rebuild of parity-ethereum
* kernel: update tests to be more accurate
* kernel: update nightly version for alloc crate
* circleci: fix error with parity installation
* circleci: fix error in previous commit
* wasm-parser: reinclude alloc
* wasm-parser: merge Cursor and CodeCursor
* circleci: add example contract 2
* circleci: set-up environment for test
* circleci: fix example_contract_2 build
* wasm-parser: properly validate instructions in syscall
* wasm-parser: fix import cursor progression
* circleci: remove config step from parity
* circleci: clear cache
* remove and gitignore build files
* validation: rustfmt and add tests
* wasm-parse: refactor
* wasm-parser: docs
* validation: forbid indirect calls
* validation: correct invalidation of bad dcall
* wasm-parser: minor cleanup
* kernel: skip unimplemented test
* wasm-parser: check for varuint32 issues
* wasm-parser: additional comments
* whitespace1 parent 33b8398 commit 947de0f
File tree
49 files changed
+5337
-256
lines changed- .circleci
- cap9-build
- src
- kernel-ewasm
- build
- example_contract_1
- src
- example_contract_2
- src
- src
- proc_table
- tests/integration
- validator
- src
- test_files
- native_validator
- src
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
49 files changed
+5337
-256
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
3 | | - | |
4 | | - | |
5 | 1 | | |
6 | 2 | | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
16 | 7 | | |
17 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
18 | 12 | | |
19 | | - | |
20 | | - | |
| 13 | + | |
21 | 14 | | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
28 | 27 | | |
29 | | - | |
30 | | - | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
31 | 32 | | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
32 | 104 | | |
| 105 | + | |
33 | 106 | | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
41 | 129 | | |
42 | | - | |
43 | | - | |
44 | | - | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
0 commit comments