-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
fix: Prevent sensitive information from being logged #14779
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
base: master
Are you sure you want to change the base?
Conversation
- Add no_log: true to OpenSSL commands that contain passwords/passphrases - Add no_log: true to WireGuard key generation commands - Add no_log: true to password/CA password generation tasks - Add no_log: true to AWS credential handling tasks - Add no_log: true to QR code generation that contains full configs This prevents sensitive information like passwords, private keys, and WireGuard configurations from being logged to syslog/journald. Fixes #1617
- Add no_log directives to all cloud provider credential handling - Set privacy-focused defaults (StrongSwan logging disabled, DNSCrypt syslog off) - Implement privacy role with log rotation, history clearing, and log filtering - Add Privacy Considerations section to README - Make all privacy features configurable and enabled by default This update significantly reduces Algo's logging footprint to enhance user privacy while maintaining the ability to enable logging for debugging when needed.
- Remove Privacy Considerations section from README - Add expanded 'Does Algo support zero logging?' question to FAQ - Better placement alongside existing logging/monitoring questions - More detailed explanation of privacy features and limitations
The privacy-monitor.sh.j2 template was using '| bool' which is not a valid Jinja2 filter. The 'bool' is a built-in Python function, not a Jinja2 filter. Fixed by removing the '| bool' filter and directly outputting the boolean variables as they will be rendered correctly by Jinja2. This resolves the template syntax error that was causing CI tests to fail: "No filter named 'bool'" error in privacy monitoring script template. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
I'm not fully happy with the documentation for this PR yet. Will fix soon. |
Claude finished @dguido's task —— View job PR Review - Privacy and Security Enhancements
I'll conduct a comprehensive review of this privacy-focused PR, examining code quality, security, and implementation approach. Review Checklist:
Overall Assessment: Strong Implementation 🟢This PR delivers a well-architected, security-focused privacy enhancement that aligns perfectly with Algo's mission. The "surgical privacy filtering" approach is exactly right - hiding user activity while preserving operational debugging capabilities. The implementation is comprehensive, conservative, and properly tested. ✅ Strengths1. Excellent Architecture & Design
2. Robust Security Implementation
3. Excellent Code Quality
4. User Experience Excellence
|
e4b6849
to
fa77f7d
Compare
- Resolved conflicts in cloud provider prompt files - Updated to use new Ansible crypto modules from master - Added no_log directives to sensitive Ansible crypto tasks - Preserved privacy enhancements from the branch
fa77f7d
to
540b250
Compare
Summary
This PR implements surgical privacy filtering for Algo VPN, providing a privacy-conscious approach that hides user activity while preserving debugging capabilities. The implementation prioritizes Algo's core mission as a security tool while offering reasonable privacy improvements.
Philosophy: Security-First Privacy
Key Principle: Algo is more about security than privacy. This implementation:
Problem Addressed
Originally reported in #1617, analysis revealed broader privacy concerns:
Implementation Details
1. Comprehensive Credential Protection
Added
no_log: true
with documentation to 50+ tasks across all components:Cloud Providers (All supported providers):
VPN Components:
2. Surgical Privacy Filtering (
roles/privacy/
)Smart Log Filtering - Hides user activity, keeps operational data:
Enhanced IPv4/IPv6 Pattern Matching:
What's Hidden:
What's Preserved (Documented Security Patterns):
3. Privacy-Aware Service Configuration
StrongSwan Logging (Fixed Critical Issue):
DNS Privacy (Already Well-Implemented):
privacy_enhanced: true
4. Robust Configuration System
Main Configuration (
config.cfg
):Advanced Privacy Features (Optional):
5. Security Hardening & Code Quality
Strengthened Regex Patterns:
Code Quality Improvements:
Secure Defaults:
algo_no_log | default(true)
6. Comprehensive Testing & Quality
Test Coverage:
Quality Assurance:
Configuration Examples
Default (Recommended):
Maximum Privacy:
Debugging Mode:
Testing Instructions
Verify Privacy Protection:
Test VPN Functionality:
Impact Assessment
✅ Security Benefits
✅ Preserved Functionality
✅ Privacy Improvements
Code Review Addressed
Recent code review feedback has been comprehensively addressed:
1. CRITICAL: StrongSwan Log Level ✅ FIXED
2. Regex Pattern Improvements ✅ ENHANCED
(?:[0-9]{1,3}\.){3}[0-9]{1,3}
for better validation[0-9a-fA-F:]+::[0-9a-fA-F:]+
patterns3. DNS Privacy ✅ ALREADY WELL-IMPLEMENTED
Backward Compatibility
config.cfg
files work unchangedThis implementation balances Algo's security-first mission with reasonable privacy improvements, ensuring users get both strong VPN security and protection from credential exposure while maintaining the debugging capabilities essential for a reliable VPN service.
Fixes #1617