songkick / oauth2-provider

Simple OAuth 2.0 provider toolkit
MIT License
529 stars 148 forks source link

[ET][86656556] freezing response_headers #80

Closed Ebtoulson closed 9 years ago

Ebtoulson commented 9 years ago

Freezing the RESPONSE_HEADERS would help prevent unintended modifications. While this constant should definitely be merged into the headers, if someone ever did:

request.headers = @oauth2.response_headers The request.headers would become a pointer to the constant, so adding or modifying any headers after this would actually modify the constant