We take the security of Codesi Programming Language seriously. This document outlines our security policies and how to report vulnerabilities.
| Version | Supported | Security Updates |
|---|---|---|
| 0.0.1 | β Yes | β Active |
Note: We recommend always using the latest stable version for the best security and features.
Codesi has been designed with security in mind:
- No External Dependencies: Zero third-party libraries reduce attack surface
- Safe Evaluation: No use of Python's dangerous
eval()function - Scope Isolation: Proper variable scoping prevents unintended access
- Input Sanitization: File operations validate paths
- Error Handling: Comprehensive exception handling prevents crashes
- Type Safety: Strong type checking at runtime
# Safe file operations
- Path validation
- Permission checking
- Error handling for all file I/O
- No arbitrary code execution# Codesi interpreter
- AST-based interpretation (no eval)
- Sandboxed scope execution
- Controlled function calls
- Safe built-in functions onlyDO NOT create a public GitHub issue for security vulnerabilities.
Instead, report vulnerabilities privately to:
Email: codesilang@gmail.com
GitHub: Send a private security advisory at https://github.com/codesi-lang
Direct Contact: @rishaankgupta
A good security report should include:
## Vulnerability Type
[e.g., Code Injection, Path Traversal, DoS, etc.]
## Affected Version
Codesi version number (e.g., 0.0.1)
## Description
Clear description of the vulnerability
## Steps to Reproduce
1. Create file with: ...
2. Run command: ...
3. Observe: ...
## Impact
What can an attacker do with this?
## Proof of Concept
```codesi
// Minimal code demonstrating the issueIf you have ideas for fixing it
- OS: Windows/macOS/Linux
- Python version: 3.x
- Additional context
### Response Timeline
We aim to respond to security reports within:
- **Acknowledgment**: 48 hours
- **Initial Assessment**: 5 business days
- **Fix Development**: Depends on severity
- **Critical**: 7 days
- **High**: 14 days
- **Medium**: 30 days
- **Low**: Next release
- **Public Disclosure**: After fix is released
### Disclosure Policy
We follow responsible disclosure:
1. **Private Report**: You report the issue privately
2. **Acknowledgment**: We acknowledge receipt
3. **Investigation**: We investigate and develop a fix
4. **Testing**: We test the fix thoroughly
5. **Release**: We release a patched version
6. **Public Disclosure**: We publicly disclose after users have time to update (typically 7-14 days)
7. **Credit**: We credit you (unless you prefer anonymity)
---
## π― Security Vulnerability Categories
### Critical π΄
Vulnerabilities that:
- Allow arbitrary code execution
- Enable privilege escalation
- Expose sensitive data without authentication
- Cause complete system compromise
**Response Time**: Immediate (within 7 days)
### High π
Vulnerabilities that:
- Allow unauthorized data access
- Enable authentication bypass
- Cause significant data loss
- Lead to denial of service
**Response Time**: 14 days
### Medium π‘
Vulnerabilities that:
- Expose limited information
- Require user interaction
- Have limited impact scope
- Affect only specific configurations
**Response Time**: 30 days
### Low π’
Vulnerabilities that:
- Require complex attack chains
- Have minimal real-world impact
- Affect only edge cases
- Are easily mitigated by users
**Response Time**: Next release
---
## π Known Security Considerations
### Current Design Decisions
1. **File System Access**
- Codesi can read/write files with user permissions
- Users should be careful with untrusted `.cds` files
- No privilege escalation possible
2. **REPL Mode**
- Full access to interpreter features
- Runs with current user permissions
- Use caution when running untrusted code
3. **Import System**
- Can import other Codesi files
- Imported files execute with same permissions
- Be cautious with untrusted imports
### Best Practices for Users
```codesi
// β
Safe: Read from controlled locations
content = file_padho("data/config.txt")
// β οΈ Caution: User-provided paths
user_path = input_lo("File path: ")
// Validate before using!
// β Risky: Blindly trusting user input
// Always validate and sanitize!
-
Validate Input
// Always validate user input naam = input_lo("Naam: ") agar (naam.lambai() > 100) { throw {message: "Naam bahut lamba hai"} } -
Check File Paths
// Validate file paths before using karya safe_read(path) { // Check if file exists agar (!file_hai(path)) { throw {message: "File nahi mili"} } vapas file_padho(path) } -
Handle Errors
// Use try-catch for file operations try { content = file_padho("data.txt") } catch (e) { likho("Error:", e.message) }
- Run with Minimal Permissions: Don't run Codesi as root/admin
- Isolated Directories: Use separate directories for untrusted scripts
- Virtual Environments: Use Python virtual environments
- Code Review: Review
.cdsfiles before running - Backup Data: Regular backups before running new scripts
- Date: 2025-10-XX
- Version: 0.0.1
- Reviewer: Rishaank Gupta
- Status: No critical issues found
- β Lexer and tokenizer
- β Parser and AST generation
- β Interpreter execution
- β Built-in functions
- β File I/O operations
- β Scope management
- β Error handling
- Input fuzzing
- Path traversal attempts
- Code injection attempts
- Memory leak testing
- Error handling validation
We appreciate security researchers who help keep Codesi secure.
Security researchers who responsibly disclose vulnerabilities will be:
- Credited in the security advisory (unless they prefer anonymity)
- Listed in our Hall of Fame
- Mentioned in release notes
- Given our sincere thanks!
No reported vulnerabilities yet - be the first!
This security policy may be updated from time to time. Major changes will be announced through:
- GitHub releases
- Repository README
- Security advisories
Last Updated: 2025-10-XX
Version: 0.0.1
Before submitting code that touches security-sensitive areas:
- No use of Python
eval()orexec() - Input validation for all user-provided data
- Path validation for file operations
- Proper error handling with no sensitive info leaks
- No hardcoded credentials or secrets
- Safe defaults for all options
- Documentation of security implications
- No introduction of new dependencies
- Testing for edge cases and attacks
For critical, actively exploited vulnerabilities:
Contact: codesilang@gmail.com (Priority response)
GitHub Security Advisory: https://github.com/codesi-lang
Expected Response: Within 24 hours
- Status: No known vulnerabilities
- Release Date: 2025-10-XX
- Security Improvements: Initial secure implementation
Future vulnerabilities and fixes will be documented here
We believe in:
- Transparency: Open communication about security
- Collaboration: Working together with researchers
- Respect: Treating all reporters with respect
- Responsibility: Quick action on valid reports
- Recognition: Crediting those who help us
Security Team: codesilang@gmail.com
Project Lead: Rishaank Gupta (@rishaankgupta)
GitHub: https://github.com/codesi-lang
Thank you for helping keep Codesi secure! π‘οΈ
Report vulnerabilities responsibly β’ Get recognized β’ Make Codesi safer for everyone