[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7EMNQ2KCTPSWFGKC8YDRCH4":3,"skill-same:01M7EMNQ2KCTPSWFGKC8YDRCH4":87},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":51,"commitSha":52,"skillDirectory":53,"forksCount":54,"repositoryHtmlUrl":55,"repositoryHomepageUrl":6,"ownerHtmlUrl":56,"ownerBlogUrl":6,"ownerDescription":57,"updatedAt":58,"install":59,"resources":72},"01M7EMNQ2KCTPSWFGKC8YDRCH4","implementing-policy-as-code-with-open-policy-agent",null,"Implements policy-as-code enforcement with Open Policy Agent (OPA) and Gatekeeper for Kubernetes and CI\u002FCD pipelines, covering writing Rego policies, deploying OPA Gatekeeper as a Kubernetes admission controller, testing policies in development, and integrating policy evaluation into deployment pipelines. Use when writing Rego policies, deploying Gatekeeper admission control, or gating CI\u002FCD pipelines with policy-as-code checks.","lza6\u002FArmor-piercing-system-prompts","lza6","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F128880206?v=4","01M7EB3K7WPX5T28EJ2NVHE6EG","Chinese-tingfeng","01M7EB3K97E1KQ16QWKJMFNGX8",11,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fimplementing-policy-as-code-with-open-policy-agent\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: implementing-policy-as-code-with-open-policy-agent\ndescription: 'Implements policy-as-code enforcement with Open Policy Agent (OPA)\n  and Gatekeeper for Kubernetes and CI\u002FCD pipelines, covering writing Rego policies,\n  deploying OPA Gatekeeper as a Kubernetes admission controller, testing policies\n  in development, and integrating policy evaluation into deployment pipelines. Use\n  when writing Rego policies, deploying Gatekeeper admission control, or gating\n  CI\u002FCD pipelines with policy-as-code checks.\n\n  '\ndomain: cybersecurity\nsubdomain: devsecops\ntags:\n- devsecops\n- cicd\n- opa\n- gatekeeper\n- policy-as-code\n- kubernetes\n- secure-sdlc\nversion: 1.0.0\nauthor: mahipal\nlicense: Apache-2.0\nnist_ai_rmf:\n- GOVERN-1.1\n- MEASURE-2.7\n- MANAGE-3.1\nnist_csf:\n- PR.PS-01\n- GV.SC-07\n- ID.IM-04\n- PR.PS-04\nmitre_attack:\n- T1195\n- T1554\n- T1059.004\n- T1610\n- T1611\n---\n\n# Implementing Policy as Code with Open Policy Agent\n\n## When to Use\n\n- When enforcing organizational security policies across Kubernetes clusters programmatically\n- When requiring admission control that blocks non-compliant resources from being created\n- When implementing policy governance that can be version-controlled, tested, and audited\n- When standardizing security rules across multiple clusters and environments\n- When needing a flexible policy engine that extends beyond Kubernetes to APIs and CI\u002FCD\n\n**Do not use** for vulnerability scanning (use Trivy\u002FCheckov), for runtime threat detection (use Falco), or for network policy enforcement (use Kubernetes NetworkPolicy or Calico).\n\n## Prerequisites\n\n- Kubernetes cluster with admin access for Gatekeeper installation\n- Helm for Gatekeeper deployment\n- OPA CLI or conftest for local policy testing\n- Rego knowledge for policy authoring\n\n## Workflow\n\n### Step 1: Install OPA Gatekeeper\n\n```bash\n# Install Gatekeeper via Helm\nhelm repo add gatekeeper https:\u002F\u002Fopen-policy-agent.github.io\u002Fgatekeeper\u002Fcharts\nhelm install gatekeeper gatekeeper\u002Fgatekeeper \\\n  --namespace gatekeeper-system --create-namespace \\\n  --set replicas=3 \\\n  --set audit.replicas=1 \\\n  --set audit.writeToRAMDisk=true\n```\n\n### Step 2: Create Constraint Templates\n\n```yaml\n# templates\u002Fk8s-required-labels.yaml\napiVersion: templates.gatekeeper.sh\u002Fv1\nkind: ConstraintTemplate\nmetadata:\n  name: k8srequiredlabels\nspec:\n  crd:\n    spec:\n      names:\n        kind: K8sRequiredLabels\n      validation:\n        openAPIV3Schema:\n          type: object\n          properties:\n            labels:\n              type: array\n              items:\n                type: string\n  targets:\n    - target: admission.k8s.gatekeeper.sh\n      rego: |\n        package k8srequiredlabels\n        violation[{\"msg\": msg}] {\n          provided := {label | input.review.object.metadata.labels[label]}\n          required := {label | label := input.parameters.labels[_]}\n          missing := required - provided\n          count(missing) > 0\n          msg := sprintf(\"Missing required labels: %v\", [missing])\n        }\n\n---\n# templates\u002Fk8s-container-limits.yaml\napiVersion: templates.gatekeeper.sh\u002Fv1\nkind: ConstraintTemplate\nmetadata:\n  name: k8scontainerlimits\nspec:\n  crd:\n    spec:\n      names:\n        kind: K8sContainerLimits\n      validation:\n        openAPIV3Schema:\n          type: object\n          properties:\n            cpu:\n              type: string\n            memory:\n              type: string\n  targets:\n    - target: admission.k8s.gatekeeper.sh\n      rego: |\n        package k8scontainerlimits\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.containers[_]\n          not container.resources.limits.cpu\n          msg := sprintf(\"Container %v has no CPU limit\", [container.name])\n        }\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.containers[_]\n          not container.resources.limits.memory\n          msg := sprintf(\"Container %v has no memory limit\", [container.name])\n        }\n\n---\n# templates\u002Fk8s-block-privileged.yaml\napiVersion: templates.gatekeeper.sh\u002Fv1\nkind: ConstraintTemplate\nmetadata:\n  name: k8sblockprivileged\nspec:\n  crd:\n    spec:\n      names:\n        kind: K8sBlockPrivileged\n  targets:\n    - target: admission.k8s.gatekeeper.sh\n      rego: |\n        package k8sblockprivileged\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.containers[_]\n          container.securityContext.privileged == true\n          msg := sprintf(\"Privileged container not allowed: %v\", [container.name])\n        }\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.initContainers[_]\n          container.securityContext.privileged == true\n          msg := sprintf(\"Privileged init container not allowed: %v\", [container.name])\n        }\n```\n\n### Step 3: Apply Constraints\n\n```yaml\n# constraints\u002Frequire-labels.yaml\napiVersion: constraints.gatekeeper.sh\u002Fv1beta1\nkind: K8sRequiredLabels\nmetadata:\n  name: require-team-labels\nspec:\n  enforcementAction: deny\n  match:\n    kinds:\n      - apiGroups: [\"\"]\n        kinds: [\"Namespace\"]\n      - apiGroups: [\"apps\"]\n        kinds: [\"Deployment\", \"StatefulSet\"]\n    excludedNamespaces:\n      - kube-system\n      - gatekeeper-system\n  parameters:\n    labels:\n      - \"team\"\n      - \"environment\"\n      - \"cost-center\"\n\n---\n# constraints\u002Fblock-privileged.yaml\napiVersion: constraints.gatekeeper.sh\u002Fv1beta1\nkind: K8sBlockPrivileged\nmetadata:\n  name: block-privileged-containers\nspec:\n  enforcementAction: deny\n  match:\n    kinds:\n      - apiGroups: [\"\"]\n        kinds: [\"Pod\"]\n      - apiGroups: [\"apps\"]\n        kinds: [\"Deployment\", \"DaemonSet\", \"StatefulSet\"]\n    excludedNamespaces:\n      - kube-system\n```\n\n### Step 4: Test Policies with conftest\n\n```bash\n# Install conftest\nbrew install conftest\n\n# Test Kubernetes manifests against OPA policies locally\nconftest test deployment.yaml --policy policies\u002F --output json\n\n# Test Terraform against OPA policies\nconftest test terraform\u002Fmain.tf --policy policies\u002Fterraform\u002F --parser hcl2\n\n# Test Dockerfiles\nconftest test Dockerfile --policy policies\u002Fdocker\u002F\n```\n\n```rego\n# policies\u002Fkubernetes\u002Fdeny_latest_tag.rego\npackage kubernetes\n\ndeny[msg] {\n  input.kind == \"Deployment\"\n  container := input.spec.template.spec.containers[_]\n  endswith(container.image, \":latest\")\n  msg := sprintf(\"Container %v uses :latest tag. Pin to specific version.\", [container.name])\n}\n\ndeny[msg] {\n  input.kind == \"Deployment\"\n  container := input.spec.template.spec.containers[_]\n  not contains(container.image, \":\")\n  msg := sprintf(\"Container %v has no tag. Pin to specific version.\", [container.name])\n}\n```\n\n### Step 5: Integrate Policy Testing in CI\u002FCD\n\n```yaml\n# .github\u002Fworkflows\u002Fpolicy-test.yml\nname: Policy Validation\n\non:\n  pull_request:\n    paths: ['k8s\u002F**', 'terraform\u002F**', 'policies\u002F**']\n\njobs:\n  conftest:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions\u002Fcheckout@v4\n      - name: Install conftest\n        run: |\n          wget -q https:\u002F\u002Fgithub.com\u002Fopen-policy-agent\u002Fconftest\u002Freleases\u002Fdownload\u002Fv0.50.0\u002Fconftest_0.50.0_Linux_x86_64.tar.gz\n          tar xzf conftest_0.50.0_Linux_x86_64.tar.gz\n          sudo mv conftest \u002Fusr\u002Flocal\u002Fbin\u002F\n      - name: Test K8s manifests\n        run: conftest test k8s\u002F**\u002F*.yaml --policy policies\u002Fkubernetes\u002F --output json\n      - name: Test Terraform\n        run: conftest test terraform\u002F*.tf --policy policies\u002Fterraform\u002F --parser hcl2\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|------------|\n| OPA | Open Policy Agent — general-purpose policy engine using Rego language for policy decisions |\n| Rego | OPA's declarative query language for writing policy rules |\n| Gatekeeper | Kubernetes-native OPA integration implementing admission control via ConstraintTemplates |\n| ConstraintTemplate | CRD defining the Rego policy logic and parameters schema for a class of constraints |\n| Constraint | Instance of a ConstraintTemplate with specific parameters and scope (which resources to check) |\n| Admission Controller | Kubernetes component that intercepts API requests before persistence and can allow or deny them |\n| conftest | CLI tool for testing structured data (YAML, JSON, HCL) against OPA policies |\n\n## Tools & Systems\n\n- **Open Policy Agent (OPA)**: General-purpose policy engine for unified policy enforcement\n- **Gatekeeper**: Kubernetes admission controller built on OPA with CRD-based configuration\n- **conftest**: Testing framework for OPA policies against configuration files\n- **Kyverno**: Alternative Kubernetes policy engine using YAML-based policies (no Rego required)\n- **Styra DAS**: Commercial OPA management platform with policy authoring, testing, and distribution\n\n## Common Scenarios\n\n### Scenario: Enforcing Container Security Standards Across Clusters\n\n**Context**: Multiple development teams deploy to shared Kubernetes clusters. Some teams run privileged containers and images without resource limits, causing security and stability issues.\n\n**Approach**:\n1. Deploy Gatekeeper on all clusters via GitOps (Helm chart in a FluxCD repository)\n2. Create ConstraintTemplates for: no privileged containers, required resource limits, required labels, no latest tag\n3. Start with `enforcementAction: warn` to identify violations without blocking deployments\n4. Notify teams of violations and provide a 2-week remediation window\n5. Switch to `enforcementAction: deny` after the remediation period\n6. Add `excludedNamespaces` for kube-system and monitoring namespaces\n\n**Pitfalls**: Deploying Gatekeeper with deny mode immediately can break existing workloads. Always start with warn mode. Overly restrictive policies without exemptions for system namespaces can prevent cluster components from functioning.\n\n## Output Format\n\n```\nOPA Policy Evaluation Report\n==============================\nCluster: production-east\nDate: 2026-02-23\nGatekeeper Version: 3.16.0\n\nCONSTRAINT SUMMARY:\n  K8sRequiredLabels:        12 violations (warn)\n  K8sBlockPrivileged:        0 violations (deny)\n  K8sContainerLimits:        8 violations (deny)\n  K8sBlockLatestTag:         3 violations (deny)\n\nBLOCKED DEPLOYMENTS (deny):\n  [K8sContainerLimits] deployment\u002Fapi-server in ns\u002Fpayments\n    - Container 'api' has no memory limit\n  [K8sBlockLatestTag] deployment\u002Ffrontend in ns\u002Fweb\n    - Container 'nginx' uses :latest tag\n\nAUDIT VIOLATIONS (warn):\n  [K8sRequiredLabels] namespace\u002Fstaging\n    - Missing labels: {cost-center}\n```\n","# Implementing Policy as Code with Open Policy Agent\n\n## When to Use\n\n- When enforcing organizational security policies across Kubernetes clusters programmatically\n- When requiring admission control that blocks non-compliant resources from being created\n- When implementing policy governance that can be version-controlled, tested, and audited\n- When standardizing security rules across multiple clusters and environments\n- When needing a flexible policy engine that extends beyond Kubernetes to APIs and CI\u002FCD\n\n**Do not use** for vulnerability scanning (use Trivy\u002FCheckov), for runtime threat detection (use Falco), or for network policy enforcement (use Kubernetes NetworkPolicy or Calico).\n\n## Prerequisites\n\n- Kubernetes cluster with admin access for Gatekeeper installation\n- Helm for Gatekeeper deployment\n- OPA CLI or conftest for local policy testing\n- Rego knowledge for policy authoring\n\n## Workflow\n\n### Step 1: Install OPA Gatekeeper\n\n```bash\n# Install Gatekeeper via Helm\nhelm repo add gatekeeper https:\u002F\u002Fopen-policy-agent.github.io\u002Fgatekeeper\u002Fcharts\nhelm install gatekeeper gatekeeper\u002Fgatekeeper \\\n  --namespace gatekeeper-system --create-namespace \\\n  --set replicas=3 \\\n  --set audit.replicas=1 \\\n  --set audit.writeToRAMDisk=true\n```\n\n### Step 2: Create Constraint Templates\n\n```yaml\n# templates\u002Fk8s-required-labels.yaml\napiVersion: templates.gatekeeper.sh\u002Fv1\nkind: ConstraintTemplate\nmetadata:\n  name: k8srequiredlabels\nspec:\n  crd:\n    spec:\n      names:\n        kind: K8sRequiredLabels\n      validation:\n        openAPIV3Schema:\n          type: object\n          properties:\n            labels:\n              type: array\n              items:\n                type: string\n  targets:\n    - target: admission.k8s.gatekeeper.sh\n      rego: |\n        package k8srequiredlabels\n        violation[{\"msg\": msg}] {\n          provided := {label | input.review.object.metadata.labels[label]}\n          required := {label | label := input.parameters.labels[_]}\n          missing := required - provided\n          count(missing) > 0\n          msg := sprintf(\"Missing required labels: %v\", [missing])\n        }\n\n---\n# templates\u002Fk8s-container-limits.yaml\napiVersion: templates.gatekeeper.sh\u002Fv1\nkind: ConstraintTemplate\nmetadata:\n  name: k8scontainerlimits\nspec:\n  crd:\n    spec:\n      names:\n        kind: K8sContainerLimits\n      validation:\n        openAPIV3Schema:\n          type: object\n          properties:\n            cpu:\n              type: string\n            memory:\n              type: string\n  targets:\n    - target: admission.k8s.gatekeeper.sh\n      rego: |\n        package k8scontainerlimits\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.containers[_]\n          not container.resources.limits.cpu\n          msg := sprintf(\"Container %v has no CPU limit\", [container.name])\n        }\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.containers[_]\n          not container.resources.limits.memory\n          msg := sprintf(\"Container %v has no memory limit\", [container.name])\n        }\n\n---\n# templates\u002Fk8s-block-privileged.yaml\napiVersion: templates.gatekeeper.sh\u002Fv1\nkind: ConstraintTemplate\nmetadata:\n  name: k8sblockprivileged\nspec:\n  crd:\n    spec:\n      names:\n        kind: K8sBlockPrivileged\n  targets:\n    - target: admission.k8s.gatekeeper.sh\n      rego: |\n        package k8sblockprivileged\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.containers[_]\n          container.securityContext.privileged == true\n          msg := sprintf(\"Privileged container not allowed: %v\", [container.name])\n        }\n        violation[{\"msg\": msg}] {\n          container := input.review.object.spec.initContainers[_]\n          container.securityContext.privileged == true\n          msg := sprintf(\"Privileged init container not allowed: %v\", [container.name])\n        }\n```\n\n### Step 3: Apply Constraints\n\n```yaml\n# constraints\u002Frequire-labels.yaml\napiVersion: constraints.gatekeeper.sh\u002Fv1beta1\nkind: K8sRequiredLabels\nmetadata:\n  name: require-team-labels\nspec:\n  enforcementAction: deny\n  match:\n    kinds:\n      - apiGroups: [\"\"]\n        kinds: [\"Namespace\"]\n      - apiGroups: [\"apps\"]\n        kinds: [\"Deployment\", \"StatefulSet\"]\n    excludedNamespaces:\n      - kube-system\n      - gatekeeper-system\n  parameters:\n    labels:\n      - \"team\"\n      - \"environment\"\n      - \"cost-center\"\n\n---\n# constraints\u002Fblock-privileged.yaml\napiVersion: constraints.gatekeeper.sh\u002Fv1beta1\nkind: K8sBlockPrivileged\nmetadata:\n  name: block-privileged-containers\nspec:\n  enforcementAction: deny\n  match:\n    kinds:\n      - apiGroups: [\"\"]\n        kinds: [\"Pod\"]\n      - apiGroups: [\"apps\"]\n        kinds: [\"Deployment\", \"DaemonSet\", \"StatefulSet\"]\n    excludedNamespaces:\n      - kube-system\n```\n\n### Step 4: Test Policies with conftest\n\n```bash\n# Install conftest\nbrew install conftest\n\n# Test Kubernetes manifests against OPA policies locally\nconftest test deployment.yaml --policy policies\u002F --output json\n\n# Test Terraform against OPA policies\nconftest test terraform\u002Fmain.tf --policy policies\u002Fterraform\u002F --parser hcl2\n\n# Test Dockerfiles\nconftest test Dockerfile --policy policies\u002Fdocker\u002F\n```\n\n```rego\n# policies\u002Fkubernetes\u002Fdeny_latest_tag.rego\npackage kubernetes\n\ndeny[msg] {\n  input.kind == \"Deployment\"\n  container := input.spec.template.spec.containers[_]\n  endswith(container.image, \":latest\")\n  msg := sprintf(\"Container %v uses :latest tag. Pin to specific version.\", [container.name])\n}\n\ndeny[msg] {\n  input.kind == \"Deployment\"\n  container := input.spec.template.spec.containers[_]\n  not contains(container.image, \":\")\n  msg := sprintf(\"Container %v has no tag. Pin to specific version.\", [container.name])\n}\n```\n\n### Step 5: Integrate Policy Testing in CI\u002FCD\n\n```yaml\n# .github\u002Fworkflows\u002Fpolicy-test.yml\nname: Policy Validation\n\non:\n  pull_request:\n    paths: ['k8s\u002F**', 'terraform\u002F**', 'policies\u002F**']\n\njobs:\n  conftest:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions\u002Fcheckout@v4\n      - name: Install conftest\n        run: |\n          wget -q https:\u002F\u002Fgithub.com\u002Fopen-policy-agent\u002Fconftest\u002Freleases\u002Fdownload\u002Fv0.50.0\u002Fconftest_0.50.0_Linux_x86_64.tar.gz\n          tar xzf conftest_0.50.0_Linux_x86_64.tar.gz\n          sudo mv conftest \u002Fusr\u002Flocal\u002Fbin\u002F\n      - name: Test K8s manifests\n        run: conftest test k8s\u002F**\u002F*.yaml --policy policies\u002Fkubernetes\u002F --output json\n      - name: Test Terraform\n        run: conftest test terraform\u002F*.tf --policy policies\u002Fterraform\u002F --parser hcl2\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|------------|\n| OPA | Open Policy Agent — general-purpose policy engine using Rego language for policy decisions |\n| Rego | OPA's declarative query language for writing policy rules |\n| Gatekeeper | Kubernetes-native OPA integration implementing admission control via ConstraintTemplates |\n| ConstraintTemplate | CRD defining the Rego policy logic and parameters schema for a class of constraints |\n| Constraint | Instance of a ConstraintTemplate with specific parameters and scope (which resources to check) |\n| Admission Controller | Kubernetes component that intercepts API requests before persistence and can allow or deny them |\n| conftest | CLI tool for testing structured data (YAML, JSON, HCL) against OPA policies |\n\n## Tools & Systems\n\n- **Open Policy Agent (OPA)**: General-purpose policy engine for unified policy enforcement\n- **Gatekeeper**: Kubernetes admission controller built on OPA with CRD-based configuration\n- **conftest**: Testing framework for OPA policies against configuration files\n- **Kyverno**: Alternative Kubernetes policy engine using YAML-based policies (no Rego required)\n- **Styra DAS**: Commercial OPA management platform with policy authoring, testing, and distribution\n\n## Common Scenarios\n\n### Scenario: Enforcing Container Security Standards Across Clusters\n\n**Context**: Multiple development teams deploy to shared Kubernetes clusters. Some teams run privileged containers and images without resource limits, causing security and stability issues.\n\n**Approach**:\n1. Deploy Gatekeeper on all clusters via GitOps (Helm chart in a FluxCD repository)\n2. Create ConstraintTemplates for: no privileged containers, required resource limits, required labels, no latest tag\n3. Start with `enforcementAction: warn` to identify violations without blocking deployments\n4. Notify teams of violations and provide a 2-week remediation window\n5. Switch to `enforcementAction: deny` after the remediation period\n6. Add `excludedNamespaces` for kube-system and monitoring namespaces\n\n**Pitfalls**: Deploying Gatekeeper with deny mode immediately can break existing workloads. Always start with warn mode. Overly restrictive policies without exemptions for system namespaces can prevent cluster components from functioning.\n\n## Output Format\n\n```\nOPA Policy Evaluation Report\n==============================\nCluster: production-east\nDate: 2026-02-23\nGatekeeper Version: 3.16.0\n\nCONSTRAINT SUMMARY:\n  K8sRequiredLabels:        12 violations (warn)\n  K8sBlockPrivileged:        0 violations (deny)\n  K8sContainerLimits:        8 violations (deny)\n  K8sBlockLatestTag:         3 violations (deny)\n\nBLOCKED DEPLOYMENTS (deny):\n  [K8sContainerLimits] deployment\u002Fapi-server in ns\u002Fpayments\n    - Container 'api' has no memory limit\n  [K8sBlockLatestTag] deployment\u002Ffrontend in ns\u002Fweb\n    - Container 'nginx' uses :latest tag\n\nAUDIT VIOLATIONS (warn):\n  [K8sRequiredLabels] namespace\u002Fstaging\n    - Missing labels: {cost-center}\n```\n",{"name":5,"tags":24,"author":32,"domain":33,"license":15,"version":34,"nist_csf":35,"subdomain":25,"description":40,"nist_ai_rmf":41,"mitre_attack":45},[25,26,27,28,29,30,31],"devsecops","cicd","opa","gatekeeper","policy-as-code","kubernetes","secure-sdlc","mahipal","cybersecurity","1.0.0",[36,37,38,39],"PR.PS-01","GV.SC-07","ID.IM-04","PR.PS-04","Implements policy-as-code enforcement with Open Policy Agent (OPA) and Gatekeeper for Kubernetes and CI\u002FCD pipelines, covering writing Rego policies, deploying OPA Gatekeeper as a Kubernetes admission controller, testing policies in development, and integrating policy evaluation into deployment pipelines. Use when writing Rego policies, deploying Gatekeeper admission control, or gating CI\u002FCD pipelines with policy-as-code checks.\n",[42,43,44],"GOVERN-1.1","MEASURE-2.7","MANAGE-3.1",[46,47,48,49,50],"T1195","T1554","T1059.004","T1610","T1611","main","d69096e239f2a89aabc2cd078c47664a9d3b1e11","04-安全渗透\u002Fimplementing-policy-as-code-with-open-policy-agent",3,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts","https:\u002F\u002Fgithub.com\u002Flza6","个人vx：Tf00798\r\n个人✈：@TFGY999","2026-10-08 14:29:22",{"source":8,"skillName":5,"commands":60,"prompt":70,"zipAvailable":71},[61,64,67],{"tool":62,"command":63},"npx","npx skills add lza6\u002FArmor-piercing-system-prompts --skill implementing-policy-as-code-with-open-policy-agent",{"tool":65,"command":66},"bunx","bunx skills add lza6\u002FArmor-piercing-system-prompts --skill implementing-policy-as-code-with-open-policy-agent",{"tool":68,"command":69},"pnpm","pnpm dlx skills add lza6\u002FArmor-piercing-system-prompts --skill implementing-policy-as-code-with-open-policy-agent","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fimplementing-policy-as-code-with-open-policy-agent\u002FSKILL.md",true,[73,79,83],{"path":74,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":77,"sourceHtmlUrl":78},"references\u002Fapi-reference.md","REFERENCE","参考文档",4139,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fimplementing-policy-as-code-with-open-policy-agent\u002Freferences\u002Fapi-reference.md",{"path":80,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":81,"sourceHtmlUrl":82},"references\u002Fstandards.md",1177,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fimplementing-policy-as-code-with-open-policy-agent\u002Freferences\u002Fstandards.md",{"path":84,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":85,"sourceHtmlUrl":86},"references\u002Fworkflows.md",1911,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fimplementing-policy-as-code-with-open-policy-agent\u002Freferences\u002Fworkflows.md",[88,97,102,109,116,123],{"skillNo":89,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":92,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":96},"01M7FFG485KY83TD6HSC4YPCMC","obsidian-clipper-template-creator","Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.","MIT","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator\u002FSKILL.md",[],[],"2026-11-16 10:05:34",{"skillNo":98,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":92,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":96},"01M7FFG0T6AZ0STEJPSB3CX84K","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator-antigravity-awesome-skills-main\u002FSKILL.md",[],[],{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":92,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":96},"01M7FFFY0QEM14SKWPDYGMXM2P","python-api","Programmatic Object-Detection-Metrics API guidance for BoundingBox, BoundingBoxes, Evaluator, enums, coordinate conversion, AP\u002FmAP semantics, and source-style import diagnostics.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Fpython-api\u002FSKILL.md",[],[],{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":92,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":115,"publishedAt":96},"01M7FFFVZQZ2GJ0C0TGP7JHD20","file-evaluation","Folder-based PASCAL VOC AP\u002FmAP evaluation from ground-truth and detection text files.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Ffile-evaluation\u002FSKILL.md",[],[],{"skillNo":117,"name":118,"nameZh":6,"description":119,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":92,"licenseFileUrl":6,"sourceHtmlUrl":120,"categories":121,"keywords":122,"publishedAt":96},"01M7FFFSFNYSE77SJ6PE1CK2DA","object-detection-metrics","Guides legacy Object-Detection-Metrics PASCAL VOC AP\u002FmAP evaluation from detection text folders and direct Python API classes.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002FSKILL.md",[],[],{"skillNo":124,"name":125,"nameZh":6,"description":126,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":92,"licenseFileUrl":6,"sourceHtmlUrl":127,"categories":128,"keywords":129,"publishedAt":96},"01M7FFFP0GCK1RVXBCPQ8APBMT","nx-workspace-patterns","Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fnx-workspace-patterns\u002FSKILL.md",[],[]]