Coming Soon: Fine-grained access controls are currently in development. This page provides a preview of planned functionality.
.malloy
files and are enforced automatically when queries execute.
Three Layers of Security
Credible implements security at three checkpoints:-
Application Layer (First Checkpoint): Can you open this resource?
- Role-based access control (admin, modeler, viewer, manager, editor)
- See Access Control Overview for details
-
Semantic Layer (Second Checkpoint): Can you query this model through governed connections?
- Database connections managed at project level
- Queries execute through semantic models, not directly against databases
- Ensures consistent business logic and definitions
-
Data Layer (Final Checkpoint - Coming Soon): Which specific rows and columns can you see?
- Row-level security: Filter data based on user attributes
- Field-level security: Hide sensitive columns from unauthorized users
- Defined in Malloy models using
#authorize
and#bind
annotations
Row-Level Security
Field-Level Security
Annotation Scopes
Annotation Reference
#authorize
public
- Anyone with access to the model can query[ "group:admin@company.com" ]
- Specific group membership[ "group:admin@faa.gov", "group:manager@faa.gov" ]
- Multiple groups
#bind
Format: # bind [ "parameter_name:FUNCTION()" ]
Available functions:
SESSION_USER()
- Authenticated user’s ID/emailSESSION_GROUP()
- User’s primary group ID- Custom functions provided by your authorization service
Implementation Architecture
- Authenticate requests
- Fetch source annotations from Publisher API
- Evaluate
#authorize
rules (allow/deny) - Retrieve runtime values for
#bind
parameters - Inject bound parameters into queries