Plain-language statement
Scope-based bounds are sound.
Exact Lean statement
theorem scope_bound_is_sound (policy : Policy) : IsSoundPolicyBound (scopeAnalysis policy) policy
Formal artifact
Lean source
theorem scope_bound_is_sound (policy : Policy) : IsSoundPolicyBound (scopeAnalysis policy) policy:= by unfold IsSoundPolicyBound intro request entities unfold scopeAnalysis unfold satisfiedBound unfold Scope.bound unfold inSomeOrNone simp only [decide_eq_true_eq] apply And.intro <;> intro h₁ <;> apply And.intro case left.left => generalize h₂ : policy.principalScope.scope = s cases s <;> simp <;> apply satisfied_implies_principal_scope h₁ <;> simp only [Scope.bound, h₂] case left.right => generalize h₂ : policy.resourceScope.scope = s cases s <;> simp <;> apply satisfied_implies_resource_scope h₁ <;> simp only [Scope.bound, h₂] case right.left => generalize h₂ : policy.principalScope.scope = s replace ⟨err, h₁⟩ := if_hasError_then_exists_error h₁ cases s <;> simp <;> apply error_implies_principal_scope_in h₁ <;> simp only [Scope.bound, h₂] case right.right => generalize h₂ : policy.resourceScope.scope = s replace ⟨err, h₁⟩ := if_hasError_then_exists_error h₁ cases s <;> simp <;> apply error_implies_resource_scope_in h₁ <;> simp only [Scope.bound, h₂]- Project
- Cedar Specification
- License
- Apache-2.0
- Commit
- 3f093947b8ae
- Source
- cedar-lean/Cedar/Thm/PolicySlice.lean:90-124
Reuse this declaration
Bring the exact result into your workflow
The import identifies the source module. Your project still needs the pinned package dependency shown on this page.
What this badge means
This completion status comes from the project or community source. It has not yet been represented here as an independent rebuild and axiom audit.
Continue in this project
Related declarations
Find? ext
Cedar.Data.Map.find?_ext
Plain-language statement
Two well-formed maps are equal if they have the same find? for every key.
Source project: Cedar Specification
Person-level attribution pending.
Find? notmem keys
Cedar.Data.Map.find?_notmem_keys
Plain-language statement
Inverse of find?_mem_toList, except that this requires wf
Source project: Cedar Specification
Person-level attribution pending.
Find? some iff in values
Cedar.Data.Map.find?_some_iff_in_values
Plain-language statement
The mp direction of this does not need the wf precondition and, in fact, is available separately as find?_some_implies_in_values above
Source project: Cedar Specification
Person-level attribution pending.