Changeset 13796 for trunk/core/lib/Foswiki/Users/ApacheHtpasswdUser.pm
- Timestamp:
- 01/23/12 19:00:19 (4 months ago)
- File:
-
- 1 edited
-
trunk/core/lib/Foswiki/Users/ApacheHtpasswdUser.pm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/core/lib/Foswiki/Users/ApacheHtpasswdUser.pm
r12236 r13796 121 121 my $path = $Foswiki::cfg{Htpasswd}{FileName}; 122 122 123 #TODO: what if the data dir is also read only? 124 if ( ( !-e $path ) || ( -e $path && -r $path && !-d $path && -w $path ) ) { 125 $this->{session}->enterContext('passwords_modifyable'); 126 return 0; 127 } 123 # We expect the path to exist and be writable. 124 return 0 if ( -e $path && -f $path && -w $path ); 125 126 # Otherwise, log a problem. 127 $this->{session}->logger->log( 128 'warning', 129 'The password file does not exist or cannot be written.' . 130 'Run =configure= and check the setting of {Htpasswd}{FileName}.' . 131 ' New user registration has been disabled until this is corrected.'); 132 # And disable registration (and password changes) 133 $Foswiki::cfg{Register}{EnableNewUserRegistration} = 0; 128 134 return 1; 129 135 }
Note: See TracChangeset
for help on using the changeset viewer.
