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

Version 2.2.0 without ua-parser/uap-php #132

Closed
sgehrig opened this issue Feb 6, 2017 · 1 comment
Closed

Version 2.2.0 without ua-parser/uap-php #132

sgehrig opened this issue Feb 6, 2017 · 1 comment

Comments

@sgehrig
Copy link

sgehrig commented Feb 6, 2017

composer.json defines ua-parser/uap-php as a dev-dependency. Since version 2.2.0 (commit #815b5d762ae26db93195abc3c7cc1a9f09f75ee7) NelmioSecurityBundle doesn't work out of the box any more with the default configuration.

This happens because the new configuration setting

nelmio_security:
    csp:
        report_endpoint:
            filters:
                browser_bugs: true # default

requires the ua-parser/uap-php library to be installed. That's somehow inconsistent as the other setting that relies on the ua-parser/uap-php library

nelmio_security:
    csp:
        report/enforce:
            browser_adaptive:
                enabled: false # default

is disabled by default. The solution could be to

  1. disable the browser_bugs filter by default
  2. make the default setting for browser_bugs dependant on the availability of ua-parser/uap-php
  3. require the ua-parser/uap-php library in composer.json

Does this make any sense?

@romainneutron
Copy link
Collaborator

I propose solution 3 in #133

romainneutron added a commit that referenced this issue Feb 7, 2017
Fix #132: Add UAParser to dependencies
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

No branches or pull requests

2 participants