Question
- TWiki version: 01 Feb 2003
- Perl version: 5.6.1 (redhat rpms)
- Web server & version: Apache/1.3.27 (w/ mod_perl among others)
- Server OS: RedHat Linux 7.3
- Web browser & version: Mozilla 1.3
- Client OS: Redhat Linux 8.0
- Testenv output: http://www.linda-lanny.us/cgi-bin/testenv
(just downloaded from CVS)
- ISP: WebIntellects
Basic account has all requirements for TWiki. (Only this authentication problem is troublesome.)
I have installed TWiki for use as a content management system for my family's and extended family's web pages.
I have successfully applied authentication such that TWikiRegistrationPub works and I get asked to authenticate when I first edit.
However I often see TWikiRegistration (oops) (even though the URL is showing "preview") when I go to preview my changes
with the expected preview page underneath the warning. I usually see something like:
border="0" cellspacing="0" cellpadding="0" valign="bottom" align="left">
at the top of the Oops page (sometimes only the tail end of this string) and between the Oops and the expected preview I see something like:
0 HTTP/1.1 200 OK Date: Sun, 20 Apr 2003 22:43:16 GMT Server: Apache/1.3.27 (Unix) (Red-Hat/Linux)
mod_jk/1.2.0 mod_perl/1.26 PHP/4.2.2 FrontPage/5.0.2 mod_ssl/2.8.12 OpenSSL/0.9.6b Keep-Alive:
timeout=15, max=99 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html;
charset=ISO-8859-1 fd1
Using Back and then previewing again will occasionally prevent the authentication warning and show a standard preview. If I successfully get a preview (or even if I don't and use the save button in the preview below the warning) to save I have to go through the same Back/save cycle before coming up with a clean view of my save. If I save from the page shown under the warning the changes are successfully saved but then I need to view the page by hand to see the changes (i.e., doesn't automatically display the changes but simply the authentication warning.)
I've used %USERNAME% to see remote_user (at least I believe that to be the correct variable) and it displays correctly as me and not
TWikiGuest. I see my username either when the Oops page is shown or when it displays correctly so I believe I really am authenticated.
The post
ReadUserAlwaysTWikiGuest had me thinking it was an issue with the ISP and a <Limit GET> line. I was able to resolve the (non) authentication issue but then it wanted authentication even to view.
My authentication setup:
-
cgi-bin/.htaccess is a copy of bin/.htaccess.txt with the following changes:
- commented out SetHandler since ISP's apache uses mod_perl
- added "gnusave" for authentication
- added "register" for authentication (want public view; admin-handled registration)
-
data/.htpasswd
I can post the full file if requested but I'm pretty sure it isn't the culprit.
Has anyone seen these symptoms before (and if so how can I fix it)? I
seem to be authenticating correctly but TWiki is not happy. On the other hand if I use <Limit GET PUT POST> in
cgi-bin/.htaccess it seems to resolve the Oops page display leading me to believe it is an ISP issue. Any insight appreciated.
--
LannyRipple - 20 Apr 2003
I believe I've found a workaround (although I'm still very interested in a full solution). It seems if I make ErrorDocument in the
cgi-bin/.htaccess file a static webpage the problem goes away. I'm speculating that the apache server is doing something odd with noticing if you are authenticated. The scripts know you are authenticated but the server thinks you aren't and starts displaying the ErrorDocument. Somehow a static file doesn't tickle the bug.
I'll leave this post open for a while to see if anyone has any other ideas. If not I'll have to go with the workaround.
--
LannyRipple - 22 Apr 2003
Commenting out the
ErrorDocument line from
bin/.htaccess also seems to fix this problem. (TWiki20030201.tar.gz)
--
EllisPritchard - 30 Jul 2003
Answer