Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid csrf token protection when esi / fragments are not available #265

Open
2 tasks
alexander-schranz opened this issue Aug 28, 2020 · 0 comments
Open
2 tasks
Labels

Comments

@alexander-schranz
Copy link
Member

alexander-schranz commented Aug 28, 2020

Q A
Bug? no
New Feature? no
Bundle Version for 2.x
Sulu Version for 2.x
Browser Version -

Actual Behavior

Currently the SuluFormBundle needs that esi/fragments are enabled else on a cache side the csrf token will error on post request.

Expected Behavior

It should not be needed that esi/fragments need to be enabled, if they are not enabled csrf protection should be disabled.

Steps to Reproduce

Disable esi/fragments (symfony default) and try to submit on a cache side.

Possible Solutions

Detect if disabled and then disable the csrf protection. But it should be able to force csrf protection over:

sulu_form:
    csrf_protection: 'auto' // 'on', 'off'

TODO

  • Make csrf protection based on esi available or not
  • Update Symfony Flex Recipe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant