{"id":50486889,"url":"https://github.com/systemslibrarian/crypto-lab-garbled-gate","last_synced_at":"2026-06-01T23:02:45.470Z","repository":{"id":350925884,"uuid":"1208801436","full_name":"systemslibrarian/crypto-lab-garbled-gate","owner":"systemslibrarian","description":null,"archived":false,"fork":false,"pushed_at":"2026-04-12T19:33:30.000Z","size":99,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-12T21:12:11.694Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://systemslibrarian.github.io/crypto-lab-garbled-gate/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/systemslibrarian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"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":"2026-04-12T19:01:48.000Z","updated_at":"2026-04-12T19:42:52.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/systemslibrarian/crypto-lab-garbled-gate","commit_stats":null,"previous_names":["systemslibrarian/crypto-lab-garbled-gate"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/systemslibrarian/crypto-lab-garbled-gate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/systemslibrarian%2Fcrypto-lab-garbled-gate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/systemslibrarian%2Fcrypto-lab-garbled-gate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/systemslibrarian%2Fcrypto-lab-garbled-gate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/systemslibrarian%2Fcrypto-lab-garbled-gate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/systemslibrarian","download_url":"https://codeload.github.com/systemslibrarian/crypto-lab-garbled-gate/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/systemslibrarian%2Fcrypto-lab-garbled-gate/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33797128,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-01T02:00:06.963Z","response_time":115,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2026-06-01T23:02:44.112Z","updated_at":"2026-06-01T23:02:45.460Z","avatar_url":"https://github.com/systemslibrarian.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# crypto-lab-garbled-gate\n\n## 1. What It Is\n\nGarbled Gate demonstrates Yao's Garbled Circuits (Yao, FOCS 1986) - the foundational protocol for general-purpose secure two-party computation. A garbled circuit allows two parties to jointly evaluate any boolean function on their private inputs without either party learning the other's input. The garbler encrypts each gate's truth table under random wire labels; the evaluator decrypts gate by gate, learning only the output. Input wire labels are exchanged using Oblivious Transfer, ensuring neither party learns more than the protocol output. The canonical application is Yao's Millionaire's Problem: who is richer, without revealing actual wealth.\n\n## 2. When to Use It\n\n- ✅ Two-party computation of any boolean function with semi-honest security\n- ✅ Private set intersection, private comparison, secure auctions\n- ✅ As the Boolean component in mixed-protocol MPC (ABY-style)\n- ✅ When constant-round communication is required (GC evaluates in 2 rounds)\n- ❌ Not practical for very large circuits (millions of gates) without significant optimization and hardware acceleration\n- ❌ Provides only semi-honest security by default - malicious security requires cut-and-choose or authenticated garbling (significant overhead)\n- ❌ Multi-party settings (\u003e2 parties) require GMW or SPDZ extensions\n\n## 3. Live Demo\n\nLink: https://systemslibrarian.github.io/crypto-lab-garbled-gate/\n\nSix exhibits: the Millionaire's Problem motivation, step-by-step garbling of an AND gate with real wire labels and encrypted garbled table, Oblivious Transfer for input wires with Chou-Orlandi OT, the full millionaire's protocol end-to-end on a 3-bit comparison circuit, security analysis and Free XOR/Half Gates optimizations, and real-world deployments in PSI, secure ML inference, and threshold cryptography.\n\n## 4. How to Run Locally\n\n```bash\ngit clone https://github.com/systemslibrarian/crypto-lab-garbled-gate\ncd crypto-lab-garbled-gate\nnpm install\nnpm run dev\n```\n\n## 5. Part of the Crypto-Lab Suite\n\nPart of [crypto-lab](https://systemslibrarian.github.io/crypto-lab/) - browser-based cryptography demos spanning 2,500 years of cryptographic history to NIST FIPS 2024 post-quantum standards.\n\nSo whether you eat or drink or whatever you do, do it all for the glory of God. — 1 Corinthians 10:31","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsystemslibrarian%2Fcrypto-lab-garbled-gate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsystemslibrarian%2Fcrypto-lab-garbled-gate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsystemslibrarian%2Fcrypto-lab-garbled-gate/lists"}