Mohar (PoL)

Teacher eligibility checks a school can prove years later, even after the platform is deleted.

Mohar (PoL)

Created At

ETHGlobal Mumbai

Project Description

In April 2025 India’s Supreme Court upheld the cancellation of 25,753 school appointments in West Bengal. The records that could have separated honest appointees from fraudulent ones had been destroyed, so everyone lost their job together. In September 2025 the same Court ruled that every in-service teacher must hold the Teacher Eligibility Test (TET) by 31 August 2028, and every school in the country will have to show that it checked. India’s Digital Personal Data Protection Rules add a duty, commencing 13 November 2026, to keep tamper-evident records of consent.

Mohar is the record of that check. A teacher holds an eligibility credential signed by the issuing body and presents only the eligibility claims to a school, under a purpose-scoped consent; the certificate’s date of birth, category, family names and marks stay hidden. The school verifies the credential and signs a receipt. Each term the school re-checks the credential’s status and signs a re-check receipt, so a cancelled certificate is caught mid-year. Commitments to the consent, the presentation and the receipts are written to an append-only log whose batch roots are anchored to Ethereum Sepolia and to Bitcoin through OpenTimestamps.

An inspector verifies any receipt against both anchors with nothing from the platform. In the demo, the platform’s databases are deleted on camera and the receipt still verifies. The live inspector page carries a sample bundle whose Bitcoin proof is complete, and anyone can repeat the check.

What Mohar does not do: it does not issue credentials, does not decide eligibility, and does not make a certificate honest. The issuer in this version is simulated. Mohar provides a cryptographic record of timing, authorship and consent, not a claim of legal compliance.

How it's Made

Node 22, plain ESM JavaScript, no framework. Credentials are SD-JWT verifiable credentials (RFC 9901) issued with @sd-jwt/core and signed with Ed25519 through jose. The issuer is a did:web with a static DID document; the teacher and the school are did:key. Selective disclosure lets the teacher reveal five eligibility claims and withhold the rest of the certificate, and a key-binding token ties each presentation to the school’s nonce and to the consent record. Credential status is an IETF Token Status List served as a static file; the verifier reports not_revoked, revoked or unknown, and never shows unknown as valid.

The log service receives only commitments: SHA-256 over a domain tag, a 32-byte random salt and the signed record. A public root reveals nothing about the record, even to someone who already holds it. Entries form a hash chain; each batch closes into a Merkle root bound with the batch header, and the batch root is written as calldata in an ordinary Ethereum Sepolia transaction and stamped with OpenTimestamps. Every accepted commit returns an acknowledgement signed by the operator key, which the teacher and the school keep; two acknowledgements for one sequence number with different entries are a proof of rollback, and a CLI subcommand produces it.

The inspector is one self-contained HTML file built with esbuild (about 1 MB, 1,471 bundled modules) hosted on GitHub Pages. It checks the receipt signature, the chain entry, the Merkle path, the Sepolia calldata, the Bitcoin proof and the acknowledgement, each as a separate pass or fail line, with the OpenTimestamps verification done in the browser through a block explorer. The school and log services run on Railway with SQLite on persistent volumes. Tests run with node --test; the privacy tests run first in CI and include deleting both databases and verifying an exported bundle offline.

Worth noting: the anchor is calldata rather than a contract, and the verifier fetches one transaction and compares bytes. The demo deletes the live log on camera. Salted commitments and signed acknowledgements were both added during the event after audit findings, with the earlier batches discarded and re-anchored. No partner technologies were used.

The code was written by AI coding agents working from me instructions. The author made every design decision, commissioned every audit (each run by a separate AI agent) and ruled on its findings.

background image mobile

Join the mailing list

Get the latest news and updates

Mohar (PoL) | ETHGlobal