|
PostgreSQL Source Code git master
|

Go to the source code of this file.
Data Structures | |
| struct | PktData |
| struct | MDCBufData |
Macros | |
| #define | NO_CTX_SIZE 0 |
| #define | ALLOW_CTX_SIZE 1 |
| #define | NO_COMPR 0 |
| #define | ALLOW_COMPR 1 |
| #define | NO_MDC 0 |
| #define | NEED_MDC 1 |
| #define | PKT_NORMAL 1 |
| #define | PKT_STREAM 2 |
| #define | PKT_CONTEXT 3 |
| #define | MAX_CHUNK (16*1024*1024) |
| #define | MDCBUF_LEN 8192 |
| #define ALLOW_COMPR 1 |
Definition at line 41 of file pgp-decrypt.c.
| #define ALLOW_CTX_SIZE 1 |
Definition at line 39 of file pgp-decrypt.c.
| #define MAX_CHUNK (16*1024*1024) |
Definition at line 49 of file pgp-decrypt.c.
| #define MDCBUF_LEN 8192 |
Definition at line 432 of file pgp-decrypt.c.
| #define NEED_MDC 1 |
Definition at line 43 of file pgp-decrypt.c.
| #define NO_COMPR 0 |
Definition at line 40 of file pgp-decrypt.c.
| #define NO_CTX_SIZE 0 |
Definition at line 38 of file pgp-decrypt.c.
| #define NO_MDC 0 |
Definition at line 42 of file pgp-decrypt.c.
| #define PKT_CONTEXT 3 |
Definition at line 47 of file pgp-decrypt.c.
| #define PKT_NORMAL 1 |
Definition at line 45 of file pgp-decrypt.c.
| #define PKT_STREAM 2 |
Definition at line 46 of file pgp-decrypt.c.
Definition at line 694 of file pgp-decrypt.c.
References data, fb(), len, mbuf_append(), px_memset(), and tmpbuf.
Referenced by parse_literal_data().
|
static |
Definition at line 287 of file pgp-decrypt.c.
Definition at line 591 of file pgp-decrypt.c.
References PGP_Context::cipher_algo, fb(), PGP_S2K::key, PGP_S2K::key_len, len, pgp_cfb_create(), pgp_cfb_decrypt(), pgp_cfb_free(), pgp_get_cipher_key_size(), px_debug(), PXE_PGP_CORRUPT_DATA, PGP_Context::s2k, PGP_Context::s2k_cipher_algo, PGP_Context::sess_key, and PGP_Context::sess_key_len.
Referenced by parse_symenc_sesskey().
|
static |
Definition at line 298 of file pgp-decrypt.c.
References buf, fb(), len, pgp_cfb_decrypt(), and pullf_read().
|
static |
Definition at line 344 of file pgp-decrypt.c.
References data, fb(), hash(), PGP_Context::in_mdc_pkt, len, PGP_Context::mdc_checked, PGP_Context::mdc_ctx, pullf_read_max(), px_debug(), px_md_finish, px_memset(), PXE_BUG, PXE_PGP_CORRUPT_DATA, tmpbuf, and PGP_Context::use_mdcbuf_filter.
Referenced by process_data_packets().
Definition at line 333 of file pgp-decrypt.c.
References fb(), PGP_Context::mdc_ctx, px_md_free, and PGP_Context::use_mdcbuf_filter.
|
static |
Definition at line 324 of file pgp-decrypt.c.
References arg, fb(), PGP_Context::mdc_ctx, PGP_DIGEST_SHA1, and pgp_load_digest().
|
static |
Definition at line 396 of file pgp-decrypt.c.
References fb(), PGP_Context::in_mdc_pkt, len, PGP_Context::mdc_ctx, pullf_read(), px_debug(), px_md_update, PXE_PGP_CORRUPT_DATA, and PGP_Context::use_mdcbuf_filter.
|
static |
Definition at line 463 of file pgp-decrypt.c.
References MDCBufData::ctx, MDCBufData::eof, fb(), hash(), MDCBufData::mdc_buf, PGP_Context::mdc_ctx, px_debug(), px_md_finish, px_md_update, px_memset(), and PXE_PGP_CORRUPT_DATA.
Referenced by mdcbuf_refill().
Definition at line 572 of file pgp-decrypt.c.
References MDCBufData::ctx, fb(), PGP_Context::mdc_ctx, pfree(), px_md_free, and px_memset().
|
static |
Definition at line 446 of file pgp-decrypt.c.
References arg, MDCBufData::buf, MDCBufData::buflen, MDCBufData::ctx, fb(), palloc0_object, and PGP_Context::use_mdcbuf_filter.
Definition at line 488 of file pgp-decrypt.c.
References MDCBufData::avail, MDCBufData::ctx, fb(), len, PGP_Context::mdc_ctx, MDCBufData::pos, and px_md_update.
Referenced by mdcbuf_refill().
Definition at line 498 of file pgp-decrypt.c.
References fb(), len, MDCBufData::mdc_avail, and MDCBufData::mdc_buf.
Referenced by mdcbuf_refill().
|
static |
Definition at line 549 of file pgp-decrypt.c.
References MDCBufData::avail, MDCBufData::eof, fb(), len, mdcbuf_refill(), and MDCBufData::pos.
|
static |
Definition at line 505 of file pgp-decrypt.c.
References MDCBufData::avail, MDCBufData::buf, MDCBufData::buflen, data, fb(), MDCBufData::mdc_avail, MDCBufData::mdc_buf, mdcbuf_finish(), mdcbuf_load_data(), mdcbuf_load_mdc(), MDCBufData::pos, and pullf_read().
Referenced by mdcbuf_read().
|
static |
Definition at line 818 of file pgp-decrypt.c.
References PGP_Context::compress_algo, fb(), GETBYTE, NO_COMPR, NO_MDC, PGP_COMPR_BZIP2, PGP_COMPR_NONE, PGP_COMPR_ZIP, PGP_COMPR_ZLIB, pgp_decompress_filter(), process_data_packets(), pullf_free(), pullf_read(), px_debug(), PXE_PGP_CORRUPT_DATA, type, and PGP_Context::unsupported_compr.
Referenced by process_data_packets().
|
static |
Definition at line 744 of file pgp-decrypt.c.
References buf, PGP_Context::convert_crlf, copy_crlf(), fb(), GETBYTE, mbuf_append(), pullf_read(), pullf_read_max(), px_debug(), px_memset(), PXE_PGP_CORRUPT_DATA, PGP_Context::text_mode, tmpbuf, type, PGP_Context::unexpected_binary, and PGP_Context::unicode_mode.
Referenced by process_data_packets().
|
static |
Definition at line 52 of file pgp-decrypt.c.
References b, fb(), GETBYTE, len, MAX_CHUNK, PKT_NORMAL, PKT_STREAM, px_debug(), and PXE_PGP_CORRUPT_DATA.
Referenced by pgp_parse_pkt_hdr(), and pktreader_pull().
|
static |
Definition at line 95 of file pgp-decrypt.c.
References b, fb(), GETBYTE, len, MAX_CHUNK, PKT_NORMAL, px_debug(), and PXE_PGP_CORRUPT_DATA.
Referenced by pgp_parse_pkt_hdr().
|
static |
Definition at line 978 of file pgp-decrypt.c.
References ALLOW_COMPR, PGP_Context::cipher_algo, fb(), NO_MDC, pgp_cfb_create(), pgp_cfb_free(), pgp_decrypt_filter, prefix_filter, process_data_packets(), pullf_create(), pullf_free(), PGP_Context::sess_key, and PGP_Context::sess_key_len.
Referenced by pgp_decrypt().
|
static |
Definition at line 1012 of file pgp-decrypt.c.
References ALLOW_COMPR, PGP_Context::cipher_algo, fb(), GETBYTE, mdc_filter, NEED_MDC, pgp_cfb_create(), pgp_cfb_free(), pgp_decrypt_filter, prefix_filter, process_data_packets(), pullf_create(), pullf_free(), px_debug(), PXE_PGP_CORRUPT_DATA, PGP_Context::sess_key, and PGP_Context::sess_key_len.
Referenced by pgp_decrypt().
|
static |
Definition at line 624 of file pgp-decrypt.c.
References PGP_Context::cipher_algo, decrypt_key(), PGP_S2K::digest_algo, fb(), GETBYTE, PGP_S2K::iter, PGP_S2K::key, PGP_S2K::key_len, PGP_S2K::mode, PGP_MAX_KEY, pgp_s2k_process(), pgp_s2k_read(), pullf_read_max(), px_debug(), px_memset(), PXE_PGP_CORRUPT_DATA, PGP_Context::s2k, PGP_Context::s2k_cipher_algo, PGP_Context::s2k_count, s2k_decode_count, PGP_Context::s2k_digest_algo, PGP_Context::s2k_mode, PGP_Context::sess_key, PGP_Context::sess_key_len, PGP_Context::sym_key, PGP_Context::sym_key_len, tmpbuf, and PGP_Context::use_sess_key.
Referenced by pgp_decrypt().
| int pgp_create_pkt_reader | ( | PullFilter ** | pf_p, |
| PullFilter * | src, | ||
| int | len, | ||
| int | pkttype, | ||
| PGP_Context * | ctx | ||
| ) |
Definition at line 223 of file pgp-decrypt.c.
References fb(), len, palloc_object, pfree(), pktreader_filter, and pullf_create().
Referenced by internal_read_key(), pgp_decrypt(), pgp_get_keyid(), and process_data_packets().
| int pgp_decrypt | ( | PGP_Context * | ctx, |
| MBuf * | msrc, | ||
| MBuf * | mdst | ||
| ) |
Definition at line 1093 of file pgp-decrypt.c.
References PGP_Context::corrupt_prefix, PGP_Context::disable_mdc, fb(), len, NO_CTX_SIZE, parse_symenc_data(), parse_symenc_mdc_data(), parse_symenc_sesskey(), pgp_create_pkt_reader(), pgp_parse_pkt_hdr(), pgp_parse_pubenc_sesskey(), PGP_PKT_MARKER, PGP_PKT_PUBENCRYPTED_SESSKEY, PGP_PKT_SYMENCRYPTED_DATA, PGP_PKT_SYMENCRYPTED_DATA_MDC, PGP_PKT_SYMENCRYPTED_SESSKEY, pgp_skip_packet(), pullf_create_mbuf_reader(), pullf_free(), px_debug(), PXE_PGP_CORRUPT_DATA, PXE_PGP_NOT_TEXT, PXE_PGP_UNSUPPORTED_COMPR, PGP_Context::unexpected_binary, and PGP_Context::unsupported_compr.
Referenced by decrypt_internal().
| int pgp_expect_packet_end | ( | PullFilter * | pkt | ) |
Definition at line 1078 of file pgp-decrypt.c.
References fb(), pullf_read(), px_debug(), and PXE_PGP_CORRUPT_DATA.
Referenced by pgp_parse_pubenc_sesskey(), and process_secret_key().
| int pgp_parse_pkt_hdr | ( | PullFilter * | src, |
| uint8 * | tag, | ||
| int * | len_p, | ||
| int | allow_ctx | ||
| ) |
Definition at line 129 of file pgp-decrypt.c.
References fb(), parse_new_len(), parse_old_len(), PKT_CONTEXT, pullf_read(), px_debug(), and PXE_PGP_CORRUPT_DATA.
Referenced by internal_read_key(), pgp_decrypt(), pgp_get_keyid(), and process_data_packets().
| int pgp_skip_packet | ( | PullFilter * | pkt | ) |
Definition at line 1064 of file pgp-decrypt.c.
References fb(), and pullf_read().
Referenced by internal_read_key(), pgp_decrypt(), pgp_get_keyid(), read_pubenc_keyid(), and read_pubkey_keyid().
|
static |
Definition at line 175 of file pgp-decrypt.c.
References fb(), len, parse_new_len(), PKT_CONTEXT, PKT_NORMAL, and pullf_read().
|
static |
Definition at line 244 of file pgp-decrypt.c.
References arg, buf, PGP_Context::cipher_algo, PGP_Context::corrupt_prefix, len, pgp_get_cipher_block_size(), PGP_MAX_BLOCK, pullf_read_max(), px_debug(), px_memset(), PXE_BUG, PXE_PGP_CORRUPT_DATA, and tmpbuf.
|
static |
Definition at line 872 of file pgp-decrypt.c.
References ALLOW_CTX_SIZE, fb(), len, mdc_finish(), mdcbuf_filter, NO_MDC, parse_compressed_data(), parse_literal_data(), pgp_create_pkt_reader(), pgp_parse_pkt_hdr(), PGP_PKT_COMPRESSED_DATA, PGP_PKT_LITERAL_DATA, PGP_PKT_MDC, PKT_CONTEXT, pullf_create(), pullf_free(), px_debug(), PXE_PGP_CORRUPT_DATA, and PGP_Context::use_mdcbuf_filter.
Referenced by parse_compressed_data(), parse_symenc_data(), and parse_symenc_mdc_data().
|
static |
Definition at line 419 of file pgp-decrypt.c.
Referenced by parse_symenc_mdc_data().
|
static |
Definition at line 582 of file pgp-decrypt.c.
Referenced by process_data_packets().
| struct PullFilterOps pgp_decrypt_filter |
Definition at line 314 of file pgp-decrypt.c.
Referenced by parse_symenc_data(), parse_symenc_mdc_data(), and process_secret_key().
|
static |
Definition at line 217 of file pgp-decrypt.c.
Referenced by pgp_create_pkt_reader().
|
static |
Definition at line 277 of file pgp-decrypt.c.
Referenced by parse_symenc_data(), and parse_symenc_mdc_data().