-
Notifications
You must be signed in to change notification settings - Fork 6
Article - API input validation and injection prevention #111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
themattwilliams
wants to merge
26
commits into
main
Choose a base branch
from
mw-security-input-validation
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Created new Security learning center card in cards.ts - Added learn/security/ directory with proper structure - Added comprehensive API design-first security guide article covering TLS, input validation, rate limiting, and access control - Fixed TOC navigation by removing bold formatting from headings - Removed confusing Mermaid diagrams per feedback - Added proper anchor links for deep navigation - Updated sidebars.yaml and created security index page
This article belongs on a separate branch for API testing, not the security branch.
…ization - Split original api-design-first-security-guide.md into 6 focused articles - Remove Redocly branding to create vendor-neutral security content - Add 3 strategic Mermaid diagrams (#4, #5, #7) for visual learning New Articles Created: • learn/security/index.md - Main landing page with article overview • api-tls-encryption-https-best-practices.md - TLS 1.3, HTTPS, mTLS guide • api-input-validation-injection-prevention.md - Schema validation, SQL injection prevention • api-rate-limiting-abuse-prevention.md - DoS protection, rate limiting algorithms • authentication-authorization-openapi.md - JWT, OAuth2, security schemes • api-design-first-security-governance.md - Automated governance, policy-as-code Navigation & UX Improvements: • Updated learn/security/sidebars.yaml with organized article structure • Enhanced pages/learning-center/cards.ts with all 6 security articles • Added strategic cross-links between related security topics • Implemented target='_blank' links to preserve user navigation context • Fixed URLs to use clean paths without .md extensions Content Quality: • Each article SEO-optimized with focused keywords and standalone value • Comprehensive cross-referencing between security domains • Real-world case studies: Heartbleed, Equifax, Facebook phone scraping • Practical code examples and governance rule implementations • Progressive learning path from infrastructure to organizational maturity
- Add originals/redocly.yaml: Clean production version without chunk annotations - Add originals/security-functions.ts: TypeScript implementation of custom security validation functions - Includes 4 advanced security validation functions: checkOperationSecurity, validateAdminSecurity, validateOAuthScopes, validateRateLimitConsistency
- Remove original files from _filesets (moved to originals/ folder) - Update automated-security-validation-walkthrough.md - Add new walkthrough versions: automated-security-validation-walkthrough-v2.md and test-simple-walkthrough.md - Update learning center cards and root redocly.yaml configuration
- Convert SQL injection examples from Python to JavaScript with Express.js - Convert rate limiting algorithms from Python/Go to JavaScript (Token Bucket, Sliding Window, Fixed Window) - Convert authorization monitoring from Python to JavaScript with Express middleware - Convert validation metrics from Python to JavaScript with Map/Set data structures - Convert rate limit testing framework from Python asyncio/aiohttp to JavaScript fetch/Promise.all - Update all tab labels and code block titles to reflect JavaScript - Maintain all security highlighting and educational explanations - Provide consistent Node.js developer experience across all security articles
- Changed 'pages:' to 'items:' in sidebars.yaml to match Redocly syntax - All security articles now display correctly in left navigation menu - Fixed sidebar configuration for API Security Fundamentals group
- Delete api-design-first-security-guide.md (replaced by focused individual articles) - Remove from sidebars.yaml navigation - Update main landing page title to 'Framework and Fundamentals' instead of 'Complete Guide' - Cleaner navigation with 5 focused security articles + landing page + walkthrough
- Delete automated-security-validation-walkthrough.md (temporarily removed) - Update sidebars.yaml to remove walkthrough from navigation - Final security learning center now has 5 focused articles + landing page
- Comprehensive guide with SQL injection prevention patterns - Mass assignment protection strategies - OpenAPI schema validation enforcement - OWASP API Security Top 10 coverage - Node.js code examples with security highlighting - Parameterized queries and validation patterns - Tabbed code organization and internal linking - Quick Start Guide for immediate implementation
- Changed all headings from title case to sentence case - Addresses @adamaltman review comment on PR #109
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
Comprehensive guide to preventing injection attacks through proper input validation and OpenAPI schema enforcement.
Article Details
Key Features
Dependencies
Preview
Once deployed, preview at: https://[preview-url]/learn/security/api-input-validation-injection-prevention