Guides
What's New in m1f v3.2
New features and improvements in m1f version 3.2
import Callout from β@/components/ui/Callout.astroβ;
Version 3.2 brings game-changing security enhancements, blazing-fast performance improvements, and powerful new configuration options to the m1f toolkit. Letβs explore what makes this release special!
π Performance Boost: Now 3-5x Faster!
Parallel Processing by Default
No configuration needed β m1f now automatically processes files in parallel, delivering:
- 3-5x speed improvements for large file sets
- Smart batch size optimization
- Thread-safe deduplication
- Deterministic output ordering
Memory Efficiency
- Stream-based checksum calculation reduces memory usage by 50%
- Handles massive files without breaking a sweat
- 8KB chunk processing prevents out-of-memory errors
π Enterprise-Grade Security
Comprehensive Protection Suite
Version 3.2 takes security seriously with multiple layers of protection:
Path Traversal Protection
Validates all file paths to prevent directory traversal attacks. Your files stay where they belong.
SSRF Protection
Blocks access to private networks and cloud metadata endpoints:
- Private IP ranges (10.x.x.x, 172.16.x.x, 192.168.x.x)
- Localhost and link-local addresses
- Cloud metadata endpoints (169.254.169.254)
Automatic robots.txt Compliance
All web scrapers now respect robots.txt β no configuration needed! This keeps you compliant with website policies automatically.
SSL/TLS Validation
SSL certificate validation is now enabled by default, protecting against man-in-the-middle attacks.
Security Modes
Choose how m1f handles potential security issues:
# Stop on security issues (default)
m1f -s ./src -o bundle.txt --security-check error
# Log warnings but continue
m1f -s ./src -o bundle.txt --security-check warn
# Skip security scanning (not recommended)
m1f -s ./src -o bundle.txt --security-check skip
β¨ New Configuration Options
Content Deduplication Control
Sometimes you need duplicate files preserved:
# Keep all duplicate files
m1f -s ./project -o output.txt --allow-duplicate-files
Encoding Flexibility
Working with legacy systems? Control UTF-8 preference:
# Disable UTF-8 preference for legacy encodings
m1f -s ./legacy -o output.txt --no-prefer-utf8-for-text-files
Enhanced Preset System
Configure everything in your preset files:
name: "My Project v3.2"
version: "3.2"
settings:
enable_content_deduplication: true
prefer_utf8_for_text_files: true
security_check: error
include_patterns:
- "src/**/*.{js,ts,jsx,tsx}"
- "**/*.md"
per_file_settings:
"*.min.js":
processors:
- minify_content
π Breaking Changes & Migration
1. Simplified File Separators
The file separator format has been streamlined:
- Before:
=== path/to/file.txt === SHA256: abc123...
- After:
=== path/to/file.txt ===
2. SSL Validation Default
SSL validation is now enabled by default. For sites with self-signed certificates:
m1f-scrape https://internal-site.com -o ./output --ignore-https-errors
3. Security Scanning Default
Security scanning now stops on sensitive data detection by default. To migrate smoothly:
# Use warn mode during migration
m1f -s . -o bundle.txt --security-check warn
π Performance Benchmarks
Real-world improvements youβll experience:
Operation | v3.1 | v3.2 | Improvement |
---|---|---|---|
1000+ files bundling | 30s | 8s | 3.75x faster |
Large file processing | 2GB RAM | 1GB RAM | 50% less memory |
s1f extraction | 20s | 10s | 2x faster |
π‘οΈ Security Audit Results
Version 3.2 passes all security audits with flying colors:
- β Path traversal vulnerabilities eliminated
- β SSRF protection implemented
- β Command injection prevented
- β SSL validation enforced
- β robots.txt compliance automatic
- β JavaScript execution validated
π‘ Quick Examples
Modern Web Project Bundle
# Automatic parallel processing with security checks
m1f -s ./src -o dist/bundle.txt --preset modern-web.yml
Legacy System Migration
# Handle legacy encodings and preserve duplicates
m1f -s ./legacy -o migration.txt \
--allow-duplicate-files \
--no-prefer-utf8-for-text-files \
--security-check warn
Secure Web Scraping
# Automatic robots.txt compliance and SSL validation
m1f-scrape https://docs.example.com -o ./scraped
π Related Documentation
- Security Best Practices - Keep your bundling secure
- CLI Reference - Complete command documentation
- Preset Configuration - Master the preset system
- Troubleshooting Guide - Solve common issues
π― Get Started
Ready to experience the speed and security of v3.2? Update your m1f installation:
pip install --upgrade m1f
Then try the new features:
# Experience the speed boost (parallel processing is automatic!)
m1f -s . -o bundle.txt
# Try the new security features
m1f -s ./project -o secure-bundle.txt --security-check error
Questions? Check our troubleshooting guide or reach out to the community. Happy bundling! π