just released tower-surf, a stateless CSRF middleware for tower/axum.
I’ve been working on a side project lately with axum and I was needing a solution for CSRF mitigation. Nothing I found suited my needs, though, so I went ahead and made my own little library. The README explains it all, but it follows the Double Submit Cookie Pattern as laid out by OWASP.
I’d love any feedback anyone has as I still feel pretty new and not confident with rust.
https://github.com/quiet-camp/tower-surf
I also have to give a big shout out to tower-sessions. I was only able to finish this because of how helpful reading its codebase for the last few days has been.