fix: use constant-time comparison for HMAC verification (#522)#523
Conversation
Replace non-constant-time === operator with crypto.timingSafeEqual() to prevent timing side-channel attacks on HMAC signature verification. Fixes node-saml#522
WalkthroughSecurity fix in Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used🧠 Learnings (2)📓 Common learnings📚 Learning: 2025-10-22T21:50:05.454ZApplied to files:
🧬 Code graph analysis (1)src/signature-algorithms.ts (1)
🔇 Additional comments (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Replace non-constant-time === operator with crypto.timingSafeEqual() to prevent timing side-channel attacks on HMAC signature verification.
Fixes #522
Summary by CodeRabbit