MediaWiki
REL1_24
|
00001 <?php 00029 class MWOldPassword extends ParameterizedPassword { 00030 protected function getDefaultParams() { 00031 return array(); 00032 } 00033 00034 protected function getDelimiter() { 00035 return ':'; 00036 } 00037 00038 public function crypt( $plaintext ) { 00039 global $wgPasswordSalt; 00040 00041 if ( $wgPasswordSalt && count( $this->args ) == 1 ) { 00042 $this->hash = md5( $this->args[0] . '-' . md5( $plaintext ) ); 00043 } else { 00044 $this->args = array(); 00045 $this->hash = md5( $plaintext ); 00046 } 00047 } 00048 }