agentleFS
korchard333korchard333/claude-power-platform-community/.claude/skills/security/SKILL.md

security

Skill49 starsChanged 8 months agoMITView on GitHub

Dataverse Security Model. Use when: designing security roles, column-level security, business units, teams (owner/access/AAD group), record sharing, hierarchy security, minimum viable privileges, security role management via Web API.

78 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use cost-reducer, trigger-dev and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • daianepepes-labSkill

    cost-reducer

    Analyze and reduce costs across cloud infrastructure, code, and services. Use when asked to cut costs, optimize spending, reduce bills, or improve cost efficiency.

    Also in 5 projects that use this

  • xfstudioSkill

    trigger-dev

    Trigger.dev expert for background jobs, AI workflows, and reliable async execution with excellent developer experience and TypeScript-first design. Use when: trigger.dev, trigger dev, background task, ai background job, long running task.

    Also in 4 projects that use this

  • ffsshhttiikkSkill

    scalability

    Core foundational concepts and principles for Scalability

    Also in 4 projects that use this

  • daianepepes-labSkill

    self-healing

    Detect, diagnose, and automatically fix recurring errors, memory issues, and system degradation. Use when a system has recurring failures, memory leaks, performance degradation, or needs automatic recovery mechanisms.

    Also in 5 projects that use this

  • xfstudioSkill

    customer-support

    Elite AI-powered customer support specialist mastering

    Also in 4 projects that use this

  • ffsshhttiikkSkill

    cicd

    Continuous integration and delivery pipelines

    Also in 4 projects that use this

  • +1 more from daianepepes-lab

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 56 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When auditing table permissions for a Power Pages site, run these 7 check categories:

    line 73
  2. Distinctive:

    Not testing access as each role type

    line 89
  3. Distinctive:

    Not scoping environment variables/connection references with appropriate read access

    line 91
  4. Distinctive:

    Not using Azure AD Group Teams when Entra ID groups already exist

    line 94

“Common” is measured: kept by at least 6 in 10 of the 56 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill: Dataverse Security Model

When to Use

Trigger when designing security roles, field-level security, row-level access, team structures, business unit hierarchies, or any access control design for Dataverse/Power Platform solutions.


Security Model Overview

Entra ID (Authentication)
  └── Confirms identity ("who are you?")

Dataverse Security (Authorization)
  ├── Security Roles          → Table-level CRUD + access depth
  ├── Column Security         → Field-level read/update control
  ├── Row-Level Security      → Record ownership + sharing
  ├── Business Units          → Organizational hierarchy
  ├── Teams                   → Group-based access
  └── Hierarchy Security      → Manager/position chain visibility

⚠️ REQUIRED: Load Sub-Files Before Implementation

SKILL.md is a summary only — it is NOT sufficient for implementation.

The detailed content (complete payloads, XML templates, working examples, edge-case handling) lives in sub-files in the same directory as this SKILL.md. Before writing any code, you MUST use read_file on the sub-files relevant to your task:

  • Roles & Privileges — Access levels (User/BU/Parent:Child/Org), privileges (CRUD + Append/AppendTo/Assign/Share), standard role patterns, minimum viable privileges
  • Row & Column Security — Column security profiles, field permissions, row-level patterns (ownership, sharing, hierarchy)
  • Business Units & Teams — BU hierarchy design, owner teams, access teams, Azure AD Group Teams, record sharing (GrantAccess/RevokeAccess)
  • Web API Management — Security role CRUD via Web API, privilege queries, role assignment to users/teams, field security profile management

Security Design Checklist

## Security Model Design: [Solution Name]

### Tables & Access Matrix
| Table | App Admin | App Manager | App User | App Reader |
|---|---|---|---|---|
| contoso_project | Org CRUD | BU CRUD | User CRW | Org R |
| contoso_task | Org CRUD | BU CRUD | User CRUD | Org R |
| contoso_resource | Org CRUD | BU R | User R | Org R |

### Column Security
| Table | Column | Who Can Read | Who Can Update |
|---|---|---|---|
| contoso_project | contoso_budget | Finance Team, App Admin | Finance Team |
| contact | contoso_salary | HR Team | HR Team |

### Validation
- [ ] Test as each role — verify CRUD boundaries
- [ ] Test cross-BU access — verify isolation
- [ ] Test column security — verify restricted fields masked
- [ ] Test with no roles — verify access denied
- [ ] Verify lookup target tables have Read access
- [ ] Verify AppendTo on lookup target tables

Power Pages Table Permissions Audit

When auditing table permissions for a Power Pages site, run these 7 check categories:

  1. Missing Permissions (Critical) — Table used in code but no permission exists (403)
  2. Overly Broad Scope (Warning) — Global scope with write/delete enabled
  3. Missing Append/AppendTo (Critical) — Tables with lookups need append on source, appendto on target
  4. Orphaned Permissions (Info) — Permission exists but table not used in code
  5. Missing Web Role Association (Warning) — Permission without web role has no effect
  6. Parent Chain Integrity (Critical) — Parent scope with broken parent reference grants no access
  7. CRUD Excess (Warning) — More privileges than code uses (principle of least privilege)

Anti-Patterns

  • Giving users System Administrator role ("just make it work")
  • Single security role for all users (no least-privilege)
  • Not testing access as each role type
  • Missing AppendTo on lookup target tables (causes confusing save errors)
  • Not scoping environment variables/connection references with appropriate read access
  • Creating security roles in root BU when they should be BU-scoped
  • Over-sharing records (share individually instead of using teams)
  • Not using Azure AD Group Teams when Entra ID groups already exist
  • Column security without a clear policy (inconsistent protection)
  • Cascade delete configured without considering security implications
  • Org-owned tables when row-level isolation is needed
  • Using hierarchy security without clear organizational structure

Related Skills

  • dataverse — Table and relationship design that security roles protect
  • dataverse-web-api — Security role and privilege management via API
  • power-pages — Table permissions and web roles for portal security
  • testing — Security role testing strategy
  • plugins — Plugin execution context and impersonation

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.