Search Postgresql Archives

Pg 9.1.3 pg_crypto question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Finally upgrading from 8.2.5 to 9.1.3 (got the latest release as of
3/12/2012)

OS: Ubuntu 11.10

The only issue I am encountering is in the pg_crypto/decrypt_iv/decode
No errors in the log, but here's what I am seeing on both 8.2.5 and 9.1.3,
I am hoping someone can help me out here:

8.2.5#
8.2.5=# select encode(encrypt_iv(text2bytea('Hello There'),
decode('bcRJvbqeWMPDXMtIP8pPOQ==', 'base64'), '0000000000000000',
'aes-cbc'), 'base64');
          encode  
--------------------------
rkMRWpnnbjaFoHyLmCD/bg==
(1 row)

8.2.5=# select decrypt_iv(decode('rkMRWpnnbjaFoHyLmCD/bg==', 'base64'),
decode('bcRJvbqeWMPDXMtIP8pPOQ==', 'base64'), '0000000000000000',
'aes-cbc');
decrypt_iv  
-------------
Hello There
(1 row)

So, the 8.2.5 is working as it always has.

9.1.3 is just not decrypting nor throwing errors.


9.1.3#
9.1.3# select encode(encrypt_iv(text2bytea('Hello There'),
decode('bcRJvbqeWMPDXMtIP8pPOQ==', 'base64'), '0000000000000000',
'aes-cbc'), 'base64');
          encode  
--------------------------
rkMRWpnnbjaFoHyLmCD/bg==
(1 row)

9.1.3# select decrypt_iv(decode('rkMRWpnnbjaFoHyLmCD/bg==', 'base64'),
decode('bcRJvbqeWMPDXMtIP8pPOQ==', 'base64'), '0000000000000000',
'aes-cbc');
        decrypt_iv
--------------------------
\x48656c6c6f205468657265
(1 row)




Thanking you in advance,

Aaron



-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux