ucdavis / payments

Accept and process credit card payments on campus
MIT License
2 stars 3 forks source link

Fix CSP Report #274

Closed srkirkland closed 4 years ago

srkirkland commented 4 years ago

CSP Report has always been broken -- the JSON format wasn't handled by the parser but more importantly the content-type for CSP reports isn't application/json so that requires modifying the default input formatter.

sprucely commented 4 years ago

Not firing on all cylinders today. How does one go about triggering a csp-report? Postman is not cooperating.

srkirkland commented 4 years ago

Not firing on all cylinders today. How does one go about triggering a csp-report? Postman is not cooperating.

I just triggered it by changing the CSP to have a failure, like commenting out the line which allows us to use google-analytics for example. I'm not sure of a good way to do it artificially though I would think postman should work as long as you get the weird content-type correct.

srkirkland commented 4 years ago

closes #273