Skip to content

[Aikido] AI Fix for Path traversal attack possible - #62

Closed
aikido-autofix[bot] wants to merge 1 commit into
mainfrom
fix/aikido-security-sast-190129094-cjvi
Closed

aikido-autofix[bot] wants to merge 1 commit into
mainfrom
fix/aikido-security-sast-190129094-cjvi

Conversation

@aikido-autofix

Copy link
Copy Markdown

This patch mitigates path traversal vulnerability on line 13 by validating the path parameter to reject null values and paths containing ".." before passing it to File.ReadAllText.

✅ 1 issue fixed by this PR, including 1 critical 🚨 issue
Issue Severity           Description
Sast#1028212471
🚨 CRITICAL
A malicious actor could control the location of this file, to include going backwards up a directory by adding '../' to the input.

High confidence: Aikido has a robust set of benchmarks for similar fixes, and they are proven to be effective.

@sonarqubecloud

Copy link
Copy Markdown

@manuc66

manuc66 commented Nov 19, 2026

Copy link
Copy Markdown
Owner

Superseded by 35f5267 on main. CHeaderDoc.FromFile no longer exists: the parser now takes header text and the generator reads the checkout once, through a path confined to the repository root (src/Shared/BuildPath.cs). That removes the sink instead of rejecting '..' on it, and the generated bindings were re-checked byte for byte.

@manuc66 manuc66 closed this Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant