pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feed7.4RC2: pg_crypto not working?
4+ messages / 3 participants
[nested] [flat]
* 7.4RC2: pg_crypto not working?
@ 2003-11-12 22:14 Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
2003-11-13 00:28 ` Re: 7.4RC2: pg_crypto not working? Tom Lane <tgl@sss.pgh.pa.us>
2003-11-13 02:14 ` Re: 7.4RC2: pg_crypto not working? Reece Hart <reece@in-machina.com>
0 siblings, 2 replies; 4+ messages in thread
From: Murthy Kambhampaty @ 2003-11-12 22:14 UTC (permalink / raw)
To: pgsql-admin
After having initdb'd and started the server (gmake check said it passed all
93 tests), and doing a make; make install in pgcrypto, I tried creating the
pgcrytpo functions with
# psql -d template1 -f pgcrypto.sql
This produced a series of errors as follows:
2003-11-12 16:56:14.287480500 [9781] LOG: statement: CREATE OR REPLACE
FUNCTION digest(text, text)
2003-11-12 16:56:14.287484500 RETURNS bytea
2003-11-12 16:56:14.287485500 AS '$libdir/pgcrypto', 'pg_digest'
2003-11-12 16:56:14.287487500 LANGUAGE 'C';
2003-11-12 16:56:14.293247500 [9781] ERROR: could not load library
"/usr/local/pgsql-7.4/lib/pgcrypto.so":
/usr/local/pgsql-7.4/lib/pgcrypto.so: undefined symbol: px_find_digest
Is this from user error or is pgcrypto not working yet in RC2?
Thanks,
Murthy
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: 7.4RC2: pg_crypto not working?
2003-11-12 22:14 7.4RC2: pg_crypto not working? Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
@ 2003-11-13 00:28 ` Tom Lane <tgl@sss.pgh.pa.us>
1 sibling, 0 replies; 4+ messages in thread
From: Tom Lane @ 2003-11-13 00:28 UTC (permalink / raw)
To: Murthy Kambhampaty <murthy.kambhampaty@goeci.com>; +Cc: pgsql-admin
Murthy Kambhampaty <murthy.kambhampaty@goeci.com> writes:
> # psql -d template1 -f pgcrypto.sql
> 2003-11-12 16:56:14.293247500 [9781] ERROR: could not load library
> "/usr/local/pgsql-7.4/lib/pgcrypto.so":
> /usr/local/pgsql-7.4/lib/pgcrypto.so: undefined symbol: px_find_digest
Works for me (at least, the creation script succeeds; don't know how
to test the functions). Maybe you have a ldconfig search-path problem?
regards, tom lane
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: 7.4RC2: pg_crypto not working?
2003-11-12 22:14 7.4RC2: pg_crypto not working? Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
@ 2003-11-13 02:14 ` Reece Hart <reece@in-machina.com>
1 sibling, 0 replies; 4+ messages in thread
From: Reece Hart @ 2003-11-13 02:14 UTC (permalink / raw)
To: pgsql-admin@postgresql.org, Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
On Wed, 2003-11-12 at 14:14, Murthy Kambhampaty wrote:
> Is this from user error or is pgcrypto not working yet in RC2?
It works for me (x86, redhat 7.3, linux 2.4.18). I did make install in
pgcrypto/, then:
CREATE FUNCTION digest (text, text) RETURNS bytea
AS 'pgcrypto', 'pg_digest'
LANGUAGE c STRICT;
Note that I don't have '$libdir/' in this function definition. I can't
remember why.
compbio@csb-dev=# select encode( digest('AAA','md5'), 'hex' );
encode
----------------------------------
e1faffb3e614e6c2fba74296962386b7
(1 row)
compbio@csb-dev=# select version();
version
--------------------------------------------------------------
PostgreSQL 7.4RC2 on i686-pc-linux-gnu, compiled by GCC 2.96
I just discovered that md5 is now built in to the 7.4 backend, so I
don't need pgcrypto anymore.
-Reece
--
Reece Hart, http://www.in-machina.com/~reece/, GPG:0x25EC91A0 0xD178AAF9
^ permalink raw reply [nested|flat] 4+ messages in thread
* [SOLVED] RE: 7.4RC2: pg_crypto not working?
@ 2003-11-13 15:13 Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
0 siblings, 0 replies; 4+ messages in thread
From: Murthy Kambhampaty @ 2003-11-13 15:13 UTC (permalink / raw)
To: pgsql-admin
Thanks Tom and Reece for replying. It turns out that the
cryptolib/cryptsrc/random source combination I specified --
openssl/system/openssl -- was the problem; changing the combination to
openssl/builtin/openssl, "solved" the problem.
~/contrib/pgcrypto/Makefile snippet:
# either 'builtin', 'mhash', 'openssl'
cryptolib = openssl # builtin
# either 'builtin', 'system'
cryptsrc = system # builtin <<< problem; revert to 'builtin'
# Random source, preferred order:
# 'dev' - read from random device
#
# 'openssl' - use openssl PRNG.
# Note that currently pgcrypto does not do any
# entropy feeding to it
# This works ofcouse only with cryptolib = openssl
#
# 'silly' - use libc random() - very weak
random = openssl # silly
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2003-11-13 15:13 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-11-12 22:14 7.4RC2: pg_crypto not working? Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
2003-11-13 00:28 ` Tom Lane <tgl@sss.pgh.pa.us>
2003-11-13 02:14 ` Reece Hart <reece@in-machina.com>
2003-11-13 15:13 [SOLVED] RE: 7.4RC2: pg_crypto not working? Murthy Kambhampaty <murthy.kambhampaty@goeci.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox