Changes between Version 6 and Version 7 of TracPermissionFilterPlugin


Ignore:
Timestamp:
Nov 9, 2015, 1:40:52 PM (8 years ago)
Author:
figaro
Comment:

Cosmetic changes

Legend:

Unmodified
Added
Removed
Modified
  • TracPermissionFilterPlugin

    v6 v7  
    55== Description
    66
    7 Plugin to remove Trac permissions using a blacklist and/or a whitelist.
     7This plugin allows you to remove Trac permissions using a blacklist and/or a whitelist.
    88
    99This hack was born to be able to ''archive'' projects without touching the Trac database, the idea is to use the filter to disable all permissions that allow users to modify it without changing their permissions on the database and be able to restore the project to the original state simply disabling the filter.
     
    1313The process is as follows:
    1414
    15  1. If the `blacklist` is available and the permission being considered is on the list the `check_permission` function returns `False` and the
    16     permission evaluation stops.
     15 1. If the `blacklist` is available and the permission being considered is on the list the `check_permission` function returns `False` and the permission evaluation stops.
    1716 1. If the `whitelist` is available and the permission we are checking is not on the list the `check_permission` function returns `False` and the permission evaluation stops.
    1817 1. If the evaluation gets here the permission is ignored by the plugin and the next permission policy is checked.
     
    2625
    2726If you have any issues, create a
    28 [http://trac-hacks.org/newticket?component=TracPermissionFilterPlugin&owner=sto new ticket].
     27[/newticket?component=TracPermissionFilterPlugin new ticket].
    2928
    3029[[TicketQuery(component=TracPermissionFilterPlugin&group=type,format=progress)]]
     
    3231== Download
    3332
    34 Download the zipped source from [download:tracpermissionfilterplugin here].
     33Download the zipped source from [export:tracpermissionfilterplugin here].
    3534
    3635== Source
    3736
    38 You can check out TracPermissionFilterPlugin from [http://trac-hacks.org/svn/tracpermissionfilterplugin here] using Subversion, or [source:tracpermissionfilterplugin browse the source] with Trac.
     37You can check out TracPermissionFilterPlugin from [/svn/tracpermissionfilterplugin here] using Subversion, or [source:tracpermissionfilterplugin browse the source] with Trac.
     38
     39== Installation
     40
     41General instructions on installing Trac plugins can be found on the [TracPlugins#InstallingaTracplugin TracPlugins] page.
    3942
    4043== Configuration
    4144
    42 After enabling the plugin in your `trac.ini`:
     45After enabling the plugin in your `trac.ini` file:
    4346
    44 {{{
    45 #!ini
     47{{{#!ini
    4648[components]
    4749tracpermissionfilter.* = enabled
     
    5052Add a section with the list of permissions to allow:
    5153
    52 {{{
    53 #!ini
     54{{{#!ini
    5455[permission-filter]
    5556whitelist = BROWSER_VIEW,CHANGESET_VIEW,FILE_VIEW,LOG_VIEW,MILESTONE_VIEW,REPORT_SQL_VIEW,REPORT_VIEW,ROADMAP_VIEW,SEARCH_VIEW,TICKET_VIEW,TIMELINE_VIEW,WIKI_VIEW
     
    5859or a list of permissions to deny:
    5960
    60 {{{
    61 #!ini
     61{{{#!ini
    6262[permission-filter]
    6363blacklist = BROWSER_VIEW
     
    6868The plugin has also an additional boolean option called `adminmeta`. If this option is set to True (the default), then the filters don't affect the users with `TRAC_ADMIN` permission:
    6969
    70 {{{
    71 #!ini
     70{{{#!ini
    7271[permission-filer]
    7372adminmeta = true
     
    7877Lastly, remember to put the filter the first on your project `permission_policies`:
    7978
    80 {{{
    81 #!ini
     79{{{#!ini
    8280[trac]
    8381permission_policies = PermissionFilter, DefaultPermissionPolicy