trac-ticketlinks / wiki-default / TracPermissions

== Trac Permissions ==

Trac uses a flexible permission system to control what different users can do
in the system.

When a user first uses a system he/she will be able to do certain things. 
Exactly what he/she can do depend on which privileges you have granted to
the special user {{{anonymous}}}.
In addition to these privileges different users can be granted additional 
rights as soon as they login into the system.

=== Available privileges ===

 * {{{LOG_VIEW}}}
 * {{{FILE_VIEW}}}
 * {{{CHANGESET_VIEW}}}
 * {{{BROWSER_VIEW}}}
 * {{{TICKET_VIEW, TICKET_CREATE, TICKET_MODIFY, TICKET_ADMIN}}}
 * {{{REPORT_VIEW, REPORT_CREATE, REPORT_MODIFY, REPORT_DELETE, REPORT_ADMIN}}}
 * {{{WIKI_VIEW, WIKI_CREATE, WIKI_MODIFY, WIKI_DELETE, WIKI_ADMIN}}}
 * {{{TIMELINE_VIEW}}}
 * {{{SEARCH_VIEW}}}

The {{{something_ADMIN}}} privileges are just shortcuts that can be used to grant a user all the ''something'' privileges in one go.

=== Granting privileges ===

Currently the only way to grant privileges to users is by using the
{{{trac_admin.py}}} script. The current set of privileges can be listed
with the following command:

{{{
  $ trac_admin.py /path/to/my.db permission list
}}}

This command will let the user ''bob'' to delete reports:

{{{
  $ trac_admin.py /path/to/my.db permission add bob REPORT_DELETE
}}}

=== Default permissions ===

Granting privileges to the special user ''anonymous'' can be used to control
what an anonymous user can do before they have logged in.
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.