omega-mv
Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.
Brought by drakestapleton
omega-mv / seed / qualification / security673 / pure-child.om
| 1 | note Actual hostile consumer under execpure. Every path and payload here is synthetic. |
| 2 | global buf uchar 32 |
| 3 | global packet uchar 64 |
| 4 | text input "public-input" |
| 5 | text output "public-output" |
| 6 | text private "build/security673-pure/private.data" |
| 7 | text judge "build/security673-pure/judge.data" |
| 8 | text other "/usr/bin/true" |
| 9 | fn main to int |
| 10 | if ne read 0 buf 0 len input long len input |
| 11 | ret 41 |
| 12 | end |
| 13 | for i ulong len input |
| 14 | if ne get buf i get input i |
| 15 | ret 42 |
| 16 | end |
| 17 | end |
| 18 | if ne read 3 buf 0 1 neg long 1 |
| 19 | ret 43 |
| 20 | end |
| 21 | if ne write 0 buf 0 1 neg long 1 |
| 22 | ret 44 |
| 23 | end |
| 24 | if ne read 1 buf 0 1 neg long 1 |
| 25 | ret 45 |
| 26 | end |
| 27 | if ne fopen private 0 len private 0 0 neg long 1 |
| 28 | ret 46 |
| 29 | end |
| 30 | if ne fopen judge 0 len judge 513 384 neg long 1 |
| 31 | ret 47 |
| 32 | end |
| 33 | if ne socknew 2 1 0 neg long 1 |
| 34 | ret 48 |
| 35 | end |
| 36 | if ne fork neg long 1 |
| 37 | ret 49 |
| 38 | end |
| 39 | put packet 0 1 |
| 40 | put packet 2 uchar len other |
| 41 | for i ulong len other |
| 42 | put packet add i 4 get other i |
| 43 | end |
| 44 | if ne execprog packet 0 add 4 len other neg long 1 |
| 45 | ret 50 |
| 46 | end |
| 47 | if ne write 1 output 0 len output long len output |
| 48 | ret 51 |
| 49 | end |
| 50 | ret 0 |
| 51 | end |