Skip to content

Idris2 0.9.0 dependency: SafeCrypto.modernIsSecure / standardIsSecure (case-rewrite eta-expansion) #83

Description

@hyperpolymath

Summary

src/Proven/SafeCrypto/Proofs.idr declares two OWED sites that are NOT covered by the Family 3 (covering/totality) refactor track:

  • modernIsSecure (line 138) — securityLevel alg = Modern -> isSecure alg = True
  • standardIsSecure (line 148) — securityLevel alg = Standard -> isSecure alg = True

Both are classified DISCHARGE-after-totality in docs/proof-debt-triage-tier-a.md, but the actual blocker is NOT totality — it's an elaborator-level issue:

case is not eta-expanded under rewrite in Idris2 0.8.0.

The proof should be a straightforward rewrite + case + Refl per arm, but the elaborator fails to unfold the case scrutinee after the rewrite step. This is a known class of Idris2 0.8.0 limitations that may be fixed in 0.9.0.

Action

This issue tracks the Idris2 0.9.0 release timeline rather than requesting a local refactor:

  • Test the discharge attempt against Idris2 0.9.0 once it ships
  • If 0.9.0 elaborator fixes the case-rewrite eta-expansion: discharge the 2 proofs locally (~30 min each, ~1h total)
  • If 0.9.0 does NOT fix it: file an upstream Idris2 bug and reclassify these as OWED-AXIOM

Workaround (if discharge needed before 0.9.0)

Hand-write the inversion: instead of rewrite prf in case alg of ..., use with blocks or explicit pattern-match on alg first, then rewrite per arm. ~2-3h estimate; acceptable for a one-off but not pattern-worthy.

OWED sites tracked

  • src/Proven/SafeCrypto/Proofs.idr:138modernIsSecure
  • src/Proven/SafeCrypto/Proofs.idr:148standardIsSecure

Related

🤖 Filed by Claude during Phase 2 Days 11-14 of the proof-debt triage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew capability or improvement to existing behaviour

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions