| 1 | = share Trac cookies between projects in the same environment = |
| 2 | |
| 3 | == Description == |
| 4 | |
| 5 | SharedCookieAuthPlugin allows cookies to be shared between Trac instances in the same environment (i.e. directory). The plugin monkey-patches `trac.web.auth.LoginModule` so that cookies get set at `/` instead of `req.base_path` (though see trac:#8486 for the request to make this configurable). The incoming request is then passed by the `authenticate` method of the `IAuthenticator` interface to projects that peer the project of interest to see if the user is authenticated there. This enables single-sign on for Trac projects in the same directory. |
| 6 | |
| 7 | Currently, this is pretty slow, as all of the peer environments are opened per authentication attempt. Any help making it faster is welcome, or I'll probably eventually get around to it. |
| 8 | |
| 9 | == Bugs/Feature Requests == |
| 10 | |
| 11 | Existing bugs and feature requests for SharedCookieAuthPlugin are |
| 12 | [report:9?COMPONENT=SharedCookieAuthPlugin here]. |
| 13 | |
| 14 | If you have any issues, create a |
| 15 | [http://trac-hacks.org/newticket?component=SharedCookieAuthPlugin&owner=k0s new ticket]. |
| 16 | |
| 17 | == Download == |
| 18 | |
| 19 | Download the zipped source from [download:sharedcookieauthplugin here]. |
| 20 | |
| 21 | == Source == |
| 22 | |
| 23 | You can check out SharedCookieAuthPlugin from [http://trac-hacks.org/svn/sharedcookieauthplugin here] using Subversion, or [source:sharedcookieauthplugin browse the source] with Trac. |
| 24 | |
| 25 | == Example == |
| 26 | |
| 27 | Install the plugin on multiple Trac instances in the same directory that use cookie-based auth. Then login to one should mirror login to all of them |
| 28 | |
| 29 | == Recent Changes == |
| 30 | |
| 31 | [[ChangeLog(sharedcookieauthplugin, 3)]] |
| 32 | |
| 33 | == Author/Contributors == |
| 34 | |
| 35 | '''Author:''' [wiki:k0s] [[BR]] |
| 36 | '''Contributors:''' |