Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
django-urldecorators
Advanced tools
Django-urldecorators is a reusable Django application which allows apply view decorators and middleware components depending on requested url.
This project is archived. It is no longer updated or maintained.
Django-urldecorators is a reusable Django application which allows apply view decorators and middleware components based on a requested URL.
This library is compatible with Django 1.4 and later. If you need to use older Django versions (which receive no security updates or bugfixes) you can install 0.4 version of django-urldecorators.
Run python setup.py install
or add the urldecorators
module to
your PYTHONPATH
(or use pip or easy_install).
In urls.py
file replace from django.conf.urls import url, include
by from urldecorators import url, include
Pass a list of decorators and/or middleware_classes as an argument
to the url
function.
Example urls.py file: ::
from urldecorators import url, include
urlpatterns = [
url(r'^private/$', include('example.private.urls'),
decorators=['django.contrib.auth.decorators.login_required']),
url(r'^articles/$', include('example.articles.urls'),
middleware_classes=['django.middleware.cache.CacheMiddleware']),
]
For the example configuration and usage see the example project included
in the repository. It can be run using django-admin.py
utility from the
repository root: ::
$ django-admin.py syncdb --settings=example.settings --pythonpath="$PWD"
$ django-admin.py createsuperuser --settings=example.settings --pythonpath="$PWD"
$ django-admin.py runserver --settings=example.settings --pythonpath="$PWD"
Django-urldecorators is tested with Django versions from 1.4 to 1.11 but
it does not support patterns function <https://docs.djangoproject.com/en/1.11/releases/1.8/#django-conf-urls-patterns>
_
from ancient Django versions.
Both Python 2 and Python 3 are supported.
Application tests can run using tox
: ::
$ tox
FAQs
Django-urldecorators is a reusable Django application which allows apply view decorators and middleware components depending on requested url.
We found that django-urldecorators demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.