Skip to content
Back to search

grc-engineering-suite

MarketplaceWorks with Claude CodeGitHubIncomplete

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today

Check it deeper on your machine

It has changed since its scan on 13 Nov 2026.

As a Claude Code plugin, install it and then ask Claude Code:

/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/GRCEngClub/claude-grc-engineering with scanskillsafety

Or from a terminal, clone it and run it:

git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/GRCEngClub/claude-grc-engineering'

It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/grcengclub-claude-grc-engineering/badge.svg)](/listings/grcengclub-claude-grc-engineering)

HTML

<a href="/listings/grcengclub-claude-grc-engineering"><img src="/api/listings/grcengclub-claude-grc-engineering/badge.svg" alt="findsafeskills safety rating" /></a>

Install

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Inside Claude Code:

/plugin marketplace add GRCEngClub/claude-grc-engineering
/plugin install grc-engineer@grc-engineering-suite

For a first run without cloud credentials, use GitHub as the evidence source:

/plugin install github-inspector@grc-engineering-suite
/plugin install soc2@grc-engineering-suite
/github-inspector:setup
/github-inspector:collect --scope=@me
/grc-engineer:gap-assessment SOC2 --sources=github-inspector

Full walkthrough: [docs/QUICKSTART.md](docs/QUICKSTART.md).

