CowRevised
COW under the post-zero-error-attack analysis: quadratic, not linear
7/7 passed in 0ms
| Test | What it does | Result |
|---|---|---|
test_cow_falls_phase_error | cow_rate falls monotonically in e_ph and is exactly zero at e_ph = 1/2. | ✅ pass |
test_cow_finite_refused | cow_finite checks n_total, then raises NotImplementedError naming the uncovered phase error, nothing to estimate it from, and the vacuum-decoy route's sdp_* lengths. | ✅ pass |
test_cow_guards | cow_rate, cow_ceiling and cow_visibility refuse out-of-domain gains and error rates, a non-positive intensity or transmittance, and a dark monitoring line, naming the argument. | ✅ pass |
test_cow_loses_to_bb84 | COW loses ground monotonically to GYS decoy BB84 over 0-80 km and stays below it to 120 km despite its 0.2 against 0.21 dB/km fibre. | ✅ pass |
test_cow_phase_pinned | Unverified exam-side pin: across the 0.17-0.24 e_phase band read off Gao et al. 2022 Fig. 3, whose Eq. (7) needs unmodelled monitoring-line decoy gains, COW stays below BB84 at 100 km. | ✅ pass |
test_cow_quadratic_scaling | With the intensity forced down linearly in loss the COW rate scales as eta^2 within 0.05 and at 100 km, Gao et al. 2022's "within 100 kilometers", is positive but under 1e-5 bit/pulse and three decades below 0 km. | ✅ pass |
test_visibility_is_not_security | Visibility is an observable, not a bound: cow_visibility reads 1 one-sided and 0 balanced, and V = 1 at e_ph = 1/2 gives no key. | ✅ pass |