{"id":29110501,"url":"https://github.com/matter-labs/zksync-os","last_synced_at":"2026-02-27T11:29:45.940Z","repository":{"id":296918661,"uuid":"986453846","full_name":"matter-labs/zksync-os","owner":"matter-labs","description":"Generalized RISC-V based state transition function for the ZKsync protocol","archived":false,"fork":false,"pushed_at":"2026-02-24T15:45:05.000Z","size":228872,"stargazers_count":28,"open_issues_count":33,"forks_count":19,"subscribers_count":7,"default_branch":"main","last_synced_at":"2026-02-24T16:46:22.869Z","etag":null,"topics":["zk","zksync"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/matter-labs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":"supporting_crates/ACKNOWLEDGEMENTS.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-05-19T16:23:04.000Z","updated_at":"2026-02-03T11:53:55.000Z","dependencies_parsed_at":"2026-01-29T15:05:41.018Z","dependency_job_id":null,"html_url":"https://github.com/matter-labs/zksync-os","commit_stats":null,"previous_names":["matter-labs/zksync-os"],"tags_count":69,"template":false,"template_full_name":null,"purl":"pkg:github/matter-labs/zksync-os","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matter-labs%2Fzksync-os","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matter-labs%2Fzksync-os/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matter-labs%2Fzksync-os/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matter-labs%2Fzksync-os/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/matter-labs","download_url":"https://codeload.github.com/matter-labs/zksync-os/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matter-labs%2Fzksync-os/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29892099,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-27T09:48:51.284Z","status":"ssl_error","status_checked_at":"2026-02-27T09:48:43.992Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["zk","zksync"],"created_at":"2025-06-29T08:38:23.227Z","updated_at":"2026-02-27T11:29:45.916Z","avatar_url":"https://github.com/matter-labs.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ZKsync OS\n\n[![Logo](zksync-os-logo.png)](https://zksync.io/)\n\nZKsync OS is a new state transition function implementation that enables multiple execution environments (EVM, EraVM, Wasm, etc.) to operate within a unified ecosystem. It is implemented in Rust and compiled into a RISC-V binary, which can later be proven using the `zksync-airbender`.\n\n## Documentation\n\nThe most recent documentation can be found here:\n\n- [In-repo documentation](./docs/README.md)\n\n## Crates\n\nThe project contains the following crates (the list is not complete):\n\n* [zk_ee](./zk_ee/) - execution environment\n* [zksync_os](./zksync_os/) - operating system - that can handle multiple execution environments. Compiled into RISC-V.\n* [zksync_os_runner](./zksync_os_runner/) - allows running programs on zksync_os using RISC-V simulator.\n* [basic_system](./basic_system/) - basic implementation of zk_ee::system and system functions\n* [basic_bootloader](./basic_bootloader/) - implementation of bootloader and main execution loop\n* [evm_interpreter](./evm_interpreter/) - EVM execution environment\n* [forward_system](./forward_system/) - implementation for \"forward\" running (sequencing)\n\n## How to build\n\n### One-Time Setup\nRun the following commands to prepare your environment (only needed once):\n\n```\nrustup target add riscv32i-unknown-none-elf\ncargo install cargo-binutils \u0026\u0026 rustup component add llvm-tools-preview\n```\n\nZKsync OS should be built for 2 targets:\n- your platform, this will be used in the sequencer to execute blocks\n- RISC-V, this is a program that will be proved using RISC-V prover\n\n### Build for your platform\n```\ncargo build --release\n```\n\n### Build for RISC-V\n\nNavigate to the `zksync_os` directory and run:\n```\n./dump_bin.sh --type for-tests\n```\n\n## Testing\n\n### Integration tests\n\n**To run the integration tests you should build ZKsync OS first, see the `building` section above**\n\nIntegration tests are located in the `tests` folder. You can run them as regular cargo tests.\n\nFor example, to run basic tests that execute a few ERC-20 calls using different tx types use:\n```\ncargo test --release -p transactions -- --nocapture\n```\n\n### Proving\n\nYou can run proving by enabling the `e2e_proving` feature while running tests, for example:\n```\ncargo test --release --features e2e_proving -p transactions -- --nocapture\n```\n\n### Alternative proving workflow with Prover CLI\n\n**Generating the CRS File**\n\nYou can set the `CSR_READS_DUMP` env variable to dump CSR reads for proving (witnesses) and then run any test.\nIt will create a CSR file with the path `CSR_READS_DUMP`.\n\n**Using the Prover CLI**\n\nThe Prover CLI is part of the `zksync-airbender` repository, located in the [tools/cli](https://github.com/matter-labs/zksync-airbender/tree/main/tools/cli) directory.\n\nRun the following from the zksync-airbender repository:\n\n```\nmkdir zkee_output\n\ncargo run --profile cli --no-default-features -p cli prove --bin ../zksync-os/zksync_os/for_tests.bin --input-file ${CSR_READS_DUMP} --output-dir zkee_output\n```\n\nThis generates multiple proof files in the `zkee_output` directory. For recursion (compressing proofs into fewer files), refer to the instructions in the `zksync-airbender` repository.\n\n\n### Proving workflow with anvil-zksync\n\n1. Build ZKsync OS\n2. Run anvil-zksync\n3. Send transactions\n4. Tell prover cli to get the witnesses from anvil-zksync\n\n**Anvil ZKsync**\n\nRun [anvil-zksync from GitHub](https://github.com/matter-labs/anvil-zksync) - **IMPORTANT** - make sure to use the `zkos-dev` branch.\n\n```shell\ncargo run  -- --use-zkos --zkos-bin-path=../zksync-os/zksync_os/for_tests.bin\n```\n\n**Send transactions**\n\nYou can use any tool (for example, forge) to send transactions to the anvil binary.\n\n**Tell prover cli to get the witnesses from anvil-zksync**\n\nFrom the zksync-airbender repo:\n```\n    cargo run --no-default-features -- run --bin ../zksync-os/zksync_os/for_tests.bin --input-rpc http://localhost:8012 --input-batch 15\n```\n\nYou can get the witness via the RPC call, where you pass the batch ID as a parameter:\n\n```\nhttp POST http://127.0.0.1:8011 \\\n    Content-Type:application/json \\\n    id:=1 jsonrpc=\"2.0\" method=\"zkos_getWitness\" params:='[1]'\n```\n\n## Policies\n\n- [Security policy](SECURITY.md)\n- [Contribution policy](CONTRIBUTING.md)\n\n## License\n\nZKsync OS is distributed under the terms of either\n\n- Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or \u003chttp://www.apache.org/licenses/LICENSE-2.0\u003e)\n- MIT license ([LICENSE-MIT](LICENSE-MIT) or \u003chttps://opensource.org/blog/license/mit/\u003e)\n\nat your option.\n\n## Official Links\n\n- [Website](https://zksync.io/)\n- [GitHub](https://github.com/matter-labs)\n- [ZK Credo](https://github.com/zksync/credo)\n- [Twitter](https://twitter.com/zksync)\n- [Twitter for Developers](https://twitter.com/zkSyncDevs)\n- [Discord](https://join.zksync.dev/)\n- [Mirror](https://zksync.mirror.xyz/)\n- [Youtube](https://youtube.com/@zksync-io)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatter-labs%2Fzksync-os","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatter-labs%2Fzksync-os","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatter-labs%2Fzksync-os/lists"}