Skip to main content

Modified ticket security for Trac.

Project description

Notes

Allow users to only see tickets they are associated with.

There are three main permissions for this plugin: TICKET_VIEW_REPORTER, TICKET_VIEW_CC, and TICKET_VIEW_OWNER. TICKET_VIEW_SELF is an alias for all three of these.

With each permission, users will only be able to see tickets where they are the person mentioned in the permission. So if a user has TICKET_VIEW_REPORTER, they can only see tickets they reported. For TICKET_VIEW_CC, they just have to be included in the CC list.

There are also group-based permissions: TICKET_VIEW_REPORTER_GROUP, TICKET_VIEW_CC_GROUP, and TICKET_VIEW_OWNER_GROUP. These work in a similar way to their non-group counterparts, except that you are granted access if you share a group with the target user. For example, if ticket 1 was reported by Allan, and Allan and Bob are both in the group company_foo, and Bob has TICKET_VIEW_REPORTER_GROUP, then Bob will be able to see ticket 1 since he shares a group with the reporter. Each group-based permission is also an alias for the normal one, so you do not have to grant both. TICKET_VIEW_GROUP is an alias for all the group-based permissions (and therefore all the normal ones as well).

These extra permissions can only deny access, not allow it. This means the user must still have TICKET_VIEW granted as normal.

Finally, users with TRAC_ADMIN will not be restricted by this plugin. The meta-user “anonymous” also cannot be restricted by this plugin, as their identity isn’t known to be checked. Be sure to not grant TICKET_VIEW to anonymous, or unauthenticated users will be able to see all tickets.

Configuration

All configuration options go in the [privatetickets] section.

group_blacklist

Groups to ignore for the purposes of the *_GROUP permissions.

Defaults to “anonymous, authenticated

You must also add PrivateTicketsPolicy to your permission_policies setting in trac.ini. It must be before the DefaultPermissionPolicy. See below for an example if you don’t have any other policies.

Example

An example configuration:

[privatetickets]
group_blacklist = anonymous, authenticated, labusers

[components]
privatetickets.* = enabled

[trac]
permission_policies = PrivateTicketsPolicy, DefaultPermissionPolicy, LegacyAttachmentPolicy

Project details


Download files

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

Source Distribution

TracPrivateTickets-2.2.0.tar.gz (4.5 kB view details)

Uploaded Source

Built Distribution

TracPrivateTickets-2.2.0-py2-none-any.whl (6.2 kB view details)

Uploaded Python 2

File details

Details for the file TracPrivateTickets-2.2.0.tar.gz.

File metadata

File hashes

Hashes for TracPrivateTickets-2.2.0.tar.gz
Algorithm Hash digest
SHA256 a42bac5d2cf655d919355104f43ab19e64fd0b205e7d273eef3531e0f422b2fa
MD5 b3646243f4d88d1d8cb6a94bf63edde3
BLAKE2b-256 27edbd55cc50796043bc42bc8254ba60e44f58a989b704d89f57e38f7550125b

See more details on using hashes here.

Provenance

File details

Details for the file TracPrivateTickets-2.2.0-py2-none-any.whl.

File metadata

File hashes

Hashes for TracPrivateTickets-2.2.0-py2-none-any.whl
Algorithm Hash digest
SHA256 9120c78a2ad3a652024a13efbf74389e142ba7274c913577a3b709b81bbc4091
MD5 1c7dd9938db27561fb020570abec1996
BLAKE2b-256 e3f7a070aa93c25a854f3f231a73b5c1c6e5c1616e4e4f58eefa76d8ef6565ee

See more details on using hashes here.

Provenance

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