Polaris, Identity Token System
Copyright 2026 Egor Khaklin

This product is licensed under the Apache License, Version 2.0 (see the
LICENSE file at the root of this repository, or
http://www.apache.org/licenses/LICENSE-2.0).

The license text is carried once, at the repository root. The four packages
(polaris_sql, polaris_web, polaris_cli, polaris_zk) are parts of this one work,
not separately distributed projects, so none carries its own copy; polaris_zk
declares `license = "Apache-2.0"` in its Cargo manifest, which is what a Rust
consumer reads.

================================================================================
About this work
================================================================================

Polaris is a reference implementation of a national identity token system:
ML-DSA-65 signatures under an audited algorithm-migration path, zero-knowledge
verification, and an append-only audit of record, enforced in the database
schema rather than in policy. What the cryptography does and does not buy,
including what a break in the underlying lattice assumption would cost, is
stated in docs/PRODUCTION-READINESS.md.

It began as the author's project for SCS-230 (Database Management Systems)
at Seton Hill University in spring 2026 and is maintained as a working
reference implementation on notional data. It has never held real identity
data, it is not deployed to any population, and the physical token it models
is not manufactured. The constitution (the ten hard constraints C1 to C10 and
the vocation) is MISSION.md.

================================================================================
Components and their separate notices
================================================================================

The Rust prover/verifier in polaris_zk/ depends on the Plonky2 library
(https://github.com/0xPolygonZero/plonky2), used here unmodified. Plonky2
is dual-licensed under MIT/Apache-2.0.

The Atlas (polaris_web/static/atlas-map.js) renders with MapLibre GL JS
(vendored under polaris_web/static/vendor/maplibre-gl.js), 3-Clause BSD,
copyright MapLibre contributors; original license header preserved in the
vendored source. The street-level basemap uses CARTO's free dark-matter
vector tiles, which are derived from OpenStreetMap data (© OpenStreetMap
contributors, ODbL) and served by CARTO (© CARTO); both are attributed in
the on-map attribution control. D3 and TopoJSON (both BSD-3-Clause) are
vendored for the earlier globe renderer; original copyright notices are
preserved in the vendored source.

The web application uses Flask, Werkzeug, psycopg2 and redis-py. Each
retains its own license; consult requirements.txt for versions and the
upstream repositories for license text. Named specifically because it is the
one dependency whose license is not permissive: psycopg2 (used through the
psycopg2-binary wheel) is LGPL 3 with an OpenSSL exception. It is used as an
unmodified library through its public API, which is the use the LGPL is
written for; its terms attach to psycopg2 itself, not to this work. A
redistributor who MODIFIES psycopg2 takes on the LGPL's obligations for that
modified copy.

Every other dependency of every package (Python, Rust and npm) is under a
permissive license: Apache-2.0, MIT, BSD-2/3-Clause, PSF-2.0, or a dual
MIT/Apache-2.0. None is incompatible with this work's Apache 2.0 license, and
none imposes a copyleft obligation on it.

The macOS launcher (Polaris.command + polaris_mac_launch.sh) is original
to this work.

The academic project report polaris_project_report.pdf and its TeX source
polaris_project_report.tex are part of the same release and inherit the
same Apache 2.0 license. The report's bibliography credits external
sources under fair-use academic citation conventions.

================================================================================
Attribution
================================================================================

If you build on Polaris, whether the code, the schema, or its patterns
(the audit-of-record discipline above all), retain the LICENSE and NOTICE
files and the author attribution, per Apache 2.0 section 4.

The audit-of-record discipline is the project's central methodological
contribution: state-changing decisions are recorded in the schema by
append-only tables guarded by triggers, and on the filesystem by
CHANGELOG.md and the git history. The same discipline applies at the
license level: provenance is preserved.
