A middleware to ensure only Sentry can access source maps
Project description
django-sentry-secure-source-map
A middleware to ensure only Sentry can access source maps.
When enabled, only requests from Sentry will be able to access source maps (any URL starting with STATIC_URL and ending .map).
For more information, see Secure Access to Source Maps
Installation
pip install django-sentry-secure-source-map
Then add sentry_secure_source_map.SentrySecureSourceMapMiddleware to your MIDDLEWARE in settings.py. Ideally, it should be placed as high as possible, before tools like whitenoise.
Next, you need to configure the token. Retrieve your project's "Security Token" from the settings page, and set it as SENTRY_SECURITY_TOKEN.
SENTRY_SECURITY_TOKEN = "abcde12345"
If the token isn't set, the middleware does nothing.
"Enable JavaScript source fetching" must be enabled in Sentry.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django_sentry_secure_source_map-0.2.0.tar.gz.
File metadata
- Download URL: django_sentry_secure_source_map-0.2.0.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
268b684028d2fe4a8f62e267534d528262b9eac1a8e804be635440f05ff14e43
|
|
| MD5 |
4176f6262b73915ce422439d8af0f894
|
|
| BLAKE2b-256 |
a97a64955e8c45162da2861b6f9fc4464a5cfa79dfd386786b91944365a2ad17
|
File details
Details for the file django_sentry_secure_source_map-0.2.0-py3-none-any.whl.
File metadata
- Download URL: django_sentry_secure_source_map-0.2.0-py3-none-any.whl
- Upload date:
- Size: 3.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6be1874cffcdd30f2206e343628aa4e43649a4bcabf44a4312d13318d0c35481
|
|
| MD5 |
ee2c5293537b06f1e8bb8a718219873a
|
|
| BLAKE2b-256 |
906e91276d6383b33a3c97f457adafafdb812810c53aa4ff36dbaa27b3808788
|