slimphp / Slim-Csrf

Slim Framework CSRF protection middleware
MIT License
338 stars 58 forks source link

How to integrate slim-session #114

Closed Regaddi closed 4 years ago

Regaddi commented 4 years ago

Hey!

I'd like to integrate slim-csrf (v0.8.3) with https://github.com/bryanjhv/slim-session (v3.0). It seems that slim-csrf directly accesses $_SESSION, but I'd need it to utilize new \SlimSession\Helper() instead. Is this achievable? I'd like to avoid having to upgrade my complete application from slim3 to slim4.

Thanks in advance!

l0gicgate commented 4 years ago

You can provide your own storage from within the Guard constructor or via the Guard::setStorage() method.