Changeset 13796 for trunk/core/lib/Foswiki/Users/HtPasswdUser.pm
- Timestamp:
- 01/23/12 19:00:19 (4 months ago)
- File:
-
- 1 edited
-
trunk/core/lib/Foswiki/Users/HtPasswdUser.pm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/core/lib/Foswiki/Users/HtPasswdUser.pm
r13756 r13796 162 162 my $path = $Foswiki::cfg{Htpasswd}{FileName}; 163 163 164 #TODO: what if the data dir is also read only? 165 if ( ( !-e $path ) || ( -e $path && -r $path && !-d $path && -w $path ) ) { 166 $this->{session}->enterContext('passwords_modifyable'); 167 return 0; 168 } 164 # We expect the path to exist and be writable. 165 return 0 if ( -e $path && -f $path && -w $path ); 166 167 # Otherwise, log a problem. 168 $this->{session}->logger->log( 169 'warning', 170 'The password file does not exist or cannot be written.' . 171 'Run =configure= and check the setting of {Htpasswd}{FileName}.' . 172 ' New user registration has been disabled until this is corrected.'); 173 # And disable registration (which will also disable password changes) 174 $Foswiki::cfg{Register}{EnableNewUserRegistration} = 0; 175 169 176 return 1; 170 177 }
Note: See TracChangeset
for help on using the changeset viewer.
