https://github.com/ccnmtl/whitelistaffilmapper
djangowind plugin
https://github.com/ccnmtl/whitelistaffilmapper
Last synced: 9 months ago
JSON representation
djangowind plugin
- Host: GitHub
- URL: https://github.com/ccnmtl/whitelistaffilmapper
- Owner: ccnmtl
- Created: 2014-07-15T19:38:58.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2018-12-05T19:03:45.000Z (over 7 years ago)
- Last Synced: 2025-04-12T06:44:58.557Z (about 1 year ago)
- Language: Python
- Size: 1.95 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.markdown
Awesome Lists containing this project
README
makes sure that the user is in a Group for every wind affil,
autovivifying Groups if necessary.
In contrast to the djangowind default, this only
bothers with affils in a whitelist.
This is useful for, eg, internal apps where
course affils don't matter and would only clutter the system.
In that case, we can whitelist just 'tlcxml' or similar
important unix group affils.
in your `settings_shared.py` you normally would have something like:
WIND_AFFIL_HANDLERS = ['djangowind.auth.AffilGroupMapper',
'djangowind.auth.StaffMapper',
'djangowind.auth.SuperuserMapper']
To use this, just change it to:
WIND_AFFIL_HANDLERS = ['whitelistaffilmapper.WhitelistAffilGroupMapper',
'djangowind.auth.StaffMapper',
'djangowind.auth.SuperuserMapper']
AFFIL_WHITELIST = ['tlcxml.cunix.local:columbia.edu', ]