Skip to content

Conversation

@alecasg555
Copy link

Updates

  • Affected products

Comments

Mitigation Solution: safe-expr-eval

I've developed safe-expr-eval as a secure drop-in replacement that completely addresses CVE-2025-12735 while maintaining 100% API compatibility with expr-eval.

Why safe-expr-eval is secure:

No eval() - Never uses JavaScript's dangerous eval() function
No Function constructor - Doesn't dynamically create executable code
Token-based parsing - Expressions are parsed into safe tokens and evaluated in a controlled environment
Type-safe - Built with TypeScript for additional security guarantees
Zero dependencies - Minimal attack surface

Migration is trivial:

// Before (vulnerable)
const { Parser } = require('expr-eval');

// After (secure)
const { Parser } = require('safe-expr-eval');

// That's it! All your existing code works unchanged.

@github-actions github-actions bot changed the base branch from main to alecasg555/advisory-improvement-6479 November 27, 2025 15:52
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.

2 participants