Using Claude Desktop or Claude Cowork instead of Claude Code? Start with [docs/CLAUDE-COWORK.md](docs/CLAUDE-COWORK.md). Anthropic's security and compliance posture is documented at [trust.anthropic.com](https://trust.anthropic.com/), and the Claude Cowork third-party platform guide is here: [Claude Desktop on third-party platforms](https://claude.com/docs/cowork/3p/overview).

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 443 lines
  1. {
  2. "name": "grc-engineering-suite",
  3. "owner": {
  4. "name": "GRC Engineering Club",
  5. "url": "https://grcengclub.com"
  6. },
  7. "metadata": {
  8. "description": "GRC Engineering Plugin Suite - Tools for auditors, internal teams, TPRM, and framework-specific compliance",
  9. "version": "0.1.0",
  10. "pluginRoot": "./plugins"
  11. },
  12. "plugins": [
  13. {
  14. "name": "vault-kv",
  15. "source": "./plugins/connectors/vault-kv",
  16. "description": "Operator-only Vault KV runtime injection into a trusted local process.",
  17. "version": "0.1.0"
  18. },
  19. {
  20. "name": "gcp-secret-metadata",
  21. "source": "./plugins/connectors/gcp-secret-metadata",
  22. "description": "GCP Secret Manager name inventory and operator-only runtime injection.",
  23. "version": "0.1.0"
  24. },
  25. {
  26. "name": "grc-engineer",
  27. "source": "./plugins/grc-engineer",
  28. "description": "Maps IaC to compliance controls, generates policies, collects evidence, reviews PRs",
  29. "version": "0.1.0"
  30. },
  31. {
  32. "name": "grc-auditor",
  33. "source": "./plugins/grc-auditor",
  34. "description": "Evidence review, control validation, and audit workpaper generation for external auditors",
  35. "version": "0.1.0"
  36. },
  37. {
  38. "name": "grc-internal",
  39. "source": "./plugins/grc-internal",
  40. "description": "Policy management, risk registers, and compliance tracking for internal GRC teams",
  41. "version": "0.1.0"
  42. },
  43. {
  44. "name": "grc-tprm",
  45. "source": "./plugins/grc-tprm",
  46. "description": "Vendor assessments, questionnaire analysis, and risk scoring for third-party risk management",
  47. "version": "0.1.0"
  48. },
  49. {
  50. "name": "grc-reporter",
  51. "source": "./plugins/grc-reporter",
  52. "description": "Translate findings, risks, and metrics into narratives leadership reads. Reference implementation of the Reporting category from RFC #38.",
  53. "version": "0.1.0"
  54. },
  55. {
  56. "name": "grc-loop",
  57. "source": "./plugins/grc-loop",
  58. "description": "Iterative GRC automation loops for gap-remediation burndown and quarterly evidence sweeps.",
  59. "version": "0.1.0"
  60. },
  61. {
  62. "name": "gcp-docs",
  63. "source": "./plugins/knowledge-sources/gcp-docs",
  64. "description": "Knowledge source for Google Developer Knowledge API: current Google developer documentation citations for GRC workflows.",
  65. "version": "0.1.0"
  66. },
  67. {
  68. "name": "teach-me",
  69. "source": "./plugins/teach-me",
  70. "description": "Socratic primer + drill plugin for new-to-GRC practitioners. Get up to speed on a framework, control, or role without already knowing it.",
  71. "version": "0.1.0"
  72. },
  73. {
  74. "name": "academic-research-companion",
  75. "source": "./plugins/academic-research-companion",
  76. "description": "Guide a research project through the academic lifecycle — idea, literature, methodology, writing, feedback, publishing, and authorship — with verified sources and a durable tracker.",
  77. "version": "0.1.0"
  78. },
  79. {
  80. "name": "grc-diagrams",
  81. "source": "./plugins/grc-diagrams",
  82. "description": "Editable draw.io diagram patterns for GRC system boundaries, evidence flows, control maps, risk treatment, audits, crosswalks, TPRM, POA&M, data flows, RACI, and operating models.",
  83. "version": "0.1.0",
  84. "category": "workflow",
  85. "tags": [
  86. "drawio",
  87. "diagrams",
  88. "grc",
  89. "audit",
  90. "risk",
  91. "compliance"
  92. ]
  93. },
  94. {
  95. "name": "soc2",
  96. "source": "./plugins/frameworks/soc2",
  97. "description": "SOC 2 Trust Service Criteria expertise and Type I/II assessment support",
  98. "version": "0.1.0"
  99. },
  100. {
  101. "name": "nist-800-53",
  102. "source": "./plugins/frameworks/nist-800-53",
  103. "description": "NIST 800-53 control families and baseline selection (Low/Moderate/High)",
  104. "version": "0.1.0"
  105. },
  106. {
  107. "name": "iso27001",
  108. "source": "./plugins/frameworks/iso27001",
  109. "description": "ISO 27001 Annex A controls and ISMS implementation guidance",
  110. "version": "0.1.0"
  111. },
  112. {
  113. "name": "fedramp-rev5",
  114. "source": "./plugins/frameworks/fedramp-rev5",
  115. "description": "FedRAMP Rev 5 traditional authorization with SSP/SAP/SAR/POA&M and NIST 800-53 controls",
  116. "version": "0.1.0"
  117. },
  118. {
  119. "name": "fedramp-20x",
  120. "source": "./plugins/frameworks/fedramp-20x",
  121. "description": "FedRAMP 20X automated authorization with KSIs, continuous monitoring, and auto-sync from official docs",
  122. "version": "0.1.0"
  123. },
  124. {
  125. "name": "pci-dss",
  126. "source": "./plugins/frameworks/pci-dss",
  127. "description": "PCI DSS v4.0.1 compliance with ROC guidance, SAQ selection, and March 2025 requirements",
  128. "version": "0.1.0"
  129. },
  130. {
  131. "name": "cmmc",
  132. "source": "./plugins/frameworks/cmmc",
  133. "description": "CMMC v2.0 (DoD contractors) with 5 levels and C3PAO assessment prep",
  134. "version": "0.1.0"
  135. },
  136. {
  137. "name": "hitrust",
  138. "source": "./plugins/frameworks/hitrust",
  139. "description": "HITRUST CSF healthcare security with i1/r2 assessments",
  140. "version": "0.1.0"
  141. },
  142. {
  143. "name": "cis-controls",
  144. "source": "./plugins/frameworks/cis-controls",
  145. "description": "CIS Controls v8 baseline security with IG1/IG2/IG3 levels",
  146. "version": "0.1.0"
  147. },
  148. {
  149. "name": "gdpr",
  150. "source": "./plugins/frameworks/gdpr",
  151. "description": "GDPR EU privacy regulation with DPIA and data subject rights",
  152. "version": "0.1.0"
  153. },
  154. {
  155. "name": "csa-ccm",
  156. "source": "./plugins/frameworks/csa-ccm",
  157. "description": "CSA Cloud Controls Matrix with 197 controls and CAIQ support",
  158. "version": "0.1.0"
  159. },
  160. {
  161. "name": "nydfs",
  162. "source": "./plugins/frameworks/nydfs",
  163. "description": "NYDFS 23 NYCRR 500 cybersecurity requirements for financial services",
  164. "version": "0.1.0"
  165. },
  166. {
  167. "name": "dora",
  168. "source": "./plugins/frameworks/dora",
  169. "description": "DORA EU Digital Operational Resilience Act for financial entities",
  170. "version": "0.1.0"
  171. },
  172. {
  173. "name": "stateramp",
  174. "source": "./plugins/frameworks/stateramp",
  175. "description": "StateRAMP state/local government cloud authorization",
  176. "version": "0.1.0"
  177. },
  178. {
  179. "name": "essential8",
  180. "source": "./plugins/frameworks/essential8",
  181. "description": "Essential 8 Australian cyber security strategies with maturity levels",
  182. "version": "0.1.0"
  183. },
  184. {
  185. "name": "glba",
  186. "source": "./plugins/frameworks/glba",
  187. "description": "GLBA Gramm-Leach-Bliley Act for financial institution privacy",
  188. "version": "0.1.0"
  189. },
  190. {
  191. "name": "us-export",
  192. "source": "./plugins/frameworks/us-export",
  193. "description": "US Export Controls: ITAR (defense) + EAR (dual-use commercial) compliance",
  194. "version": "0.1.0"
  195. },
  196. {
  197. "name": "us-hipaa-security",
  198. "source": "./plugins/frameworks/us-hipaa-security",
  199. "description": "HIPAA Security Rule (45 CFR Part 164, Subpart C) for ePHI protection with Administrative, Physical, and Technical Safeguards",
  200. "version": "0.1.0"
  201. },
  202. {
  203. "name": "pbmm",
  204. "source": "./plugins/frameworks/pbmm",
  205. "description": "Canadian PBMM (Protected B Medium Medium) with ITSG-33 controls",
  206. "version": "0.1.0"
  207. },
  208. {
  209. "name": "ismap",
  210. "source": "./plugins/frameworks/ismap",
  211. "description": "Japanese ISMAP government cloud security (ISO 27001/27017/27018)",
  212. "version": "0.1.0"
  213. },
  214. {
  215. "name": "irap",
  216. "source": "./plugins/frameworks/irap",
  217. "description": "Australian IRAP (ISM + Essential Eight) for government cloud",
  218. "version": "0.1.0"
  219. },
  220. {
  221. "name": "aws-inspector",
  222. "source": "./plugins/connectors/aws-inspector",
  223. "description": "GRC connector for AWS: IAM, S3, CloudTrail, EBS compliance checks \u2192 v1 finding contract",
  224. "version": "0.1.0"
  225. },
  226. {
  227. "name": "onepassword-connector",
  228. "source": "./plugins/connectors/onepassword-connector",
  229. "description": "Run trusted local commands with 1Password secret references and suppressed output.",
  230. "version": "0.1.0"
  231. },
  232. {
  233. "name": "aws-secrets-inspector",
  234. "source": "./plugins/connectors/aws-secrets-inspector",
  235. "description": "GRC connector for AWS Secrets Manager: rotation, customer-managed KMS, resource policy, and access-pattern checks \u2192 v1 finding contract. Hybrid shape supports opt-in secret retrieval to stdout or 0600-permission files.",
  236. "version": "0.1.0"
  237. },
  238. {
  239. "name": "github-inspector",
  240. "source": "./plugins/connectors/github-inspector",
  241. "description": "GRC connector for GitHub: branch protection, secret scanning, Dependabot, code scanning \u2192 v1 finding contract",
  242. "version": "0.1.0"
  243. },
  244. {
  245. "name": "gcp-inspector",
  246. "source": "./plugins/connectors/gcp-inspector",
  247. "description": "GRC connector for Google Cloud: IAM, Cloud Storage, audit logs, KMS rotation, Compute OS Login \u2192 v1 finding contract",
  248. "version": "0.1.0"
  249. },
  250. {
  251. "name": "azure-inspector",
  252. "source": "./plugins/connectors/azure-inspector",
  253. "description": "GRC connector for Azure: Entra ID, Storage, Key Vault, Monitor, and Defender for Cloud to v1 finding contract",
  254. "version": "0.1.0"
  255. },
  256. {
  257. "name": "slack-inspector",
  258. "source": "./plugins/connectors/slack-inspector",
  259. "description": "GRC connector for Slack: workspace 2FA, SSO/session, retention, app approvals, and DLP visibility to v1 finding contract",
  260. "version": "0.1.0"
  261. },
  262. {
  263. "name": "datadog-inspector",
  264. "source": "./plugins/connectors/datadog-inspector",
  265. "description": "GRC connector for Datadog: log retention, audit logs, monitor coverage, SSO, and RBAC to v1 finding contract",
  266. "version": "0.1.0"
  267. },
  268. {
  269. "name": "crowdstrike-inspector",
  270. "source": "./plugins/connectors/crowdstrike-inspector",
  271. "description": "GRC connector for CrowdStrike Falcon: sensor coverage, policies, and host-group scoping to v1 finding contract",
  272. "version": "0.1.0"
  273. },
  274. {
  275. "name": "drata-inspector",
  276. "source": "./plugins/connectors/drata-inspector",
  277. "description": "GRC connector for Drata: wraps drata-cli workflows and normalizes compliance posture to v1 finding contract",
  278. "version": "0.1.0"
  279. },
  280. {
  281. "name": "splunk-inspector",
  282. "source": "./plugins/connectors/splunk-inspector",
  283. "description": "GRC connector for Splunk: index retention, RBAC, audit coverage, search ACLs, and auth posture to v1 finding contract",
  284. "version": "0.1.0"
  285. },
  286. {
  287. "name": "tenable-inspector",
  288. "source": "./plugins/connectors/tenable-inspector",
  289. "description": "GRC connector for Tenable.io/Tenable.sc: scan coverage, credentialed scans, vulnerability age, and scan access to v1 finding contract",
  290. "version": "0.1.0"
  291. },
  292. {
  293. "name": "snowflake-inspector",
  294. "source": "./plugins/connectors/snowflake-inspector",
  295. "description": "GRC connector for Snowflake: MFA, network policies, masking/row access policies, session timeout, and retention to v1 finding contract",
  296. "version": "0.1.0"
  297. },
  298. {
  299. "name": "wiz-inspector",
  300. "source": "./plugins/connectors/wiz-inspector",
  301. "description": "GRC connector for Wiz CNAPP: configuration findings, issues, vulnerabilities, and cloud inventory to v1 finding contract",
  302. "version": "0.1.0"
  303. },
  304. {
  305. "name": "testssl-inspector",
  306. "source": "./plugins/connectors/testssl-inspector",
  307. "description": "GRC connector wrapping testssl.sh: TLS/SSL protocol, cipher, certificate, and known-CVE checks on HTTPS endpoints → v1 finding contract",
  308. "version": "0.1.0"
  309. },
  310. {
  311. "name": "okta-inspector",
  312. "source": "./plugins/connectors/okta-inspector",
  313. "description": "GRC connector for Okta: password/MFA/session policies, inactive users, admin factor enrollment \u2192 v1 finding contract",
  314. "version": "0.1.0"
  315. },
  316. {
  317. "name": "oscal",
  318. "source": "./plugins/oscal",
  319. "description": "OSCAL toolkit: validate and convert catalogs, profiles, SSPs, SAPs, SARs, POA&Ms, assessment results, component definitions. Wraps ethanolivertroy/oscal-cli.",
  320. "version": "0.1.0"
  321. },
  322. {
  323. "name": "fedramp-ssp",
  324. "source": "./plugins/fedramp-ssp",
  325. "description": "Convert FedRAMP Rev 5 SSP DOCX templates to validated OSCAL 1.2.0 SSP JSON. Wraps ethanolivertroy/frdocx-to-froscal-ssp.",
  326. "version": "0.1.0"
  327. },
  328. {
  329. "name": "singapore-pdpa",
  330. "source": "./plugins/frameworks/singapore-pdpa",
  331. "description": "Singapore - Personal Data Protection Ac (PDPA) (2012) \u2014 reference-depth plugin backed by the SCF crosswalk (30 SCF \u2192 14 framework controls).",
  332. "version": "0.1.0"
  333. },
  334. {
  335. "name": "us-finra",
  336. "source": "./plugins/frameworks/us-finra",
  337. "description": "FINRA Broker-Dealer Cybersecurity Guidance \u2014 stub-depth plugin backed by the SCF crosswalk (17 SCF \u2192 39 framework controls).",
  338. "version": "0.1.0"
  339. },
  340. {
  341. "name": "cyber-essentials-plus",
  342. "source": "./plugins/frameworks/cyber-essentials-plus",
  343. "description": "UK NCSC Cyber Essentials Plus (CE+) v3.3 Danzell \u2014 gap assessments, evidence checklists, remediation plans, and cross-framework mapping to ISO 27001 and NIST CSF.",
  344. "version": "0.1.0"
  345. },
  346. {
  347. "name": "ch-fadp",
  348. "source": "./plugins/frameworks/ch-fadp",
  349. "description": "Swiss Federal Act on Data Protection (nFADP) \u2014 stub-depth plugin backed by the SCF crosswalk (35 SCF \u2192 90 framework controls).",
  350. "version": "0.1.0"
  351. },
  352. {
  353. "name": "ind-dpdpa",
  354. "source": "./plugins/frameworks/ind-dpdpa",
  355. "description": "India Digital Personal Data Protection Act, 2023 \u2014 reference-depth plugin with scope determination, evidence checklist, and breach-process workflow backed by the SCF crosswalk.",
  356. "version": "0.1.0"
  357. },
  358. {
  359. "name": "poam-automation",
  360. "source": "./plugins/connectors/poam-automation",
  361. "description": "GRC connector wrapping networkbm/POAM-Automation-Tool: converts vulnerability scans into FedRAMP POA&M Excel and emits NIST-800-53-r5 (SI-2) findings \u2192 v1 finding contract.",
  362. "version": "0.1.0"
  363. },
  364. {
  365. "name": "eu-nis2",
  366. "source": "./plugins/frameworks/eu-nis2",
  367. "description": "EU NIS2 Directive (2022) \u2014 reference-depth plugin backed by the SCF crosswalk (68 SCF \u2192 30 framework controls).",
  368. "version": "0.1.0"
  369. },
  370. {
  371. "name": "nist-csf-20",
  372. "source": "./plugins/frameworks/nist-csf-20",
  373. "description": "NIST Cybersecurity Framework (v2.0) \u2014 reference-depth plugin backed by the SCF crosswalk (250 SCF \u2192 134 framework controls).",
  374. "version": "0.1.0"
  375. },
  376. {
  377. "name": "us-sox",
  378. "source": "./plugins/frameworks/us-sox",
  379. "description": "US Sarbanes-Oxley Act of 2002 (SOX) \u2014 Reference-depth plugin for ICFR scoping, IT General Control (ITGC) testing, and \u00a7302/\u00a7404/\u00a7906 evidence preparation. Backed by the SCF crosswalk (4 SCF \u2192 17 framework controls).",
  380. "version": "0.1.0"
  381. },
  382. {
  383. "name": "us-ccpa",
  384. "source": "./plugins/frameworks/us-ccpa",
  385. "description": "California Consumer Privacy Act (CCPA) and California Privacy Rights Act (CPRA) \u2014 Reference plugin with scope determination, evidence checklist, and SCF-backed gap assessment for the California Privacy Protection Agency (CPPA) regulations.",
  386. "version": "0.1.0"
  387. },
  388. {
  389. "name": "compliance-posture-dashboard",
  390. "source": "./plugins/dashboards/compliance-posture",
  391. "description": "Localhost compliance posture dashboard for monitor-continuous JSON output. Reference implementation of the Dashboards category from RFC #38.",
  392. "version": "0.1.0"
  393. },
  394. {
  395. "name": "jp-appi",
  396. "source": "./plugins/frameworks/jp-appi",
  397. "description": "Japan APPI reference plugin with scope, evidence checklist, and SCF-backed gap assessment.",
  398. "version": "0.1.0"
  399. },
  400. {
  401. "name": "sg-mas-trm",
  402. "source": "./plugins/frameworks/sg-mas-trm",
  403. "description": "Singapore MAS TRM reference plugin with scope, evidence checklist, and SCF-backed gap assessment.",
  404. "version": "0.1.0"
  405. },
  406. {
  407. "name": "au-apra-cps-234",
  408. "source": "./plugins/frameworks/au-apra-cps-234",
  409. "description": "APRA CPS 234 reference plugin with scope, evidence checklist, and SCF-backed gap assessment.",
  410. "version": "0.1.0"
  411. },
  412. {
  413. "name": "us-nerc-cip",
  414. "source": "./plugins/frameworks/us-nerc-cip",
  415. "description": "NERC CIP reference plugin with scope, evidence checklist, and SCF-backed gap assessment.",
  416. "version": "0.1.0"
  417. },
  418. {
  419. "name": "grc-portfolio",
  420. "source": "./plugins/grc-portfolio",
  421. "description": "Build and deploy a professional portfolio website for GRC engineers — certifications, frameworks, audit experience, and AWS hosting.",
  422. "version": "0.1.0"
  423. },
  424. {
  425. "name": "trust-center",
  426. "source": "./plugins/trust-center",
  427. "description": "Build and deploy a serverless trust center — public compliance posture, gated document access with optional NDA e-signature, admin dashboard. Deploys to AWS.",
  428. "version": "0.1.0"
  429. },
  430. {
  431. "name": "nist-ai-rmf",
  432. "source": "./plugins/frameworks/nist-ai-rmf",
  433. "description": "NIST AI 100-1 (AI RMF 1.0) \u2014 stub-depth plugin backed by the SCF crosswalk (158 SCF \u2192 91 framework controls).",
  434. "version": "0.1.0"
  435. },
  436. {
  437. "name": "nist-ai-600-1",
  438. "source": "./plugins/frameworks/nist-ai-600-1",
  439. "description": "NIST AI 600-1 (Generative AI Profile) \u2014 stub-depth plugin backed by the SCF crosswalk (139 SCF controls map to 250 profile items and suggested actions).",
  440. "version": "0.1.0"
  441. }
  442. ]
  443. }
