Every SQL aggregate, native speed. No decryption required. The geometry — and the analytics — survive.
GIGI's gauge-equivariant encryption protects payload content while preserving every property your queries need — geometric and analytical. SUM, AVG, MIN, MAX, RANGE, equality, k-NN — all resolve at native server speed on the encrypted bundle, because encryption, in the fiber-bundle formulation, is a coordinate transform on the fiber, not a content cipher. Post-quantum delegation (ML-KEM + lattice threshold), tamper-evident audit (Curvature-MAC + holonomy ledger), public deterministic verification of the invariant fingerprint, and credential-gated invariant queries compose on top.
For each capability a cryptographer would want on encrypted data: what the standard does, what GIGI does, and what changes. The right-hand column is the operational delta.
subtle::ConstantTimeEq. Constant-time by discipline: the byte loop exists, the discipline says don't short-circuit it; compilers occasionally re-introduce shortcuts.u64; equality is a single x86_64 cmp instruction through the bitmap-index probe. No byte loop exists to short-circuit, by construction.c under the same gauge g, then probe the encrypted B-tree at native speed. Order preserved iff a > 0; equality is always bijective.ρg−1 inversion. Eleven aggregates shipped: SUM, AVG, MIN, MAX, VAR, STDDEV, RANGE, MEDIAN, QUANTILE, ARGMIN, ARGMAX — all native server speed, O(1) client work, no bootstrapping. Order statistics under Probabilistic-mode noise are bias-refused at the API with a typed BiasedUnderProbabilisticNoise error rather than silently overshooting.aggregate_helpers.rs · 24 unit tests · bias-refusal API for order statistics under noise.IAff (range, equality, distance) and the branches are equivariant operations — covers most analytical SQL. Server evaluates the predicate at native B-tree speed; branches resolve at native aggregate speed.IAff.ρg−1 (one scalar inversion) then calls the transcendental on the recovered scalar. One transcendental evaluation per query, at full precision.transcendental(aggregate(v)) at the client (previous row).rkA→B = g2skB/skA; Kshared = e(C1, rk). Security reduces to BDH on GT + DLP on G2.K-of-N over Fp (information-theoretic) wrapped in per-share ML-KEM-768 transport (PQ IND-CCA).K−1 + PQ transport.(timestamp, op_id, holonomy_delta, record_hash, op_kind). Audit by the telescope identity Hol(BT) = Hol(B0) + Σ Δt.gt+1 = HKDF-SHA256(record_bytes ‖ t, gt). Retention horizon R drops checkpoints below T − R; old keys computationally unrecoverable past horizon.πinv = (K, λ1, 〈Hol〉, τ, β0, β1) at 10−10 quantization. Layered with holonomy ledger for byte-level evidence.χ2(k, 1−α) threshold. Two encrypted-side variants: scalar isotropic (ball preserved) and field-wise (ball → ellipsoid).πinv from ciphertext alone, compare to prover's claim. Sub-ms verification on a 1k-record bundle. Deterministic, not ZK."GIGI_v0.4_credential_v1", constant-time tag comparison, bound to (user_commit, query_class, bundle_id). BBS+ unlinkability is the pinned v0.5 upgrade path.IAff. v0.5: full CL-style unlinkability via BBS+; PQ path via Beullens-Dobson-Katsumata lattice-BBS.Nine headline capabilities landed in v0.3 & v0.4: FHE parity for analytical SQL on encrypted bundles, two post-quantum delegation modes, BLS12-381 pairing-based single-party collusion-resistant delegation, the six-component invariant fingerprint with append-only audit ledger, public deterministic verification of that fingerprint by a holder of the ciphertext alone, HMAC-bound credential-gated invariant queries with BBS+ on the v0.5 upgrade path, a dimension-aware geodesic-ball membership index, and the mathematical characterization of which transformation groups preserve K. Every claim has a passing Rust test — 998 lib + 22 v0.4 integration; the paper carries the formal statements.
ρg−1 application. No ciphertext multiplication, no FHE bootstrapping — the aggregate is ρ-equivariant under the affine gauge by construction. Order statistics under noise are bias-refused with a typed error.src/aggregate_helpers.rs · 24 unit tests · O(1) client worksrc/mlkem_delegation.rs · 7 unit tests · NIST Level 3K-of-N split over Fp (information-theoretic) composed with per-share ML-KEM transport (PQ). Any K−1 shareholders learn information-theoretically zero — strictly stronger than DLP-based collusion resistance, with PQ transport on top.src/lattice_delegation.rs · 7 unit tests · PQ + IT-secureGT + DLP on G2 in BLS12-381. Formal security theorem with BDH reduction (paper §6). Pre-quantum; retained alongside the two PQ-safe modes for classical-assumption deployments.src/pairing_delegation.rs · 6 unit tests · ∼2128 workπinv = (K, λ1, 〈Hol〉, τ, β0, β1) at 10−10 quantization. Holonomy ledger appends RFC 6962 Merkle leaves carrying a per-write record_hash for byte-level tamper evidence.src/integrity.rs + src/ledger.rs · 22 testsπinv from ciphertext alone and compares against the prover's claim. Soundness probability 1 in exact arithmetic; ≥ 1 − 2−40 under quantization. No gauge key handed to the verifier — ever.src/invariant_verify.rs · 5 integration + 3 unit testsK, K + K², ...) without revealing identity. Falsification harness rejects K_fake = mean / std² at gauge (3.7, 100). HMAC-SHA256-bound today with domain separator "GIGI_v0.4_credential_v1"; BBS+ unlinkability is the v0.5 upgrade path.src/credentials.rs + src/invariant_ring.rs · 6 integration + 11 unit testsχ2(k, 1−α) threshold via Wilson-Hilferty (~2.5% error at k=1, sub-0.5% for k≥3). Scalar-gauge ball preserved; field-wise gauge handled via ellipsoidal check. Explicit leakage scope: centroid + covariance + count + gauge type, not a hiding primitive.src/membership_index.rs · 6 integration + 4 unit tests(ℝ*)k ⊹ ℝk is the exact K-preserving subgroup of Aff(ℝ)k. Tests confirm: shear breaks per-field K, diagonal affine preserves it bit-identically, rotation preserves tr(Cov) but not (max−min)2, LWE samples are K-statistically indistinguishable from uniform random.tests/k_preserving_v0_4.rs · 5 integration tests · roadmap-only sprintEncryption, in GIGI's formulation, is a change of coordinates on the fiber. The stored payload is the plaintext acted on by a private group element — the GaugeKey. Any geometric quantity that is invariant under coordinate change is invariant under encryption. Curvature, holonomy, Betti numbers, spectral gap, confidence — all unchanged. And the equality query, expressed geometrically as a point coincidence check, inherits the constant-time property from the structure of the lookup itself.
Think of it as a secret rotation applied to every stored value. Without the rotation key, the ciphertext looks like random gibberish that still has the same shape as the original — same distances, same curves, same relationships. With the key, you can un-rotate and see the plaintext. The engine never un-rotates; it operates on the rotated values directly, and because the rotation preserves shape, every geometric question returns the same answer.
Capacity C is a ratio of gauge-invariant quantities — tolerance τ and curvature K are both coordinate-free. Because gauge transforms preserve both, they preserve C. Encryption, being a gauge transform, cannot alter any GIGI measurement that depends on C. This is why GIGI's curvature, confidence, and capacity queries return identical values on plaintext and encrypted bundles.
Two keys are equal if they land on the same point. Asking "are these two points the same point?" takes one lookup, always, no matter what the points are. There is no loop that can exit early. There is no sequence of comparisons whose length depends on the input. The duration of the question is decoupled from the content of the question, and that is exactly what a timing-side-channel attacker cannot exploit.
Sameness (S) and squared deviation (d²) always sum to unity. When two encrypted values are equal, d² = 0 and S = 1; when they're not, d² = 1 and S = 0. The identity collapses to a binary in this case, and the collapse is the single-lookup equality. No intermediate comparison exists to be measured.
The stored key lives as a section on a bundle with an ENCRYPTED fiber. Try each test submission against it. The round-trip time stays flat — whether the submission matches exactly, almost matches, or is pure noise. The distribution below proves it across 500 comparisons.
There is no byte-wise loop to short-circuit. The submitted key is projected to a point on the fiber bundle; equality is a single lookup against the stored point's location. Duration depends on neither key content nor how many leading bytes agree.
Pick a dataset. Set a secret gauge (a, b). Run an aggregate query. The server sees only the encrypted column. The aggregate is computed directly on ciphertext at native speed. The client applies ρ-1 to a single number to recover the result. The recovered value matches the plaintext aggregate exactly.
(a, b) never left the client. Switch aggregates: COUNT is fully gauge-invariant (no decrypt needed); SUM / AVG / MIN / MAX / VAR / STDDEV each have a different closed-form ρ-1. Theorem 3.1 of the paper proves these are exactly the ciphertext-computable aggregates.
The four numbers at the bottom of each panel are identical — that is the demonstration, not a bug. The shape deforms under a gauge transform on the fiber (encryption) and the sample coordinates listed below each panel do differ point-by-point. But scalar curvature, holonomy, confidence, and β₁ are invariants of the manifold, not properties of any particular coordinate chart, so they read identically on both sides. Press Animate gauge transform to sweep the gauge parameter θ through a full cycle: per-section coordinates move, the four invariants stay pinned.
GIGI Encrypt is the full packaging of gauge-invariant encryption as a first-class product surface. Some primitives—affine numeric encryption, the base-hashed O(1) lookup, curvature and spectral-gap invariance—have lived inside GIGI since 0.5.0 as engine building blocks. What's new is the full cryptographic suite built on top: every fiber type encrypted, every gauge-invariant query directly callable, equality structurally constant-time, dual-seed forward-secret key rotation, and a randomized numeric mode that still answers equality queries via the Davis Identity. Every claim below is a theorem with a passing math test in encryption_strong_claims_validation.py (34/34 tests pass across two suites).
cmp instruction—not a loop over bytes. Libraries like subtle::ConstantTimeEq offer "no content-dependent branching inside a byte loop." GIGI offers "there is no byte loop." This is strictly stronger: a compiler cannot accidentally reintroduce a short-circuit that does not exist. Fiber bytes are never read on the equality path; instrumentation confirms zero fiber-byte reads on misses. (The hash G itself processes a fixed canonical length per column, so its timing depends on schema, not content.)PROJECT INVARIANT is the query form that never decrypts. For any analytics workload expressible in the invariant ring, the number of bytes decrypted is exactly zero. (Čech H¹ is on the Band 2 horizon — the math is in place but a base-only sheaf computation that maintains the no-decrypt guarantee hasn't shipped yet.) Raw-row projection PROJECT (label, tier) still exists and decrypts only the matched rows — but the headline "zero plaintext materialized" attaches structurally to the analytics surface, not to a discipline the operator must remember to follow.Before the math drill-downs: a one-glance translation from the primitives your stack already knows to the GIGI capability that answers the same need. Then 13 shipping features with click-to-expand math, mechanism, and real numerical evidence.
cmp through a HashMap probe. No byte loop exists for a compiler to re-introduce a short-circuit. Strictly stronger than loop-body discipline.OPAQUE text/binary mode. Per-record nonce, authenticated, tamper-detected on decrypt. Direct AES-GCM-SIV instantiation on payloads where no indexed access is needed.INDEXED PRF mode. Keyed deterministic hash (AES-256-CMAC / keyed SipHash). Same plaintext → same ciphertext, so the categorical bitmap index & O(1) equality survive.PROBABILISTIC mode + Davis Identity. S + d² = 1 makes equality a distance check. Two encryptions of the same value differ (statistical unlinkability at schema-declared σ); equality still resolves in a HashMap probe.GAUGE ROTATE_KEY FORWARD_SECRET: rotate base-hash seed s and GaugeKey g, coarse-grain the pre-rotation snapshot. Post-compromise recovery: 0.00%.PROJECT INVARIANT (...) evaluates curvature, confidence, capacity(τ), spectral gap, β₀, β₁, holonomy_avg on ciphertext with 0 bytes decrypted (per-thread instrumented counter assertion). Tighter and faster than FHE for geometric workloads.a₂/a₁, b₂−b₁·a₂/a₁). Streaming pass over storage; 0 bytes of plaintext materialized.The full matrix below gives the math, the mechanism, and the captured numerical evidence for each primitive. Every row has a passing test in the math validation suite (34/34 across two Python suites on N = 10,000 curvature samples and N = 20,000 Davis-Identity trials), a passing Rust regression test in the gigi engine (667 lib + 50 binary tests), and a passing live e2e check against gigi-stream.fly.dev (25 e2e checks).
E_ZeroBytesDecrypted::test_curvature_on_ciphertext_equals_curvature_on_plaintext. Engine: geo_enc_2_curvature_invariant, geo_enc_3_confidence_invariant, geo_enc_11_batch_curvature_invariant in gigi/src/bundle.rs; test_project_invariant_works_on_encrypted_bundle in gigi/src/invariant.rs. Live: POST /v1/gql {"query": "PROJECT INVARIANT (curvature) FROM b"}.DavisLawInvariantChain::test_davis_law_invariant_under_full_affine. Engine: callable from GQL as PROJECT INVARIANT (capacity(tau)) FROM b; pinned by test_project_invariant_capacity_davis_law + test_project_invariant_capacity_invariant_under_encryption in gigi/src/invariant.rs. capacity is part of the no-decrypt invariant ring — computing it on an encrypted bundle triggers zero decrypt calls.geo_enc_4 in bundle.rs(w − b) / a, exact up to float64 round-trip. Deterministic: same plaintext → same ciphertext (feature, for indexed equality).geo_enc_1INDEXED is deterministic encryption. Same plaintext → same ciphertext means an adversary with population statistics can map ciphertexts to plaintexts by frequency alone, without breaking the PRF. INDEXED is therefore intended for high-cardinality columns (UUIDs, row keys, 64-bit IDs) where frequency analysis yields no useful signal. Low-cardinality categoricals (gender, zip, diagnosis code) must use OPAQUE (randomized, unqueryable) or PROBABILISTIC (randomized, queryable via Davis Identity). The schema designer declares the mode per column. Test class: Ask1_TextEncryption — 4 tests pass. Reference PRF: HMAC-SHA256 in the Python suite; production target: AES-256-CMAC.Ask1_TextEncryption — AEAD indistinguishability + tampering detection tests. Production target: AES-256-GCM-SIV (RFC 8452, nonce-misuse-resistant).cmp instruction
subtle::ConstantTimeEq (stronger)
›
cmp instruction. Libraries like subtle::ConstantTimeEq promise "no branching inside a byte loop." GIGI promises: there is no byte loop.u64 mul/xor/shift, constant by emissionpending scopebool; no byte loop exists in the source. (2) Hash-step timing depends on schema-fixed canonical_len, not content; see the median-based evidence above. The Python-level dudect Welch t of −26 on N = 20,000 is dominated by Python BigInt multiplication latency in the reference wyhash implementation and does not reflect the shipping Rust path, which compiles to three operand-independent u64 instructions. An oscilloscope-resolution dudect test against the Rust binary is planned. (3) HashMap-probe timing — probe sequences are in principle data-dependent. Adversarial hash-collision attacks are mitigated by the keyed hash seed s: without access to s an attacker cannot construct inputs producing adversarial probe sequences. Rotation of s (see forward-secret row) voids any collisions learned before rotation. Test class: A_StructuralConstantTime — 4 tests pass including test_dudect_welch_t_on_hash_timing.B_GaugeCovariantHolonomy — 2 tests pass in encryption_strong_claims_validation.py. Engine: the affine-gauge holonomy with the Γ = Δv / range connection 1-form is computed by the HOLONOMY top-level GQL statement, which reads fiber values (decrypts on encrypted bundles). For the structural 0-decrypt invariant ring there is a base-only proxy holonomy_avg (defined as β₁ / (β₀ + 1) over the base-point graph) that captures cycle-richness without ever reading fiber values; pinned by test_project_invariant_holonomy_avg_invariant. So callers willing to decrypt get the precise affine-gauge holonomy; callers needing 0-decrypt analytics get the base-only proxy — both available via GQL.β_k(E) = Σ β_i(B)·β_j(FG) assumes a trivial bundle. For pure primary-key-driven tabular access this holds; for non-trivial bundles (e.g. base-fiber coupling via foreign keys that encode fiber values), additional structure must be verified. β₀ and β₁ are demonstrated on the tested schemas; higher βk≥2 vanish trivially for tabular data but the Leray argument generalizes to any schema whose bundle structure is trivial. Test class: F_FullBundleBetti — 2 tests pass.PROJECT INVARIANT (…) is the query form that never decrypts — for any analytics workload expressible in R, bytes decrypted = 0.DavisLawInvariantChain, E_ZeroBytesDecrypted_UnderInvariantQueries in encryption_strong_claims_validation.py. Engine: gigi/src/invariant.rs::test_project_invariant_zero_decrypt_calls_in_execution_path instruments a per-thread decrypt counter inside FieldTransform::decrypt_value and GaugeKey::decrypt_fiber, runs every op (curvature, confidence, capacity(τ), spectral_gap, beta_0, beta_1, holonomy_avg) on a fully-encrypted bundle, and asserts the counter stays at 0. Whitelist enforcement is at parse time: PROJECT INVARIANT (sum) FROM b is a syntax error, not a runtime error — a query that compiles is one whose evaluator is structurally proven never to reach a decryption code path. Live API: POST /v1/gql {"query": "PROJECT INVARIANT (curvature, capacity(0.1), holonomy_avg) FROM b"} on gigi-stream.fly.dev.D_DavisIdentity_NeighborhoodEquality.C_BaseHashRotation_ForwardSecrecy — 2 tests pass. Engine: BundleStore::rotate_key in gigi/src/bundle.rs drives both the GaugeKey seed g and the base-space hash seed s from a single 32-byte master via domain-separated mixing; the rotation is built off-side and atomic-swapped (test_rotate_key_atomicity_via_wal_in_process). Forward-secrecy properties pinned by:
test_rotate_key_old_gauge_cannot_decrypt_post_rotation (gauge half),
test_rotate_key_old_seed_cannot_lookup_post_rotation (1000 keys, ≤5 collisions = effectively 0% hit rate — the base half),
test_rotate_key_record_count_invariant,
test_rotate_key_two_consecutive_rotations (chain forward secrecy),
test_rotate_key_curvature_after_rg_step_increases_or_equal (RG flow ΔS ≥ 0),
test_rotate_key_concurrent_writes_block_during_rotation. Live e2e: e2e/encrypt_v02_live_test.mjs runs the full rotation cycle against gigi-stream.fly.dev.
Ask6_KeyRotation — 2 tests pass in encryption_math_validation.py. Engine: BundleStore::rotate_key_affine_closure in gigi/src/bundle.rs walks the storage layer, applies the affine rekey directly to ciphertext, and instruments the per-thread decrypt counter; test_rotate_key_affine_closure_zero_decrypt_calls asserts the counter stays at 0 across the rekey of 100 records. Mixed-mode bundles (OPAQUE/INDEXED/PROBABILISTIC) have no Aff(ℝ) closure and fall through to the standard rotate_key decrypt+re-encrypt path; the closure fast-path applies to AFFINE-only schemas.GROUP wind { wind_x, wind_y, wind_z } ENCRYPTED ISOMETRIC), sample a random orthogonal matrix O from the seed via QR decomposition of a Gaussian matrix. Orthogonal transforms preserve the Fisher metric exactly — pairwise distances unchanged to machine precision.Ask4B_IsometricEncryption — 3 tests pass in the rev-1 suite.src/integrity.rs · 10 unit tests · paper §3.5 documents the f64 quantization rationale; layered with the Holonomy ledger (next entry) for byte-level tamper evidence.K-of-N over the secp256k1 base field Fp, framed as Čech reconstruction on the share-holder cover. Each share carries an HMAC-SHA256 auth tag binding it to (bundle_id, share_index, holder.pubkey), so shares cannot be re-targeted across deployments. Information-theoretic up to the threshold; any subset of size ≤ K−1 recovers zero.src/threshold.rs · spec §6 · composes with ML-KEM transport in the lattice-threshold delegation mode (see headline results above) for PQ + IT-secure delegation.(timestamp, op_id, holonomy_delta, record_hash, op_kind) with internal-node hash SHA-256(0x01 ‖ left ‖ right). The telescope identity Hol(BT) = Hol(B0) + Σ Δt lets an auditor verify the entire log by holonomy difference. The extended record_hash leaf field closes Curvature-MAC's gauge-invariant-content blindspot at byte level.src/ledger.rs · 12 unit tests · spec §5 · paired with Curvature-MAC for invariant-level + byte-level tamper evidence.N writes; retention horizon R drops checkpoints below T − R, making gt for t < T − R computationally unrecoverable. Per-field semantics: INDEXED (deterministic-PRF) fields stay non-ratcheting; all other modes ratchet on write.src/ratchet.rs · 9 unit tests · spec §7 · replaces the v0.2 epoch-coarse-grain rotation with continuous per-write advancement; old plaintext recovery rate measured at 0.00% past the horizon on 1,000-key tests.GaugeKey Affine / Isometric / Identity transforms into a per-field capability the proxy applies on ciphertext — never touches plaintext. Honest framing: this is recipient-applied key-delegation, not strict collusion-resistant proxy re-encryption. A Bob+capability+own-key coalition recovers Alice's key (algebraic recovery; documented in spec §4.7 as Limitation 4.7.1). For deployments needing collusion-resistance, use the pairing or threshold paths.src/delegation.rs · 11 unit tests · the collusion-recovers-Alice-key test is load-bearing — it passes by design and the limitation is documented in the paper.sk ∈ Fp, pk = g2sk ∈ G2. KEM capsule C1 = g1r ∈ G1. Delegatee applies the capability themselves via pairing (the proxy is a non-cryptographic transport). Single-party collusion-resistance under BDH on GT + DLP on G2; formal theorem with BDH reduction in paper §6.src/pairing_delegation.rs · 6 unit tests including collusion-resistance verification · pre-quantum (broken by Shor's); the two PQ-safe modes (ML-KEM trusted + lattice threshold) cover the post-quantum threat models.src/mlkem_delegation.rs · 7 unit tests · closes the BLS12-381 quantum gap for the trusted-delegatee threat model.K-of-N split (information-theoretic) wrapped in per-share ML-KEM transport (PQ IND-CCA). Any K−1 colluding shareholders learn information-theoretically zero about the delegated payload; transport is PQ-safe under MLWE. The strictly stronger collusion-resistance property than BLS12-381's DLP-based resistance, at the cost of being a multi-party deployment shape.src/lattice_delegation.rs · 7 unit tests · exhaustively verified for (K=3, N=5) across all 10 collusion subsets in tests/fhe_pq_parity_rigor.rs::b2_*_subset_*.O(1) client work per query, independent of bundle size. Value aggregates (SUM, AVG, VAR, STDDEV) invert via the affine map; order statistics (MIN, MAX, RANGE, MEDIAN, QUANTILE) use the same inverse on Affine mode with sign-aware quantile selection at the query layer; ARGMIN/ARGMAX recover record positions with the joint sign-aware swap automatic. Probabilistic-mode order statistics are bias-refused at the API with a typed BiasedUnderProbabilisticNoise error — the bias cannot leak into application code unnoticed.src/aggregate_helpers.rs · 24 unit tests (16 exactness + 8 bias-refusal) · tests/fhe_pq_parity_rigor.rs 25 integration tests · Python oracle validation_tests_fhe_pq_rigor.py 66/66 pass.πinv from the ciphertext alone and compares to the prover's claim. Rejection returns the first disagreement in canonical fingerprint order (K → λ1 → 〈Hol〉 → τ → β0 → β1). f64 fields use a 10−10 tolerance matching the integrity-tag quantization; u64 fields (record_count, β0, β1) are checked for exact equality.src/invariant_verify.rs · 12 integration + 4 unit tests (including N-3 at 1000 trials, N-5 bundle-id binding, N-6 same-K-different-topology, N-7 end-to-end through EncryptionMode::Affine) · deterministic verification, not zero knowledge — the formal Sigma protocol target (completeness / special soundness / SHVZK) is documented in the v0.4 spec as open work (see v0.4/v0.5 horizon below).invariant_ring::is_in_iaff_harness runtime-falsifies ad-hoc query callbacks by running them on plaintext + 5 random gauges; K_fake = mean / std² is caught at gauge (3.7, 100) with relative error > 0.1. The credential primitive is HMAC-SHA256-bound today with a typed domain separator and constant-time tag comparison; full Camenisch–Lysyanskaya unlinkability via BBS+ is the v0.5 upgrade path (pinned in the v0.4 spec).src/credentials.rs + src/invariant_ring.rs · 6 integration + 11 unit tests · rejects on wrong bundle_id / wrong class / wrong key; 5-way gauge rerandomization with identical K result; closest architectural ancestor: Lysyanskaya's CL anonymous-credential lineage.χ2(k, 1−α) (~2.5% error at k=1, sub-0.5% for k≥3); Beasley-Springer-Moro for the normal quantile. Two encrypted-side variants: encrypted_membership_scalar(v, a, b) for isotropic gauge (ball preserved), encrypted_membership_fieldwise(v, d, b) for per-field gauge (ball → ellipsoid, induced Mahalanobis metric). Explicit leakage scope: (centroid, Σ, χ2-threshold, count, gauge_type) — not a hiding primitive; layer OPAQUE on member-encoding for confidentiality.src/membership_index.rs · 6 integration + 6 unit tests (including the exact χ2 table for k∈{1..5} at p∈{0.95, 0.99} with Wilson-Hilferty fallback elsewhere) · TPR matches 1−α tail bound within sampling deviation; batch-deletion drift averages > 3× single-deletion drift (confirms O(|R|/n) scaling); boundary-adversary false-admit rate documented as open problem (formal membership witness deferred to the v0.5 Sigma-protocol upgrade of the verifier).ai ≠ 0 + per-field translations bi. Shear matrices break K (off-diagonal mixing). Rotations preserve tr(Cov) but break (max−min)2 — an O(k)-invariant trace-K must use squared diameter, not coordinate range (matches paper §3 isometric-mode correction).tests/k_preserving_v0_4.rs · 5 integration tests · no new module: exercises invariant_ring::compute_k against shear / diagonal-affine / rotation / scalar-isotropic / LWE samples. Separates the gauge question (which group preserves K) from the hiding question (what gives PQ confidentiality); the latter is the genuinely open construction in the horizon below.w = (g, σ) satisfying relation R. The additive offset b admits a Schnorr-style proof; the multiplicative scale a ∈ ℝ* is not a finite-field group element and needs a fresh construction — range-bounded a via Pedersen commitments, or a treatment over the reals. Same relation as v0.4; stronger soundness property.GAffK = (ℝ*)k ⊹ ℝk is the exact K-preserving group. The remaining open work is the hiding-side construction: a lattice hiding layer HLWE whose induced action commutes with GAffK, so the verifier can compute K(HLWE(g(σ))) without decrypting. The shipped ML-KEM + Shamir threshold modes cover the multi-party PQ collusion-resistance axis; this construction is the missing single-party + PQ + collusion-resistance combination.A note on industry peers: the "peer" line names the closest mainstream primitive so cryptographers have a bridge. It does not claim equivalence. Every GIGI mechanism derives from gauge theory applied to the fiber bundle — the peer is a translation aid, not a replacement. Where no peer exists (curvature, confidence, spectral-gap invariance, Davis-Identity equality), the capability is GIGI-native and has no direct analog in NIST-standardized cryptography.
Cryptographers read these pages carefully. Here is a one-page, symmetric read: every capability GIGI Encrypt ships today (v0.2 engine + v0.3 + v0.4 cryptographic suites), and the five places it composes cleanly with the rest of a production stack.
ENCRYPTED field is a private gauge ρg applied to the fiber. Affine on numeric, orthogonal on grouped numeric, PRF or AEAD on text/categorical/binary. The 32-byte seed inverts; nothing else does.PROJECT INVARIANT (...) evaluates curvature K, spectral gap λ1, base-graph Betti β0, β1, mean holonomy 〈Hol〉, record-count τ directly on ciphertext. 0 bytes decrypted by construction, not by discipline — pinned by an instrumented per-thread decrypt counter test that runs every op on a fully-encrypted bundle.cmp through the base-hash probe. No byte loop exists for a compiler or speculative executor to exploit. Strictly stronger than subtle::ConstantTimeEq (no loop body to discipline).ρg−1 per query. The aggregate is ρ-equivariant; the client inversion is O(1) in bundle size. Probabilistic-mode order statistics (MIN/MAX/RANGE/MEDIAN/QUANTILE/ARGMIN/ARGMAX with σ > 0) are bias-refused at the API with a typed error rather than silently overshooting.PROBABILISTIC mode adds Gaussian noise; the Davis Identity (S + d² = 1) makes equality a distance check that survives it. Two encryptions of the same value differ; equality queries still resolve in a HashMap probe. Order statistics under noise are bias-refused with a typed error rather than silently overshooting.GAUGE ROTATE_KEY FORWARD_SECRET rotates base-hash seed s and GaugeKey g atomically. The v0.3 continuous RG-flow ratchet advances g per write via HKDF chain; retention horizon R makes pre-horizon keys computationally unrecoverable. Post-compromise recovery of old plaintext: 0.00% past the horizon.record_hash; byte-level tamper evidence + invariant-level attestation, layered."GIGI_v0.4_credential_v1"; BBS+ unlinkability is the pinned v0.5 upgrade path.Most of the GIGI Encrypt vocabulary comes from differential geometry and fiber bundles. Below, every term of art used above, in plain English, with the engineer / cryptographer benefit stated in their own vocabulary. Click any underlined term earlier in the page to jump here.
u64 produced by a keyed base-space hash G.u64, not a byte compare on the ciphertext.∮ ΓK = Var(v) / range(v)², a dimensionless normalized-dispersion scalar per column. Affine-invariant by construction (Var scales as a², range² scales as a², ratio invariant). Related to but not identical with Riemannian scalar curvature in its classical differential-geometric sense (contraction of the Riemann tensor); see Davis 2024 Branch I for the precise correspondence on the statistical manifold with Fisher metric.1/(1+K) and capacity C = τ/K fall out of one number. All computable on ciphertext, all affine-gauge invariant.PROJECT INVARIANT surface.INDEXED mode is built on.OPAQUE mode is. Drop-in AES-GCM-SIV on payload fibers.PROBABILISTIC numeric mode clears it while still answering equality queries via the Davis Identity — previously treated as mutually exclusive.OPAQUE uses GCM-SIV directly; INDEXED is the conceptual cousin of SIV with an AES-CMAC / keyed-SipHash PRF.subtle::ConstantTimeEq)cmp on a u64 base point.Eq(w₁, w₂) = 𝟙[d² ≤ (3σ)²].u64 base point. Seed s is rotatable.INDEXED · OPAQUE · PROBABILISTICINDEXED = PRF, deterministic, equality-queryable — high-cardinality columns only (deterministic encryption leaks frequency). OPAQUE = AEAD, randomized, formally IND-CPA (AES-GCM-SIV), not queryable. PROBABILISTIC = affine + Gaussian noise, statistically unlinkable (empirical — not formally IND-CPA) and equality-queryable via the Davis Identity.PROJECT INVARIANT (…)GAUGE ROTATE_KEY FORWARD_SECRETEvery claim on this page descends from a single paper: Geometric Encryption — Property-Preserving Database Encryption via Gauge Invariance on Fiber Bundles. Published 2026-05-29 on Zenodo with DOI 10.5281/zenodo.20438796.
We introduce geometric encryption, a property-preserving database-encryption framework in which the encryption acts on the fiber of a fiber-bundle data store. The action determines, by construction, which queries are computable on ciphertext: a query of arity m is computable on ciphertext at native server speed with O(poly(m)) closed-form client post-processing iff it is ρ-equivariant under the structure group G for some representation ρ. The ρ = id slice (gauge-invariant queries) needs no post-processing; the non-trivial slices — SUM, AVG, MIN, MAX, VAR, STDDEV, RANGE, MEDIAN, QUANTILE, ARGMIN, ARGMAX on affine ciphertext — are recovered by the client via a single closed-form ρg−1 application (with sign-aware joint swap for the argmin/argmax pair under a < 0, and bias-refusal at the API for the order-statistic family under Probabilistic noise). A taxonomy of five encryption modes (Affine, Opaque, Indexed, Probabilistic, Isometric), six higher-level constructions (Curvature-MAC, Aff(ℝ) capability delegation, holonomy ledger, Čech threshold sharing, RG-flow ratchet, pairing-based collusion-resistant delegation on BLS12-381), and two post-quantum delegation modes (ML-KEM-768 trusted-delegatee + lattice threshold) constitute the v0.3 implementation. Per-mode leakage profiles graded by the Chase–Kamara structured-encryption taxonomy. Three further constructions are stated as derived with reference implementation deferred to a successor paper.
Leq, Lord, Ldist, Lacc)K−1 collusion)πinv — auditor reconstructs the invariant fingerprint from ciphertext alone, no gauge key handed overχ2(k, 1−α) threshold(ℝ*)k ⊹ ℝktests/composition_v0_3.rs, tests/fhe_pq_parity_rigor.rs), the v0.4 suite (tests/invariant_verify_v0_4.rs, tests/credentials_v0_4.rs, tests/membership_index_v0_4.rs, tests/k_preserving_v0_4.rs), and the independent Python math-oracle suite across three files (theory/encryption/validation/validation_tests_v0_3.py + validation_tests_fhe_pq_rigor.py + validation_tests_v0_4_sprint_n.py). Anyone can clone, run cargo test && python validation_tests_*.py, and reproduce every shipped number from a clean checkout.
GIGI is the geometric database engine that powers every product in the Davis Geometric stack. Licensing and pilots welcome.