Skip to content
This repository has been archived by the owner. It is now read-only.

Some 500 responses to /_/csp-violation #4031

Closed
shane-tomlinson opened this issue Aug 10, 2016 · 9 comments
Closed

Some 500 responses to /_/csp-violation #4031

shane-tomlinson opened this issue Aug 10, 2016 · 9 comments
Labels

Comments

@shane-tomlinson
Copy link
Member

@shane-tomlinson shane-tomlinson commented Aug 10, 2016

From Kibana:

screen shot 2016-08-10 at 09 16 52

Nothing stands out to me that would cause an exception with the route.

Attaching a heart to this because 500 responses cause stress, spurious ones even more so.

@philbooth
Copy link
Contributor

@philbooth philbooth commented Aug 10, 2016

Not sure how likely it is in reality, but the thing that stands out to me is dereferencing report without checking whether it was in in the request body. If it's not set for any reason we should return a 400 error.

@shane-tomlinson
Copy link
Member Author

@shane-tomlinson shane-tomlinson commented Aug 10, 2016

Not sure how likely it is in reality, but the thing that stands out to me is dereferencing report without checking whether it was in in the request body.

I initially thought that too until I noticed the line that checks whether the request is well-formatted.

Does returning false cause a 500?

@vladikoff
Copy link
Contributor

@vladikoff vladikoff commented Aug 11, 2016

We already do res.json({result: 'ok'}); so either this error happened when the content server was updating / down or the request was malformed in such a way that Express was not able to process it properly (could be the size of the request)

@vladikoff
Copy link
Contributor

@vladikoff vladikoff commented Aug 22, 2016

need to check the kibana dashboard to see how many of these we are getting

@jrgm
Copy link
Contributor

@jrgm jrgm commented Sep 23, 2016

Yeah, see the other bug. String.length !== String "byteLength".

@vladikoff
Copy link
Contributor

@vladikoff vladikoff commented Sep 26, 2016

trigger a csp warning with a script sample that has unicode characters.
dxr has code that truncates the script sample.

@vladikoff
Copy link
Contributor

@vladikoff vladikoff commented Sep 26, 2016

from mtg: on the server we can parse the content and not use the bodyParser.

@jrgm
Copy link
Contributor

@jrgm jrgm commented Oct 13, 2016

I think there is a fix for this pending in Gecko - https://bugzilla.mozilla.org/show_bug.cgi?id=1307321

@shane-tomlinson
Copy link
Member Author

@shane-tomlinson shane-tomlinson commented Oct 13, 2016

Closing as "this is firefox's fault"

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants