Skip to content

Comments

Access control#340

Merged
dcramer merged 5 commits intogetsentry:masterfrom
lincolnloop:access-control
Feb 6, 2012
Merged

Access control#340
dcramer merged 5 commits intogetsentry:masterfrom
lincolnloop:access-control

Conversation

@bkonkle
Copy link
Contributor

@bkonkle bkonkle commented Feb 6, 2012

This adds the SENTRY_ALLOW_ORIGIN setting, which will set Access-Control-Allow-Origin and Access-Control-Allow-Headers on the /api/store/ url to allow cross-domain requests. This enables JavaScript cross-domain error reporting without having to deal with jsonp.

Setting SENTRY_ALLOW_ORIGIN to "*" will allow cross-domain requests from any domain.

Setting SENTRY_ALLOW_ORIGIN to a specific domain will only allow cross-domain requests from that domain.

https://developer.mozilla.org/En/HTTP_access_control#Simple_requests

This also fixes a minor bug in _get_rendered_interfaces() which will cause it to error out if there is a problem with interface.to_html(), since the html variable is not defined in that case.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we put a default in the "defaults.py" file, then we dont have to use getattr here

dcramer added a commit that referenced this pull request Feb 6, 2012
@dcramer dcramer merged commit 5f70b52 into getsentry:master Feb 6, 2012
@github-actions github-actions bot locked and limited conversation to collaborators Dec 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants