~vcs-imports/mammoth-replicator/trunk

« back to all changes in this revision

Viewing changes to contrib/pgcrypto/expected/crypt-xdes.out

  • Committer: alvherre
  • Date: 2005-12-16 21:24:52 UTC
  • Revision ID: svn-v4:db760fc0-0f08-0410-9d63-cc6633f64896:trunk:1
Initial import of the REL8_0_3 sources from the Pgsql CVS repository.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--
 
2
-- crypt() and gen_salt(): extended des
 
3
--
 
4
SELECT crypt('', '_J9..j2zz');
 
5
        crypt         
 
6
----------------------
 
7
 _J9..j2zzR/nIRDK3pPc
 
8
(1 row)
 
9
 
 
10
SELECT crypt('foox', '_J9..j2zz');
 
11
        crypt         
 
12
----------------------
 
13
 _J9..j2zzAYKMvO2BYRY
 
14
(1 row)
 
15
 
 
16
CREATE TABLE ctest (data text, res text, salt text);
 
17
INSERT INTO ctest VALUES ('password', '', '');
 
18
UPDATE ctest SET salt = gen_salt('xdes', 1001);
 
19
UPDATE ctest SET res = crypt(data, salt);
 
20
SELECT res = crypt(data, res) AS "worked"
 
21
FROM ctest;
 
22
 worked 
 
23
--------
 
24
 t
 
25
(1 row)
 
26
 
 
27
DROP TABLE ctest;