Skip to main content

a privileges app for Django

Project description

privileges makes segmenting authenticated users easy and extensible.

Unlike Django permissions, privileges is not tied to operations on individual models. It operates at a higher level of abstraction and is instead concerned more with providing the site developer complete freedom in determining who can do what. There certainly is some overlap with the built in permissions system, and while you could use privileges to replace it, at least large parts of it, that is not the aim of this app.

Instead, think of privileges allowing the site developer to control access to certain features. Operating at the template and view layers the site developer can paint as broad or as fine of strokes to suit their needs.

It is extensible in the sense that the site developer can define and register their own privilege validation handlers. In fact they must define at least one handler. There is a template tag for checking privileges in templates and a decorator for checking privileges when a view is called.

There is a model that stores the named privileges which are nothing more than named slugs. The records carry no special meeting to privileges in isolation but depend on the site developer to impart meaning through reference in his site.

Sponsorship

development sponsored by Midwest Communications

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

privileges-0.1.tar.gz (9.9 kB view details)

Uploaded Source

File details

Details for the file privileges-0.1.tar.gz.

File metadata

  • Download URL: privileges-0.1.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for privileges-0.1.tar.gz
Algorithm Hash digest
SHA256 ea18cfefb617e0cebc83c9500b1c43d239e03d98e9e70e023d068d51b5857da8
MD5 ffa835799870c8b7e3d56258402164ff
BLAKE2b-256 1c760adaf30f08c61fabcbb8807e9c807ae2980bf861b6cc8b429ebc8156e6ab

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page