cedar library
Core types and interfaces of the Cedar policy language in Dart.
Cedar is a policy language for defining and enforcing access control policies in a declarative way. It is used in Celest for ensuring that only authorized users meeting certain criteria can access your backend.
The actual implementation of the Cedar engine is in
cedar_ffi, which uses FFI and Dart's
native assets feature to bind to the Rust implementation of Cedar. This
package only holds the Dart AST representation and is separate from
package:cedar_ffi
so that the types can be used without bundling the
native assets of package:cedar_ffi
.
Classes
- ActionAll
- ActionConstraint
- ActionEquals
- ActionIn
- ActionInSet
- AuthorizationErrors
- The errors which caused a Decision.deny.
- AuthorizationRequest
-
A request for authorization to a
CedarEngine
. - AuthorizationResponse
- The response to a CedarAuthorizer request.
- BoolValue
- CedarActionAppliesTo
- CedarActionSchema
- CedarAuthorizer
- CedarBooleanType
- CedarDecimalType
- CedarEntitySchema
- CedarEntityType
- CedarIpAddressType
- CedarLongType
- CedarNamespace
- CedarRecordType
- CedarSchema
- Dart representation of a Cedar schema.
- CedarSetType
- CedarStringType
- CedarType
- CedarTypeDefinition
- CedarTypeReference
- Component
- Condition
- DecimalValue
- Entity
- Dart representation of a Cedar entity.
- EntityUid
-
Unique ID for an entity, such as
User::"alice"
. - EntityValue
- ExtensionCall
- LongValue
- Policy
- PolicyBuilder
- PolicyConstraint
- PolicyConstraintAll
- PolicyConstraintEquals
- PolicyConstraintIn
- PolicyConstraintInSet
- PolicyConstraintIs
- PolicyConstraintIsIn
- PolicySet
- A collection of Cedar policies.
- PolicySetBuilder
- PrincipalAll
- PrincipalConstraint
- PrincipalEquals
- PrincipalIn
- PrincipalIs
- PrincipalIsIn
- RecordValue
- ResourceAll
- ResourceConstraint
- ResourceEquals
- ResourceIn
- ResourceIs
- ResourceIsIn
- SetValue
- StringValue
- TemplateLink
- Value
Enums
- CedarVariable
- ConditionKind
- Decision
- The decision of an authorization request.
- Effect
- SlotId
Extension Types
- EntityId
- Identifier portion of the EntityUid type.
- EntityTypeName
- Represents an entity type name. Consists of a namespace and the type name.
Extensions
Exceptions / Errors
- ArityException
- AttributeAccessException
- AuthorizationException
- An error in approving a AuthorizationRequest, including potentially the policyId which caused the error.
- CedarException
- EntityNotFoundException
- EvaluationException
- OverflowException
- TypeException
- UnknownExtensionException
- UnspecifiedEntityException