⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.101
Server IP:
178.33.27.10
Server:
Linux cpanel.dev-unit.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
Server Software:
Apache/2.4.62 (Unix) OpenSSL/1.0.2k-fips
PHP Version:
8.2.25
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
home
/
id
/
taxi.dev-unit.com
/
public
/
View File Name :
Crypto.php
<?php /* * @param1 : Plain String * @param2 : Working key provided by CCAvenue * @return : Encrypted String */ function ccavenue_encrypt($plainText, $key) { $key = hextobin(md5($key)); $initVector = pack("C*", 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f); $openMode = openssl_encrypt($plainText, 'AES-128-CBC', $key, OPENSSL_RAW_DATA, $initVector); $encryptedText = bin2hex($openMode); return $encryptedText; } /* * @param1 : Encrypted String * @param2 : Working key provided by CCAvenue * @return : Plain String */ function ccavenue_decrypt($encryptedText, $key) { $key = hextobin(md5($key)); $initVector = pack("C*", 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f); $encryptedText = hextobin($encryptedText); $decryptedText = openssl_decrypt($encryptedText, 'AES-128-CBC', $key, OPENSSL_RAW_DATA, $initVector); return $decryptedText; } function hextobin($hexString) { $length = strlen($hexString); $binString=""; $count=0; while($count < $length) { $subString = substr($hexString, $count, 2); $packedString = pack("H*", $subString); if ($count == 0) { $binString = $packedString; } else { $binString .= $packedString; } $count += 2; } return $binString; } ?>