配布スクリプトの読めない部分を解説しちゃる
Perl、PHPなんでもござれ。 配布スクリプトの中でよくわからん構文などがあったら解読&解説しちゃる。 このスクリプトの説明をお願いします。 function ssl_encrypt($source,$type,$key){ //Assumes 1024 bit key and encrypts in chunks. $maxlength=117; $output=''; while($source){ $input= substr($source,0,$maxlength); $source=substr($source,$maxlength); if($type=='private'){ $ok= openssl_private_encrypt($input,$encrypted,$key); }else{ $ok= openssl_public_encrypt($input,$encrypted,$key); } $output.=$encrypted; } return $output; } 続き function ssl_decrypt($source,$type,$key){ // The raw PHP decryption functions appear to work // on 128 Byte chunks. So this decrypts long text // encrypted with ssl_encrypt(). $maxlength=128; $output=''; while($source){ $input= substr($source,0,$maxlength); $source=substr($source,$maxlength); if($type=='private'){ $ok= openssl_private_decrypt($input,$out,$key); }else{ $ok= openssl_public_decrypt($input,$out,$key); } $output.=$out; } return $output; } read.cgi ver 07.4.7 2024/03/31 Walang Kapalit ★ | Donguri System Team 5ちゃんねる