Access Caveats Troubleshooting Guide
Overview
This guide helps administrators diagnose and resolve issues related to Access Caveats functionality in Brief Connect. Access Caveats control access to restricted records through field value filtering in Role Assignments.
Common Issues and Solutions
Issue 1: User Cannot Access Restricted Record with Appropriate Caveat
Symptoms: - User should have access based on caveat selection - User gets "Access Denied" or cannot see the record - User is in the correct security group
Diagnostic Steps:
-
Verify Record Configuration:
Check record settings: - Override Default Access: Must be "Yes/True" - Access Caveats: Verify correct caveats are selected -
Check Role Assignment Configuration:
Verify Role Assignment has correct ForFieldValues: { "PartitionKey": "[RecordType or All]", "AADGroupNames": "[Correct security group]", "ForFieldValues": "[{\"ABCAccessCaveats\":\"~[CaveatName]\"}]" } -
Validate Security Group Membership:
- Confirm user is member of security group specified in Role Assignment
- Check for nested group membership if applicable
- Verify group names match exactly (case-sensitive)
Solutions: - Enable "Override Default Access" on the record - Correct caveat selection on the record - Fix Role Assignment ForFieldValues syntax - Add user to appropriate security group - Wait for group membership sync (can take up to 24 hours)
Issue 2: Unexpected Access Granted to Restricted Record
Symptoms: - Users can access records they shouldn't - Access granted despite not being in caveat-specific groups - Security expectations not met
Diagnostic Steps:
-
Audit All Role Assignments:
Check for overlapping or overly broad assignments: - Multiple Role Assignments for same user/group - Broad caveat filters like "~" without specific caveat names - Missing field value filters -
Review User's Effective Permissions:
- Check all security groups user belongs to
- Identify all Role Assignments that apply to the user
-
Look for admin permissions or override roles
-
Verify Record Setup:
- Confirm "Override Default Access" is enabled
- Check if caveats are correctly applied
- Review security classification alignment
Solutions: - Remove or modify conflicting Role Assignments - Tighten field value filters to be more specific - Remove users from inappropriate security groups - Enable proper record restriction
Issue 3: Access Caveats Field Not Available
Symptoms: - Users cannot see Access Caveats field when creating/editing records - Field appears but is read-only or disabled - Field missing from record forms
Diagnostic Steps:
-
Check Field Configuration:
Verify in Admin Panel > Configuration: - ABCAccessCaveats field is active (isActive: true) - Field is enabled for appropriate stages - Field type is correctly set (fieldType: 3 for taxonomy) -
Validate Term Store:
- Verify "Teams" term set exists in SharePoint Term Store
- Confirm all caveat terms are present (Personnel, Cabinet, Legal, Freedom of Information)
-
Check term permissions and availability
-
Review User Permissions:
- Confirm user has edit permissions on records
- Check if user's role allows field modification
- Verify content type field permissions
Solutions: - Enable ABCAccessCaveats field in Admin Panel configuration - Restore missing terms in SharePoint Term Store - Grant appropriate edit permissions to user - Refresh browser cache and test again
Issue 4: Role Assignment Field Value Filter Syntax Errors
Symptoms: - Role Assignments created but not working - Users not getting expected access - Permission evaluation errors in logs
Common Syntax Errors:
❌ Incorrect:
"ForFieldValues": "ABCAccessCaveats:Personnel"
"ForFieldValues": "[ABCAccessCaveats~Personnel]"
"ForFieldValues": "{'ABCAccessCaveats':'~Personnel'}"
✅ Correct:
"ForFieldValues": "[{\"ABCAccessCaveats\":\"~Personnel\"}]"
"ForFieldValues": "[{\"ABCAccessCaveats\":\"~Cabinet\"}, {\"ABCAccessCaveats\":\"~Legal\"}]"
Solutions:
- Use proper JSON array format with escaped quotes
- Include proper comparison operator (~ for contains)
- Validate JSON syntax before saving
- Test with single caveat first, then add complexity
Issue 5: Performance Issues with Caveat Filtering
Symptoms: - Slow record loading for restricted records - Timeouts when accessing records with caveats - High resource usage during permission evaluation
Diagnostic Steps:
- Review Role Assignment Complexity:
- Count number of Role Assignments with field value filters
- Check for overly complex ForFieldValues expressions
-
Identify assignments with multiple field filters
-
Monitor Permission Evaluation:
- Check Application Insights logs for performance metrics
- Look for timeout errors during permission calculation
- Monitor database query performance
Solutions:
- Simplify complex Role Assignments where possible
- Reduce number of field value filters per assignment
- Optimize security group membership (fewer, larger groups vs many small groups)
- Consider caching strategies for frequently accessed records
Diagnostic Tools and Techniques
Role Assignment Validation
Use this checklist to validate Role Assignment configuration:
{
"PartitionKey": "All", // ✓ Correct partition key
"RowKey": "Descriptive Name", // ✓ Unique, descriptive name
"AADGroupNames": "SG-Group-Name", // ✓ Exact group name
"PermissionSet": "StandardUser", // ✓ Valid permission set
"ForFieldValues": "[{\"ABCAccessCaveats\":\"~Personnel\"}]", // ✓ Valid JSON
"Organisations": "All", // ✓ Organization scope
"Stages": "All" // ✓ Stage scope
}
Testing Access Scenarios
Create test scenarios to validate caveat functionality:
- Test User Setup:
- Create test user accounts in different security groups
-
Test with users who should and shouldn't have access
-
Test Record Creation:
Scenario 1: Personnel Caveat - Override Default Access: Yes - Access Caveats: Personnel - Expected: Only Personnel group members can access Scenario 2: Multi-Caveat - Override Default Access: Yes - Access Caveats: Legal, Cabinet - Expected: Legal OR Cabinet group members can access Scenario 3: No Restriction - Override Default Access: No - Access Caveats: Personnel - Expected: Normal role permissions apply (caveats ignored)
Log Analysis
Key log entries to monitor:
Application Insights Queries:
// Permission evaluation errors
traces
| where message contains "FieldValuesMatch"
| where severityLevel >= 2
// Role assignment processing
traces
| where message contains "GetPermissionPairs"
| project timestamp, message, severityLevel
// Access denied events
traces
| where message contains "Access Denied"
| where customDimensions contains "caveat"
Advanced Troubleshooting
Permission Flow Analysis
To understand why a user can/cannot access a record:
-
Identify User's Groups:
User Groups → Role Assignments → Field Filters → Record Match -
Trace Permission Evaluation:
- Stage filtering (record stage vs role assignment stages)
- Organization filtering (record org vs role assignment orgs)
-
Field value filtering (record caveats vs role assignment filters)
-
Check Permission Inheritance:
- User-specific role assignments
- Group-based role assignments
- Admin overrides
Database Query Troubleshooting
If experiencing performance issues:
- Check Table Storage Performance:
- Monitor Role Assignment table query times
- Look for partition hot spots
-
Verify proper indexing
-
Optimize Role Assignments:
- Consolidate similar assignments
- Use broader partition keys where appropriate
- Minimize complex field value filters
Integration Issues
SharePoint Term Store: - Verify Term Store service application is running - Check term permissions and inheritance - Test term retrieval via SharePoint API
Azure AD Groups: - Confirm group synchronization is working - Test group membership queries via Microsoft Graph - Verify nested group expansion
Prevention Strategies
Configuration Management
- Standardize Role Assignments:
- Use consistent naming conventions
- Document purpose and scope of each assignment
-
Regular review and cleanup
-
Testing Process:
- Test all caveat combinations before production
- Maintain test user accounts for each security group
-
Automated testing of permission scenarios
-
Documentation:
- Keep current mapping of groups to caveats
- Document business rules for caveat usage
- Maintain troubleshooting runbooks
Monitoring and Alerting
Set up monitoring for:
- Failed permission evaluations
- Unexpected access patterns
- Role assignment configuration changes
- Security group membership changes
Escalation Procedures
When to Escalate
Escalate to development team when: - Core permission logic appears faulty - Performance issues cannot be resolved through configuration - Data corruption in Role Assignments table - Integration failures with Azure AD or SharePoint
Information to Provide
When escalating, include:
- Specific user accounts and records affected
- Role Assignment configurations
- Error messages and logs
- Steps to reproduce the issue
- Business impact and urgency
Temporary Workarounds
While waiting for resolution: - Temporarily add users to broader security groups - Use admin override permissions for critical access needs - Document temporary changes for later cleanup - Communicate impact to affected users