Update: 2026-06-16 02:52:06
This commit is contained in:
@@ -104,18 +104,8 @@ class EncryptionHelper {
|
||||
|
||||
try {
|
||||
$encryptionHelper = new EncryptionHelper($key, $iv);
|
||||
|
||||
// ✅ Test encryption and decryption with padding matching Flutter
|
||||
$plainText = "https://sefer.click/"; // Example plaintext
|
||||
$encryptedText = $encryptionHelper->encryptData($plainText);
|
||||
$decryptedText = $encryptionHelper->decryptData($encryptedText);
|
||||
/*
|
||||
echo "🔹 Original Text: " . $plainText . PHP_EOL;
|
||||
echo "🔹 Encrypted Text: " . $encryptedText . PHP_EOL;
|
||||
echo "🔹 Decrypted Text: " . $decryptedText . PHP_EOL;
|
||||
*/
|
||||
} catch (Exception $e) {
|
||||
echo "Error: " . $e->getMessage() . PHP_EOL;
|
||||
error_log("[encrypt_decrypt] Initialization error: " . $e->getMessage());
|
||||
}
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user