cli-jaw 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.ko.md +411 -0
- package/README.md +416 -0
- package/README.zh-CN.md +411 -0
- package/dist/bin/cli-jaw.js +108 -0
- package/dist/bin/cli-jaw.js.map +1 -0
- package/dist/bin/commands/browser.js +241 -0
- package/dist/bin/commands/browser.js.map +1 -0
- package/dist/bin/commands/chat.js +878 -0
- package/dist/bin/commands/chat.js.map +1 -0
- package/dist/bin/commands/doctor.js +152 -0
- package/dist/bin/commands/doctor.js.map +1 -0
- package/dist/bin/commands/employee.js +70 -0
- package/dist/bin/commands/employee.js.map +1 -0
- package/dist/bin/commands/init.js +110 -0
- package/dist/bin/commands/init.js.map +1 -0
- package/dist/bin/commands/mcp.js +219 -0
- package/dist/bin/commands/mcp.js.map +1 -0
- package/dist/bin/commands/memory.js +105 -0
- package/dist/bin/commands/memory.js.map +1 -0
- package/dist/bin/commands/reset.js +109 -0
- package/dist/bin/commands/reset.js.map +1 -0
- package/dist/bin/commands/serve.js +75 -0
- package/dist/bin/commands/serve.js.map +1 -0
- package/dist/bin/commands/skill.js +232 -0
- package/dist/bin/commands/skill.js.map +1 -0
- package/dist/bin/commands/status.js +51 -0
- package/dist/bin/commands/status.js.map +1 -0
- package/dist/bin/postinstall.js +218 -0
- package/dist/bin/postinstall.js.map +1 -0
- package/dist/lib/mcp-sync.js +639 -0
- package/dist/lib/mcp-sync.js.map +1 -0
- package/dist/lib/quota-copilot.js +62 -0
- package/dist/lib/quota-copilot.js.map +1 -0
- package/dist/lib/upload.js +72 -0
- package/dist/lib/upload.js.map +1 -0
- package/dist/server.js +832 -0
- package/dist/server.js.map +1 -0
- package/dist/src/agent/args.js +66 -0
- package/dist/src/agent/args.js.map +1 -0
- package/dist/src/agent/events.js +328 -0
- package/dist/src/agent/events.js.map +1 -0
- package/dist/src/agent/spawn.js +646 -0
- package/dist/src/agent/spawn.js.map +1 -0
- package/dist/src/browser/actions.js +168 -0
- package/dist/src/browser/actions.js.map +1 -0
- package/dist/src/browser/connection.js +79 -0
- package/dist/src/browser/connection.js.map +1 -0
- package/dist/src/browser/index.js +4 -0
- package/dist/src/browser/index.js.map +1 -0
- package/dist/src/browser/vision.js +128 -0
- package/dist/src/browser/vision.js.map +1 -0
- package/dist/src/cli/acp-client.js +298 -0
- package/dist/src/cli/acp-client.js.map +1 -0
- package/dist/src/cli/commands.js +267 -0
- package/dist/src/cli/commands.js.map +1 -0
- package/dist/src/cli/handlers.js +405 -0
- package/dist/src/cli/handlers.js.map +1 -0
- package/dist/src/cli/registry.js +87 -0
- package/dist/src/cli/registry.js.map +1 -0
- package/dist/src/command-contract/catalog.js +36 -0
- package/dist/src/command-contract/catalog.js.map +1 -0
- package/dist/src/command-contract/help-renderer.js +39 -0
- package/dist/src/command-contract/help-renderer.js.map +1 -0
- package/dist/src/command-contract/policy.js +34 -0
- package/dist/src/command-contract/policy.js.map +1 -0
- package/dist/src/core/bus.js +17 -0
- package/dist/src/core/bus.js.map +1 -0
- package/dist/src/core/config.js +198 -0
- package/dist/src/core/config.js.map +1 -0
- package/dist/src/core/db.js +97 -0
- package/dist/src/core/db.js.map +1 -0
- package/dist/src/core/i18n.js +86 -0
- package/dist/src/core/i18n.js.map +1 -0
- package/dist/src/core/logger.js +14 -0
- package/dist/src/core/logger.js.map +1 -0
- package/dist/src/core/settings-merge.js +40 -0
- package/dist/src/core/settings-merge.js.map +1 -0
- package/dist/src/http/async-handler.js +6 -0
- package/dist/src/http/async-handler.js.map +1 -0
- package/dist/src/http/error-middleware.js +24 -0
- package/dist/src/http/error-middleware.js.map +1 -0
- package/dist/src/http/response.js +16 -0
- package/dist/src/http/response.js.map +1 -0
- package/dist/src/memory/heartbeat.js +106 -0
- package/dist/src/memory/heartbeat.js.map +1 -0
- package/dist/src/memory/memory.js +119 -0
- package/dist/src/memory/memory.js.map +1 -0
- package/dist/src/memory/worklog.js +154 -0
- package/dist/src/memory/worklog.js.map +1 -0
- package/dist/src/orchestrator/distribute.js +310 -0
- package/dist/src/orchestrator/distribute.js.map +1 -0
- package/dist/src/orchestrator/parser.js +118 -0
- package/dist/src/orchestrator/parser.js.map +1 -0
- package/dist/src/orchestrator/pipeline.js +343 -0
- package/dist/src/orchestrator/pipeline.js.map +1 -0
- package/dist/src/prompt/builder.js +531 -0
- package/dist/src/prompt/builder.js.map +1 -0
- package/dist/src/routes/browser.js +126 -0
- package/dist/src/routes/browser.js.map +1 -0
- package/dist/src/routes/quota.js +94 -0
- package/dist/src/routes/quota.js.map +1 -0
- package/dist/src/security/decode.js +23 -0
- package/dist/src/security/decode.js.map +1 -0
- package/dist/src/security/path-guards.js +62 -0
- package/dist/src/security/path-guards.js.map +1 -0
- package/dist/src/telegram/bot.js +469 -0
- package/dist/src/telegram/bot.js.map +1 -0
- package/dist/src/telegram/forwarder.js +93 -0
- package/dist/src/telegram/forwarder.js.map +1 -0
- package/package.json +80 -0
- package/public/css/chat.css +571 -0
- package/public/css/layout.css +350 -0
- package/public/css/markdown.css +270 -0
- package/public/css/modals.css +172 -0
- package/public/css/sidebar.css +225 -0
- package/public/css/variables.css +142 -0
- package/public/index.html +470 -0
- package/public/js/api.js +55 -0
- package/public/js/constants.js +119 -0
- package/public/js/features/appname.js +43 -0
- package/public/js/features/chat.js +242 -0
- package/public/js/features/employees.js +120 -0
- package/public/js/features/heartbeat.js +80 -0
- package/public/js/features/i18n.js +125 -0
- package/public/js/features/memory.js +85 -0
- package/public/js/features/settings.js +512 -0
- package/public/js/features/sidebar.js +88 -0
- package/public/js/features/skills.js +68 -0
- package/public/js/features/slash-commands.js +231 -0
- package/public/js/features/theme.js +40 -0
- package/public/js/locale.js +23 -0
- package/public/js/main.js +281 -0
- package/public/js/render.js +294 -0
- package/public/js/state.js +16 -0
- package/public/js/ui.js +172 -0
- package/public/js/ws.js +76 -0
- package/public/locales/en.json +180 -0
- package/public/locales/ko.json +180 -0
- package/public/theme-test.html +545 -0
- package/skills_ref/1password/SKILL.md +70 -0
- package/skills_ref/agents-sdk/SKILL.md +155 -0
- package/skills_ref/agents-sdk/references/callable.md +92 -0
- package/skills_ref/agents-sdk/references/codemode.md +207 -0
- package/skills_ref/agents-sdk/references/email.md +146 -0
- package/skills_ref/agents-sdk/references/mcp.md +154 -0
- package/skills_ref/agents-sdk/references/state-scheduling.md +164 -0
- package/skills_ref/agents-sdk/references/streaming-chat.md +178 -0
- package/skills_ref/agents-sdk/references/workflows.md +132 -0
- package/skills_ref/algorithmic-art/LICENSE.txt +202 -0
- package/skills_ref/algorithmic-art/SKILL.md +405 -0
- package/skills_ref/algorithmic-art/templates/generator_template.js +223 -0
- package/skills_ref/algorithmic-art/templates/viewer.html +599 -0
- package/skills_ref/apple-notes/SKILL.md +77 -0
- package/skills_ref/apple-reminders/SKILL.md +118 -0
- package/skills_ref/atlas/SKILL.md +99 -0
- package/skills_ref/brainstorming/SKILL.md +96 -0
- package/skills_ref/browser/SKILL.md +179 -0
- package/skills_ref/canvas-design/LICENSE.txt +202 -0
- package/skills_ref/canvas-design/SKILL.md +130 -0
- package/skills_ref/canvas-design/canvas-fonts/ArsenalSC-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/ArsenalSC-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/BigShoulders-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/BigShoulders-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/BigShoulders-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Boldonse-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Boldonse-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/BricolageGrotesque-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/BricolageGrotesque-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/BricolageGrotesque-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/CrimsonPro-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/CrimsonPro-Italic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/CrimsonPro-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/CrimsonPro-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/DMMono-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/DMMono-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/EricaOne-OFL.txt +94 -0
- package/skills_ref/canvas-design/canvas-fonts/EricaOne-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/GeistMono-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/GeistMono-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/GeistMono-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Gloock-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Gloock-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexMono-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexMono-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexMono-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexSerif-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexSerif-BoldItalic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexSerif-Italic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/IBMPlexSerif-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSans-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSans-BoldItalic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSans-Italic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSans-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSans-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSerif-Italic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/InstrumentSerif-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Italiana-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Italiana-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/JetBrainsMono-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/JetBrainsMono-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/JetBrainsMono-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Jura-Light.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Jura-Medium.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Jura-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/LibreBaskerville-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/LibreBaskerville-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Lora-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Lora-BoldItalic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Lora-Italic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Lora-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Lora-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/NationalPark-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/NationalPark-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/NationalPark-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/NothingYouCouldDo-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/NothingYouCouldDo-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Outfit-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Outfit-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Outfit-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/PixelifySans-Medium.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/PixelifySans-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/PoiretOne-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/PoiretOne-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/RedHatMono-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/RedHatMono-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/RedHatMono-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Silkscreen-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Silkscreen-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/SmoochSans-Medium.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/SmoochSans-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Tektur-Medium.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/Tektur-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/Tektur-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/WorkSans-Bold.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/WorkSans-BoldItalic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/WorkSans-Italic.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/WorkSans-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/WorkSans-Regular.ttf +0 -0
- package/skills_ref/canvas-design/canvas-fonts/YoungSerif-OFL.txt +93 -0
- package/skills_ref/canvas-design/canvas-fonts/YoungSerif-Regular.ttf +0 -0
- package/skills_ref/changelog-generator/SKILL.md +104 -0
- package/skills_ref/cloudflare-deploy/SKILL.md +207 -0
- package/skills_ref/codebase-orientation/SKILL.md +29 -0
- package/skills_ref/config-file-explainer/SKILL.md +26 -0
- package/skills_ref/context-compression/SKILL.md +265 -0
- package/skills_ref/context-compression/references/evaluation-framework.md +213 -0
- package/skills_ref/context-compression/scripts/compression_evaluator.py +658 -0
- package/skills_ref/data-structure-chooser/SKILL.md +26 -0
- package/skills_ref/debugging-checklist/SKILL.md +26 -0
- package/skills_ref/debugging-helpers/CREATION-LOG.md +119 -0
- package/skills_ref/debugging-helpers/SKILL.md +296 -0
- package/skills_ref/debugging-helpers/condition-based-waiting-example.ts +158 -0
- package/skills_ref/debugging-helpers/condition-based-waiting.md +115 -0
- package/skills_ref/debugging-helpers/defense-in-depth.md +122 -0
- package/skills_ref/debugging-helpers/find-polluter.sh +63 -0
- package/skills_ref/debugging-helpers/root-cause-tracing.md +169 -0
- package/skills_ref/debugging-helpers/test-academic.md +14 -0
- package/skills_ref/debugging-helpers/test-pressure-1.md +58 -0
- package/skills_ref/debugging-helpers/test-pressure-2.md +68 -0
- package/skills_ref/debugging-helpers/test-pressure-3.md +69 -0
- package/skills_ref/deep-research/.env.example +7 -0
- package/skills_ref/deep-research/README.md +246 -0
- package/skills_ref/deep-research/SKILL.md +106 -0
- package/skills_ref/deep-research/requirements.txt +2 -0
- package/skills_ref/deep-research/scripts/research.py +692 -0
- package/skills_ref/dependency-install-helper/SKILL.md +26 -0
- package/skills_ref/dev/SKILL.md +65 -0
- package/skills_ref/dev-backend/SKILL.md +61 -0
- package/skills_ref/dev-data/SKILL.md +76 -0
- package/skills_ref/dev-frontend/LICENSE.txt +177 -0
- package/skills_ref/dev-frontend/SKILL.md +42 -0
- package/skills_ref/dev-testing/LICENSE.txt +202 -0
- package/skills_ref/dev-testing/SKILL.md +96 -0
- package/skills_ref/dev-testing/examples/console_logging.py +35 -0
- package/skills_ref/dev-testing/examples/element_discovery.py +40 -0
- package/skills_ref/dev-testing/examples/static_html_automation.py +33 -0
- package/skills_ref/dev-testing/scripts/with_server.py +106 -0
- package/skills_ref/develop-web-game/SKILL.md +149 -0
- package/skills_ref/differential-review/.claude-plugin/plugin.json +10 -0
- package/skills_ref/differential-review/README.md +109 -0
- package/skills_ref/differential-review/commands/diff-review.md +21 -0
- package/skills_ref/differential-review/skills/differential-review/SKILL.md +220 -0
- package/skills_ref/differential-review/skills/differential-review/adversarial.md +203 -0
- package/skills_ref/differential-review/skills/differential-review/methodology.md +234 -0
- package/skills_ref/differential-review/skills/differential-review/patterns.md +300 -0
- package/skills_ref/differential-review/skills/differential-review/reporting.md +369 -0
- package/skills_ref/dispatching-parallel-agents/SKILL.md +180 -0
- package/skills_ref/doc-coauthoring/SKILL.md +375 -0
- package/skills_ref/docx/LICENSE.txt +30 -0
- package/skills_ref/docx/SKILL.md +481 -0
- package/skills_ref/docx/scripts/__init__.py +1 -0
- package/skills_ref/docx/scripts/accept_changes.py +135 -0
- package/skills_ref/docx/scripts/comment.py +318 -0
- package/skills_ref/docx/scripts/office/helpers/__init__.py +0 -0
- package/skills_ref/docx/scripts/office/helpers/merge_runs.py +199 -0
- package/skills_ref/docx/scripts/office/helpers/simplify_redlines.py +197 -0
- package/skills_ref/docx/scripts/office/pack.py +159 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
- package/skills_ref/docx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
- package/skills_ref/docx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
- package/skills_ref/docx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
- package/skills_ref/docx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
- package/skills_ref/docx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
- package/skills_ref/docx/scripts/office/schemas/mce/mc.xsd +75 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
- package/skills_ref/docx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
- package/skills_ref/docx/scripts/office/soffice.py +183 -0
- package/skills_ref/docx/scripts/office/unpack.py +132 -0
- package/skills_ref/docx/scripts/office/validate.py +111 -0
- package/skills_ref/docx/scripts/office/validators/__init__.py +15 -0
- package/skills_ref/docx/scripts/office/validators/base.py +847 -0
- package/skills_ref/docx/scripts/office/validators/docx.py +446 -0
- package/skills_ref/docx/scripts/office/validators/pptx.py +275 -0
- package/skills_ref/docx/scripts/office/validators/redlining.py +247 -0
- package/skills_ref/docx/scripts/templates/comments.xml +3 -0
- package/skills_ref/docx/scripts/templates/commentsExtended.xml +3 -0
- package/skills_ref/docx/scripts/templates/commentsExtensible.xml +3 -0
- package/skills_ref/docx/scripts/templates/commentsIds.xml +3 -0
- package/skills_ref/docx/scripts/templates/people.xml +3 -0
- package/skills_ref/durable-objects/SKILL.md +186 -0
- package/skills_ref/durable-objects/references/rules.md +286 -0
- package/skills_ref/durable-objects/references/testing.md +264 -0
- package/skills_ref/durable-objects/references/workers.md +346 -0
- package/skills_ref/email-draft-polish/SKILL.md +24 -0
- package/skills_ref/error-message-explainer/SKILL.md +27 -0
- package/skills_ref/fal-image-edit/SKILL.md +249 -0
- package/skills_ref/fal-image-edit/scripts/edit-image.sh +199 -0
- package/skills_ref/figma-implement-design/SKILL.md +264 -0
- package/skills_ref/git-worktrees/SKILL.md +218 -0
- package/skills_ref/github/SKILL.md +210 -0
- package/skills_ref/gog/SKILL.md +116 -0
- package/skills_ref/goplaces/SKILL.md +52 -0
- package/skills_ref/himalaya/SKILL.md +257 -0
- package/skills_ref/hugging-face-cli/SKILL.md +186 -0
- package/skills_ref/hugging-face-cli/references/commands.md +954 -0
- package/skills_ref/hugging-face-cli/references/examples.md +374 -0
- package/skills_ref/hugging-face-evaluation/SKILL.md +651 -0
- package/skills_ref/hugging-face-evaluation/examples/.env.example +7 -0
- package/skills_ref/hugging-face-evaluation/examples/USAGE_EXAMPLES.md +382 -0
- package/skills_ref/hugging-face-evaluation/examples/artificial_analysis_to_hub.py +141 -0
- package/skills_ref/hugging-face-evaluation/examples/example_readme_tables.md +135 -0
- package/skills_ref/hugging-face-evaluation/examples/metric_mapping.json +50 -0
- package/skills_ref/hugging-face-evaluation/requirements.txt +20 -0
- package/skills_ref/hugging-face-evaluation/scripts/evaluation_manager.py +1374 -0
- package/skills_ref/hugging-face-evaluation/scripts/inspect_eval_uv.py +104 -0
- package/skills_ref/hugging-face-evaluation/scripts/inspect_vllm_uv.py +317 -0
- package/skills_ref/hugging-face-evaluation/scripts/lighteval_vllm_uv.py +303 -0
- package/skills_ref/hugging-face-evaluation/scripts/run_eval_job.py +98 -0
- package/skills_ref/hugging-face-evaluation/scripts/run_vllm_eval_job.py +331 -0
- package/skills_ref/hugging-face-evaluation/scripts/test_extraction.py +206 -0
- package/skills_ref/hugging-face-model-trainer/SKILL.md +718 -0
- package/skills_ref/hugging-face-model-trainer/references/gguf_conversion.md +296 -0
- package/skills_ref/hugging-face-model-trainer/references/hardware_guide.md +283 -0
- package/skills_ref/hugging-face-model-trainer/references/hub_saving.md +364 -0
- package/skills_ref/hugging-face-model-trainer/references/reliability_principles.md +371 -0
- package/skills_ref/hugging-face-model-trainer/references/trackio_guide.md +189 -0
- package/skills_ref/hugging-face-model-trainer/references/training_methods.md +150 -0
- package/skills_ref/hugging-face-model-trainer/references/training_patterns.md +203 -0
- package/skills_ref/hugging-face-model-trainer/references/troubleshooting.md +282 -0
- package/skills_ref/hugging-face-model-trainer/references/unsloth.md +313 -0
- package/skills_ref/hugging-face-model-trainer/scripts/convert_to_gguf.py +424 -0
- package/skills_ref/hugging-face-model-trainer/scripts/dataset_inspector.py +417 -0
- package/skills_ref/hugging-face-model-trainer/scripts/estimate_cost.py +150 -0
- package/skills_ref/hugging-face-model-trainer/scripts/train_dpo_example.py +106 -0
- package/skills_ref/hugging-face-model-trainer/scripts/train_grpo_example.py +89 -0
- package/skills_ref/hugging-face-model-trainer/scripts/train_sft_example.py +122 -0
- package/skills_ref/hugging-face-model-trainer/scripts/unsloth_sft_example.py +512 -0
- package/skills_ref/imagegen/SKILL.md +174 -0
- package/skills_ref/insecure-defaults/.claude-plugin/plugin.json +10 -0
- package/skills_ref/insecure-defaults/README.md +45 -0
- package/skills_ref/insecure-defaults/skills/insecure-defaults/SKILL.md +117 -0
- package/skills_ref/insecure-defaults/skills/insecure-defaults/references/examples.md +409 -0
- package/skills_ref/jupyter-notebook/SKILL.md +107 -0
- package/skills_ref/linear/SKILL.md +87 -0
- package/skills_ref/linter-fix-guide/SKILL.md +27 -0
- package/skills_ref/log-summarizer/SKILL.md +27 -0
- package/skills_ref/mcp-builder/LICENSE.txt +202 -0
- package/skills_ref/mcp-builder/SKILL.md +236 -0
- package/skills_ref/mcp-builder/reference/evaluation.md +602 -0
- package/skills_ref/mcp-builder/reference/mcp_best_practices.md +249 -0
- package/skills_ref/mcp-builder/reference/node_mcp_server.md +970 -0
- package/skills_ref/mcp-builder/reference/python_mcp_server.md +719 -0
- package/skills_ref/mcp-builder/scripts/connections.py +151 -0
- package/skills_ref/mcp-builder/scripts/evaluation.py +373 -0
- package/skills_ref/mcp-builder/scripts/example_evaluation.xml +22 -0
- package/skills_ref/mcp-builder/scripts/requirements.txt +2 -0
- package/skills_ref/memory/SKILL.md +129 -0
- package/skills_ref/modern-python/.claude-plugin/plugin.json +10 -0
- package/skills_ref/modern-python/README.md +66 -0
- package/skills_ref/modern-python/hooks/hooks.json +16 -0
- package/skills_ref/modern-python/hooks/setup-shims.bats +70 -0
- package/skills_ref/modern-python/hooks/setup-shims.sh +24 -0
- package/skills_ref/modern-python/hooks/shims/pip +27 -0
- package/skills_ref/modern-python/hooks/shims/pip-shim.bats +45 -0
- package/skills_ref/modern-python/hooks/shims/pip3 +27 -0
- package/skills_ref/modern-python/hooks/shims/pipx +41 -0
- package/skills_ref/modern-python/hooks/shims/pipx-shim.bats +64 -0
- package/skills_ref/modern-python/hooks/shims/python +26 -0
- package/skills_ref/modern-python/hooks/shims/python-shim.bats +53 -0
- package/skills_ref/modern-python/hooks/shims/python3 +26 -0
- package/skills_ref/modern-python/hooks/shims/uv +27 -0
- package/skills_ref/modern-python/hooks/shims/uv-shim.bats +47 -0
- package/skills_ref/modern-python/skills/modern-python/SKILL.md +333 -0
- package/skills_ref/modern-python/skills/modern-python/references/dependabot.md +43 -0
- package/skills_ref/modern-python/skills/modern-python/references/migration-checklist.md +141 -0
- package/skills_ref/modern-python/skills/modern-python/references/pep723-scripts.md +259 -0
- package/skills_ref/modern-python/skills/modern-python/references/prek.md +211 -0
- package/skills_ref/modern-python/skills/modern-python/references/pyproject.md +254 -0
- package/skills_ref/modern-python/skills/modern-python/references/ruff-config.md +240 -0
- package/skills_ref/modern-python/skills/modern-python/references/security-setup.md +255 -0
- package/skills_ref/modern-python/skills/modern-python/references/testing.md +284 -0
- package/skills_ref/modern-python/skills/modern-python/references/uv-commands.md +200 -0
- package/skills_ref/modern-python/skills/modern-python/templates/dependabot.yml +36 -0
- package/skills_ref/modern-python/skills/modern-python/templates/pre-commit-config.yaml +66 -0
- package/skills_ref/nano-banana-pro/SKILL.md +58 -0
- package/skills_ref/netlify-deploy/SKILL.md +233 -0
- package/skills_ref/notion/SKILL.md +304 -0
- package/skills_ref/notion-knowledge-capture/SKILL.md +56 -0
- package/skills_ref/notion-meeting-intelligence/SKILL.md +60 -0
- package/skills_ref/notion-research-documentation/SKILL.md +59 -0
- package/skills_ref/notion-spec-to-implementation/SKILL.md +58 -0
- package/skills_ref/obsidian/SKILL.md +81 -0
- package/skills_ref/openai-docs/SKILL.md +56 -0
- package/skills_ref/openhue/SKILL.md +112 -0
- package/skills_ref/pdf/SKILL.md +69 -0
- package/skills_ref/postgres/README.md +77 -0
- package/skills_ref/postgres/SKILL.md +129 -0
- package/skills_ref/postgres/connections.example.json +34 -0
- package/skills_ref/postgres/requirements.txt +1 -0
- package/skills_ref/postgres/scripts/query.py +262 -0
- package/skills_ref/pptx/LICENSE.txt +30 -0
- package/skills_ref/pptx/SKILL.md +232 -0
- package/skills_ref/pptx/editing.md +205 -0
- package/skills_ref/pptx/pptxgenjs.md +420 -0
- package/skills_ref/pptx/scripts/__init__.py +0 -0
- package/skills_ref/pptx/scripts/add_slide.py +195 -0
- package/skills_ref/pptx/scripts/clean.py +286 -0
- package/skills_ref/pptx/scripts/office/helpers/__init__.py +0 -0
- package/skills_ref/pptx/scripts/office/helpers/merge_runs.py +199 -0
- package/skills_ref/pptx/scripts/office/helpers/simplify_redlines.py +197 -0
- package/skills_ref/pptx/scripts/office/pack.py +159 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
- package/skills_ref/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
- package/skills_ref/pptx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
- package/skills_ref/pptx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
- package/skills_ref/pptx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
- package/skills_ref/pptx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
- package/skills_ref/pptx/scripts/office/schemas/mce/mc.xsd +75 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
- package/skills_ref/pptx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
- package/skills_ref/pptx/scripts/office/soffice.py +183 -0
- package/skills_ref/pptx/scripts/office/unpack.py +132 -0
- package/skills_ref/pptx/scripts/office/validate.py +111 -0
- package/skills_ref/pptx/scripts/office/validators/__init__.py +15 -0
- package/skills_ref/pptx/scripts/office/validators/base.py +847 -0
- package/skills_ref/pptx/scripts/office/validators/docx.py +446 -0
- package/skills_ref/pptx/scripts/office/validators/pptx.py +275 -0
- package/skills_ref/pptx/scripts/office/validators/redlining.py +247 -0
- package/skills_ref/pptx/scripts/thumbnail.py +289 -0
- package/skills_ref/property-based-testing/.claude-plugin/plugin.json +9 -0
- package/skills_ref/property-based-testing/README.md +47 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/README.md +88 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/SKILL.md +123 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/design.md +191 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/generating.md +204 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/interpreting-failures.md +239 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/libraries.md +130 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/refactoring.md +181 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/reviewing.md +209 -0
- package/skills_ref/property-based-testing/skills/property-based-testing/references/strategies.md +124 -0
- package/skills_ref/react-best-practices/AGENTS.md +2934 -0
- package/skills_ref/react-best-practices/README.md +123 -0
- package/skills_ref/react-best-practices/SKILL.md +136 -0
- package/skills_ref/react-best-practices/metadata.json +15 -0
- package/skills_ref/react-best-practices/rules/_sections.md +46 -0
- package/skills_ref/react-best-practices/rules/_template.md +28 -0
- package/skills_ref/react-best-practices/rules/advanced-event-handler-refs.md +55 -0
- package/skills_ref/react-best-practices/rules/advanced-init-once.md +42 -0
- package/skills_ref/react-best-practices/rules/advanced-use-latest.md +39 -0
- package/skills_ref/react-best-practices/rules/async-api-routes.md +38 -0
- package/skills_ref/react-best-practices/rules/async-defer-await.md +80 -0
- package/skills_ref/react-best-practices/rules/async-dependencies.md +51 -0
- package/skills_ref/react-best-practices/rules/async-parallel.md +28 -0
- package/skills_ref/react-best-practices/rules/async-suspense-boundaries.md +99 -0
- package/skills_ref/react-best-practices/rules/bundle-barrel-imports.md +59 -0
- package/skills_ref/react-best-practices/rules/bundle-conditional.md +31 -0
- package/skills_ref/react-best-practices/rules/bundle-defer-third-party.md +49 -0
- package/skills_ref/react-best-practices/rules/bundle-dynamic-imports.md +35 -0
- package/skills_ref/react-best-practices/rules/bundle-preload.md +50 -0
- package/skills_ref/react-best-practices/rules/client-event-listeners.md +74 -0
- package/skills_ref/react-best-practices/rules/client-localstorage-schema.md +71 -0
- package/skills_ref/react-best-practices/rules/client-passive-event-listeners.md +48 -0
- package/skills_ref/react-best-practices/rules/client-swr-dedup.md +56 -0
- package/skills_ref/react-best-practices/rules/js-batch-dom-css.md +107 -0
- package/skills_ref/react-best-practices/rules/js-cache-function-results.md +80 -0
- package/skills_ref/react-best-practices/rules/js-cache-property-access.md +28 -0
- package/skills_ref/react-best-practices/rules/js-cache-storage.md +70 -0
- package/skills_ref/react-best-practices/rules/js-combine-iterations.md +32 -0
- package/skills_ref/react-best-practices/rules/js-early-exit.md +50 -0
- package/skills_ref/react-best-practices/rules/js-hoist-regexp.md +45 -0
- package/skills_ref/react-best-practices/rules/js-index-maps.md +37 -0
- package/skills_ref/react-best-practices/rules/js-length-check-first.md +49 -0
- package/skills_ref/react-best-practices/rules/js-min-max-loop.md +82 -0
- package/skills_ref/react-best-practices/rules/js-set-map-lookups.md +24 -0
- package/skills_ref/react-best-practices/rules/js-tosorted-immutable.md +57 -0
- package/skills_ref/react-best-practices/rules/rendering-activity.md +26 -0
- package/skills_ref/react-best-practices/rules/rendering-animate-svg-wrapper.md +47 -0
- package/skills_ref/react-best-practices/rules/rendering-conditional-render.md +40 -0
- package/skills_ref/react-best-practices/rules/rendering-content-visibility.md +38 -0
- package/skills_ref/react-best-practices/rules/rendering-hoist-jsx.md +46 -0
- package/skills_ref/react-best-practices/rules/rendering-hydration-no-flicker.md +82 -0
- package/skills_ref/react-best-practices/rules/rendering-hydration-suppress-warning.md +30 -0
- package/skills_ref/react-best-practices/rules/rendering-svg-precision.md +28 -0
- package/skills_ref/react-best-practices/rules/rendering-usetransition-loading.md +75 -0
- package/skills_ref/react-best-practices/rules/rerender-defer-reads.md +39 -0
- package/skills_ref/react-best-practices/rules/rerender-dependencies.md +45 -0
- package/skills_ref/react-best-practices/rules/rerender-derived-state-no-effect.md +40 -0
- package/skills_ref/react-best-practices/rules/rerender-derived-state.md +29 -0
- package/skills_ref/react-best-practices/rules/rerender-functional-setstate.md +74 -0
- package/skills_ref/react-best-practices/rules/rerender-lazy-state-init.md +58 -0
- package/skills_ref/react-best-practices/rules/rerender-memo-with-default-value.md +38 -0
- package/skills_ref/react-best-practices/rules/rerender-memo.md +44 -0
- package/skills_ref/react-best-practices/rules/rerender-move-effect-to-event.md +45 -0
- package/skills_ref/react-best-practices/rules/rerender-simple-expression-in-memo.md +35 -0
- package/skills_ref/react-best-practices/rules/rerender-transitions.md +40 -0
- package/skills_ref/react-best-practices/rules/rerender-use-ref-transient-values.md +73 -0
- package/skills_ref/react-best-practices/rules/server-after-nonblocking.md +73 -0
- package/skills_ref/react-best-practices/rules/server-auth-actions.md +96 -0
- package/skills_ref/react-best-practices/rules/server-cache-lru.md +41 -0
- package/skills_ref/react-best-practices/rules/server-cache-react.md +76 -0
- package/skills_ref/react-best-practices/rules/server-dedup-props.md +65 -0
- package/skills_ref/react-best-practices/rules/server-parallel-fetching.md +83 -0
- package/skills_ref/react-best-practices/rules/server-serialization.md +38 -0
- package/skills_ref/receiving-code-review/SKILL.md +213 -0
- package/skills_ref/registry.json +1493 -0
- package/skills_ref/render-deploy/SKILL.md +462 -0
- package/skills_ref/requesting-code-review/SKILL.md +105 -0
- package/skills_ref/requesting-code-review/code-reviewer.md +146 -0
- package/skills_ref/screen-capture/SKILL.md +162 -0
- package/skills_ref/security-best-practices/LICENSE.txt +201 -0
- package/skills_ref/security-best-practices/SKILL.md +86 -0
- package/skills_ref/security-best-practices/agents/openai.yaml +4 -0
- package/skills_ref/security-best-practices/references/golang-general-backend-security.md +826 -0
- package/skills_ref/security-best-practices/references/javascript-express-web-server-security.md +1158 -0
- package/skills_ref/security-best-practices/references/javascript-general-web-frontend-security.md +747 -0
- package/skills_ref/security-best-practices/references/javascript-jquery-web-frontend-security.md +678 -0
- package/skills_ref/security-best-practices/references/javascript-typescript-nextjs-web-server-security.md +1144 -0
- package/skills_ref/security-best-practices/references/javascript-typescript-react-web-frontend-security.md +990 -0
- package/skills_ref/security-best-practices/references/javascript-typescript-vue-web-frontend-security.md +791 -0
- package/skills_ref/security-best-practices/references/python-django-web-server-security.md +882 -0
- package/skills_ref/security-best-practices/references/python-fastapi-web-server-security.md +1036 -0
- package/skills_ref/security-best-practices/references/python-flask-web-server-security.md +705 -0
- package/skills_ref/security-ownership-map/LICENSE.txt +201 -0
- package/skills_ref/security-ownership-map/SKILL.md +206 -0
- package/skills_ref/security-ownership-map/agents/openai.yaml +4 -0
- package/skills_ref/security-ownership-map/references/neo4j-import.md +60 -0
- package/skills_ref/security-ownership-map/scripts/build_ownership_map.py +956 -0
- package/skills_ref/security-ownership-map/scripts/community_maintainers.py +544 -0
- package/skills_ref/security-ownership-map/scripts/query_ownership.py +483 -0
- package/skills_ref/security-ownership-map/scripts/run_ownership_map.py +200 -0
- package/skills_ref/security-threat-model/LICENSE.txt +201 -0
- package/skills_ref/security-threat-model/SKILL.md +81 -0
- package/skills_ref/security-threat-model/agents/openai.yaml +4 -0
- package/skills_ref/security-threat-model/references/prompt-template.md +255 -0
- package/skills_ref/security-threat-model/references/security-controls-and-assets.md +32 -0
- package/skills_ref/sentry/SKILL.md +123 -0
- package/skills_ref/skill-creator/SKILL.md +372 -0
- package/skills_ref/sora/SKILL.md +153 -0
- package/skills_ref/speech/SKILL.md +144 -0
- package/skills_ref/spotify-player/SKILL.md +64 -0
- package/skills_ref/static-analysis/.claude-plugin/plugin.json +8 -0
- package/skills_ref/static-analysis/README.md +65 -0
- package/skills_ref/static-analysis/agents/semgrep-scanner.md +71 -0
- package/skills_ref/static-analysis/agents/semgrep-triager.md +107 -0
- package/skills_ref/static-analysis/skills/codeql/SKILL.md +119 -0
- package/skills_ref/static-analysis/skills/codeql/references/diagnostic-query-templates.md +339 -0
- package/skills_ref/static-analysis/skills/codeql/references/language-details.md +207 -0
- package/skills_ref/static-analysis/skills/codeql/references/performance-tuning.md +111 -0
- package/skills_ref/static-analysis/skills/codeql/references/ruleset-catalog.md +63 -0
- package/skills_ref/static-analysis/skills/codeql/references/threat-models.md +44 -0
- package/skills_ref/static-analysis/skills/codeql/workflows/build-database.md +669 -0
- package/skills_ref/static-analysis/skills/codeql/workflows/create-data-extensions.md +536 -0
- package/skills_ref/static-analysis/skills/codeql/workflows/run-analysis.md +436 -0
- package/skills_ref/static-analysis/skills/sarif-parsing/SKILL.md +479 -0
- package/skills_ref/static-analysis/skills/sarif-parsing/resources/jq-queries.md +162 -0
- package/skills_ref/static-analysis/skills/sarif-parsing/resources/sarif_helpers.py +331 -0
- package/skills_ref/static-analysis/skills/semgrep/SKILL.md +431 -0
- package/skills_ref/static-analysis/skills/semgrep/references/rulesets.md +162 -0
- package/skills_ref/static-analysis/skills/semgrep/references/scanner-task-prompt.md +102 -0
- package/skills_ref/static-analysis/skills/semgrep/references/triage-task-prompt.md +122 -0
- package/skills_ref/static-analysis/skills/semgrep/scripts/merge_triaged_sarif.py +252 -0
- package/skills_ref/summarize/SKILL.md +87 -0
- package/skills_ref/tdd/SKILL.md +371 -0
- package/skills_ref/tdd/testing-anti-patterns.md +299 -0
- package/skills_ref/telegram-send/SKILL.md +99 -0
- package/skills_ref/terraform/README.md +105 -0
- package/skills_ref/terraform/code-generation/.claude-plugin/plugin.json +30 -0
- package/skills_ref/terraform/code-generation/skills/azure-verified-modules/SKILL.md +613 -0
- package/skills_ref/terraform/code-generation/skills/terraform-style-guide/SKILL.md +353 -0
- package/skills_ref/terraform/code-generation/skills/terraform-test/SKILL.md +1669 -0
- package/skills_ref/terraform/module-generation/.claude-plugin/plugin.json +30 -0
- package/skills_ref/terraform/module-generation/skills/refactor-module/SKILL.md +538 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/SKILL.md +468 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/references/api-monitoring.md +543 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/references/component-blocks.md +476 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/references/deployment-blocks.md +391 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/references/examples.md +1529 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/references/linked-stacks.md +187 -0
- package/skills_ref/terraform/module-generation/skills/terraform-stacks/references/troubleshooting.md +671 -0
- package/skills_ref/terraform/provider-development/.claude-plugin/plugin.json +13 -0
- package/skills_ref/terraform/provider-development/skills/new-terraform-provider/SKILL.md +25 -0
- package/skills_ref/terraform/provider-development/skills/new-terraform-provider/assets/main.go +40 -0
- package/skills_ref/terraform/provider-development/skills/provider-actions/SKILL.md +478 -0
- package/skills_ref/terraform/provider-development/skills/provider-resources/SKILL.md +599 -0
- package/skills_ref/terraform/provider-development/skills/run-acceptance-tests/SKILL.md +41 -0
- package/skills_ref/theme-factory/LICENSE.txt +202 -0
- package/skills_ref/theme-factory/SKILL.md +59 -0
- package/skills_ref/theme-factory/theme-showcase.pdf +0 -0
- package/skills_ref/theme-factory/themes/arctic-frost.md +19 -0
- package/skills_ref/theme-factory/themes/botanical-garden.md +19 -0
- package/skills_ref/theme-factory/themes/desert-rose.md +19 -0
- package/skills_ref/theme-factory/themes/forest-canopy.md +19 -0
- package/skills_ref/theme-factory/themes/golden-hour.md +19 -0
- package/skills_ref/theme-factory/themes/midnight-galaxy.md +19 -0
- package/skills_ref/theme-factory/themes/modern-minimalist.md +19 -0
- package/skills_ref/theme-factory/themes/ocean-depths.md +19 -0
- package/skills_ref/theme-factory/themes/sunset-boulevard.md +19 -0
- package/skills_ref/theme-factory/themes/tech-innovation.md +19 -0
- package/skills_ref/things-mac/SKILL.md +86 -0
- package/skills_ref/tmux/SKILL.md +153 -0
- package/skills_ref/transcribe/SKILL.md +81 -0
- package/skills_ref/trello/SKILL.md +95 -0
- package/skills_ref/tts/SKILL.md +99 -0
- package/skills_ref/vercel-deploy/SKILL.md +115 -0
- package/skills_ref/video-downloader/SKILL.md +99 -0
- package/skills_ref/video-downloader/scripts/download_video.py +145 -0
- package/skills_ref/video-frames/SKILL.md +46 -0
- package/skills_ref/vision-click/SKILL.md +128 -0
- package/skills_ref/weather/SKILL.md +112 -0
- package/skills_ref/web-artifacts-builder/LICENSE.txt +202 -0
- package/skills_ref/web-artifacts-builder/SKILL.md +74 -0
- package/skills_ref/web-artifacts-builder/scripts/bundle-artifact.sh +54 -0
- package/skills_ref/web-artifacts-builder/scripts/init-artifact.sh +322 -0
- package/skills_ref/web-artifacts-builder/scripts/shadcn-components.tar.gz +0 -0
- package/skills_ref/web-perf/SKILL.md +193 -0
- package/skills_ref/web-routing/SKILL.md +26 -0
- package/skills_ref/whatsapp/SKILL.md +255 -0
- package/skills_ref/whatsapp/assets/agent-app-integration-example.json +35 -0
- package/skills_ref/whatsapp/assets/databases-example.json +11 -0
- package/skills_ref/whatsapp/assets/function-decide-route-interactive-buttons.json +6 -0
- package/skills_ref/whatsapp/assets/functions-example.json +5 -0
- package/skills_ref/whatsapp/assets/workflow-agent-simple.json +31 -0
- package/skills_ref/whatsapp/assets/workflow-api-template-wait-agent.json +59 -0
- package/skills_ref/whatsapp/assets/workflow-customer-support-intake-agent.json +56 -0
- package/skills_ref/whatsapp/assets/workflow-decision.json +83 -0
- package/skills_ref/whatsapp/assets/workflow-interactive-buttons-decide-ai.json +89 -0
- package/skills_ref/whatsapp/assets/workflow-interactive-buttons-decide-function.json +88 -0
- package/skills_ref/whatsapp/assets/workflow-linear.json +53 -0
- package/skills_ref/whatsapp/package.json +10 -0
- package/skills_ref/whatsapp/references/app-integrations.md +89 -0
- package/skills_ref/whatsapp/references/databases-reference.md +21 -0
- package/skills_ref/whatsapp/references/execution-context.md +42 -0
- package/skills_ref/whatsapp/references/function-contracts.md +55 -0
- package/skills_ref/whatsapp/references/functions-payloads.md +87 -0
- package/skills_ref/whatsapp/references/functions-reference.md +133 -0
- package/skills_ref/whatsapp/references/graph-contract.md +145 -0
- package/skills_ref/whatsapp/references/node-types.md +430 -0
- package/skills_ref/whatsapp/references/triggers.md +20 -0
- package/skills_ref/whatsapp/references/workflow-overview.md +22 -0
- package/skills_ref/whatsapp/references/workflow-reference.md +123 -0
- package/skills_ref/whatsapp/scripts/configure-prop.js +113 -0
- package/skills_ref/whatsapp/scripts/create-connect-token.js +38 -0
- package/skills_ref/whatsapp/scripts/create-function.js +64 -0
- package/skills_ref/whatsapp/scripts/create-integration.js +137 -0
- package/skills_ref/whatsapp/scripts/create-row.js +47 -0
- package/skills_ref/whatsapp/scripts/create-trigger.js +88 -0
- package/skills_ref/whatsapp/scripts/create-workflow.js +85 -0
- package/skills_ref/whatsapp/scripts/delete-integration.js +44 -0
- package/skills_ref/whatsapp/scripts/delete-row.js +49 -0
- package/skills_ref/whatsapp/scripts/delete-trigger.js +44 -0
- package/skills_ref/whatsapp/scripts/deploy-function.js +47 -0
- package/skills_ref/whatsapp/scripts/edit-graph.js +289 -0
- package/skills_ref/whatsapp/scripts/get-action-schema.js +44 -0
- package/skills_ref/whatsapp/scripts/get-context-value.js +80 -0
- package/skills_ref/whatsapp/scripts/get-execution-event.js +55 -0
- package/skills_ref/whatsapp/scripts/get-execution.js +44 -0
- package/skills_ref/whatsapp/scripts/get-function.js +43 -0
- package/skills_ref/whatsapp/scripts/get-graph.js +85 -0
- package/skills_ref/whatsapp/scripts/get-table.js +45 -0
- package/skills_ref/whatsapp/scripts/get-workflow.js +44 -0
- package/skills_ref/whatsapp/scripts/invoke-function.js +60 -0
- package/skills_ref/whatsapp/scripts/lib/databases/args.js +87 -0
- package/skills_ref/whatsapp/scripts/lib/databases/filters.js +30 -0
- package/skills_ref/whatsapp/scripts/lib/databases/kapso-api.js +70 -0
- package/skills_ref/whatsapp/scripts/lib/functions/args.js +55 -0
- package/skills_ref/whatsapp/scripts/lib/functions/kapso-api.js +70 -0
- package/skills_ref/whatsapp/scripts/lib/workflows/args.js +53 -0
- package/skills_ref/whatsapp/scripts/lib/workflows/kapso-api.js +123 -0
- package/skills_ref/whatsapp/scripts/lib/workflows/result.js +16 -0
- package/skills_ref/whatsapp/scripts/list-accounts.js +62 -0
- package/skills_ref/whatsapp/scripts/list-apps.js +42 -0
- package/skills_ref/whatsapp/scripts/list-execution-events.js +61 -0
- package/skills_ref/whatsapp/scripts/list-executions.js +53 -0
- package/skills_ref/whatsapp/scripts/list-function-invocations.js +53 -0
- package/skills_ref/whatsapp/scripts/list-functions.js +41 -0
- package/skills_ref/whatsapp/scripts/list-integrations.js +41 -0
- package/skills_ref/whatsapp/scripts/list-provider-models.js +48 -0
- package/skills_ref/whatsapp/scripts/list-tables.js +41 -0
- package/skills_ref/whatsapp/scripts/list-triggers.js +44 -0
- package/skills_ref/whatsapp/scripts/list-whatsapp-phone-numbers.js +56 -0
- package/skills_ref/whatsapp/scripts/list-workflows.js +44 -0
- package/skills_ref/whatsapp/scripts/openapi-explore.mjs +1273 -0
- package/skills_ref/whatsapp/scripts/query-rows.js +71 -0
- package/skills_ref/whatsapp/scripts/reload-props.js +110 -0
- package/skills_ref/whatsapp/scripts/resume-execution.js +75 -0
- package/skills_ref/whatsapp/scripts/search-actions.js +64 -0
- package/skills_ref/whatsapp/scripts/update-execution-status.js +51 -0
- package/skills_ref/whatsapp/scripts/update-function.js +65 -0
- package/skills_ref/whatsapp/scripts/update-graph.js +154 -0
- package/skills_ref/whatsapp/scripts/update-integration.js +82 -0
- package/skills_ref/whatsapp/scripts/update-row.js +51 -0
- package/skills_ref/whatsapp/scripts/update-trigger.js +60 -0
- package/skills_ref/whatsapp/scripts/update-workflow-settings.js +67 -0
- package/skills_ref/whatsapp/scripts/upsert-row.js +64 -0
- package/skills_ref/whatsapp/scripts/validate-graph.js +293 -0
- package/skills_ref/whatsapp/scripts/variables-delete.js +37 -0
- package/skills_ref/whatsapp/scripts/variables-list.js +55 -0
- package/skills_ref/whatsapp/scripts/variables-set.js +39 -0
- package/skills_ref/writing-plans/SKILL.md +116 -0
- package/skills_ref/xlsx/LICENSE.txt +30 -0
- package/skills_ref/xlsx/SKILL.md +292 -0
- package/skills_ref/xlsx/scripts/office/helpers/__init__.py +0 -0
- package/skills_ref/xlsx/scripts/office/helpers/merge_runs.py +199 -0
- package/skills_ref/xlsx/scripts/office/helpers/simplify_redlines.py +197 -0
- package/skills_ref/xlsx/scripts/office/pack.py +159 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
- package/skills_ref/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
- package/skills_ref/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
- package/skills_ref/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
- package/skills_ref/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
- package/skills_ref/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
- package/skills_ref/xlsx/scripts/office/schemas/mce/mc.xsd +75 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
- package/skills_ref/xlsx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
- package/skills_ref/xlsx/scripts/office/soffice.py +183 -0
- package/skills_ref/xlsx/scripts/office/unpack.py +132 -0
- package/skills_ref/xlsx/scripts/office/validate.py +111 -0
- package/skills_ref/xlsx/scripts/office/validators/__init__.py +15 -0
- package/skills_ref/xlsx/scripts/office/validators/base.py +847 -0
- package/skills_ref/xlsx/scripts/office/validators/docx.py +446 -0
- package/skills_ref/xlsx/scripts/office/validators/pptx.py +275 -0
- package/skills_ref/xlsx/scripts/office/validators/redlining.py +247 -0
- package/skills_ref/xlsx/scripts/recalc.py +184 -0
- package/skills_ref/xurl/SKILL.md +461 -0
|
@@ -0,0 +1,826 @@
|
|
|
1
|
+
# Go (Golang) Security Spec (Go 1.25.x, Standard Library, net/http)
|
|
2
|
+
|
|
3
|
+
This document is designed as a **security spec** that supports:
|
|
4
|
+
1) **Secure-by-default code generation** for new Go code.
|
|
5
|
+
2) **Security review / vulnerability hunting** in existing Go code (passive “notice issues while working” and active “scan the repo and report findings”).
|
|
6
|
+
|
|
7
|
+
It is intentionally written as a set of **normative requirements** (“MUST/SHOULD/MAY”) plus **audit rules** (what bad patterns look like, how to detect them, and how to fix/mitigate them).
|
|
8
|
+
|
|
9
|
+
--------------------------------------------------------------------
|
|
10
|
+
|
|
11
|
+
## 0) Safety, boundaries, and anti-abuse constraints (MUST FOLLOW)
|
|
12
|
+
|
|
13
|
+
- MUST NOT request, output, log, or commit secrets (API keys, passwords, private keys, session cookies, JWTs, database URLs with credentials, signing keys, client secrets).
|
|
14
|
+
- MUST NOT “fix” security by disabling protections (e.g., `InsecureSkipVerify`, `GOSUMDB=off` for public modules, wildcard CORS + credentials, removing auth checks, disabling CSRF defenses on cookie-auth apps).
|
|
15
|
+
- MUST provide **evidence-based findings** during audits: cite file paths, code snippets, build/deploy configs, and concrete values that justify the claim.
|
|
16
|
+
- MUST treat uncertainty honestly: if a control might exist in infrastructure (reverse proxy, WAF, service mesh, platform config), report it as “not visible in app code; verify at runtime/config.”
|
|
17
|
+
- MUST keep fixes minimal, correct, and production-safe; avoid introducing breaking changes without warning (especially around auth/session flows, and proxies).
|
|
18
|
+
|
|
19
|
+
--------------------------------------------------------------------
|
|
20
|
+
|
|
21
|
+
## 1) Operating modes
|
|
22
|
+
|
|
23
|
+
### 1.1 Generation mode (default)
|
|
24
|
+
When asked to write new Go code or modify existing code:
|
|
25
|
+
- MUST follow every **MUST** requirement in this spec.
|
|
26
|
+
- SHOULD follow every **SHOULD** requirement unless the user explicitly says otherwise.
|
|
27
|
+
- MUST prefer safe-by-default APIs and proven libraries over custom security code.
|
|
28
|
+
- MUST avoid introducing new risky sinks (shell execution, dynamic template execution, serving user files as HTML, unsafe redirects, weak crypto, unbounded parsing, etc.).
|
|
29
|
+
|
|
30
|
+
### 1.2 Passive review mode (always on while editing)
|
|
31
|
+
While working anywhere in a Go repo (even if the user did not ask for a security scan):
|
|
32
|
+
- MUST “notice” violations of this spec in touched/nearby code.
|
|
33
|
+
- SHOULD mention issues as they come up, with a brief explanation + safe fix.
|
|
34
|
+
|
|
35
|
+
### 1.3 Active audit mode (explicit scan request)
|
|
36
|
+
When the user asks to “scan”, “audit”, or “hunt for vulns”:
|
|
37
|
+
- MUST systematically search the codebase for violations of this spec.
|
|
38
|
+
- MUST output findings in a structured format (see §2.3).
|
|
39
|
+
|
|
40
|
+
Recommended audit order:
|
|
41
|
+
1) Build/deploy entrypoints: `main.go`, `cmd/*`, Dockerfiles, Kubernetes manifests, systemd units, CI workflows.
|
|
42
|
+
2) Go toolchain & dependency policy: Go version, modules, `go.mod/go.sum`, proxy/sumdb settings, govulncheck usage.
|
|
43
|
+
3) Secret management and config loading (env, files, secret stores) + logging patterns.
|
|
44
|
+
4) HTTP server configuration (timeouts, body limits, proxy trust, security headers).
|
|
45
|
+
5) AuthN/AuthZ boundaries, session/cookie settings, token validation.
|
|
46
|
+
6) CSRF protections for cookie-authenticated state-changing endpoints.
|
|
47
|
+
7) Template usage and output encoding (XSS), and any “render template from string” behavior (SSTI).
|
|
48
|
+
8) File handling (uploads/downloads/path traversal/temp files), static file serving.
|
|
49
|
+
9) Injection sinks: SQL, OS command execution, SSRF/outbound fetch, open redirects.
|
|
50
|
+
10) Concurrency/resource exhaustion (unbounded goroutines/queues, missing timeouts/contexts).
|
|
51
|
+
11) Use of `unsafe` / `cgo` / `reflect` in security-sensitive paths.
|
|
52
|
+
12) Debug/diagnostic endpoints (pprof/expvar/metrics) exposure.
|
|
53
|
+
13) Cryptography usage (randomness, password hashing).
|
|
54
|
+
|
|
55
|
+
--------------------------------------------------------------------
|
|
56
|
+
|
|
57
|
+
## 2) Definitions and review guidance
|
|
58
|
+
|
|
59
|
+
### 2.1 Untrusted input (treat as attacker-controlled unless proven otherwise)
|
|
60
|
+
Examples include:
|
|
61
|
+
- `*http.Request` fields: `r.URL.Path`, `r.URL.RawQuery`, `r.Form`, `r.PostForm`, headers, cookies, `r.Body`
|
|
62
|
+
- Path parameters from routers (including values extracted from URL paths)
|
|
63
|
+
- JSON/XML/YAML bodies, multipart form parts, uploaded files
|
|
64
|
+
- Any data from external systems (webhooks, third-party APIs, message queues)
|
|
65
|
+
- Any persisted user content (DB rows) that originated from users
|
|
66
|
+
- Configuration values that might be attacker-influenced in some deployments (headers set by upstream proxies, environment variables in multi-tenant systems)
|
|
67
|
+
|
|
68
|
+
### 2.2 State-changing request
|
|
69
|
+
A request is state-changing if it can create/update/delete data, change auth/session state, trigger side effects (purchase, email send, webhook send), or initiate privileged actions.
|
|
70
|
+
|
|
71
|
+
### 2.3 Required audit finding format
|
|
72
|
+
For each issue found, output:
|
|
73
|
+
|
|
74
|
+
- Rule ID:
|
|
75
|
+
- Severity: Critical / High / Medium / Low
|
|
76
|
+
- Location: file path + function/handler name + line(s)
|
|
77
|
+
- Evidence: the exact code/config snippet
|
|
78
|
+
- Impact: what could go wrong, who can exploit it
|
|
79
|
+
- Fix: safe change (prefer minimal diff)
|
|
80
|
+
- Mitigation: defense-in-depth if immediate fix is hard
|
|
81
|
+
- False positive notes: what to verify if uncertain (edge configs, proxy behavior, auth assumptions)
|
|
82
|
+
|
|
83
|
+
--------------------------------------------------------------------
|
|
84
|
+
|
|
85
|
+
## 3) Secure baseline: minimum production configuration (MUST in production)
|
|
86
|
+
|
|
87
|
+
This is the smallest “production baseline” that prevents common Go misconfigurations.
|
|
88
|
+
|
|
89
|
+
### 3.1 Toolchain, patching, and dependency hygiene (MUST)
|
|
90
|
+
- MUST run a supported Go major version and keep to the latest patch releases.
|
|
91
|
+
- MUST treat Go standard library patch releases as security-relevant (many security fixes land in stdlib components like `net/http`, `crypto/*`, parsing packages).
|
|
92
|
+
- MUST use Go modules with committed `go.mod` and `go.sum`.
|
|
93
|
+
- MUST NOT disable module authenticity mechanisms for public modules (checksum DB) unless you have a controlled, documented replacement.
|
|
94
|
+
- MUST run `govulncheck` (source scan and/or binary scan) in CI and address findings.
|
|
95
|
+
|
|
96
|
+
### 3.2 HTTP server baseline (MUST for network-facing services)
|
|
97
|
+
If the program serves HTTP (directly or via a framework built on `net/http`):
|
|
98
|
+
- MUST configure an `http.Server` with explicit timeouts and header limits.
|
|
99
|
+
- MUST set request body size limits (global and per-route as needed).
|
|
100
|
+
- MUST avoid exposing diagnostic endpoints (pprof/expvar) publicly.
|
|
101
|
+
- SHOULD set a consistent set of security headers (or verify they are set at the edge).
|
|
102
|
+
- MUST set cookie security attributes for any cookies you issue.
|
|
103
|
+
- SHOULD implement rate limiting and abuse controls for auth and expensive endpoints.
|
|
104
|
+
|
|
105
|
+
Illustrative baseline skeleton (adjust to your project):
|
|
106
|
+
- Create a dedicated mux (avoid implicit global defaults unless intentionally managed).
|
|
107
|
+
- Wrap handlers with: panic-safe error handling, request ID, logging, auth, and limits.
|
|
108
|
+
|
|
109
|
+
--------------------------------------------------------------------
|
|
110
|
+
|
|
111
|
+
## 4) Rules (generation + audit)
|
|
112
|
+
|
|
113
|
+
Each rule contains: required practice, insecure patterns, detection hints, and remediation.
|
|
114
|
+
|
|
115
|
+
### GO-DEPLOY-001: Keep the Go toolchain and standard library updated (security releases)
|
|
116
|
+
Severity: Medium
|
|
117
|
+
|
|
118
|
+
NOTE: Upgrading dependencies and the core Go version can break projects in unexpected ways. Focus on only security-critical dependencies and if noticed, let the user know rather than upgrading automatically.
|
|
119
|
+
|
|
120
|
+
Required:
|
|
121
|
+
- MUST run a supported Go major release and apply patch releases promptly.
|
|
122
|
+
- SHOULD treat patch releases as security-relevant, even if your application code didn’t change.
|
|
123
|
+
|
|
124
|
+
Insecure patterns:
|
|
125
|
+
- Production builds pinned to old Go versions without a patching process.
|
|
126
|
+
- Docker images like `golang:1.xx` or custom base images that are not updated regularly.
|
|
127
|
+
- CI pipelines that intentionally suppress Go updates.
|
|
128
|
+
|
|
129
|
+
Detection hints:
|
|
130
|
+
- Inspect CI (`.github/workflows`, `gitlab-ci.yml`, etc.) for `go-version:` or toolchain setup.
|
|
131
|
+
- Inspect Dockerfiles for `FROM golang:` tags.
|
|
132
|
+
- Inspect `go.mod` `go` directive and any toolchain pinning.
|
|
133
|
+
|
|
134
|
+
Fix:
|
|
135
|
+
- Upgrade to the latest patch of a supported Go version.
|
|
136
|
+
- Add an automated check (CI) that fails when Go is below an approved minimum.
|
|
137
|
+
|
|
138
|
+
Notes:
|
|
139
|
+
- Go publishes regular minor releases that frequently include security fixes across standard library packages.
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
### GO-SUPPLY-001: Go module authenticity MUST NOT be disabled for public dependencies
|
|
144
|
+
Severity: High
|
|
145
|
+
|
|
146
|
+
Required:
|
|
147
|
+
- MUST keep module checksum verification enabled for public modules.
|
|
148
|
+
- SHOULD commit `go.sum` and treat changes as security-sensitive.
|
|
149
|
+
- MUST NOT use insecure module fetching settings for public modules.
|
|
150
|
+
- MAY configure private module behavior using `GOPRIVATE`/`GONOSUMDB` for private repos, but must do so narrowly and intentionally.
|
|
151
|
+
|
|
152
|
+
Insecure patterns:
|
|
153
|
+
- `GOSUMDB=off` in CI or production build environments for public modules.
|
|
154
|
+
- `GONOSUMDB=*` or overly broad patterns that effectively disable verification.
|
|
155
|
+
- `GOINSECURE=*` or broad `GOINSECURE` patterns for public modules.
|
|
156
|
+
- `GOPROXY=direct` everywhere without a clear policy.
|
|
157
|
+
|
|
158
|
+
Detection hints:
|
|
159
|
+
- Search build configs for `GOSUMDB`, `GONOSUMDB`, `GOINSECURE`, `GOPROXY`, `GOPRIVATE`.
|
|
160
|
+
- Look for documentation/scripts that recommend disabling checksum DB “to make builds work”.
|
|
161
|
+
|
|
162
|
+
Fix:
|
|
163
|
+
- Restore defaults for public module verification.
|
|
164
|
+
- For private modules:
|
|
165
|
+
- Set `GOPRIVATE=your.private.domain/*`
|
|
166
|
+
- Configure an internal proxy or direct fetching, and restrict `GONOSUMDB` to private patterns only.
|
|
167
|
+
|
|
168
|
+
Notes:
|
|
169
|
+
- Disabling checksum verification removes an important integrity layer against targeted or compromised upstream delivery.
|
|
170
|
+
|
|
171
|
+
---
|
|
172
|
+
|
|
173
|
+
### GO-CONFIG-001: Secrets must be externalized and never logged or committed
|
|
174
|
+
Severity: High (Critical if credentials are committed)
|
|
175
|
+
|
|
176
|
+
Required:
|
|
177
|
+
- MUST load secrets from environment variables, secret managers, or secure config files with restricted permissions.
|
|
178
|
+
- MUST NOT hard-code secrets in Go source, test fixtures that may reach production, or build args.
|
|
179
|
+
- MUST NOT log secrets or full credential-bearing connection strings.
|
|
180
|
+
- SHOULD fail closed in production if required secrets are missing.
|
|
181
|
+
|
|
182
|
+
Insecure patterns:
|
|
183
|
+
- String constants containing tokens/keys/passwords.
|
|
184
|
+
- `.env` files or config files with secrets committed to repo.
|
|
185
|
+
- Logging `os.Environ()`, dumping full configs, or printing DSNs.
|
|
186
|
+
|
|
187
|
+
Detection hints:
|
|
188
|
+
- Search for suspicious literals (`API_KEY`, `SECRET`, `PASSWORD`, `Authorization:`).
|
|
189
|
+
- Inspect config loaders and logging statements.
|
|
190
|
+
- Inspect CI logs or debug print paths.
|
|
191
|
+
|
|
192
|
+
Fix:
|
|
193
|
+
- Move secrets to a secret store / environment variables.
|
|
194
|
+
- Redact sensitive fields in logs.
|
|
195
|
+
- Add secret scanning to CI and pre-commit.
|
|
196
|
+
|
|
197
|
+
---
|
|
198
|
+
|
|
199
|
+
### GO-HTTP-001: HTTP servers MUST set timeouts and MaxHeaderBytes
|
|
200
|
+
Severity: High (DoS risk)
|
|
201
|
+
|
|
202
|
+
Required:
|
|
203
|
+
- MUST set: `ReadHeaderTimeout`, and SHOULD set `ReadTimeout`, `WriteTimeout`, `IdleTimeout` as appropriate for the service.
|
|
204
|
+
- MUST set `MaxHeaderBytes` to a justified limit for your application.
|
|
205
|
+
- MUST NOT rely on default zero-values for timeouts in production for internet-facing servers.
|
|
206
|
+
|
|
207
|
+
Insecure patterns:
|
|
208
|
+
- `http.ListenAndServe(":8080", handler)` with a default `http.Server` (no explicit timeouts).
|
|
209
|
+
- `&http.Server{}` with timeouts left at zero.
|
|
210
|
+
- Missing `MaxHeaderBytes`.
|
|
211
|
+
|
|
212
|
+
Detection hints:
|
|
213
|
+
- Search for `http.ListenAndServe(`, `ListenAndServeTLS(`, `Server{` and inspect configured fields.
|
|
214
|
+
- Check for reverse proxies; even with a proxy, app-level timeouts still matter.
|
|
215
|
+
|
|
216
|
+
Fix:
|
|
217
|
+
- Use `http.Server{ReadHeaderTimeout: ..., ReadTimeout: ..., WriteTimeout: ..., IdleTimeout: ..., MaxHeaderBytes: ...}`.
|
|
218
|
+
- Calibrate timeouts per endpoint type (streaming vs JSON APIs).
|
|
219
|
+
|
|
220
|
+
Notes:
|
|
221
|
+
- Net/http documents that these timeouts exist and that zero/negative values mean “no timeout”; production services should choose explicit values.
|
|
222
|
+
|
|
223
|
+
---
|
|
224
|
+
|
|
225
|
+
### GO-HTTP-002: Request body and multipart parsing MUST be size-bounded
|
|
226
|
+
Severity: Medium (DoS risk; can be High for upload-heavy apps)
|
|
227
|
+
|
|
228
|
+
Required:
|
|
229
|
+
- MUST enforce a global maximum request body size for endpoints that accept bodies.
|
|
230
|
+
- MUST enforce strict multipart upload limits and avoid unbounded form parsing.
|
|
231
|
+
- SHOULD enforce per-route limits when some endpoints legitimately need larger bodies.
|
|
232
|
+
- SHOULD set upstream (proxy) limits as defense-in-depth.
|
|
233
|
+
|
|
234
|
+
Insecure patterns:
|
|
235
|
+
- Reading `r.Body` with `io.ReadAll(r.Body)` without a size cap.
|
|
236
|
+
- Calling `r.ParseMultipartForm(...)` with overly large limits (or forgetting size controls).
|
|
237
|
+
- Accepting file uploads with no limits on file size, number of parts, or total body size.
|
|
238
|
+
|
|
239
|
+
Detection hints:
|
|
240
|
+
- Search for `io.ReadAll(r.Body)`, `json.NewDecoder(r.Body)`, `ParseMultipartForm`, `FormFile`, `multipart`.
|
|
241
|
+
- Look for missing `http.MaxBytesReader` or equivalent per-handler limiting.
|
|
242
|
+
- Look for “upload” endpoints and check limits.
|
|
243
|
+
|
|
244
|
+
Fix:
|
|
245
|
+
- Wrap request bodies with `http.MaxBytesReader(w, r.Body, maxBytes)` before parsing.
|
|
246
|
+
- For multipart, set conservative limits and validate file sizes/part counts explicitly.
|
|
247
|
+
- Set proxy limits (e.g., at ingress) in addition to app limits.
|
|
248
|
+
|
|
249
|
+
Notes:
|
|
250
|
+
- There are known vulnerability classes and advisories related to excessive resource consumption in multipart/form parsing; treat unbounded parsing as a security issue.
|
|
251
|
+
|
|
252
|
+
---
|
|
253
|
+
|
|
254
|
+
### GO-DEPLOY-002: Diagnostic endpoints (pprof/expvar/metrics) MUST NOT be publicly exposed
|
|
255
|
+
Severity: High
|
|
256
|
+
|
|
257
|
+
NOTE: This only applies to production configurations. These endpoints are often used for debug or dev endpoints. If found, confirm that it would be reachable from the actual production deployment.
|
|
258
|
+
|
|
259
|
+
Required:
|
|
260
|
+
- MUST NOT expose `net/http/pprof` handlers on a public internet-facing listener without strong access controls.
|
|
261
|
+
- SHOULD run diagnostics on a separate, internal-only listener (loopback/VPC-only) and require auth.
|
|
262
|
+
- MUST review what diagnostic endpoints reveal (stack traces, memory, command lines, environment, internal URLs).
|
|
263
|
+
|
|
264
|
+
Insecure patterns:
|
|
265
|
+
- Side-effect import `import _ "net/http/pprof"` in a server binary with a public mux.
|
|
266
|
+
- `/debug/pprof/*` reachable without auth.
|
|
267
|
+
- `/debug/vars` (expvar) reachable without auth.
|
|
268
|
+
|
|
269
|
+
Detection hints:
|
|
270
|
+
- Search for `net/http/pprof` imports (including blank imports).
|
|
271
|
+
- Search for route prefixes `/debug/pprof`, `/debug/vars`.
|
|
272
|
+
- Check whether `http.DefaultServeMux` is used and whether any debug handlers register globally.
|
|
273
|
+
|
|
274
|
+
Fix:
|
|
275
|
+
- Remove diagnostics from production builds, or bind them to an internal-only listener.
|
|
276
|
+
- Add strong authentication/authorization (and ideally network-level restrictions).
|
|
277
|
+
|
|
278
|
+
Notes:
|
|
279
|
+
- pprof is typically imported for its side effect of registering HTTP handlers under `/debug/pprof/`.
|
|
280
|
+
|
|
281
|
+
---
|
|
282
|
+
|
|
283
|
+
### GO-HTTP-003: Reverse proxy and forwarded header trust MUST be explicit
|
|
284
|
+
Severity: High (auth, URL generation, logging/auditing correctness)
|
|
285
|
+
|
|
286
|
+
Required:
|
|
287
|
+
- If behind a reverse proxy, MUST define which proxy is trusted and how client IP/scheme/host are derived.
|
|
288
|
+
- MUST NOT trust `X-Forwarded-For`, `X-Forwarded-Proto`, `Forwarded`, or similar headers from the open internet.
|
|
289
|
+
- MUST ensure “secure cookie” logic, redirects, and absolute URL generation do not rely on spoofable headers.
|
|
290
|
+
|
|
291
|
+
Insecure patterns:
|
|
292
|
+
- Using `r.Header.Get("X-Forwarded-For")` as the client IP without validating the proxy boundary.
|
|
293
|
+
- Deriving “is HTTPS” from `X-Forwarded-Proto` without confirming it came from a trusted proxy.
|
|
294
|
+
- Using forwarded `Host` values for password reset links without allowlisting.
|
|
295
|
+
|
|
296
|
+
Detection hints:
|
|
297
|
+
- Search for `X-Forwarded-For`, `X-Forwarded-Proto`, `Forwarded`, `Real-IP`, and any custom “client IP” helpers.
|
|
298
|
+
- Inspect ingress/proxy configs; if not visible, mark as “verify at edge”.
|
|
299
|
+
|
|
300
|
+
Fix:
|
|
301
|
+
- Enforce proxy trust at the edge and in app:
|
|
302
|
+
- Accept forwarded headers only from known proxy IP ranges.
|
|
303
|
+
- Prefer platform-provided mechanisms where available.
|
|
304
|
+
- If generating external links, use a configured allowlisted canonical origin (not the request’s Host header).
|
|
305
|
+
|
|
306
|
+
---
|
|
307
|
+
|
|
308
|
+
### GO-HTTP-004: Security headers SHOULD be set (in app or at the edge)
|
|
309
|
+
Severity: Medium
|
|
310
|
+
|
|
311
|
+
Required (typical web app serving browsers):
|
|
312
|
+
- SHOULD set:
|
|
313
|
+
- `Content-Security-Policy` (CSP) appropriate to the app. NOTE: It is most important to set the CSP's script-src. All other directives are not as important and can generally be excluded for the ease of development.
|
|
314
|
+
- `X-Content-Type-Options: nosniff`
|
|
315
|
+
- Clickjacking protection (`X-Frame-Options` and/or CSP `frame-ancestors`)
|
|
316
|
+
- `Referrer-Policy` and `Permissions-Policy` where appropriate
|
|
317
|
+
- MUST ensure cookies have secure attributes (see GO-HTTP-005).
|
|
318
|
+
|
|
319
|
+
NOTE:
|
|
320
|
+
- These headers may be set via reverse proxy/CDN; if not visible in app code, report as “verify at edge”.
|
|
321
|
+
|
|
322
|
+
Insecure patterns:
|
|
323
|
+
- No security headers anywhere (app or edge) for a browser-facing app.
|
|
324
|
+
- CSP missing for apps rendering untrusted content.
|
|
325
|
+
|
|
326
|
+
Detection hints:
|
|
327
|
+
- Search for middleware setting headers: `w.Header().Set("Content-Security-Policy", ...)`, etc.
|
|
328
|
+
- Search for reverse proxy config that sets headers.
|
|
329
|
+
|
|
330
|
+
Fix:
|
|
331
|
+
- Add centralized header middleware in Go, or configure at the edge.
|
|
332
|
+
- Keep CSP realistic; avoid `unsafe-inline` where possible.
|
|
333
|
+
|
|
334
|
+
---
|
|
335
|
+
|
|
336
|
+
### GO-HTTP-005: Cookies MUST use secure attributes in production
|
|
337
|
+
Severity: Medium
|
|
338
|
+
|
|
339
|
+
Required (production, HTTPS):
|
|
340
|
+
- MUST set `Secure` on cookies that carry auth/session state. IMPORTANT NOTE: Only set `Secure` in production environment when TLS is configured. When running in a local dev environment over HTTP, do not set `Secure` property on cookies. You should do this conditionally based on if the app is running in production mode. You should also include a property like `SESSION_COOKIE_SECURE` which can be used to disable `Secure` cookies when testing over HTTP.
|
|
341
|
+
- MUST set `HttpOnly` on auth/session cookies.
|
|
342
|
+
- SHOULD set `SameSite=Lax` by default (or `Strict` if compatible), and only use `None` when necessary (and only with `Secure`).
|
|
343
|
+
- SHOULD set bounded lifetimes (`Max-Age`/`Expires`) appropriate to the app.
|
|
344
|
+
|
|
345
|
+
Insecure patterns:
|
|
346
|
+
- Setting auth/session cookies without `Secure` in HTTPS deployments.
|
|
347
|
+
- Cookies without `HttpOnly` for session identifiers.
|
|
348
|
+
- `SameSite=None` for cookie-authenticated apps without a strong CSRF strategy.
|
|
349
|
+
|
|
350
|
+
Detection hints:
|
|
351
|
+
- Search for `http.SetCookie`, `&http.Cookie{`, `Set-Cookie`.
|
|
352
|
+
- Inspect cookie flags in auth/session code.
|
|
353
|
+
|
|
354
|
+
Fix:
|
|
355
|
+
- Set the correct fields on `http.Cookie` and centralize cookie creation.
|
|
356
|
+
|
|
357
|
+
Notes:
|
|
358
|
+
- SameSite is defense-in-depth and does not replace CSRF protections for cookie-auth apps.
|
|
359
|
+
|
|
360
|
+
---
|
|
361
|
+
|
|
362
|
+
### GO-HTTP-006: Cookie-authenticated state-changing endpoints MUST be CSRF-protected
|
|
363
|
+
Severity: High
|
|
364
|
+
|
|
365
|
+
- IMPORTANT NOTE: If cookies are not used for auth (e.g., pure bearer token in Authorization header with no ambient cookies), CSRF is not a risk for those endpoints.
|
|
366
|
+
|
|
367
|
+
Required:
|
|
368
|
+
- MUST protect all state-changing endpoints (POST/PUT/PATCH/DELETE) that rely on cookies for authentication.
|
|
369
|
+
- SHOULD use a well-tested CSRF library/middleware rather than rolling your own.
|
|
370
|
+
- MAY use additional defenses (Origin/Referer checks, Fetch Metadata, SameSite cookies), but tokens remain the primary defense for cookie-authenticated apps.
|
|
371
|
+
If tokens are impractical, or for small applications:
|
|
372
|
+
* MUST at a minimum require a custom header to be set and set the session cookie SESSION_COOKIE_SAMESITE=lax, as this is the strongest method besides requiring a form token, and may be much easier to implement.
|
|
373
|
+
|
|
374
|
+
|
|
375
|
+
Insecure patterns:
|
|
376
|
+
- Cookie-authenticated JSON endpoints that mutate state with no CSRF checks.
|
|
377
|
+
- Using GET for state-changing actions.
|
|
378
|
+
|
|
379
|
+
Detection hints:
|
|
380
|
+
- Enumerate all non-GET routes and identify auth mechanism.
|
|
381
|
+
- Look for CSRF middleware usage; if absent, treat as suspicious in browser-facing apps.
|
|
382
|
+
|
|
383
|
+
Fix:
|
|
384
|
+
- Add CSRF middleware and ensure it covers all state-changing routes.
|
|
385
|
+
- If the service is an API intended for non-browser clients, avoid cookie auth; use Authorization headers.
|
|
386
|
+
|
|
387
|
+
---
|
|
388
|
+
|
|
389
|
+
### GO-HTTP-007: CORS must be explicit and least-privilege
|
|
390
|
+
Severity: Medium (High if misconfigured with credentials)
|
|
391
|
+
|
|
392
|
+
Required:
|
|
393
|
+
- If CORS is not needed, MUST keep it disabled.
|
|
394
|
+
- If CORS is needed:
|
|
395
|
+
- MUST allowlist trusted origins (do not reflect arbitrary origins)
|
|
396
|
+
- MUST be careful with credentialed requests; do not combine broad origins with cookies
|
|
397
|
+
- SHOULD restrict allowed methods/headers
|
|
398
|
+
|
|
399
|
+
Insecure patterns:
|
|
400
|
+
- `Access-Control-Allow-Origin: *` paired with cookies (`Access-Control-Allow-Credentials: true`).
|
|
401
|
+
- Reflecting `Origin` without validation.
|
|
402
|
+
|
|
403
|
+
Detection hints:
|
|
404
|
+
- Search for `Access-Control-Allow-` header setting.
|
|
405
|
+
- Search for CORS middleware configuration.
|
|
406
|
+
|
|
407
|
+
Fix:
|
|
408
|
+
- Implement strict origin allowlists and minimal methods/headers.
|
|
409
|
+
- Ensure cookie-auth endpoints are not exposed cross-origin unless required.
|
|
410
|
+
|
|
411
|
+
---
|
|
412
|
+
|
|
413
|
+
### GO-XSS-001: Use html/template and avoid bypassing auto-escaping with untrusted data
|
|
414
|
+
Severity: High
|
|
415
|
+
|
|
416
|
+
Required:
|
|
417
|
+
- MUST use `html/template` for HTML rendering (not `text/template`).
|
|
418
|
+
- MUST NOT convert untrusted data into “trusted” template types (`template.HTML`, `template.JS`, `template.URL`, etc.).
|
|
419
|
+
- SHOULD keep templates static and controlled by developers; treat dynamic templates as high risk.
|
|
420
|
+
- MUST NOT serve user-uploaded HTML/JS as active content unless explicitly intended and safely sandboxed.
|
|
421
|
+
|
|
422
|
+
Insecure patterns:
|
|
423
|
+
- `text/template` used to generate HTML.
|
|
424
|
+
- Using `template.HTML(userInput)` or similar typed wrappers.
|
|
425
|
+
- Directly writing unescaped user content into HTML responses.
|
|
426
|
+
|
|
427
|
+
Detection hints:
|
|
428
|
+
- Search for `text/template`, `template.New(...).Parse(...)`, and typed wrappers like `template.HTML(`.
|
|
429
|
+
- Inspect handlers that return HTML with string concatenation.
|
|
430
|
+
|
|
431
|
+
Fix:
|
|
432
|
+
- Use `html/template` and pass untrusted data as data, not markup.
|
|
433
|
+
- If you must allow limited HTML, use a vetted HTML sanitizer and still be careful with attributes/URLs.
|
|
434
|
+
|
|
435
|
+
---
|
|
436
|
+
|
|
437
|
+
### GO-SSTI-001: Never parse/execute templates from untrusted input (SSTI)
|
|
438
|
+
Severity: Critical
|
|
439
|
+
|
|
440
|
+
Required:
|
|
441
|
+
- MUST NOT call `template.Parse` / `template.ParseFiles` / `template.New(...).Parse(...)` on template text influenced by untrusted input.
|
|
442
|
+
- MUST treat “user-defined templates” as a special high-risk design:
|
|
443
|
+
- MUST use heavy sandboxing and strict allowlists
|
|
444
|
+
- MUST isolate execution (process/container boundary) if truly required
|
|
445
|
+
|
|
446
|
+
Insecure patterns:
|
|
447
|
+
- `tmpl := template.Must(template.New("x").Parse(r.FormValue("tmpl")))`
|
|
448
|
+
- Reading templates from uploads / DB entries and executing them in the same trust domain as server code.
|
|
449
|
+
|
|
450
|
+
Detection hints:
|
|
451
|
+
- Search for `.Parse(` and trace the origin of the template string.
|
|
452
|
+
- Look for “custom email templates”, “user theming templates”, etc.
|
|
453
|
+
|
|
454
|
+
Fix:
|
|
455
|
+
- Replace with safe substitution mechanisms (no code execution).
|
|
456
|
+
- If templates must be user-controlled, isolate and sandbox aggressively.
|
|
457
|
+
|
|
458
|
+
---
|
|
459
|
+
|
|
460
|
+
### GO-PATH-001: Prevent path traversal and unsafe file serving
|
|
461
|
+
Severity: High
|
|
462
|
+
|
|
463
|
+
Required:
|
|
464
|
+
- MUST NOT pass user-controlled paths to `os.Open`, `os.ReadFile`, `http.ServeFile`, or `http.FileServer` without strict validation and base-dir enforcement.
|
|
465
|
+
- MUST treat `..`, absolute paths, and OS-specific path tricks as hostile input.
|
|
466
|
+
- SHOULD store user uploads outside any static web root; serve through controlled handlers.
|
|
467
|
+
- MUST avoid directory listing for sensitive file trees.
|
|
468
|
+
|
|
469
|
+
Insecure patterns:
|
|
470
|
+
- `http.ServeFile(w, r, r.URL.Query().Get("path"))`
|
|
471
|
+
- `os.Open(filepath.Join(baseDir, userPath))` without checking that the result stays under `baseDir`
|
|
472
|
+
- `http.FileServer(http.Dir("."))` serving the project root or user-writable directories
|
|
473
|
+
|
|
474
|
+
Detection hints:
|
|
475
|
+
- Search for `ServeFile(`, `FileServer(`, `http.Dir(`, `os.Open(`, `ReadFile(`, `filepath.Join(`.
|
|
476
|
+
- Trace whether path components come from request/DB.
|
|
477
|
+
|
|
478
|
+
Fix:
|
|
479
|
+
- Use an allowlist of file identifiers (e.g., database IDs) mapped to server-side paths.
|
|
480
|
+
- Enforce base directory containment after cleaning and joining.
|
|
481
|
+
- Serve active formats as downloads (`Content-Disposition: attachment`) unless explicitly intended.
|
|
482
|
+
|
|
483
|
+
---
|
|
484
|
+
|
|
485
|
+
### GO-UPLOAD-001: File uploads must be validated, stored safely, and served safely
|
|
486
|
+
Severity: High
|
|
487
|
+
|
|
488
|
+
Required:
|
|
489
|
+
- MUST enforce upload size limits (app + edge).
|
|
490
|
+
- MUST validate file type using allowlists and content checks (not only extensions).
|
|
491
|
+
- MUST store uploads outside executable/static roots when possible.
|
|
492
|
+
- SHOULD generate server-side filenames (random IDs) and avoid trusting original names.
|
|
493
|
+
- MUST serve potentially active formats safely (download attachment) unless explicitly intended.
|
|
494
|
+
|
|
495
|
+
Insecure patterns:
|
|
496
|
+
- Accepting arbitrary file types and serving them back inline.
|
|
497
|
+
- Using user-supplied filename as storage path.
|
|
498
|
+
- Missing size/type validation.
|
|
499
|
+
|
|
500
|
+
Detection hints:
|
|
501
|
+
- Search for `multipart`, `FormFile`, `ParseMultipartForm`, `io.Copy` to disk.
|
|
502
|
+
- Check where files are stored and how they are served.
|
|
503
|
+
|
|
504
|
+
Fix:
|
|
505
|
+
- Implement allowlist validation + safe storage + safe serving.
|
|
506
|
+
- Add scanning/quarantine workflows where applicable.
|
|
507
|
+
|
|
508
|
+
---
|
|
509
|
+
|
|
510
|
+
### GO-INJECT-001: Prevent SQL injection (parameterized queries / ORM)
|
|
511
|
+
Severity: High
|
|
512
|
+
|
|
513
|
+
Required:
|
|
514
|
+
- MUST use parameterized queries or an ORM that parameterizes under the hood.
|
|
515
|
+
- MUST NOT build SQL by string concatenation / `fmt.Sprintf` / string interpolation with untrusted input.
|
|
516
|
+
|
|
517
|
+
Insecure patterns:
|
|
518
|
+
- `fmt.Sprintf("SELECT ... WHERE id=%s", r.URL.Query().Get("id"))`
|
|
519
|
+
- `query := "UPDATE users SET role='" + role + "' WHERE id=" + id`
|
|
520
|
+
|
|
521
|
+
Detection hints:
|
|
522
|
+
- Grep for `SELECT`, `INSERT`, `UPDATE`, `DELETE` and check how query strings are built.
|
|
523
|
+
- Trace untrusted data into `db.Query`, `db.Exec`, `QueryRow`, etc.
|
|
524
|
+
|
|
525
|
+
Fix:
|
|
526
|
+
- Replace with placeholders (`?`, `$1`, etc.) and pass parameters separately.
|
|
527
|
+
- Validate and type-check IDs before use.
|
|
528
|
+
|
|
529
|
+
---
|
|
530
|
+
|
|
531
|
+
### GO-INJECT-002: Prevent OS command injection; avoid shelling out with untrusted input
|
|
532
|
+
Severity: Critical to High (depends on exposure)
|
|
533
|
+
|
|
534
|
+
Required:
|
|
535
|
+
- MUST avoid executing external commands with attacker-controlled strings.
|
|
536
|
+
- If subprocess is necessary:
|
|
537
|
+
- MUST use `exec.CommandContext` with an argument list (not `sh -c`).
|
|
538
|
+
- MUST NOT pass untrusted input to a shell (`bash -c`, `sh -c`, PowerShell).
|
|
539
|
+
- SHOULD use strict allowlists for any variable component (subcommand, flags, filenames).
|
|
540
|
+
- MUST assume CLI tools may interpret attacker-controlled args as flags or special values.
|
|
541
|
+
|
|
542
|
+
Insecure patterns:
|
|
543
|
+
- `exec.Command("sh", "-c", userString)`
|
|
544
|
+
- `exec.Command("bash", "-c", fmt.Sprintf("tool %s", user))`
|
|
545
|
+
- Calling the shell to get glob expansion for user-supplied globs.
|
|
546
|
+
|
|
547
|
+
Detection hints:
|
|
548
|
+
- Search for `os/exec`, `exec.Command(`, `CommandContext(`, `"sh"`, `"bash"`, `"-c"`.
|
|
549
|
+
- Trace untrusted input into command name/args.
|
|
550
|
+
|
|
551
|
+
Fix:
|
|
552
|
+
- Use library APIs instead of subprocesses.
|
|
553
|
+
- Hardcode command and allowlist/validate args.
|
|
554
|
+
- If a shell is unavoidable, escape robustly and treat as high risk (prefer avoiding).
|
|
555
|
+
|
|
556
|
+
Notes:
|
|
557
|
+
- The Go `os/exec` package intentionally does invoke a shell; introducing `sh -c` reintroduces shell injection hazards.
|
|
558
|
+
|
|
559
|
+
---
|
|
560
|
+
|
|
561
|
+
### GO-SSRF-001: Prevent SSRF in outbound HTTP requests
|
|
562
|
+
Severity: Medium (High in cloud/LAN environments)
|
|
563
|
+
|
|
564
|
+
- Note: For small stand alone projects this is less important. It is most important when deploying into an LAN or with other services listening on the same server.
|
|
565
|
+
|
|
566
|
+
Required:
|
|
567
|
+
- MUST treat outbound requests to user-provided URLs as high risk.
|
|
568
|
+
- SHOULD allowlist hosts/domains for any user-influenced URL fetch.
|
|
569
|
+
- SHOULD block access to localhost/private IP ranges/link-local addresses and cloud metadata endpoints.
|
|
570
|
+
- MUST restrict schemes to `http`/`https` (no `file:`, `gopher:`, etc.).
|
|
571
|
+
- MUST set client timeouts and restrict redirects.
|
|
572
|
+
|
|
573
|
+
Insecure patterns:
|
|
574
|
+
- `http.Get(r.URL.Query().Get("url"))`
|
|
575
|
+
- “URL preview” / “webhook test” endpoints that fetch arbitrary URLs.
|
|
576
|
+
|
|
577
|
+
Detection hints:
|
|
578
|
+
- Search for `http.Get`, `client.Do`, and URL values derived from requests/DB.
|
|
579
|
+
- Identify features that fetch remote resources.
|
|
580
|
+
|
|
581
|
+
Fix:
|
|
582
|
+
- Parse URLs strictly; enforce scheme and allowlisted hostnames.
|
|
583
|
+
- Resolve DNS and enforce IP-range restrictions (with care for DNS rebinding).
|
|
584
|
+
- Set timeouts, disable redirects unless needed, and cap response sizes.
|
|
585
|
+
|
|
586
|
+
---
|
|
587
|
+
|
|
588
|
+
### GO-HTTPCLIENT-001: Outbound HTTP clients MUST set timeouts and close bodies
|
|
589
|
+
Severity: High (DoS and resource exhaustion)
|
|
590
|
+
|
|
591
|
+
Required:
|
|
592
|
+
- MUST set an overall timeout on `http.Client` usage (or equivalent per-request deadlines via context + transport timeouts).
|
|
593
|
+
- MUST ensure `resp.Body.Close()` is called for all successful requests (typically `defer resp.Body.Close()` immediately after error check).
|
|
594
|
+
- SHOULD limit response body reads (do not `io.ReadAll` unbounded responses).
|
|
595
|
+
- SHOULD restrict redirects for security-sensitive fetches (SSRF, auth flows).
|
|
596
|
+
|
|
597
|
+
Insecure patterns:
|
|
598
|
+
- Using `http.DefaultClient` / `http.Get` for user-influenced destinations with no timeout policy.
|
|
599
|
+
- Missing `defer resp.Body.Close()` leading to resource leaks.
|
|
600
|
+
- `io.ReadAll(resp.Body)` with no limit.
|
|
601
|
+
|
|
602
|
+
Detection hints:
|
|
603
|
+
- Search for `http.Get(`, `http.Post(`, `client := &http.Client{}` without `Timeout`, `client.Do(` and missing closes.
|
|
604
|
+
- Search for `io.ReadAll(resp.Body)`.
|
|
605
|
+
|
|
606
|
+
Fix:
|
|
607
|
+
- Use a configured client with timeouts.
|
|
608
|
+
- Always close response bodies.
|
|
609
|
+
- Use bounded readers (`io.LimitReader`) for large/untrusted responses.
|
|
610
|
+
|
|
611
|
+
Notes:
|
|
612
|
+
- The net/http package exposes `DefaultClient` as a zero-valued `http.Client`, which can easily lead to “no timeout” behavior unless configured.
|
|
613
|
+
|
|
614
|
+
---
|
|
615
|
+
|
|
616
|
+
### GO-REDIRECT-001: Prevent open redirects
|
|
617
|
+
Severity: Medium (can be High with auth flows)
|
|
618
|
+
|
|
619
|
+
Required:
|
|
620
|
+
- MUST validate redirect targets derived from untrusted input (`next`, `redirect`, `return_to`).
|
|
621
|
+
- SHOULD prefer only same-site relative paths.
|
|
622
|
+
- SHOULD fall back to a safe default on validation failure.
|
|
623
|
+
|
|
624
|
+
Insecure patterns:
|
|
625
|
+
- `http.Redirect(w, r, r.URL.Query().Get("next"), http.StatusFound)` with no validation.
|
|
626
|
+
|
|
627
|
+
Detection hints:
|
|
628
|
+
- Search for `http.Redirect(` and check origin of the location.
|
|
629
|
+
|
|
630
|
+
Fix:
|
|
631
|
+
- Allowlist internal paths or known domains.
|
|
632
|
+
- Reject absolute URLs unless explicitly needed and allowlisted.
|
|
633
|
+
|
|
634
|
+
---
|
|
635
|
+
|
|
636
|
+
### GO-CRYPTO-001: Cryptographic randomness MUST come from crypto/rand
|
|
637
|
+
Severity: High (Critical if used for auth/session tokens or keys)
|
|
638
|
+
|
|
639
|
+
Required:
|
|
640
|
+
- MUST use `crypto/rand` for:
|
|
641
|
+
- session IDs, password reset tokens, API keys, CSRF tokens, nonces
|
|
642
|
+
- encryption keys, signing keys, salts when required
|
|
643
|
+
- MUST NOT use `math/rand` for any security-sensitive value.
|
|
644
|
+
- SHOULD use built-in helpers that produce appropriately strong tokens when available.
|
|
645
|
+
|
|
646
|
+
Insecure patterns:
|
|
647
|
+
- `math/rand.Seed(time.Now().UnixNano())` followed by token generation for auth or sessions.
|
|
648
|
+
- Using UUIDv4-like constructs built from `math/rand`.
|
|
649
|
+
|
|
650
|
+
Detection hints:
|
|
651
|
+
- Search for `math/rand`, `rand.Seed`, `rand.Intn` in code that touches auth/session/token flows.
|
|
652
|
+
- Search for custom token generators.
|
|
653
|
+
|
|
654
|
+
Fix:
|
|
655
|
+
- Switch to `crypto/rand` (`rand.Reader`, `rand.Read`, or secure token helpers).
|
|
656
|
+
- Ensure sufficient entropy and use URL-safe encoding.
|
|
657
|
+
|
|
658
|
+
Notes:
|
|
659
|
+
- The crypto/rand package provides secure randomness APIs and token generation helpers.
|
|
660
|
+
|
|
661
|
+
---
|
|
662
|
+
|
|
663
|
+
### GO-AUTH-001: Password storage MUST use adaptive hashing (bcrypt/argon2id) and safe comparisons
|
|
664
|
+
Severity: High
|
|
665
|
+
|
|
666
|
+
Required:
|
|
667
|
+
- MUST hash passwords using an adaptive password hashing function (bcrypt or argon2id).
|
|
668
|
+
- MUST NOT store plaintext passwords or reversible encryption of passwords.
|
|
669
|
+
- MUST compare secrets in constant time when relevant (tokens, MACs, API keys) to reduce timing leaks.
|
|
670
|
+
- SHOULD ensure password policies do not exceed algorithm constraints (e.g., bcrypt has input length limits; handle long passphrases appropriately).
|
|
671
|
+
|
|
672
|
+
Insecure patterns:
|
|
673
|
+
- `sha256(password)` stored as password hash.
|
|
674
|
+
- Plaintext password storage.
|
|
675
|
+
- Comparing secrets with `==` in timing-sensitive contexts.
|
|
676
|
+
|
|
677
|
+
Detection hints:
|
|
678
|
+
- Search for `sha1`, `sha256`, `md5` used on passwords.
|
|
679
|
+
- Search for `bcrypt`/`argon2` usage; if absent, suspect.
|
|
680
|
+
- Search for `==` comparisons on tokens/API keys.
|
|
681
|
+
|
|
682
|
+
Fix:
|
|
683
|
+
- Use `bcrypt.GenerateFromPassword` / `CompareHashAndPassword` or argon2id with recommended parameters.
|
|
684
|
+
- Use constant-time compare helpers when comparing MACs/tokens.
|
|
685
|
+
|
|
686
|
+
Notes:
|
|
687
|
+
- Go provides bcrypt in `golang.org/x/crypto/bcrypt`, and constant-time comparisons in `crypto/subtle`.
|
|
688
|
+
|
|
689
|
+
---
|
|
690
|
+
|
|
691
|
+
### GO-CONC-001: Data races and concurrency hazards MUST be treated as security-relevant
|
|
692
|
+
Severity: Medium to High (depends on what races affect)
|
|
693
|
+
|
|
694
|
+
Required:
|
|
695
|
+
- MUST run tests with the race detector (`go test -race`) in CI for security-sensitive services.
|
|
696
|
+
- MUST fix detected races; do not suppress without deep justification.
|
|
697
|
+
- SHOULD treat shared mutable state in handlers as high risk; enforce synchronization or avoid shared mutability.
|
|
698
|
+
|
|
699
|
+
Insecure patterns:
|
|
700
|
+
- Global maps/slices mutated from multiple goroutines without a mutex.
|
|
701
|
+
- Caches or auth/session state stored in globals without concurrency protection.
|
|
702
|
+
- Racy access to authorization state (can lead to bypasses or inconsistent enforcement).
|
|
703
|
+
|
|
704
|
+
Detection hints:
|
|
705
|
+
- Search for `var someMap = map[...]...` used in handlers.
|
|
706
|
+
- Look for missing `sync.Mutex`, `sync.Map`, channels, or other synchronization.
|
|
707
|
+
- Ensure CI includes `-race` and that it runs relevant tests.
|
|
708
|
+
|
|
709
|
+
Fix:
|
|
710
|
+
- Add proper synchronization or redesign to avoid shared mutable state.
|
|
711
|
+
- Add race tests and run them continuously.
|
|
712
|
+
|
|
713
|
+
Notes:
|
|
714
|
+
- The Go race detector only finds races that occur in executed code paths; improve test coverage and run realistic workloads with `-race` where feasible.
|
|
715
|
+
|
|
716
|
+
---
|
|
717
|
+
|
|
718
|
+
### GO-UNSAFE-001: Use of unsafe/cgo MUST be minimized and audited like memory-unsafe code
|
|
719
|
+
Severity: High (Critical in high-risk code paths)
|
|
720
|
+
|
|
721
|
+
Required:
|
|
722
|
+
- SHOULD avoid importing `unsafe` in application code unless absolutely necessary.
|
|
723
|
+
- If `unsafe` is used, MUST treat it as “manual memory safety” requiring careful review and test coverage.
|
|
724
|
+
- If `cgo` is used, MUST treat the C/C++ boundary as memory-unsafe; apply secure coding practices on the C side and isolate where possible.
|
|
725
|
+
|
|
726
|
+
Insecure patterns:
|
|
727
|
+
- Widespread `unsafe.Pointer` casts in parsing, serialization, auth, or network code.
|
|
728
|
+
- `cgo` used for parsing or security boundaries without sandboxing.
|
|
729
|
+
|
|
730
|
+
Detection hints:
|
|
731
|
+
- Search for `import "unsafe"`, `unsafe.Pointer`, `// #cgo`, `import "C"`.
|
|
732
|
+
- Prioritize review where unsafe touches untrusted input.
|
|
733
|
+
|
|
734
|
+
Fix:
|
|
735
|
+
- Replace unsafe/cgo usage with safe standard library alternatives where possible.
|
|
736
|
+
- Isolate unsafe code in small, well-tested modules with fuzz/race tests.
|
|
737
|
+
|
|
738
|
+
Notes:
|
|
739
|
+
- The unsafe package explicitly provides operations that step around Go’s type safety guarantees.
|
|
740
|
+
|
|
741
|
+
--------------------------------------------------------------------
|
|
742
|
+
|
|
743
|
+
## 5) Practical scanning heuristics (how to “hunt”)
|
|
744
|
+
|
|
745
|
+
When actively scanning, use these high-signal patterns:
|
|
746
|
+
|
|
747
|
+
Toolchain & dependencies:
|
|
748
|
+
- `FROM golang:` (Dockerfiles), `go-version:` (CI), `toolchain go` (go.mod), pinned old versions
|
|
749
|
+
- `GOSUMDB=off`, `GOINSECURE`, `GONOSUMDB`, `GOPROXY=direct`
|
|
750
|
+
- `replace` directives in `go.mod` to forks/paths
|
|
751
|
+
- `govulncheck` missing in CI
|
|
752
|
+
|
|
753
|
+
HTTP server hardening:
|
|
754
|
+
- `http.ListenAndServe(`, `ListenAndServeTLS(`, `&http.Server{` with missing timeouts
|
|
755
|
+
- `ReadHeaderTimeout: 0`, `ReadTimeout: 0`, `WriteTimeout: 0`, `IdleTimeout: 0`, missing `MaxHeaderBytes`
|
|
756
|
+
|
|
757
|
+
Body parsing / DoS:
|
|
758
|
+
- `io.ReadAll(r.Body)`, `json.NewDecoder(r.Body)` without size cap
|
|
759
|
+
- `ParseMultipartForm`, `FormFile`, `multipart.NewReader` without explicit limits
|
|
760
|
+
- Missing `http.MaxBytesReader`
|
|
761
|
+
|
|
762
|
+
Debug exposure:
|
|
763
|
+
- `import _ "net/http/pprof"`
|
|
764
|
+
- `/debug/pprof`, `/debug/vars`
|
|
765
|
+
|
|
766
|
+
Templates / XSS / SSTI:
|
|
767
|
+
- `text/template` used for HTML output
|
|
768
|
+
- `template.HTML(`, `template.JS(`, `template.URL(` with user-controlled data
|
|
769
|
+
- `.Parse(` on user-controlled strings
|
|
770
|
+
|
|
771
|
+
Files:
|
|
772
|
+
- `http.ServeFile(` with user path
|
|
773
|
+
- `http.FileServer(http.Dir(` pointing at repo root or uploads
|
|
774
|
+
- `os.Open(filepath.Join(base, user))` without containment checks
|
|
775
|
+
|
|
776
|
+
Injection:
|
|
777
|
+
- SQL building with `fmt.Sprintf`, string concatenation near `db.Query/Exec`
|
|
778
|
+
- `exec.Command("sh","-c", ...)`, `exec.Command("bash","-c", ...)`
|
|
779
|
+
|
|
780
|
+
SSRF / outbound HTTP:
|
|
781
|
+
- `http.Get(userURL)`, `client.Do(req)` where URL comes from request/DB
|
|
782
|
+
- Missing client timeout, missing `resp.Body.Close()`, unbounded `io.ReadAll(resp.Body)`
|
|
783
|
+
|
|
784
|
+
Crypto:
|
|
785
|
+
- `math/rand` in token/session generation
|
|
786
|
+
- `InsecureSkipVerify: true`
|
|
787
|
+
- Password hashing with `sha256`/`md5` instead of bcrypt/argon2
|
|
788
|
+
|
|
789
|
+
Concurrency:
|
|
790
|
+
- Shared maps/slices mutated from handlers without locks
|
|
791
|
+
- CI lacking `go test -race`
|
|
792
|
+
|
|
793
|
+
Always try to confirm:
|
|
794
|
+
- data origin (untrusted vs trusted)
|
|
795
|
+
- sink type (template/SQL/subprocess/files/http)
|
|
796
|
+
- protective controls present (limits, validation, allowlists, middleware, network controls)
|
|
797
|
+
|
|
798
|
+
--------------------------------------------------------------------
|
|
799
|
+
|
|
800
|
+
## 6) Sources (accessed 2026-01-28)
|
|
801
|
+
|
|
802
|
+
Primary Go documentation:
|
|
803
|
+
- Go Security Policy — https://go.dev/doc/security/policy
|
|
804
|
+
- Go Release History (security fixes in patch releases) — https://go.dev/doc/devel/release
|
|
805
|
+
- Go 1.25 Release Notes — https://go.dev/doc/go1.25
|
|
806
|
+
- net/http (server timeouts, MaxHeaderBytes, DefaultClient) — https://pkg.go.dev/net/http
|
|
807
|
+
- html/template (auto-escaping and trusted-template assumptions) — https://pkg.go.dev/html/template
|
|
808
|
+
- crypto/tls (MinVersion defaults, InsecureSkipVerify warnings) — https://pkg.go.dev/crypto/tls
|
|
809
|
+
- crypto/rand (secure randomness, token helpers) — https://pkg.go.dev/crypto/rand
|
|
810
|
+
- crypto/subtle (constant-time comparisons) — https://pkg.go.dev/crypto/subtle
|
|
811
|
+
- os/exec (no shell by default; command execution guidance) — https://pkg.go.dev/os/exec
|
|
812
|
+
- unsafe (bypasses type safety) — https://go.dev/src/unsafe/unsafe.go
|
|
813
|
+
- net/http/pprof (debug endpoints) — https://pkg.go.dev/net/http/pprof
|
|
814
|
+
- cmd/go (module authentication via go.sum/checksum DB; env vars like GOINSECURE) — https://pkg.go.dev/cmd/go
|
|
815
|
+
- Module Mirror and Checksum Database Launched (Go blog) — https://go.dev/blog/module-mirror-launch
|
|
816
|
+
- govulncheck documentation — https://pkg.go.dev/golang.org/x/vuln/cmd/govulncheck
|
|
817
|
+
- Go Race Detector documentation — https://go.dev/doc/articles/race_detector
|
|
818
|
+
- bcrypt (password hashing) — https://pkg.go.dev/golang.org/x/crypto/bcrypt
|
|
819
|
+
- Go vulnerability entry example (multipart resource consumption) — https://pkg.go.dev/vuln/GO-2023-1569
|
|
820
|
+
|
|
821
|
+
OWASP Cheat Sheet Series (general web security):
|
|
822
|
+
- Session Management — https://cheatsheetseries.owasp.org/cheatsheets/Session_Management_Cheat_Sheet.html
|
|
823
|
+
- CSRF Prevention — https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Request_Forgery_Prevention_Cheat_Sheet.html
|
|
824
|
+
- SSRF Prevention — https://cheatsheetseries.owasp.org/cheatsheets/Server_Side_Request_Forgery_Prevention_Cheat_Sheet.html
|
|
825
|
+
- XSS Prevention — https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html
|
|
826
|
+
- HTTP Security Response Headers — https://cheatsheetseries.owasp.org/cheatsheets/HTTP_Headers_Cheat_Sheet.html
|