libpolicy

Evaluate access requests against stored policies using actor, resource, and action inputs.

1|1|Updated Aug 7, 2025
One-click install
npx skills add https://github.com/copilot-ld/copilot-ld --skill libpolicy
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: libpolicy
Source: https://github.com/copilot-ld/copilot-ld/tree/main/packages/libpolicy
Command: npx skills add https://github.com/copilot-ld/copilot-ld --skill libpolicy

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Policy-based access control for software systems requires reliable, pluggable evaluation of authorization decisions against stored policies.

Core Features & Use Cases

  • PolicyIndex: Stores policies and evaluates access requests.
  • Policy loading: Loads policies from storage and prepares evaluation context.
  • RBAC/ABAC support: Works with actor/resource/action triplets to determine access.

Quick Start

Load policies from storage and evaluate an access request by providing an actor, a resource, and an action to receive a true/false decision.

Frequently Asked Questions about libpolicy

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I evaluate access requests against stored policies for multi-tenant resource control?

To evaluate access requests against stored policies, you provide an actor, resource, and action triplet to the PolicyIndex. The system loads the policies from storage and returns a boolean indicating whether access is allowed.

What is policy-driven access control and when do I need it?

Policy-driven access control is a mechanism that reliably evaluates authorization decisions against stored policies. You need it when software systems require pluggable, instant true/false access decisions for multi-tenant resource scenarios.

Does this policy evaluation approach support RBAC and ABAC inputs?

Yes, this policy evaluation approach supports both RBAC and ABAC by working with actor, resource, and action triplets. It determines access by loading these inputs from storage to prepare the evaluation context.

How do I load policies from storage and prepare the evaluation context?

You load policies from storage and prepare the evaluation context by using the PolicyIndex feature. It stores the policies and handles the loading process to evaluate incoming access requests effectively.

Can I use OPA-WASM for instant policy decisions in multi-tenant environments?

You can achieve instant policy decisions in multi-tenant environments by evaluating actor, resource, and action inputs against stored policies. The system loads these policies via PolicyIndex to return a boolean access decision.