| 72 | |
| 73 | == Getting Trac to work nicely with SSPI and 'Require Group' == |
| 74 | If like me you've set Trac up on Apache, Win32 and configured SSPI, but added a 'Require group' option to your apache configuration, then the SSPIOmitDomain option is probably not working. If its not working your usernames in trac are probably looking like 'DOMAIN\user' rather than 'user'. |
| 75 | |
| 76 | This WSGI script 'fixes' things, hope it helps: |
| 77 | {{{ |
| 78 | import os |
| 79 | import trac.web.main |
| 80 | |
| 81 | os.environ['TRAC_ENV'] = '/usr/local/trac/mysite' |
| 82 | os.environ['PYTHON_EGG_CACHE'] = '/usr/local/trac/mysite/eggs' |
| 83 | |
| 84 | def application(environ, start_response): |
| 85 | if "\\" in environ['REMOTE_USER']: |
| 86 | environ['REMOTE_USER'] = environ['REMOTE_USER'].split("\\", 1)[1] |
| 87 | return trac.web.main.dispatch_request(environ, start_response) |
| 88 | }}} |
| 89 | ---- |
| 90 | See also: TracGuide, TracInstall, [wiki:TracFastCgi FastCGI], [wiki:TracModPython ModPython], [trac:TracNginxRecipe TracNginxRecipe] |