Skip to content

src/dazzle_back/runtime/access_control.py

Generated: 2026-03-30T04:38:46.680682+00:00

Commit: 615f1354a103

Language: python

Scope: dazzle_back

Purpose

Access control and row-level security for DNR Backend.

Provides owner-based and tenant-based access control for entities.

Key Exports

  • AccessContext
  • AccessOperation
  • AccessRule
  • AccessPolicy
  • PolicyRegistry
  • AccessDenied
  • AccessEnforcer
  • detect_owner_field
  • detect_tenant_field
  • create_policy_from_entity
  • is_authenticated
  • is_tenant_scoped
  • has_role
  • evaluate
  • create_public
  • create_authenticated
  • create_owner_based
  • create_tenant_based
  • can_access
  • get_list_filters

Dependencies

Imports

  • __future__.annotations
  • collections.abc.Callable
  • enum.StrEnum
  • typing.Any
  • uuid.UUID
  • pydantic.BaseModel
  • pydantic.Field

Event Interactions

None detected.

Invariants and Assumptions

No invariants documented.

Tests

  • tests/unit/test_access_control.py
  • tests/security/test_asvs_v4_access_control.py
  • tests/integration/test_runtime_e2e.py
  • tests/integration/test_runtime_pipeline.py
  • tests/unit/test_runtime_test_routes.py

Notes

This page was automatically generated by tools/gen_reference_docs.py.