Jump to content

Autoit and PHP,decrypting data


Recommended Posts

Hello.I hope that I've chosen right section.Shorty I don't retrieve the same result after decrypting with certain alghoritm & key in Au3 and PHP (output is different) .

Au3 code

#include <Crypt.au3>
_Crypt_Startup()
$PATH = "0xCA7BD3085A1FFF0CC9EEFEA1728D6F3E"
$Key = "key2xH"
;$Crypted = _Crypt_EncryptData($PATH,$Key,$CALG_RC2) ;RESULT OF THE ENCRYPTION: 0xCA7BD3085A1FFF0CC9EEFEA1728D6F3E
$Decrypted =BinaryToString(_Crypt_DecryptData($PATH,$Key,$CALG_RC2))
Clipput($Decrypted)
_Crypt_Shutdown()

;After decrypting - should be returned

;secretmessage

php code (I don't know too much php)

<?php

$bub_str = mcrypt_decrypt(MCRYPT_RC2, 'key2xH','0xCA7BD3085A1FFF0CC9EEFEA1728D6F3E', MCRYPT_MODE_ECB);
echo ($bub_str);


//Instead of 'secret message' I get it.

//{Ůą.ă˝čänwÓuťPl 9şßĐ
//Ťc \ç2




?>

I would be very grateful for your help :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...