From: | "daddy2times" <fill-in-the-blank_(at)mediaone(dot)net> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | pgcrypto: 2 questions |
Date: | 2001-11-04 04:37:15 |
Message-ID: | %B3F7.17711$e55.3995806@typhoon.ne.mediaone.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
using PostgreSQL 7.1.1, pgcrypto (contrib -- actually full pgcrypto from
Marko Kreen's site pgcrypto-0.3)
Question 1
PHP script builds a large transaction (pseudo code):
---PHASE I---
1. begin;
2. select 2 randoms from randoms_table;
---PHASE II---
3. update randoms_table; (mark the ones retrieved in #2 as used)
---PHASE III---
4. select substr(orgname, 1, 1);
---PHASE IV---
5. insert into people; (some stuff in-the-clear, some
stuff encrypted like this:
encrypt('$data', '$salt', 'bf')
6. insert into records; (again some encrypted, some not)
7. insert into answers; (1)
8. insert into answers; (2)
9. insert into answers; (...) - sometimes many, many inserts
10. insert into answers; (n)
11. insert into answers; (one record, data encrypted as above)
12. commit;
This kills the backend with:
pqReadData() -- backend closed the channel unexpectedly.
This probably means the backend terminated abnormally before or
while processing the request.
However, if I re-position statement #11 to just before statement #7, it
works fine. Any ideas?
Question 2
Does anybody know what an appropriate range would be for the salt length (in
characters) for using blowfish to encrypt data?
Any help will be greatly appreciated!
Thanks
From | Date | Subject | |
---|---|---|---|
Next Message | Jefim Matskin | 2001-11-04 08:21:13 | psql question |
Previous Message | Jeff Lu | 2001-11-04 02:49:02 | Need help with pg_dump |