Changes between Version 3 and Version 4 of ProtectedMacro


Ignore:
Timestamp:
Dec 22, 2008, 8:01:30 AM (6 years ago)
Author:
frayja
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ProtectedMacro

    v3 v4  
    33== Description ==
    44
    5 With this plugin certain parts of a wiki page can be shielded from reading.
     5With the TracProtected macro it is possible to limit access to parts of a wiki page.
    66
    7 There are four explicit permissions. PROTECTED_VIEW, PROTECTED_RED_VIEW, PROTECTED_BLUE_VIEW, and PROTECTED_GREEN_VIEW. Each of these permissions allows view access to different parts (as seen in the examples below)
     7A protected part has the following syntax:         
     8{{{
     9{{{                                               
     10#!protected                                       
     11#:This is what an unauthorized user sees (optional)
     12This is what an authorized user sees               
     13}}}
     14}}}                                               
    815
    9 A #!protected part will be rendered with a red line to the left, a #!protected-blue part will be rendered with a blue line to the left, etc.
     16A protected part can use !protected, !protected-red,
     17!protected-blue, or !protected-green to provide access           
     18restrictions on different levels. Users will only see these       
     19protected sections when they have the permissions                 
     20"PROTECTED_VIEW", "PROTECTED_RED_VIEW", "PROTECTED_BLUE_VIEW", or
     21"PROTECTED_GREEN_VIEW", respectively.                             
     22
     23A #!protected part will be rendered with a red line to the left, a
     24#!protected-blue part will be rendered with a blue line to the
     25left, etc.
     26
     27Attachments are protected when the key-string "!protected",   
     28"!protected-red", "!protected-blue", or "!protected-green" is
     29present in the attachment's description.                     
     30                                                             
     31To enable the attachment protection the conf/trac.ini must be
     32modified. Add the ProtectedAttachmentPolicy to the           
     33permission_policies:                                         
     34{{{
     35[trac]                                                                 
     36permission_policies = ProtectedAttachmentPolicy, DefaultPermissionPolicy
     37}}}
    1038
    1139Note: a user who is allowed to edit the wiki page will always be able to see (and edit) protected parts.
     
    1543 * Supply an admin feature to add/edit protected-xxx
    1644 * Supply an admin feature to edit the style/template for a permission part
     45 * Give visual feedback for unauthorized attachments in the attachment list
    1746
    1847== Bugs/Feature Requests ==