README.md · README · 161 lines
  1. # claude-grc-engineering
  2. ![CodeRabbit Pull Request Reviews](https://img.shields.io/coderabbit/prs/github/GRCEngClub/claude-grc-engineering?utm_source=oss&utm_medium=github&utm_campaign=GRCEngClub%2Fclaude-grc-engineering&labelColor=171717&color=FF570A&link=https%3A%2F%2Fcoderabbit.ai&label=CodeRabbit+Reviews)
  3. [![Greptile runs](https://img.shields.io/badge/dynamic/json?label=Greptile%20runs&query=$.total_count&url=https://api.github.com/search/issues?q=repo%253AGRCEngClub%252Fclaude-grc-engineering%2520type%253Apr%2520commenter%253Agreptile-apps%255Bbot%255D&suffix=%20reviews&color=1f6feb&labelColor=171717)](https://github.com/GRCEngClub/claude-grc-engineering/pulls?q=commenter%3Agreptile-apps%5Bbot%5D)
  4. [![OSV-Scanner](https://github.com/GRCEngClub/claude-grc-engineering/actions/workflows/osv-scanner.yml/badge.svg)](https://github.com/GRCEngClub/claude-grc-engineering/actions/workflows/osv-scanner.yml)
  5. [![Greptile: The War on Bugs](https://www.greptile.com/badge.svg)](https://www.greptile.com/?utm_source=oss_badge&utm_medium=readme&utm_campaign=greptile_for_open_source)
  6. https://github.com/user-attachments/assets/a83aa297-9fba-4a7d-b56c-06f962d1ec6b
  7. Open-source GRC Engineering resource for Claude.
  8. `claude-grc-engineering` turns technical evidence from cloud, SaaS, code, and security tools into framework-aligned findings, gap reports, remediation guidance, evidence packages, and OSCAL workflows.
  9. It is built for the Claude ecosystem: Claude Code plugin installs first, with Claude Desktop and Claude Cowork usage supported through the same Markdown skills, command runbooks, schemas, and repository files.
  10. It is maintained by the [GRC Engineering Club](https://grcengclub.com) for people who want compliance work to behave more like engineering work: repeatable, testable, versioned, and easy to extend.
  11. > Not affiliated with Anthropic. Claude, Anthropic, and related marks are property of their respective owners.
  12. ## What it does
  13. The toolkit is a Claude Code plugin marketplace. The same plugin skills and command runbooks are also useful in Claude Desktop and Claude Cowork when you add this repository as project context or a shared workspace. Install the pieces you need:
  14. - `grc-engineer`: the core automation hub for gap assessment, IaC scanning, evidence collection, remediation generation, policy generation, PR review, continuous monitoring, and multi-framework optimization.
  15. - Persona plugins: workflows for auditors, internal GRC teams, third-party risk, reporting, learning, and iterative GRC automation.
  16. - Framework plugins: reference guidance for SOC 2, NIST 800-53, ISO 27001, FedRAMP, PCI DSS, CMMC, HITRUST, CIS Controls, GDPR, DORA, HIPAA Security, regional privacy/security regimes, and more.
  17. - Connector plugins: thin wrappers around tools such as AWS CLI, GitHub CLI, gcloud, Azure CLI, Okta, Slack, Datadog, CrowdStrike, Drata, Splunk, Tenable, Snowflake, and POA&M automation.
  18. - Diagram plugins: editable draw.io system boundaries, evidence flows, control maps, risk treatment, audit workflows, framework crosswalks, TPRM, POA&M, data flows, RACI, and operating model visuals.
  19. - OSCAL and bridge plugins: tooling for FedRAMP/OSCAL workflows and integrations with external GRC systems.
  20. The common path is:
  21. ```text
  22. connectors collect evidence
  23. ↓
  24. findings match schemas/finding.schema.json
  25. ↓
  26. grc-engineer maps findings through SCF
  27. ↓
  28. reports, remediation, evidence packages, OSCAL outputs
  29. ```
  30. The Secure Controls Framework (SCF) crosswalk is used as the control backbone: 1,468 controls mapped to 249 frameworks. The toolkit references control IDs and implementation guidance; it does not reproduce copyrighted standards text.
  31. ## Install in 60 seconds
  32. Inside Claude Code:
  33. ```bash
  34. /plugin marketplace add GRCEngClub/claude-grc-engineering
  35. /plugin install grc-engineer@grc-engineering-suite
  36. ```
  37. For a first run without cloud credentials, use GitHub as the evidence source:
  38. ```bash
  39. /plugin install github-inspector@grc-engineering-suite
  40. /plugin install soc2@grc-engineering-suite
  41. /github-inspector:setup
  42. /github-inspector:collect --scope=@me
  43. /grc-engineer:gap-assessment SOC2 --sources=github-inspector
  44. ```
  45. Full walkthrough: [docs/QUICKSTART.md](docs/QUICKSTART.md).
  46. Using Claude Desktop or Claude Cowork instead of Claude Code? Start with [docs/CLAUDE-COWORK.md](docs/CLAUDE-COWORK.md). Anthropic's security and compliance posture is documented at [trust.anthropic.com](https://trust.anthropic.com/), and the Claude Cowork third-party platform guide is here: [Claude Desktop on third-party platforms](https://claude.com/docs/cowork/3p/overview).
  47. ## Common workflows
  48. | Goal | Command |
  49. |---|---|
  50. | Run a gap assessment against one or more frameworks | `/grc-engineer:gap-assessment` |
  51. | Scan Terraform, CloudFormation, or Kubernetes for compliance issues | `/grc-engineer:scan-iac` |
  52. | Run available control checks (results may be indeterminate) | `/grc-engineer:test-control` |
  53. | Generate remediation code, scripts, or policy | `/grc-engineer:generate-implementation`, `/grc-engineer:generate-policy` |
  54. | Map one control across frameworks | `/grc-engineer:map-controls-unified` |
  55. | Find conflicting requirements across frameworks | `/grc-engineer:find-conflicts` |
  56. | Optimize a multi-framework control plan | `/grc-engineer:optimize-multi-framework` |
  57. | Collect evidence from cloud/SaaS/code systems | connector-specific setup, collect, and status commands |
  58. | Build audit workpapers or evidence packages | `/grc-auditor:generate-workpaper`, `/grc-engineer:collect-evidence` |
  59. | Generate OSCAL SSP/SAP/SAR/POA&M outputs | `/oscal:*`, `/fedramp-ssp:*` |
  60. | Draft leadership updates and automation coverage reports | `/report:exec-summary`, `/report:automation-coverage` |
  61. | Create editable GRC diagrams | `/grc-diagrams:drawio`, `/grc-diagrams:system-boundary`, `/grc-diagrams:evidence-flow`, `/grc-diagrams:control-map` |
  62. | Learn a framework, control, or GRC role | `/teach-me:framework`, `/teach-me:control`, `/teach-me:role`, `/teach-me:quiz` |
  63. | Run an academic research project end-to-end | `/academic-research-companion:research` |
  64. Every command has a reference page in its plugin's `commands/` directory.
  65. ## Plugin map
  66. Use `/grc-engineer:frameworks` to discover framework coverage and plugin depth.
  67. High-level categories:
  68. | Category | Examples |
  69. |---|---|
  70. | Engineering hub | `grc-engineer` |
  71. | Persona/workflow plugins | `grc-auditor`, `grc-internal`, `grc-tprm`, `grc-reporter`, `grc-loop`, `teach-me`, `academic-research-companion` |
  72. | Diagram plugin | `grc-diagrams` for editable draw.io GRC diagrams |
  73. | Framework plugins | `soc2`, `nist-800-53`, `iso27001`, `fedramp-rev5`, `fedramp-20x`, `pci-dss`, `cmmc`, `hitrust`, `cis-controls`, `gdpr`, `dora`, `us-hipaa-security`, and others |
  74. | Connector plugins | `aws-inspector`, `github-inspector`, `gcp-inspector`, `azure-inspector`, `okta-inspector`, `slack-inspector`, `datadog-inspector`, `crowdstrike-inspector`, `drata-inspector`, `splunk-inspector`, `tenable-inspector`, `snowflake-inspector` |
  75. | Dashboards, knowledge sources | `compliance-posture-dashboard`, `gcp-docs` |
  76. | OSCAL/FedRAMP tooling | `oscal`, `fedramp-ssp`, POA&M automation plugins |
  77. The marketplace manifest lives at [.claude-plugin/marketplace.json](.claude-plugin/marketplace.json).
  78. ## Data contract
  79. Every connector emits Findings that match [schemas/finding.schema.json](schemas/finding.schema.json). A Finding is one resource with one or more control evaluations.
  80. That contract keeps connectors small: each connector only needs to collect and normalize evidence. `grc-engineer` handles framework expansion, reporting, remediation, and downstream workflows.
  81. For the full architecture and schema example, see [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md).
  82. ## Documentation
  83. - [docs/QUICKSTART.md](docs/QUICKSTART.md): first gap assessment in about 10 minutes
  84. - [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md): pipeline model, data contract, plugin categories, extensibility
  85. - [docs/FRAMEWORK-COVERAGE.md](docs/FRAMEWORK-COVERAGE.md): generated coverage for SCF-mapped frameworks
  86. - [docs/FRAMEWORK-PLUGIN-GUIDE.md](docs/FRAMEWORK-PLUGIN-GUIDE.md): scaffold and level up framework plugins
  87. - [docs/GRC-DATA.md](docs/GRC-DATA.md): user-owned `grc-data/` contracts for metrics, risks, vendors, exceptions, and policies
  88. - [docs/ENTERPRISE-DEPLOYMENT.md](docs/ENTERPRISE-DEPLOYMENT.md): AWS Bedrock, Claude Platform on AWS, and Google Vertex AI guidance
  89. - [docs/CLAUDE-COWORK.md](docs/CLAUDE-COWORK.md): Claude Desktop and Claude Cowork file-oriented usage, including third-party platform handoff notes
  90. - [Anthropic Trust Center](https://trust.anthropic.com/): Anthropic security, compliance, and trust resources
  91. - [Claude Desktop on third-party platforms](https://claude.com/docs/cowork/3p/overview): official Cowork platform guidance
  92. - [docs/CONTRIBUTING.md](docs/CONTRIBUTING.md): how to contribute connectors, framework guidance, and docs
  93. - [docs/SCF-ATTRIBUTION.md](docs/SCF-ATTRIBUTION.md): SCF licensing and attribution
  94. ## Contributing
  95. Contributions are welcome from GRC practitioners, auditors, security engineers, platform teams, framework experts, and commercial GRC vendors.
  96. The highest-value contributions are:
  97. - New connector plugins
  98. - Improvements to existing connectors
  99. - Framework plugin guidance and evidence patterns
  100. - Real-world remediation examples
  101. - Documentation that helps practitioners learn GRC engineering
  102. First-time contributors follow the issue → vouch → PR flow described in [docs/CONTRIBUTING.md](docs/CONTRIBUTING.md) and [GOVERNANCE.md](GOVERNANCE.md).
  103. Security-sensitive reports should use the private advisory process described in [SECURITY.md](SECURITY.md).
  104. ## Status
  105. Pre-1.0. The Finding schema is versioned, and breaking changes are documented in [CHANGELOG.md](CHANGELOG.md).
  106. ## Star History
  107. <a href="https://www.star-history.com/?repos=GRCEngClub%2Fclaude-grc-engineering&type=date&legend=top-left">
  108. <picture>
  109. <source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/chart?repos=GRCEngClub/claude-grc-engineering&type=date&theme=dark&legend=top-left" />
  110. <source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/chart?repos=GRCEngClub/claude-grc-engineering&type=date&legend=top-left" />
  111. <img alt="Star History Chart" src="https://api.star-history.com/chart?repos=GRCEngClub/claude-grc-engineering&type=date&legend=top-left" />
  112. </picture>
  113. </a>
  114. ## License
  115. MIT for original code, copyright © GRC Engineering Club contributors. Exceptions are documented in [LICENSE](LICENSE). The CIS Controls plugin is CC BY-SA 4.0 per upstream terms. SCF data is CC BY-ND 4.0 and redistributed verbatim.
plugins/grc-engineer/src/evidence-collector.js · Bundled script · 607 lines · 1 finding marked
  1. /**
  2. * Evidence Artifact Collector
  3. * Generates scripts to collect audit evidence from multiple cloud providers
  4. *
  5. * Supported providers: AWS, Azure, GCP, Kubernetes
  6. * Supported formats: python, bash
  7. */
  8. import {
  9. loadProvider,
  10. listProviders,
  11. findMatchingTemplate,
  12. getNISTControl,
  13. getCloudCommands,
  14. getAllCloudCommands,
  15. getControlsByFedRAMPBaseline,
  16. getExportControlCommands,
  17. generateEvidenceScript as generateBaselineEvidenceScript
  18. } from './config-loader.js';
  19. // Legacy templates for backward compatibility (will be deprecated)
  20. const LEGACY_TEMPLATES = {
  21. aws: {
  22. python: {
  23. default: `#!/usr/bin/env python3
  24. """
  25. Evidence Collection Script
  26. Control: {control}
  27. Provider: AWS
  28. Generated: {timestamp}
  29. """
  30. import boto3
  31. import json
  32. from datetime import datetime
  33. def collect_evidence():
  34. """Collect evidence for: {control}"""
  35. evidence = {
  36. "control": "{control}",
  37. "timestamp": datetime.utcnow().isoformat(),
  38. "provider": "AWS",
  39. "results": []
  40. }
  41. # Add your evidence collection logic here
  42. return evidence
  43. if __name__ == "__main__":
  44. result = collect_evidence()
  45. print(json.dumps(result, indent=2))
  46. `
  47. },
  48. bash: {
  49. default: `#!/bin/bash
  50. # Evidence Collection Script
  51. # Control: {control}
  52. # Provider: AWS
  53. # Generated: {timestamp}
  54. echo "Collecting evidence for: {control}"
  55. # Add your AWS CLI evidence collection commands here
  56. `
  57. }
  58. }
  59. };
  60. /**
  61. * Generate an evidence collection script for a specific control and provider
  62. * @param {string} control - The control requirement to collect evidence for
  63. * @param {string} provider - Cloud provider (aws, azure, gcp, kubernetes)
  64. * @param {string} format - Output format (python, bash)
  65. * @returns {Promise<Object>} Generated script and metadata
  66. */
  67. export async function generateEvidenceScript(control, provider = 'aws', format = 'python') {
  68. const timestamp = new Date().toISOString();
  69. const normalizedProvider = provider.toLowerCase();
  70. const normalizedFormat = format.toLowerCase();
  71. // Validate format
  72. if (!['python', 'bash'].includes(normalizedFormat)) {
  73. throw new Error(`Unsupported format: ${format}. Supported: python, bash`);
  74. }
  75. let script;
  76. let templateKey;
  77. let instructions;
  78. try {
  79. // Try to load from YAML config
  80. const providerConfig = await loadProvider(normalizedProvider);
  81. const { key, template } = findMatchingTemplate(control, providerConfig);
  82. templateKey = key;
  83. // Get the script for the requested format
  84. if (template.formats && template.formats[normalizedFormat]) {
  85. script = template.formats[normalizedFormat];
  86. instructions = template.instructions || generateDefaultInstructions(normalizedProvider, normalizedFormat);
  87. } else {
  88. // Fall back to legacy templates
  89. script = LEGACY_TEMPLATES[normalizedProvider]?.[normalizedFormat]?.default ||
  90. LEGACY_TEMPLATES.aws[normalizedFormat]?.default;
  91. instructions = generateDefaultInstructions(normalizedProvider, normalizedFormat);
  92. }
  93. } catch (error) {
  94. // Fall back to legacy templates if config not found
  95. console.warn(`Config not found for ${provider}, using legacy template: ${error.message}`);
  96. script = LEGACY_TEMPLATES[normalizedProvider]?.[normalizedFormat]?.default ||
  97. LEGACY_TEMPLATES.aws[normalizedFormat]?.default;
  98. templateKey = 'default';
  99. instructions = generateDefaultInstructions(normalizedProvider, normalizedFormat);
  100. }
  101. if (!script) {
  102. throw new Error(`No template available for provider: ${provider}, format: ${format}`);
  103. }
  104. // Replace placeholders
  105. const processedScript = script
  106. .replace(/{timestamp}/g, timestamp)
  107. .replace(/{control}/g, control)
  108. .replace(/{provider}/g, provider.toUpperCase());
  109. return {
  110. control,
  111. provider: normalizedProvider,
  112. format: normalizedFormat,
  113. script: processedScript,
  114. metadata: {
  115. generated: timestamp,
  116. template_key: templateKey,
  117. config_source: templateKey !== 'default' ? 'yaml' : 'legacy'
  118. },
  119. instructions
  120. };
  121. }
  122. /**
  123. * Generate default instructions for a provider/format combination
  124. * @param {string} provider - Cloud provider
  125. * @param {string} format - Script format
  126. * @returns {string} Instructions markdown
  127. */
  128. function generateDefaultInstructions(provider, format) {
  129. const instructions = {
  130. aws: {
  131. python: `## AWS Python Evidence Collection
  132. 1. **Install dependencies:**
  133. \`\`\`bash
  134. pip install boto3
  135. \`\`\`
  136. 2. **Configure AWS credentials:**
  137. \`\`\`bash
  138. aws configure
  139. # Or set environment variables:
  140. export AWS_ACCESS_KEY_ID=your-key
  141. export AWS_SECRET_ACCESS_KEY=your-secret
  142. export AWS_DEFAULT_REGION=us-east-1
  143. \`\`\`
  144. 3. **Run the script:**
  145. \`\`\`bash
  146. python3 evidence_script.py > evidence_report.json
  147. \`\`\`
  148. 4. **Review the output and save for audit documentation**
  149. `,
  150. bash: `## AWS CLI Evidence Collection
  151. 1. **Install AWS CLI:**
  152. \`\`\`bash
  153. # macOS
  154. brew install awscli
  155. # Linux
  156. curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
  157. \`\`\`
  158. 2. **Configure AWS CLI:**
  159. \`\`\`bash
  160. aws configure
  161. \`\`\`
  162. 3. **Make script executable and run:**
  163. \`\`\`bash
  164. chmod +x evidence_script.sh
  165. ./evidence_script.sh > evidence_report.txt
  166. \`\`\`
  167. `
  168. },
  169. azure: {
  170. python: `## Azure Python Evidence Collection
  171. 1. **Install dependencies:**
  172. \`\`\`bash
  173. pip install azure-identity azure-mgmt-resource azure-mgmt-storage msgraph-sdk
  174. \`\`\`
  175. 2. **Configure Azure credentials:**
  176. \`\`\`bash
  177. az login
  178. # Or use service principal with environment variables
  179. \`\`\`
  180. 3. **Run the script:**
  181. \`\`\`bash
  182. python3 evidence_script.py > evidence_report.json
  183. \`\`\`
  184. `,
  185. bash: `## Azure CLI Evidence Collection
  186. 1. **Install Azure CLI:**
  187. \`\`\`bash
  188. # macOS
  189. brew install azure-cli
  190. # Linux
  191. curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
    • Note: Pipes a downloaded script directly into a shell (curl | sh / wget | bash)
    • Line 221 on GitHub
  192. \`\`\`
  193. 2. **Login to Azure:**
  194. \`\`\`bash
  195. az login
  196. az account set --subscription <subscription-id>
  197. \`\`\`
  198. 3. **Make script executable and run:**
  199. \`\`\`bash
  200. chmod +x evidence_script.sh
  201. ./evidence_script.sh > evidence_report.txt
  202. \`\`\`
  203. `
  204. },
  205. gcp: {
  206. python: `## GCP Python Evidence Collection
  207. 1. **Install dependencies:**
  208. \`\`\`bash
  209. pip install google-cloud-storage google-cloud-kms google-cloud-resource-manager
  210. \`\`\`
  211. 2. **Configure GCP credentials:**
  212. \`\`\`bash
  213. gcloud auth application-default login
  214. # Or set GOOGLE_APPLICATION_CREDENTIALS
  215. \`\`\`
  216. 3. **Run the script:**
  217. \`\`\`bash
  218. python3 evidence_script.py > evidence_report.json
  219. \`\`\`
  220. `,
  221. bash: `## GCP CLI Evidence Collection
  222. 1. **Install Google Cloud SDK:**
  223. \`\`\`bash
  224. # macOS
  225. brew install google-cloud-sdk
  226. # Linux
  227. curl https://sdk.cloud.google.com | bash
  228. \`\`\`
  229. 2. **Authenticate:**
  230. \`\`\`bash
  231. gcloud auth login
  232. gcloud config set project PROJECT_ID
  233. \`\`\`
  234. 3. **Make script executable and run:**
  235. \`\`\`bash
  236. chmod +x evidence_script.sh
  237. ./evidence_script.sh > evidence_report.txt
  238. \`\`\`
  239. `
  240. },
  241. kubernetes: {
  242. python: `## Kubernetes Python Evidence Collection
  243. 1. **Install dependencies:**
  244. \`\`\`bash
  245. pip install kubernetes
  246. \`\`\`
  247. 2. **Configure cluster access:**
  248. \`\`\`bash
  249. # Ensure kubeconfig is set up
  250. kubectl cluster-info
  251. \`\`\`
  252. 3. **Run the script:**
  253. \`\`\`bash
  254. python3 evidence_script.py > evidence_report.json
  255. \`\`\`
  256. `,
  257. bash: `## Kubernetes CLI Evidence Collection
  258. 1. **Install kubectl:**
  259. \`\`\`bash
  260. # macOS
  261. brew install kubectl
  262. \`\`\`
  263. 2. **Configure cluster access:**
  264. \`\`\`bash
  265. # EKS
  266. aws eks update-kubeconfig --name CLUSTER_NAME
  267. # AKS
  268. az aks get-credentials --name CLUSTER_NAME
  269. # GKE
  270. gcloud container clusters get-credentials CLUSTER_NAME
  271. \`\`\`
  272. 3. **Make script executable and run:**
  273. \`\`\`bash
  274. chmod +x evidence_script.sh
  275. ./evidence_script.sh > evidence_report.txt
  276. \`\`\`
  277. `
  278. }
  279. };
  280. return instructions[provider]?.[format] || 'See script comments for usage instructions.';
  281. }
  282. /**
  283. * List available providers
  284. * @returns {Promise<string[]>} Array of provider names
  285. */
  286. export async function getAvailableProviders() {
  287. return listProviders();
  288. }
  289. // ============================================================================
  290. // NIST 800-53 Control Evidence Collection
  291. // ============================================================================
  292. /**
  293. * Generate evidence collection commands for a specific NIST 800-53 control
  294. * @param {string} controlId - NIST control ID (e.g., "AC-2", "AU-6")
  295. * @param {string} provider - Cloud provider (aws, azure, gcp, kubernetes)
  296. * @returns {Promise<Object>} Control information with CLI commands and evidence script
  297. */
  298. export async function generateNISTControlEvidence(controlId, provider = 'aws') {
  299. const timestamp = new Date().toISOString();
  300. const normalizedProvider = provider.toLowerCase();
  301. const commandInfo = await getCloudCommands(controlId, normalizedProvider);
  302. // Build a standalone evidence script from the commands
  303. let script = `#!/bin/bash
  304. # NIST 800-53 Evidence Collection Script
  305. # Control: ${commandInfo.controlId}
  306. # Title: ${commandInfo.controlTitle || 'N/A'}
  307. # Provider: ${normalizedProvider.toUpperCase()}
  308. # Generated: ${timestamp}
  309. set -e
  310. echo "============================================"
  311. echo "NIST 800-53 Evidence Collection"
  312. echo "Control: ${commandInfo.controlId}"
  313. echo "Provider: ${normalizedProvider.toUpperCase()}"
  314. echo "Date: $(date -u +%Y-%m-%dT%H:%M:%SZ)"
  315. echo "============================================"
  316. echo ""
  317. `;
  318. if (commandInfo.evidence_script) {
  319. script += commandInfo.evidence_script;
  320. } else if (commandInfo.commands && commandInfo.commands.length > 0) {
  321. for (const cmd of commandInfo.commands) {
  322. script += `
  323. echo ">> ${cmd.description}"
  324. ${cmd.cmd} || echo "Command failed or not applicable"
  325. echo ""
  326. `;
  327. }
  328. } else {
  329. script += `echo "No automated evidence collection commands available for this control on ${normalizedProvider}."\n`;
  330. }
  331. script += `
  332. echo "============================================"
  333. echo "Evidence Collection Complete"
  334. echo "============================================"
  335. `;
  336. return {
  337. controlId: commandInfo.controlId,
  338. controlTitle: commandInfo.controlTitle,
  339. controlDescription: commandInfo.controlDescription,
  340. provider: normalizedProvider,
  341. commands: commandInfo.commands || [],
  342. script,
  343. metadata: {
  344. generated: timestamp,
  345. framework: 'NIST 800-53',
  346. hasAutomatedEvidence: !!(commandInfo.evidence_script || (commandInfo.commands && commandInfo.commands.length > 0))
  347. }
  348. };
  349. }
  350. /**
  351. * Generate evidence collection for all providers for a NIST control
  352. * @param {string} controlId - NIST control ID
  353. * @returns {Promise<Object>} Commands organized by provider
  354. */
  355. export async function generateNISTControlEvidenceAllProviders(controlId) {
  356. const timestamp = new Date().toISOString();
  357. const allCommands = await getAllCloudCommands(controlId);
  358. const result = {
  359. controlId: allCommands.controlId,
  360. controlTitle: allCommands.controlTitle,
  361. controlDescription: allCommands.controlDescription,
  362. metadata: {
  363. generated: timestamp,
  364. framework: 'NIST 800-53'
  365. },
  366. providers: {}
  367. };
  368. for (const [provider, providerData] of Object.entries(allCommands.providers)) {
  369. result.providers[provider] = {
  370. commands: providerData.commands || [],
  371. evidence_script: providerData.evidence_script || null
  372. };
  373. }
  374. return result;
  375. }
  376. // ============================================================================
  377. // FedRAMP Baseline Evidence Collection
  378. // ============================================================================
  379. /**
  380. * Generate a complete evidence collection script for a FedRAMP baseline
  381. * @param {string} baseline - FedRAMP baseline (low, moderate, high)
  382. * @param {string} provider - Cloud provider
  383. * @returns {Promise<Object>} Full evidence collection script and metadata
  384. */
  385. export async function generateFedRAMPBaselineEvidence(baseline, provider = 'aws') {
  386. const timestamp = new Date().toISOString();
  387. const normalizedBaseline = baseline.toLowerCase();
  388. const normalizedProvider = provider.toLowerCase();
  389. // Get all controls for this baseline
  390. const controls = await getControlsByFedRAMPBaseline(normalizedBaseline);
  391. // Generate the combined script
  392. const script = await generateBaselineEvidenceScript(normalizedBaseline, normalizedProvider);
  393. // Count controls with automated evidence
  394. let automatedCount = 0;
  395. let manualCount = 0;
  396. for (const control of controls) {
  397. if (control.cloud_tests && control.cloud_tests[normalizedProvider]) {
  398. automatedCount++;
  399. } else {
  400. manualCount++;
  401. }
  402. }
  403. return {
  404. baseline: normalizedBaseline,
  405. provider: normalizedProvider,
  406. script,
  407. metadata: {
  408. generated: timestamp,
  409. totalControls: controls.length,
  410. automatedControls: automatedCount,
  411. manualControls: manualCount,
  412. coveragePercent: controls.length > 0 ? Math.round((automatedCount / controls.length) * 100) : 0
  413. },
  414. controlSummary: controls.map(c => ({
  415. id: c.id,
  416. title: c.title,
  417. family: c.family,
  418. hasAutomatedEvidence: !!(c.cloud_tests && c.cloud_tests[normalizedProvider])
  419. }))
  420. };
  421. }
  422. /**
  423. * Get a summary of FedRAMP baseline controls with evidence availability
  424. * @param {string} baseline - FedRAMP baseline
  425. * @param {string} provider - Cloud provider
  426. * @returns {Promise<Object>} Summary of controls and evidence availability
  427. */
  428. export async function getFedRAMPBaselineSummary(baseline, provider = 'aws') {
  429. const normalizedBaseline = baseline.toLowerCase();
  430. const normalizedProvider = provider.toLowerCase();
  431. const controls = await getControlsByFedRAMPBaseline(normalizedBaseline);
  432. // Group by family
  433. const byFamily = {};
  434. for (const control of controls) {
  435. const family = control.family || 'Unknown';
  436. if (!byFamily[family]) {
  437. byFamily[family] = {
  438. familyName: control.familyName,
  439. total: 0,
  440. automated: 0,
  441. controls: []
  442. };
  443. }
  444. byFamily[family].total++;
  445. const hasAutomated = !!(control.cloud_tests && control.cloud_tests[normalizedProvider]);
  446. if (hasAutomated) {
  447. byFamily[family].automated++;
  448. }
  449. byFamily[family].controls.push({
  450. id: control.id,
  451. title: control.title,
  452. hasAutomatedEvidence: hasAutomated
  453. });
  454. }
  455. return {
  456. baseline: normalizedBaseline,
  457. provider: normalizedProvider,
  458. totalControls: controls.length,
  459. families: byFamily
  460. };
  461. }
  462. // ============================================================================
  463. // Export Control Framework Evidence Collection
  464. // ============================================================================
  465. /**
  466. * Generate evidence collection for export control framework
  467. * @param {string} framework - Framework name (itar, irap, ismap)
  468. * @param {string} provider - Cloud provider
  469. * @returns {Promise<Object>} Evidence collection script and commands
  470. */
  471. export async function generateExportControlEvidence(framework, provider = 'aws') {
  472. const timestamp = new Date().toISOString();
  473. const normalizedProvider = provider.toLowerCase();
  474. const frameworkData = await getExportControlCommands(framework, normalizedProvider);
  475. // Build evidence script
  476. let script = `#!/bin/bash
  477. # Export Control Evidence Collection Script
  478. # Framework: ${frameworkData.framework}
  479. # Version: ${frameworkData.version}
  480. # Provider: ${normalizedProvider.toUpperCase()}
  481. # Generated: ${timestamp}
  482. set -e
  483. echo "============================================"
  484. echo "Export Control Evidence Collection"
  485. echo "Framework: ${frameworkData.framework}"
  486. echo "Provider: ${normalizedProvider.toUpperCase()}"
  487. echo "Date: $(date -u +%Y-%m-%dT%H:%M:%SZ)"
  488. echo "============================================"
  489. echo ""
  490. `;
  491. for (const control of frameworkData.controls) {
  492. script += `
  493. # ============================================
  494. # ${control.id}: ${control.title}
  495. # ============================================
  496. echo "=== ${control.id}: ${control.title} ==="
  497. `;
  498. if (control.evidence_script) {
  499. script += control.evidence_script;
  500. } else if (control.commands && control.commands.length > 0) {
  501. for (const cmd of control.commands) {
  502. script += `echo ">> ${cmd.description}"\n`;
  503. script += `${cmd.cmd} || echo "Command failed or not applicable"\n`;
  504. script += `echo ""\n`;
  505. }
  506. }
  507. }
  508. script += `
  509. echo "============================================"
  510. echo "Evidence Collection Complete"
  511. echo "============================================"
  512. `;
  513. return {
  514. framework: frameworkData.framework,
  515. version: frameworkData.version,
  516. provider: normalizedProvider,
  517. script,
  518. controls: frameworkData.controls,
  519. metadata: {
  520. generated: timestamp,
  521. totalControls: frameworkData.controls.length
  522. }
  523. };
  524. }
plugins/grc-portfolio/scripts/bootstrap.sh · Bundled script · 183 lines · 1 finding marked
  1. #!/bin/bash
  2. # AWS Website Deployment - Bootstrap Script
  3. # This script sets up your local environment for deploying websites to AWS
  4. set -e # Exit on any error
  5. # Colors for output
  6. RED='\033[0;31m'
  7. GREEN='\033[0;32m'
  8. YELLOW='\033[1;33m'
  9. BLUE='\033[0;34m'
  10. NC='\033[0m' # No Color
  11. # Print functions
  12. print_header() {
  13. echo -e "\n${BLUE}========================================${NC}"
  14. echo -e "${BLUE}$1${NC}"
  15. echo -e "${BLUE}========================================${NC}\n"
  16. }
  17. print_success() {
  18. echo -e "${GREEN}✓ $1${NC}"
  19. }
  20. print_error() {
  21. echo -e "${RED}✗ $1${NC}"
  22. }
  23. print_warning() {
  24. echo -e "${YELLOW}⚠ $1${NC}"
  25. }
  26. print_info() {
  27. echo -e "${BLUE}ℹ $1${NC}"
  28. }
  29. # Check if command exists
  30. command_exists() {
  31. command -v "$1" >/dev/null 2>&1
  32. }
  33. print_header "AWS Website Deployment - Environment Setup"
  34. echo "This script will check and install the necessary tools for deploying your website to AWS."
  35. echo ""
  36. # Check Operating System
  37. print_info "Detecting operating system..."
  38. OS="$(uname -s)"
  39. case "${OS}" in
  40. Linux*) MACHINE=Linux;;
  41. Darwin*) MACHINE=Mac;;
  42. MINGW*) MACHINE=Windows;;
  43. *) MACHINE="UNKNOWN:${OS}"
  44. esac
  45. print_success "Operating System: ${MACHINE}"
  46. # Check for Homebrew (Mac only)
  47. if [ "$MACHINE" = "Mac" ]; then
  48. print_info "Checking for Homebrew..."
  49. if ! command_exists brew; then
  50. print_warning "Homebrew not found. Installing Homebrew..."
  51. /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  52. print_success "Homebrew installed successfully"
  53. else
  54. print_success "Homebrew is already installed"
  55. fi
  56. fi
  57. # Check for AWS CLI
  58. print_info "Checking for AWS CLI..."
  59. if ! command_exists aws; then
  60. print_warning "AWS CLI not found. Installing..."
  61. if [ "$MACHINE" = "Mac" ]; then
  62. brew install awscli
  63. elif [ "$MACHINE" = "Linux" ]; then
  64. curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
  65. unzip awscliv2.zip
  66. sudo ./aws/install
  67. rm -rf aws awscliv2.zip
  68. else
  69. print_error "Please install AWS CLI manually from: https://aws.amazon.com/cli/"
  70. exit 1
  71. fi
  72. print_success "AWS CLI installed successfully"
  73. else
  74. print_success "AWS CLI is already installed ($(aws --version))"
  75. fi
  76. # Check for Node.js
  77. print_info "Checking for Node.js..."
  78. if ! command_exists node; then
  79. print_warning "Node.js not found. Installing..."
  80. if [ "$MACHINE" = "Mac" ]; then
  81. brew install node
  82. elif [ "$MACHINE" = "Linux" ]; then
  83. curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
    • Note: Pipes a downloaded script directly into a shell (curl | sh / wget | bash)
    • Line 101 on GitHub
  84. sudo apt-get install -y nodejs
  85. else
  86. print_error "Please install Node.js manually from: https://nodejs.org/"
  87. exit 1
  88. fi
  89. print_success "Node.js installed successfully"
  90. else
  91. print_success "Node.js is already installed ($(node --version))"
  92. fi
  93. # Check for npm
  94. print_info "Checking for npm..."
  95. if ! command_exists npm; then
  96. print_error "npm not found. Please reinstall Node.js"
  97. exit 1
  98. else
  99. print_success "npm is already installed ($(npm --version))"
  100. fi
  101. # Configure AWS CLI
  102. print_header "AWS Configuration"
  103. if [ ! -f ~/.aws/credentials ]; then
  104. print_warning "AWS credentials not configured"
  105. echo ""
  106. echo "You'll need:"
  107. echo " 1. AWS Access Key ID"
  108. echo " 2. AWS Secret Access Key"
  109. echo " 3. Default region (e.g., us-east-1)"
  110. echo ""
  111. print_info "You can get these from the AWS Console: IAM → Users → Security Credentials"
  112. echo ""
  113. read -p "Would you like to configure AWS now? (y/n) " -n 1 -r
  114. echo
  115. if [[ $REPLY =~ ^[Yy]$ ]]; then
  116. aws configure
  117. print_success "AWS configured successfully"
  118. else
  119. print_warning "Skipping AWS configuration. Run 'aws configure' later to set up credentials"
  120. fi
  121. else
  122. print_success "AWS credentials already configured"
  123. print_info "Current AWS identity:"
  124. aws sts get-caller-identity 2>/dev/null || print_warning "Could not verify AWS credentials. You may need to run 'aws configure'"
  125. fi
  126. # Verify deployment scripts exist
  127. print_header "Verifying Deployment Scripts"
  128. SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
  129. DEPLOY_SCRIPT="$SCRIPT_DIR/deploy.sh"
  130. VALIDATE_SCRIPT="$SCRIPT_DIR/validate-stack.sh"
  131. if [ -f "$DEPLOY_SCRIPT" ]; then
  132. print_success "deploy.sh found at scripts/deploy.sh"
  133. else
  134. print_error "deploy.sh not found! This should not happen."
  135. fi
  136. if [ -f "$VALIDATE_SCRIPT" ]; then
  137. print_success "validate-stack.sh found at scripts/validate-stack.sh"
  138. else
  139. print_error "validate-stack.sh not found! This should not happen."
  140. fi
  141. print_info "Run these from your project directory (point at the plugin's scripts/):"
  142. echo " <plugin-root>/scripts/deploy.sh <bucket> <distribution-id> [profile]"
  143. echo " <plugin-root>/scripts/validate-stack.sh [template-file] [profile]"
  144. # Summary
  145. print_header "Setup Complete!"
  146. echo "✓ All required tools are installed"
  147. echo ""
  148. echo "Next steps:"
  149. echo " 1. From Claude Code, run /grc-portfolio:plan to scaffold your site config."
  150. echo " 2. Run /grc-portfolio:preflight to validate AWS readiness."
  151. echo " 3. Run /grc-portfolio:infra to deploy the CloudFormation stack."
  152. echo " 4. Run /grc-portfolio:deploy to build and publish the site."
  153. echo ""
  154. print_success "You're ready to deploy your website to AWS!"

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.