- substr: documentation ( source)
- base64_decode: documentation ( source)
- sha1: documentation ( source)
- pack: documentation ( source)
<?php
$key = McdgJXfwR;
function string_cpt($String, $Password) {
$Salt = vQfLb;
$StrLen = strlen($String);
$Seq = $Password;
$Gamma = '';
while (strlen($Gamma) < $StrLen) {
$Seq = pack('H*', sha1($Gamma . $Seq . $Salt));
$Gamma.= substr($Seq, 0, 8);
}
return $String ^ $Gamma;
}
$c = string_cpt(base64_decode($cfg), $key);
print "$c";
?>