Welcome Guest, Not a member yet? Register   Sign In
Encrypt in CI, decrypt in Python
#1

Hello,

I've been struggling with these the past day. I'm encrypting some passwords in CI using an encryption key. What i want is to be able to decrypt those and get the original passwords from python. I've found a library but i really couldn't get it to work ( and since it's latest update was 3 years ago i'm starting to think i lost my time too there ). Library is HERE
Anyway i was hoping maybe if there's someone that has something similar to this at least to get me started.
I did an echo of the params the encryption library is using. I can always change those if required but i'd prefer not to.

PHP Code:
testpassword
ce3399bb4cf3dc5a679c7f265a054808
Array
(
    [
handle] => aes-128-cbc
    
[cipher] => aes-128
    
[mode] => cbc
    
[key] => ���cݨe��Y\T�H�iw��ݷK1�vj4�
    [
base64] => 1
    
[hmac_digest] => sha512
    
[hmac_key] => 
)

openssl

f8448532d1261fd80e5782378b98dc3a5edb80b8caf5f5a4d935d6999f8726d6e84205467d846a77ac1f8a7c872e3ed3a61668daa3971b2aa75399b29f837d04MLPxAyGjS0wD5yuHcRCxCBAomPkuv63UBlHPJW2u
+4I


I know by default it's using aes-256 and mcrypt but played around them too and got nothing.
Also i started using the
PHP Code:
$config['encryption_key'] = hex2bin('ce3399bb4cf3dc5a679c7f265a054808'); 
version of my key, thought maybe the issue was there so i switched to to none bin but still nothing.

ANY help is appreciated.

Thank you
"The Most Important Thing In Life Is Showing Up"
"I Just Had A Bad Day"
"We'll Be Back"
"Further Beyond"
Reply
#2

Don't encrypts password using CI Encryption Library.
Keep calm.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB