diff --git a/skills/architecture-review/README.md b/skills/architecture-review/README.md new file mode 100644 index 00000000..7308174b --- /dev/null +++ b/skills/architecture-review/README.md @@ -0,0 +1,15 @@ +# Architecture Review + +Review system architecture for scalability, maintainability, and best practices. Analyzes code structure, dependencies, data flow, and provides recommendations for improvements. + +## Triggers + +- `/architecture-review` +- `/arch-review` + +## What It Does + +1. Maps system components and dependencies +2. Identifies architectural patterns and anti-patterns +3. Evaluates scalability, maintainability, and security +4. Provides prioritized improvement recommendations diff --git a/skills/architecture-review/SKILL.md b/skills/architecture-review/SKILL.md new file mode 100644 index 00000000..38f272f5 --- /dev/null +++ b/skills/architecture-review/SKILL.md @@ -0,0 +1,58 @@ +--- +name: architecture-review +description: Review system architecture for scalability, maintainability, and best practices. Analyzes code structure, dependencies, data flow, and provides recommendations for improvements. +triggers: +- /architecture-review +- /arch-review +--- + +# Architecture Review + +Evaluate system architecture and provide actionable recommendations for improvement. + +## Process + +1. **Map the system**: Understand components, dependencies, and data flow +2. **Identify patterns**: Recognize architectural patterns and anti-patterns +3. **Assess qualities**: Evaluate scalability, maintainability, testability, security +4. **Provide recommendations**: Suggest concrete improvements with trade-offs + +## Review Areas + +### Code Organization +- Module boundaries and cohesion +- Dependency direction and coupling +- Layer separation (presentation, business, data) +- Package structure and naming + +### Scalability +- Horizontal vs vertical scaling considerations +- Stateless design patterns +- Caching strategies +- Database design and query patterns + +### Maintainability +- Code complexity and readability +- Technical debt hotspots +- Test coverage and testability +- Documentation completeness + +### Security Architecture +- Authentication and authorization patterns +- Data protection and encryption +- Network security boundaries +- Secret management + +### Operational Concerns +- Observability (logging, metrics, tracing) +- Error handling and resilience +- Deployment and rollback strategies +- Configuration management + +## Output Format + +Provide: +1. **Architecture diagram** (if helpful) +2. **Strengths**: What the architecture does well +3. **Concerns**: Issues that should be addressed +4. **Recommendations**: Prioritized list of improvements with effort estimates diff --git a/skills/architecture-review/commands/architecture-review.md b/skills/architecture-review/commands/architecture-review.md new file mode 100644 index 00000000..d7c0a495 --- /dev/null +++ b/skills/architecture-review/commands/architecture-review.md @@ -0,0 +1,22 @@ +# /architecture-review + +Review the architecture of a codebase. + +## Usage + +``` +/architecture-review +/architecture-review --focus +``` + +## Examples + +``` +/architecture-review +``` +Performs a comprehensive architecture review. + +``` +/architecture-review --focus scalability +``` +Focuses on scalability concerns and recommendations. diff --git a/skills/audit-accessibility/README.md b/skills/audit-accessibility/README.md new file mode 100644 index 00000000..bf0790ae --- /dev/null +++ b/skills/audit-accessibility/README.md @@ -0,0 +1,17 @@ +# Audit Accessibility + +Audit web applications for accessibility compliance with WCAG guidelines. Identifies barriers for users with disabilities and provides fixes to improve inclusivity. + +## Triggers + +- `/audit-accessibility` +- `/a11y-audit` +- `/wcag-check` + +## What It Does + +1. Scans for common accessibility violations +2. Checks keyboard navigation and focus management +3. Verifies ARIA usage and screen reader compatibility +4. Reports issues with WCAG references +5. Provides code fixes for identified issues diff --git a/skills/audit-accessibility/SKILL.md b/skills/audit-accessibility/SKILL.md new file mode 100644 index 00000000..89dc0253 --- /dev/null +++ b/skills/audit-accessibility/SKILL.md @@ -0,0 +1,85 @@ +--- +name: audit-accessibility +description: Audit web applications for accessibility compliance with WCAG guidelines. Identifies barriers for users with disabilities and provides fixes to improve inclusivity. +triggers: +- /audit-accessibility +- /a11y-audit +- /wcag-check +--- + +# Audit Accessibility + +Ensure web applications are accessible to users with disabilities. + +## Process + +1. **Automated checks**: Scan for common accessibility violations +2. **Manual review**: Assess keyboard navigation, screen reader compatibility +3. **Report issues**: Catalog violations with WCAG references +4. **Implement fixes**: Provide code changes to resolve issues + +## WCAG Compliance Areas + +### Perceivable +- Images have alt text +- Videos have captions +- Color is not the only indicator +- Sufficient color contrast +- Text can be resized + +### Operable +- All functionality keyboard accessible +- Focus indicators visible +- No keyboard traps +- Skip navigation links +- Sufficient time limits + +### Understandable +- Language declared +- Consistent navigation +- Clear error messages +- Form labels and instructions + +### Robust +- Valid HTML markup +- ARIA used correctly +- Compatible with assistive technologies + +## Common Issues + +### Missing or Poor Alt Text +```html + + + + +Sales increased 25% from Q1 to Q2 +``` + +### Insufficient Color Contrast +- Text must have 4.5:1 contrast ratio (normal text) +- Large text needs 3:1 ratio + +### Missing Form Labels +```html + + + + + + +``` + +### Non-Keyboard Accessible +- onClick without onKeyDown +- Custom controls without keyboard support +- Missing tabIndex for interactive elements + +## Output Format + +For each issue: +1. **Severity**: Critical, Serious, Moderate, Minor +2. **WCAG Criterion**: e.g., 1.1.1 Non-text Content +3. **Location**: Component/element affected +4. **Description**: What the issue is +5. **Fix**: Code change to resolve the issue diff --git a/skills/audit-accessibility/commands/audit-accessibility.md b/skills/audit-accessibility/commands/audit-accessibility.md new file mode 100644 index 00000000..4b2b7a51 --- /dev/null +++ b/skills/audit-accessibility/commands/audit-accessibility.md @@ -0,0 +1,23 @@ +# /audit-accessibility + +Audit for accessibility compliance. + +## Usage + +``` +/audit-accessibility +/audit-accessibility +/audit-accessibility --level +``` + +## Examples + +``` +/audit-accessibility +``` +Audits the entire frontend for accessibility issues. + +``` +/audit-accessibility src/components/Form.tsx +``` +Audits a specific component. diff --git a/skills/clean-logs/README.md b/skills/clean-logs/README.md new file mode 100644 index 00000000..6706be44 --- /dev/null +++ b/skills/clean-logs/README.md @@ -0,0 +1,16 @@ +# Clean Up Logs + +Analyze and improve application logging by removing noise, standardizing formats, adding structured context, and ensuring appropriate log levels. + +## Triggers + +- `/clean-logs` +- `/improve-logging` + +## What It Does + +1. Audits existing log statements +2. Fixes incorrect log levels +3. Adds missing context (correlation IDs, user info) +4. Removes noisy or redundant logs +5. Standardizes log format diff --git a/skills/clean-logs/SKILL.md b/skills/clean-logs/SKILL.md new file mode 100644 index 00000000..19192172 --- /dev/null +++ b/skills/clean-logs/SKILL.md @@ -0,0 +1,54 @@ +--- +name: clean-logs +description: Analyze and improve application logging by removing noise, standardizing formats, adding structured context, and ensuring appropriate log levels. +triggers: +- /clean-logs +- /improve-logging +--- + +# Clean Up Logs + +Improve application logging for better observability and debugging. + +## Process + +1. **Audit current logging**: Review existing log statements +2. **Identify issues**: Find noise, missing context, incorrect levels +3. **Standardize**: Apply consistent formatting and structure +4. **Add context**: Include relevant debugging information +5. **Remove noise**: Eliminate unnecessary or redundant logs + +## Common Issues + +### Log Level Problems +- Debug logs in production code paths +- Errors logged as warnings (or vice versa) +- Info logs that should be debug +- Missing error logs for failure cases + +### Missing Context +- Logs without request/correlation IDs +- Error logs without stack traces +- Missing user or session context +- No timing information for slow operations + +### Noise and Redundancy +- Excessive logging in hot paths +- Duplicate log messages +- Logging sensitive data (PII, credentials) +- Logs that don't aid debugging + +### Format Issues +- Inconsistent log formats +- Unstructured logs that are hard to parse +- Missing timestamps +- Non-standard field names + +## Best Practices + +- Use structured logging (JSON format) +- Include correlation IDs for request tracing +- Log at appropriate levels (ERROR, WARN, INFO, DEBUG) +- Redact sensitive information +- Include relevant context (user, request, operation) +- Make logs grep-able and queryable diff --git a/skills/clean-logs/commands/clean-logs.md b/skills/clean-logs/commands/clean-logs.md new file mode 100644 index 00000000..a0adf038 --- /dev/null +++ b/skills/clean-logs/commands/clean-logs.md @@ -0,0 +1,22 @@ +# /clean-logs + +Improve application logging quality. + +## Usage + +``` +/clean-logs +/clean-logs +``` + +## Examples + +``` +/clean-logs +``` +Reviews and improves logging across the codebase. + +``` +/clean-logs src/api/ +``` +Focuses on logging in the API directory. diff --git a/skills/cobol-modernization/README.md b/skills/cobol-modernization/README.md new file mode 100644 index 00000000..cb34a66a --- /dev/null +++ b/skills/cobol-modernization/README.md @@ -0,0 +1,17 @@ +# COBOL Modernization + +Understand, document, and modernize legacy COBOL systems. Analyzes COBOL code, extracts business logic, generates documentation, and assists with migration to modern languages. + +## Triggers + +- `/modernize-cobol` +- `/cobol-to-java` +- `/analyze-cobol` + +## What It Does + +1. Analyzes COBOL program structure and copybooks +2. Extracts and documents business rules +3. Generates comprehensive documentation +4. Plans and executes migration to modern languages +5. Validates transformations preserve behavior diff --git a/skills/cobol-modernization/SKILL.md b/skills/cobol-modernization/SKILL.md new file mode 100644 index 00000000..405057e9 --- /dev/null +++ b/skills/cobol-modernization/SKILL.md @@ -0,0 +1,97 @@ +--- +name: cobol-modernization +description: Understand, document, and modernize legacy COBOL systems. Analyzes COBOL code, extracts business logic, generates documentation, and assists with migration to modern languages. +triggers: +- /modernize-cobol +- /cobol-to-java +- /analyze-cobol +--- + +# COBOL Modernization + +Understand and modernize legacy COBOL systems while preserving critical business logic. + +## Process + +1. **Analyze**: Parse COBOL code structure, copybooks, and data divisions +2. **Document**: Generate documentation for undocumented programs +3. **Extract logic**: Identify and document business rules +4. **Plan migration**: Create modernization roadmap +5. **Transform**: Convert to modern languages when ready + +## Analysis Capabilities + +### Code Structure +- Program divisions (IDENTIFICATION, ENVIRONMENT, DATA, PROCEDURE) +- Paragraph and section organization +- PERFORM and GO TO flow analysis +- Copybook dependencies + +### Data Analysis +- File descriptions (FD) and record layouts +- Working storage analysis +- Data flow through programs +- Implicit data transformations + +### Business Logic +- Conditional logic extraction +- Calculation rules +- Validation rules +- Reporting logic + +## Documentation Generation + +Generate comprehensive documentation including: +- Program overview and purpose +- Input/output file descriptions +- Data dictionary from copybooks +- Business rule catalog +- Call graphs and dependencies +- Flowcharts for complex logic + +## Migration Paths + +### COBOL to Java +- Map COBOL data types to Java classes +- Convert PERFORM loops to methods +- Handle decimal arithmetic (BigDecimal) +- Preserve file I/O semantics + +### COBOL to Python +- Simplify data structures +- Convert to modern file handling +- Maintain calculation precision + +### Incremental Modernization +- Wrap COBOL in API layer +- Strangler fig pattern +- Gradual replacement of modules + +## Example Usage + +``` +/analyze-cobol + +Analyze PAYROLL.cbl and its copybooks: +- Document the program structure +- Extract all business rules +- Identify dependencies +- Create data dictionary +``` + +``` +/cobol-to-java PAYROLL.cbl + +Convert the payroll calculation module to Java: +- Preserve all business logic +- Create equivalent data classes +- Add unit tests for validation +``` + +## Best Practices + +- Always validate transformations against original behavior +- Preserve comments and documentation +- Maintain audit trail of changes +- Test with production-like data +- Involve domain experts in validation diff --git a/skills/cobol-modernization/commands/modernize-cobol.md b/skills/cobol-modernization/commands/modernize-cobol.md new file mode 100644 index 00000000..3ea103f9 --- /dev/null +++ b/skills/cobol-modernization/commands/modernize-cobol.md @@ -0,0 +1,28 @@ +# /modernize-cobol + +Analyze and modernize COBOL programs. + +## Usage + +``` +/modernize-cobol +/analyze-cobol +/cobol-to-java +``` + +## Examples + +``` +/analyze-cobol PAYROLL.cbl +``` +Analyzes the program and generates documentation. + +``` +/cobol-to-java PAYROLL.cbl +``` +Converts the COBOL program to equivalent Java code. + +``` +/modernize-cobol --extract-rules BILLING.cbl +``` +Extracts and documents all business rules from the program. diff --git a/skills/discover-vulnerabilities/README.md b/skills/discover-vulnerabilities/README.md new file mode 100644 index 00000000..05b82fb3 --- /dev/null +++ b/skills/discover-vulnerabilities/README.md @@ -0,0 +1,17 @@ +# Discover Vulnerabilities + +Proactively scan codebases to discover security vulnerabilities before they're exploited. Combines static analysis, dependency scanning, and pattern matching to find security issues. + +## Triggers + +- `/discover-vulns` +- `/find-vulnerabilities` +- `/vuln-scan` + +## What It Does + +1. Scans dependencies for known CVEs +2. Analyzes code for vulnerable patterns +3. Detects exposed secrets and credentials +4. Audits configuration for security issues +5. Prioritizes findings by severity diff --git a/skills/discover-vulnerabilities/SKILL.md b/skills/discover-vulnerabilities/SKILL.md new file mode 100644 index 00000000..33b24026 --- /dev/null +++ b/skills/discover-vulnerabilities/SKILL.md @@ -0,0 +1,54 @@ +--- +name: discover-vulnerabilities +description: Proactively scan codebases to discover security vulnerabilities before they're exploited. Combines static analysis, dependency scanning, and pattern matching to find security issues. +triggers: +- /discover-vulns +- /find-vulnerabilities +- /vuln-scan +--- + +# Discover Vulnerabilities + +Proactively identify security vulnerabilities in your codebase. + +## Process + +1. **Dependency scan**: Check for known CVEs in dependencies +2. **Static analysis**: Identify vulnerable code patterns +3. **Secret detection**: Find exposed credentials and API keys +4. **Configuration audit**: Check for insecure settings +5. **Report findings**: Prioritize by severity and exploitability + +## Vulnerability Categories + +### Dependency Vulnerabilities +- Known CVEs in direct dependencies +- Transitive dependency vulnerabilities +- Outdated packages with security fixes + +### Code Vulnerabilities +- Injection flaws (SQL, command, LDAP) +- Cross-site scripting (XSS) +- Insecure deserialization +- Server-side request forgery (SSRF) + +### Secrets and Credentials +- Hardcoded passwords and API keys +- Exposed tokens in code or configs +- Credentials in version control history + +### Configuration Issues +- Default credentials +- Debug mode in production +- Permissive CORS policies +- Missing security headers + +## Output Format + +For each vulnerability found: +1. **Severity**: Critical, High, Medium, Low +2. **CVE/CWE**: If applicable +3. **Location**: File and line number +4. **Description**: What the vulnerability is +5. **Exploitation**: How it could be exploited +6. **Remediation**: How to fix it diff --git a/skills/discover-vulnerabilities/commands/discover-vulns.md b/skills/discover-vulnerabilities/commands/discover-vulns.md new file mode 100644 index 00000000..2dedacf4 --- /dev/null +++ b/skills/discover-vulnerabilities/commands/discover-vulns.md @@ -0,0 +1,22 @@ +# /discover-vulns + +Scan for security vulnerabilities in the codebase. + +## Usage + +``` +/discover-vulns +/discover-vulns --focus +``` + +## Examples + +``` +/discover-vulns +``` +Performs a comprehensive vulnerability scan. + +``` +/discover-vulns --focus deps +``` +Focuses on dependency vulnerabilities only. diff --git a/skills/fix-ci-pipelines/README.md b/skills/fix-ci-pipelines/README.md new file mode 100644 index 00000000..ed915a14 --- /dev/null +++ b/skills/fix-ci-pipelines/README.md @@ -0,0 +1,26 @@ +# Fix CI Pipelines + +Diagnose and fix CI/CD pipeline failures including GitHub Actions, GitLab CI, Jenkins, and other CI systems. Analyzes build logs, identifies root causes, and implements fixes to get pipelines green again. + +## Triggers + +This skill is activated by the following commands: + +- `/fix-ci` +- `/fix-pipeline` + +## What It Does + +1. Fetches and analyzes CI build logs +2. Identifies the root cause of failures +3. Implements appropriate fixes +4. Verifies the fix resolves the issue + +## Common Issues Handled + +- Dependency version conflicts +- Flaky or failing tests +- Build configuration errors +- Missing secrets or environment variables +- Resource limit issues +- Docker and container problems diff --git a/skills/fix-ci-pipelines/SKILL.md b/skills/fix-ci-pipelines/SKILL.md new file mode 100644 index 00000000..c7fdf0a6 --- /dev/null +++ b/skills/fix-ci-pipelines/SKILL.md @@ -0,0 +1,53 @@ +--- +name: fix-ci-pipelines +description: Diagnose and fix CI/CD pipeline failures including GitHub Actions, GitLab CI, Jenkins, and other CI systems. Analyzes build logs, identifies root causes, and implements fixes to get pipelines green again. +triggers: +- /fix-ci +- /fix-pipeline +--- + +# Fix CI Pipelines + +Diagnose and resolve CI/CD pipeline failures to restore healthy builds and deployments. + +## Process + +1. **Identify the failure**: Fetch CI logs and identify the failing job, step, and error message +2. **Analyze root cause**: Determine if it's a code issue, dependency problem, flaky test, configuration error, or infrastructure issue +3. **Implement fix**: Apply the appropriate fix based on the root cause +4. **Verify**: Ensure the fix resolves the issue without breaking other jobs + +## Common CI Failure Patterns + +### Dependency Issues +- Version conflicts or missing dependencies +- Lock file out of sync with manifest +- Private registry authentication failures + +### Test Failures +- Flaky tests with race conditions +- Environment-specific failures +- Missing test fixtures or data + +### Build Failures +- Compilation errors +- Type checking failures +- Asset bundling issues + +### Configuration Issues +- Invalid YAML syntax +- Missing secrets or environment variables +- Incorrect job dependencies or ordering + +### Infrastructure Issues +- Resource limits (memory, disk, time) +- Network connectivity problems +- Docker image availability + +## Output + +Provide: +1. Root cause analysis of the failure +2. Specific fix with code changes +3. Explanation of why the fix works +4. Recommendations to prevent similar failures diff --git a/skills/fix-ci-pipelines/commands/fix-ci.md b/skills/fix-ci-pipelines/commands/fix-ci.md new file mode 100644 index 00000000..9f8eb5cc --- /dev/null +++ b/skills/fix-ci-pipelines/commands/fix-ci.md @@ -0,0 +1,28 @@ +# /fix-ci + +Diagnose and fix CI/CD pipeline failures. + +## Usage + +``` +/fix-ci +/fix-ci +/fix-ci +``` + +## Examples + +``` +/fix-ci +``` +Analyzes the most recent CI failure in the current repository. + +``` +/fix-ci build +``` +Focuses on failures in the "build" workflow. + +``` +/fix-ci #123 +``` +Analyzes CI failures for PR #123. diff --git a/skills/fix-merge-conflicts/README.md b/skills/fix-merge-conflicts/README.md new file mode 100644 index 00000000..bc1d7a7c --- /dev/null +++ b/skills/fix-merge-conflicts/README.md @@ -0,0 +1,15 @@ +# Fix Merge Conflicts + +Resolve git merge conflicts intelligently by understanding the intent of both changes. Handles code conflicts, configuration file merges, and lock file reconciliation. + +## Triggers + +- `/fix-conflicts` +- `/resolve-conflicts` + +## What It Does + +1. Analyzes both sides of each conflict +2. Understands the intent behind each change +3. Resolves conflicts while preserving both intents +4. Handles lock file regeneration when needed diff --git a/skills/fix-merge-conflicts/SKILL.md b/skills/fix-merge-conflicts/SKILL.md new file mode 100644 index 00000000..23558b57 --- /dev/null +++ b/skills/fix-merge-conflicts/SKILL.md @@ -0,0 +1,47 @@ +--- +name: fix-merge-conflicts +description: Resolve git merge conflicts intelligently by understanding the intent of both changes. Handles code conflicts, configuration file merges, and lock file reconciliation. +triggers: +- /fix-conflicts +- /resolve-conflicts +--- + +# Fix Merge Conflicts + +Intelligently resolve git merge conflicts while preserving the intent of both changes. + +## Process + +1. **Understand the conflict**: Analyze both sides of each conflict +2. **Determine intent**: Understand what each change was trying to accomplish +3. **Resolve intelligently**: Merge changes in a way that preserves both intents +4. **Verify correctness**: Ensure the resolution doesn't break functionality + +## Conflict Types + +### Code Conflicts +- Parallel changes to the same function +- Competing refactors +- Feature additions that overlap + +### Configuration Conflicts +- Package.json, Cargo.toml, pyproject.toml changes +- Environment configuration files +- Build configuration + +### Lock File Conflicts +- package-lock.json +- yarn.lock, pnpm-lock.yaml +- Cargo.lock, poetry.lock + +### Documentation Conflicts +- README updates +- Changelog entries +- Comment modifications + +## Resolution Strategies + +- **Both valid**: Combine both changes when they don't conflict semantically +- **One supersedes**: Choose the more complete or correct change +- **Requires redesign**: When changes are fundamentally incompatible, suggest a new approach +- **Lock files**: Regenerate rather than manually merge diff --git a/skills/fix-merge-conflicts/commands/fix-conflicts.md b/skills/fix-merge-conflicts/commands/fix-conflicts.md new file mode 100644 index 00000000..21a09b9b --- /dev/null +++ b/skills/fix-merge-conflicts/commands/fix-conflicts.md @@ -0,0 +1,22 @@ +# /fix-conflicts + +Resolve git merge conflicts in the current branch. + +## Usage + +``` +/fix-conflicts +/fix-conflicts +``` + +## Examples + +``` +/fix-conflicts +``` +Resolves all merge conflicts in the current working tree. + +``` +/fix-conflicts src/config.ts +``` +Resolves conflicts in a specific file. diff --git a/skills/internationalization/README.md b/skills/internationalization/README.md new file mode 100644 index 00000000..da59fd3e --- /dev/null +++ b/skills/internationalization/README.md @@ -0,0 +1,17 @@ +# Internationalization + +Implement internationalization (i18n) and localization (l10n) support including string extraction, translation management, locale handling, and RTL support. + +## Triggers + +- `/i18n` +- `/internationalize` +- `/add-translations` + +## What It Does + +1. Audits hardcoded strings +2. Sets up i18n framework for your stack +3. Extracts strings to translation files +4. Implements locale-aware formatting +5. Adds RTL language support diff --git a/skills/internationalization/SKILL.md b/skills/internationalization/SKILL.md new file mode 100644 index 00000000..0731a1b8 --- /dev/null +++ b/skills/internationalization/SKILL.md @@ -0,0 +1,69 @@ +--- +name: internationalization +description: Implement internationalization (i18n) and localization (l10n) support including string extraction, translation management, locale handling, and RTL support. +triggers: +- /i18n +- /internationalize +- /add-translations +--- + +# Internationalization + +Add multi-language support and localization capabilities to applications. + +## Process + +1. **Audit current state**: Identify hardcoded strings and locale-dependent code +2. **Set up i18n framework**: Configure appropriate library for the stack +3. **Extract strings**: Move hardcoded text to translation files +4. **Implement locale handling**: Date, number, and currency formatting +5. **Add RTL support**: Right-to-left language layout support + +## Implementation Steps + +### String Extraction +- Find all user-facing strings in code +- Extract to translation files (JSON, YAML, PO) +- Add placeholders for dynamic content +- Handle pluralization rules + +### i18n Libraries by Stack +- React: react-i18next, react-intl +- Vue: vue-i18n +- Angular: @angular/localize +- Node.js: i18next +- Python: gettext, Babel + +### Locale-Dependent Formatting +```javascript +// Numbers +new Intl.NumberFormat('de-DE').format(1234.56) // "1.234,56" + +// Currency +new Intl.NumberFormat('ja-JP', { style: 'currency', currency: 'JPY' }) + +// Dates +new Intl.DateTimeFormat('fr-FR').format(date) // "31/12/2024" +``` + +### RTL Support +- CSS logical properties (margin-inline-start vs margin-left) +- Direction-aware icons +- Bidirectional text handling +- Layout mirroring + +## Best Practices + +- Never concatenate translated strings +- Use ICU message format for complex cases +- Include context for translators +- Test with pseudo-localization +- Consider text expansion (German is ~30% longer than English) + +## Output Format + +Provide: +1. **Audit results**: Hardcoded strings found +2. **Setup guide**: Framework configuration +3. **Code changes**: String extraction and implementation +4. **Translation files**: Structure for translation keys diff --git a/skills/internationalization/commands/i18n.md b/skills/internationalization/commands/i18n.md new file mode 100644 index 00000000..35ad5d0b --- /dev/null +++ b/skills/internationalization/commands/i18n.md @@ -0,0 +1,23 @@ +# /i18n + +Add internationalization support. + +## Usage + +``` +/i18n +/i18n --extract +/i18n --add-locale +``` + +## Examples + +``` +/i18n +``` +Sets up i18n and extracts all translatable strings. + +``` +/i18n --add-locale es-ES +``` +Adds Spanish locale support. diff --git a/skills/keep-docs-updated/README.md b/skills/keep-docs-updated/README.md new file mode 100644 index 00000000..eb268145 --- /dev/null +++ b/skills/keep-docs-updated/README.md @@ -0,0 +1,25 @@ +# Keep Docs Updated + +Keep documentation in sync with code changes. Automatically updates READMEs, API docs, inline comments, and other documentation when code changes are made. + +## Triggers + +This skill is activated by the following commands: + +- `/update-docs` +- `/sync-docs` + +## What It Does + +1. Identifies documentation that's out of sync with code +2. Updates READMEs, API docs, and inline documentation +3. Generates new documentation for undocumented code +4. Keeps examples and tutorials current + +## Documentation Types Handled + +- README files and quick start guides +- API documentation and function signatures +- Inline comments and docstrings +- Usage examples and tutorials +- Configuration documentation diff --git a/skills/keep-docs-updated/SKILL.md b/skills/keep-docs-updated/SKILL.md new file mode 100644 index 00000000..58201fe2 --- /dev/null +++ b/skills/keep-docs-updated/SKILL.md @@ -0,0 +1,49 @@ +--- +name: keep-docs-updated +description: Keep documentation in sync with code changes. Automatically updates READMEs, API docs, inline comments, and other documentation when code changes are made. +triggers: +- /update-docs +- /sync-docs +--- + +# Keep Docs Updated + +Ensure documentation stays current and accurate as code evolves. + +## Process + +1. **Identify documentation gaps**: Compare code changes with existing documentation +2. **Analyze what needs updating**: README, API docs, inline comments, examples, tutorials +3. **Generate updates**: Create accurate, clear documentation that matches the code +4. **Verify accuracy**: Ensure documentation reflects actual behavior + +## Documentation Types + +### README Files +- Project overview and setup instructions +- Usage examples and quick start guides +- Configuration options + +### API Documentation +- Function and method signatures +- Parameter descriptions and types +- Return values and error cases +- Usage examples + +### Inline Documentation +- Code comments explaining complex logic +- JSDoc, docstrings, or language-specific doc formats +- Type annotations + +### Tutorials and Guides +- Step-by-step walkthroughs +- Best practices and patterns +- Migration guides + +## Best Practices + +- Write for your audience (developers, users, operators) +- Include working code examples +- Keep it concise but complete +- Update examples when APIs change +- Document breaking changes prominently diff --git a/skills/keep-docs-updated/commands/update-docs.md b/skills/keep-docs-updated/commands/update-docs.md new file mode 100644 index 00000000..2883bf21 --- /dev/null +++ b/skills/keep-docs-updated/commands/update-docs.md @@ -0,0 +1,28 @@ +# /update-docs + +Update documentation to match code changes. + +## Usage + +``` +/update-docs +/update-docs +/update-docs --type +``` + +## Examples + +``` +/update-docs +``` +Scans recent changes and updates all relevant documentation. + +``` +/update-docs src/api/ +``` +Updates documentation for files in the API directory. + +``` +/update-docs --type readme +``` +Focuses on updating README files only. diff --git a/skills/manage-dependencies/README.md b/skills/manage-dependencies/README.md new file mode 100644 index 00000000..0c4cca4c --- /dev/null +++ b/skills/manage-dependencies/README.md @@ -0,0 +1,17 @@ +# Manage Dependencies + +Manage and upgrade project dependencies including security updates, breaking change handling, and version compatibility. Supports npm, pip, cargo, and other package managers. + +## Triggers + +- `/update-deps` +- `/manage-dependencies` +- `/upgrade-packages` + +## What It Does + +1. Audits outdated packages and security vulnerabilities +2. Plans update strategy based on risk +3. Handles breaking changes in major updates +4. Updates lock files for consistency +5. Validates changes with tests diff --git a/skills/manage-dependencies/SKILL.md b/skills/manage-dependencies/SKILL.md new file mode 100644 index 00000000..8a2367fb --- /dev/null +++ b/skills/manage-dependencies/SKILL.md @@ -0,0 +1,92 @@ +--- +name: manage-dependencies +description: Manage and upgrade project dependencies including security updates, breaking change handling, and version compatibility. Supports npm, pip, cargo, and other package managers. +triggers: +- /update-deps +- /manage-dependencies +- /upgrade-packages +--- + +# Manage Dependencies + +Keep project dependencies up to date, secure, and compatible. + +## Process + +1. **Audit current state**: Review outdated packages and security vulnerabilities +2. **Plan updates**: Identify which packages need updating and in what order +3. **Handle breaking changes**: Address API changes and compatibility issues +4. **Update lock files**: Ensure consistent installations +5. **Validate**: Run tests to verify updates don't break functionality + +## Update Strategies + +### Security Updates (Highest Priority) +- Update packages with known CVEs immediately +- Check transitive dependencies for vulnerabilities +- Verify patches don't introduce regressions + +### Minor/Patch Updates +- Generally safe to batch update +- Review changelogs for unexpected changes +- Run test suite after updates + +### Major Version Updates +- Handle one at a time +- Review migration guides +- Update code for breaking changes +- Test thoroughly + +## Package Manager Support + +### npm/yarn/pnpm +```bash +npm outdated +npm update +npm audit fix +``` + +### pip/uv +```bash +pip list --outdated +pip install --upgrade package +pip-audit +``` + +### cargo +```bash +cargo outdated +cargo update +cargo audit +``` + +## Common Tasks + +### Check for outdated packages +``` +/update-deps --check +``` + +### Update all safe packages (minor/patch) +``` +/update-deps --safe +``` + +### Update specific package with breaking changes +``` +/update-deps lodash@5.0.0 +``` + +### Fix security vulnerabilities +``` +/update-deps --security +``` + +## Output Format + +Provide: +1. **Current state**: List of outdated packages with versions +2. **Update plan**: Prioritized list of updates +3. **Breaking changes**: API changes that need code updates +4. **Code changes**: Fixes for compatibility issues +5. **Validation**: Test results after updates diff --git a/skills/manage-dependencies/commands/update-deps.md b/skills/manage-dependencies/commands/update-deps.md new file mode 100644 index 00000000..67630843 --- /dev/null +++ b/skills/manage-dependencies/commands/update-deps.md @@ -0,0 +1,35 @@ +# /update-deps + +Manage and update project dependencies. + +## Usage + +``` +/update-deps +/update-deps --check +/update-deps --security +/update-deps --safe +/update-deps @ +``` + +## Examples + +``` +/update-deps --check +``` +Lists all outdated packages without making changes. + +``` +/update-deps --security +``` +Updates only packages with known security vulnerabilities. + +``` +/update-deps --safe +``` +Updates all packages to latest minor/patch versions. + +``` +/update-deps react@19.0.0 +``` +Updates a specific package, handling breaking changes. diff --git a/skills/security-review/README.md b/skills/security-review/README.md new file mode 100644 index 00000000..ab04a899 --- /dev/null +++ b/skills/security-review/README.md @@ -0,0 +1,27 @@ +# Security Review + +Perform security-focused code review to identify vulnerabilities, insecure patterns, and security best practice violations. Covers OWASP Top 10, authentication, authorization, data protection, and secure coding practices. + +## Triggers + +This skill is activated by the following commands: + +- `/security-review` +- `/pentest` + +## What It Does + +1. Analyzes code for common vulnerability patterns +2. Reviews authentication and authorization logic +3. Checks for data protection issues +4. Audits dependencies for known vulnerabilities +5. Provides remediation guidance with severity ratings + +## Security Areas Covered + +- Input validation (SQL injection, XSS, command injection) +- Authentication and session management +- Authorization and access control +- Sensitive data handling and encryption +- API security and rate limiting +- Configuration and infrastructure security diff --git a/skills/security-review/SKILL.md b/skills/security-review/SKILL.md new file mode 100644 index 00000000..07e2995f --- /dev/null +++ b/skills/security-review/SKILL.md @@ -0,0 +1,62 @@ +--- +name: security-review +description: Perform security-focused code review to identify vulnerabilities, insecure patterns, and security best practice violations. Covers OWASP Top 10, authentication, authorization, data protection, and secure coding practices. +triggers: +- /security-review +- /pentest +--- + +# Security Review + +Conduct thorough security analysis of code to identify vulnerabilities and security risks. + +## Process + +1. **Threat modeling**: Identify attack surfaces and potential threat vectors +2. **Code analysis**: Review for common vulnerability patterns +3. **Configuration review**: Check for insecure defaults and misconfigurations +4. **Dependency audit**: Identify vulnerable dependencies +5. **Report findings**: Provide actionable remediation guidance + +## Security Checks + +### Input Validation +- SQL injection vulnerabilities +- Cross-site scripting (XSS) +- Command injection +- Path traversal +- XML external entity (XXE) attacks + +### Authentication & Authorization +- Weak authentication mechanisms +- Missing or improper authorization checks +- Session management issues +- Insecure password handling + +### Data Protection +- Sensitive data exposure +- Insufficient encryption +- Insecure data storage +- PII/PHI handling issues + +### API Security +- Broken access control +- Mass assignment vulnerabilities +- Rate limiting gaps +- Improper error handling + +### Infrastructure +- Insecure configurations +- Missing security headers +- TLS/SSL issues +- Container security + +## Output Format + +Provide findings with: +1. **Severity**: Critical, High, Medium, Low, Informational +2. **Location**: File, line, and code snippet +3. **Description**: Clear explanation of the vulnerability +4. **Impact**: Potential consequences if exploited +5. **Remediation**: Specific fix with code examples +6. **References**: CWE, OWASP, or other relevant standards diff --git a/skills/security-review/commands/security-review.md b/skills/security-review/commands/security-review.md new file mode 100644 index 00000000..b6e30dbd --- /dev/null +++ b/skills/security-review/commands/security-review.md @@ -0,0 +1,28 @@ +# /security-review + +Perform a security-focused review of code. + +## Usage + +``` +/security-review +/security-review +/security-review --focus +``` + +## Examples + +``` +/security-review +``` +Reviews the entire codebase for security issues. + +``` +/security-review src/api/auth/ +``` +Focuses security review on authentication code. + +``` +/security-review --focus input +``` +Specifically checks for input validation vulnerabilities. diff --git a/skills/seo-optimization/README.md b/skills/seo-optimization/README.md new file mode 100644 index 00000000..69ad77bf --- /dev/null +++ b/skills/seo-optimization/README.md @@ -0,0 +1,16 @@ +# SEO Optimization + +Analyze and improve website SEO including meta tags, structured data, performance, and content optimization for better search engine rankings. + +## Triggers + +- `/seo-audit` +- `/optimize-seo` + +## What It Does + +1. Audits meta tags and content structure +2. Checks technical SEO requirements +3. Validates and implements structured data +4. Analyzes Core Web Vitals +5. Provides specific code fixes diff --git a/skills/seo-optimization/SKILL.md b/skills/seo-optimization/SKILL.md new file mode 100644 index 00000000..0e822545 --- /dev/null +++ b/skills/seo-optimization/SKILL.md @@ -0,0 +1,62 @@ +--- +name: seo-optimization +description: Analyze and improve website SEO including meta tags, structured data, performance, and content optimization for better search engine rankings. +triggers: +- /seo-audit +- /optimize-seo +--- + +# SEO Optimization + +Improve search engine optimization for better visibility and rankings. + +## Process + +1. **Technical audit**: Check meta tags, structure, and performance +2. **Content analysis**: Review headings, keywords, and content quality +3. **Structured data**: Implement and validate schema markup +4. **Performance**: Ensure Core Web Vitals are met +5. **Implement fixes**: Apply optimizations with code changes + +## SEO Checklist + +### Meta Tags +- Title tags (50-60 characters) +- Meta descriptions (150-160 characters) +- Canonical URLs +- Open Graph tags for social sharing +- Twitter Card tags + +### Content Structure +- Single H1 per page +- Logical heading hierarchy (H1 > H2 > H3) +- Descriptive URLs with keywords +- Internal linking strategy +- Alt text for images + +### Technical SEO +- XML sitemap +- Robots.txt configuration +- HTTPS everywhere +- Mobile-friendly design +- Page speed optimization + +### Structured Data +- Organization schema +- BreadcrumbList +- Article/BlogPosting +- Product (for e-commerce) +- FAQ schema + +### Core Web Vitals +- Largest Contentful Paint (LCP) < 2.5s +- First Input Delay (FID) < 100ms +- Cumulative Layout Shift (CLS) < 0.1 + +## Output Format + +Provide: +1. **SEO score**: Overall health assessment +2. **Critical issues**: Must-fix problems +3. **Improvements**: Recommended optimizations +4. **Code changes**: Specific fixes to implement diff --git a/skills/seo-optimization/commands/seo-audit.md b/skills/seo-optimization/commands/seo-audit.md new file mode 100644 index 00000000..05375118 --- /dev/null +++ b/skills/seo-optimization/commands/seo-audit.md @@ -0,0 +1,22 @@ +# /seo-audit + +Audit and optimize SEO. + +## Usage + +``` +/seo-audit +/seo-audit +``` + +## Examples + +``` +/seo-audit +``` +Performs a comprehensive SEO audit of the site. + +``` +/seo-audit src/pages/blog/ +``` +Focuses on blog page SEO optimization. diff --git a/skills/slack-responder/README.md b/skills/slack-responder/README.md new file mode 100644 index 00000000..ee9c3122 --- /dev/null +++ b/skills/slack-responder/README.md @@ -0,0 +1,19 @@ +# Slack Responder + +Set up an automated Slack responder that monitors channels for engineering questions and requests, then responds with helpful information or takes action on behalf of the team. + +## Triggers + +- `/slack-responder` +- `/setup-slack-bot` + +## What It Does + +1. Monitors Slack channels for trigger phrases +2. Responds to engineering questions +3. Takes action on requests +4. Integrates with OpenHands automations + +## Related Skills + +- [Slack Channel Monitor](../slack-channel-monitor/) - For detailed monitoring setup diff --git a/skills/slack-responder/SKILL.md b/skills/slack-responder/SKILL.md new file mode 100644 index 00000000..0a634764 --- /dev/null +++ b/skills/slack-responder/SKILL.md @@ -0,0 +1,67 @@ +--- +name: slack-responder +description: Set up an automated Slack responder that monitors channels for engineering questions and requests, then responds with helpful information or takes action on behalf of the team. +triggers: +- /slack-responder +- /setup-slack-bot +--- + +# Slack Responder + +Create an automated engineering assistant that monitors Slack and responds to requests. + +## Process + +1. **Configure monitoring**: Set up channels and trigger phrases +2. **Define responses**: Map requests to actions or information +3. **Implement automation**: Create the polling and response workflow +4. **Test and deploy**: Verify the bot works correctly + +## Use Cases + +### Engineering Support +- Answer common questions about the codebase +- Provide links to relevant documentation +- Explain how features work + +### Request Handling +- Respond to @openhands mentions +- Handle on-call handoffs +- Triage incoming requests + +### Automated Actions +- Trigger deployments +- Create tickets from messages +- Generate reports on request + +## Setup Steps + +### 1. Slack App Configuration +- Create a Slack app with appropriate permissions +- Add bot token scopes: `channels:history`, `chat:write` +- Install to workspace + +### 2. Channel Monitoring +- Select channels to monitor +- Configure trigger phrases (e.g., "@openhands", "help:") +- Set polling interval + +### 3. Response Configuration +- Define response templates +- Configure which actions to take +- Set up escalation paths + +### 4. Automation Setup +- Create a cron automation in OpenHands +- Configure the Slack channel monitor skill +- Test with sample messages + +## Integration with OpenHands + +Use the `slack-channel-monitor` skill to: +- Poll up to 10 Slack channels +- Detect trigger phrases +- Start OpenHands conversations for complex requests +- Post responses back to Slack + +See the [Slack Channel Monitor](https://github.com/OpenHands/extensions/tree/main/skills/slack-channel-monitor) skill for detailed setup instructions. diff --git a/skills/slack-responder/commands/slack-responder.md b/skills/slack-responder/commands/slack-responder.md new file mode 100644 index 00000000..8e82a1fa --- /dev/null +++ b/skills/slack-responder/commands/slack-responder.md @@ -0,0 +1,22 @@ +# /slack-responder + +Set up a Slack responder automation. + +## Usage + +``` +/slack-responder +/slack-responder --channels +``` + +## Examples + +``` +/slack-responder +``` +Guides you through setting up a Slack responder bot. + +``` +/slack-responder --channels #engineering,#support +``` +Sets up monitoring for specific channels. diff --git a/skills/triage-incidents/README.md b/skills/triage-incidents/README.md new file mode 100644 index 00000000..8ef95628 --- /dev/null +++ b/skills/triage-incidents/README.md @@ -0,0 +1,17 @@ +# Triage Incidents + +Quickly investigate and triage production incidents by analyzing logs, metrics, and traces. Identifies root causes, suggests fixes, and helps coordinate incident response. + +## Triggers + +- `/triage-incident` +- `/incident` +- `/investigate` + +## What It Does + +1. Gathers context from logs and metrics +2. Traces the error to its root cause +3. Identifies recent changes that may be responsible +4. Proposes immediate and long-term fixes +5. Documents findings for incident reports diff --git a/skills/triage-incidents/SKILL.md b/skills/triage-incidents/SKILL.md new file mode 100644 index 00000000..7c45e978 --- /dev/null +++ b/skills/triage-incidents/SKILL.md @@ -0,0 +1,78 @@ +--- +name: triage-incidents +description: Quickly investigate and triage production incidents by analyzing logs, metrics, and traces. Identifies root causes, suggests fixes, and helps coordinate incident response. +triggers: +- /triage-incident +- /incident +- /investigate +--- + +# Triage Incidents + +Rapidly investigate production incidents to identify root causes and restore service. + +## Process + +1. **Gather context**: Collect error logs, metrics, recent changes +2. **Identify symptoms**: Understand what's failing and how +3. **Trace root cause**: Follow the error chain to the source +4. **Propose fix**: Suggest immediate remediation +5. **Document findings**: Create incident report + +## Investigation Steps + +### 1. Initial Assessment +- What is the impact? (users affected, severity) +- When did it start? +- What changed recently? (deploys, config changes) +- Is it getting worse or stable? + +### 2. Log Analysis +- Search for error messages and stack traces +- Correlate events across services +- Identify the first occurrence +- Look for patterns or spikes + +### 3. Metrics Review +- Check error rates and latency +- Monitor resource utilization (CPU, memory, disk) +- Look for anomalies in traffic patterns +- Review dependency health + +### 4. Recent Changes +- Review recent deployments +- Check configuration changes +- Look for infrastructure changes +- Identify new dependencies + +### 5. Root Cause Categories + +**Code Issues** +- Bugs in recent changes +- Edge cases not handled +- Race conditions + +**Infrastructure** +- Resource exhaustion +- Network problems +- Database issues + +**Dependencies** +- Third-party service outages +- API changes +- Rate limiting + +**Configuration** +- Misconfigured settings +- Missing environment variables +- Permission issues + +## Output Format + +Provide: +1. **Summary**: One-sentence description of the issue +2. **Impact**: Users/systems affected, severity +3. **Root cause**: What's causing the problem +4. **Immediate fix**: Steps to restore service +5. **Long-term fix**: Prevent recurrence +6. **Timeline**: Key events during incident diff --git a/skills/triage-incidents/commands/triage-incident.md b/skills/triage-incidents/commands/triage-incident.md new file mode 100644 index 00000000..3276d8e5 --- /dev/null +++ b/skills/triage-incidents/commands/triage-incident.md @@ -0,0 +1,23 @@ +# /triage-incident + +Investigate a production incident. + +## Usage + +``` +/triage-incident +/triage-incident +/triage-incident --service +``` + +## Examples + +``` +/triage-incident +``` +Investigates the most recent error or alert. + +``` +/triage-incident "500 errors on /api/users" +``` +Investigates a specific error pattern. diff --git a/skills/tune-resources/README.md b/skills/tune-resources/README.md new file mode 100644 index 00000000..2181e730 --- /dev/null +++ b/skills/tune-resources/README.md @@ -0,0 +1,16 @@ +# Tune Resources + +Optimize application memory and CPU usage by analyzing resource consumption patterns, identifying inefficiencies, and implementing performance improvements. + +## Triggers + +- `/tune-resources` +- `/optimize-memory` +- `/optimize-cpu` + +## What It Does + +1. Analyzes code for resource-intensive operations +2. Identifies memory leaks and excessive allocations +3. Finds CPU hotspots and inefficient algorithms +4. Implements targeted optimizations diff --git a/skills/tune-resources/SKILL.md b/skills/tune-resources/SKILL.md new file mode 100644 index 00000000..bcd017ea --- /dev/null +++ b/skills/tune-resources/SKILL.md @@ -0,0 +1,59 @@ +--- +name: tune-resources +description: Optimize application memory and CPU usage by analyzing resource consumption patterns, identifying inefficiencies, and implementing performance improvements. +triggers: +- /tune-resources +- /optimize-memory +- /optimize-cpu +--- + +# Tune Memory and CPU + +Optimize application resource usage for better performance and cost efficiency. + +## Process + +1. **Analyze usage patterns**: Review code for resource-intensive operations +2. **Identify inefficiencies**: Find memory leaks, excessive allocations, CPU hotspots +3. **Implement optimizations**: Apply targeted fixes +4. **Measure improvement**: Validate changes improve resource usage + +## Memory Optimization + +### Common Issues +- Memory leaks from unclosed resources +- Excessive object allocation +- Large data structures held in memory +- Cache without eviction policies +- Circular references preventing garbage collection + +### Optimization Techniques +- Object pooling and reuse +- Lazy loading and pagination +- Stream processing instead of loading all data +- Proper resource cleanup (try-with-resources, context managers) +- Cache size limits and eviction + +## CPU Optimization + +### Common Issues +- Inefficient algorithms (O(n²) when O(n) is possible) +- Unnecessary recomputation +- Blocking operations on main thread +- Excessive string concatenation +- Unoptimized database queries + +### Optimization Techniques +- Algorithm improvements +- Caching computed values +- Async/parallel processing +- Query optimization and indexing +- Batch processing + +## Output Format + +Provide: +1. **Current issues**: Identified resource inefficiencies +2. **Recommendations**: Prioritized list of optimizations +3. **Code changes**: Specific fixes with before/after +4. **Expected impact**: Estimated resource savings diff --git a/skills/tune-resources/commands/tune-resources.md b/skills/tune-resources/commands/tune-resources.md new file mode 100644 index 00000000..0ad8fd48 --- /dev/null +++ b/skills/tune-resources/commands/tune-resources.md @@ -0,0 +1,23 @@ +# /tune-resources + +Optimize memory and CPU usage in the application. + +## Usage + +``` +/tune-resources +/tune-resources --focus +/tune-resources +``` + +## Examples + +``` +/tune-resources +``` +Analyzes the codebase for resource optimization opportunities. + +``` +/tune-resources --focus memory +``` +Focuses on memory optimization only. diff --git a/skills/zero-day-response/README.md b/skills/zero-day-response/README.md new file mode 100644 index 00000000..fbad5cd6 --- /dev/null +++ b/skills/zero-day-response/README.md @@ -0,0 +1,17 @@ +# Zero-Day Response + +Rapidly respond to zero-day vulnerabilities by assessing exposure, implementing mitigations, and applying patches. Designed for urgent security incidents. + +## Triggers + +- `/zero-day` +- `/cve-response` +- `/urgent-vuln` + +## What It Does + +1. Assesses if your codebase is affected +2. Evaluates severity and attack vectors +3. Implements immediate mitigations +4. Applies patches or workarounds +5. Verifies the fix is effective diff --git a/skills/zero-day-response/SKILL.md b/skills/zero-day-response/SKILL.md new file mode 100644 index 00000000..d5455afd --- /dev/null +++ b/skills/zero-day-response/SKILL.md @@ -0,0 +1,61 @@ +--- +name: zero-day-response +description: Rapidly respond to zero-day vulnerabilities by assessing exposure, implementing mitigations, and applying patches. Designed for urgent security incidents. +triggers: +- /zero-day +- /cve-response +- /urgent-vuln +--- + +# Zero-Day Response + +Rapidly assess and respond to critical security vulnerabilities. + +## Process + +1. **Assess exposure**: Determine if and how your codebase is affected +2. **Evaluate impact**: Understand the severity and attack vectors +3. **Implement mitigations**: Apply immediate protective measures +4. **Apply patches**: Update vulnerable components +5. **Verify fix**: Confirm the vulnerability is addressed + +## Response Steps + +### 1. Exposure Assessment +- Search codebase for affected libraries/components +- Check dependency tree for transitive vulnerabilities +- Identify affected code paths and entry points +- Determine if vulnerable code is reachable + +### 2. Impact Analysis +- Review CVE details and CVSS score +- Understand exploitation requirements +- Assess data/systems at risk +- Check for known exploits in the wild + +### 3. Immediate Mitigations +- Disable affected functionality if critical +- Add input validation or sanitization +- Implement WAF rules or network controls +- Enable additional logging/monitoring + +### 4. Patch Application +- Update to patched version if available +- Apply vendor-provided workarounds +- Implement code-level fixes if no patch exists +- Update all affected environments + +### 5. Verification +- Confirm patch addresses the vulnerability +- Test that functionality still works +- Verify mitigations are effective +- Document response actions taken + +## Output Format + +Provide: +1. **Exposure status**: Affected / Not affected / Unknown +2. **Risk assessment**: Critical / High / Medium / Low +3. **Affected components**: List of vulnerable dependencies/code +4. **Recommended actions**: Prioritized response steps +5. **Timeline**: Urgency of each action diff --git a/skills/zero-day-response/commands/zero-day.md b/skills/zero-day-response/commands/zero-day.md new file mode 100644 index 00000000..3f9456ec --- /dev/null +++ b/skills/zero-day-response/commands/zero-day.md @@ -0,0 +1,22 @@ +# /zero-day + +Respond to a zero-day vulnerability. + +## Usage + +``` +/zero-day +/zero-day +``` + +## Examples + +``` +/zero-day CVE-2024-1234 +``` +Assesses exposure to a specific CVE and provides response plan. + +``` +/zero-day "Log4j remote code execution" +``` +Searches for and responds to a described vulnerability.