~ubuntu-branches/ubuntu/lucid/postgresql-8.4/lucid-proposed

« back to all changes in this revision

Viewing changes to contrib/pgcrypto/pgp-s2k.c

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2009-07-11 16:59:35 UTC
  • mfrom: (5.1.1 karmic)
  • Revision ID: james.westby@ubuntu.com-20090711165935-jfwin6gfrxf0gfsi
Tags: 8.4.0-2
* debian/libpq-dev.install: Ship catalog/genbki.h. (Closes: #536139)
* debian/rules: Drop --enable-cassert for final release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27
27
 * SUCH DAMAGE.
28
28
 *
29
 
 * $PostgreSQL: pgsql/contrib/pgcrypto/pgp-s2k.c,v 1.4 2005/10/15 02:49:06 momjian Exp $
 
29
 * $PostgreSQL: pgsql/contrib/pgcrypto/pgp-s2k.c,v 1.5 2009/06/11 14:48:52 momjian Exp $
30
30
 */
31
31
 
32
32
#include "postgres.h"
36
36
#include "pgp.h"
37
37
 
38
38
static int
39
 
calc_s2k_simple(PGP_S2K * s2k, PX_MD * md, const uint8 *key,
 
39
calc_s2k_simple(PGP_S2K *s2k, PX_MD *md, const uint8 *key,
40
40
                                unsigned key_len)
41
41
{
42
42
        unsigned        md_bs,
81
81
}
82
82
 
83
83
static int
84
 
calc_s2k_salted(PGP_S2K * s2k, PX_MD * md, const uint8 *key, unsigned key_len)
 
84
calc_s2k_salted(PGP_S2K *s2k, PX_MD *md, const uint8 *key, unsigned key_len)
85
85
{
86
86
        unsigned        md_bs,
87
87
                                md_rlen;
126
126
}
127
127
 
128
128
static int
129
 
calc_s2k_iter_salted(PGP_S2K * s2k, PX_MD * md, const uint8 *key,
 
129
calc_s2k_iter_salted(PGP_S2K *s2k, PX_MD *md, const uint8 *key,
130
130
                                         unsigned key_len)
131
131
{
132
132
        unsigned        md_bs,
213
213
}
214
214
 
215
215
int
216
 
pgp_s2k_fill(PGP_S2K * s2k, int mode, int digest_algo)
 
216
pgp_s2k_fill(PGP_S2K *s2k, int mode, int digest_algo)
217
217
{
218
218
        int                     res = 0;
219
219
        uint8           tmp;
244
244
}
245
245
 
246
246
int
247
 
pgp_s2k_read(PullFilter * src, PGP_S2K * s2k)
 
247
pgp_s2k_read(PullFilter *src, PGP_S2K *s2k)
248
248
{
249
249
        int                     res = 0;
250
250
 
270
270
}
271
271
 
272
272
int
273
 
pgp_s2k_process(PGP_S2K * s2k, int cipher, const uint8 *key, int key_len)
 
273
pgp_s2k_process(PGP_S2K *s2k, int cipher, const uint8 *key, int key_len)
274
274
{
275
275
        int                     res;
276
276
        PX_MD      *md;