2016-12-11 Jeffrey Stedfast * README: Bumped version * configure.ac: Bumped version to 2.6.21 2016-12-10 Jeffrey Stedfast * gmime/gmime-gpg-context.c (gpg_ctx_get_argv): Don't pass --yes, ever. 2016-12-10 Jeffrey Stedfast * gmime/gmime-gpg-context.c (gpg_ctx_get_argv): Add back --batch and --yes to fix the unit tests for GnuPG 1.4.x. (gpg_ctx_get_argv): Now also takes a path argument to gpg to use as the first argument instead of hard-coding "gpg". (g_mime_gpg_context_new): Updated to query the GnuPG version in case we need that information (turns out we don't at the moment). 2016-12-09 Jeffrey Stedfast * gmime/gmime-crypto-context.c (g_mime_crypto_context_set_retrieve_session_key): Moved here from GMimeGpgContext. (g_mime_crypto_context_get_retrieve_session_key): Same. Thanks to Daniel Kahn Gillmor for this patch. 2016-12-05 Jeffrey Stedfast * gmime/gmime-multipart-encrypted.c (g_mime_multipart_encrypted_decrypt_session): New function to decrypt a multipart/encrypted using a session_key. * gmime/gmime-crypto-context.c (g_mime_crypto_context_decrypt_session): New function to decrypt a MIME part using a session_key. * gmime/gmime-gpg-context.c (gpg_ctx_get_argv): Added support for --override-session-key-id for the new decrypt_session() method. (gpg_ctx_op_start): Updated to create the secret_fd when passing a session_key as well. (gpg_ctx_write_session_key): New function to write the session_key to gpg. (gpg_decrypt_session): New function to decrypt a MIME part using a session_key. Thanks to Daniel Kahn Gillmor for this patch. 2016-12-05 Jeffrey Stedfast * gmime/gmime-gpg-context.c (gpg_ctx_parse_status): Advance over the SESSION_KEY identifier before calling next_token() so that next_token() actually gets the sesstion key token that we want. Also fixed to free any existing session_key if gpg somehow sends us multiple SESSION_KEY responses. Thanks to Daniel Kahn Gillmor for this patch. 2016-12-03 Jeffrey Stedfast * gmime/gmime-gpg-context.c (next_token): Now takes a 'secret' argument to determine if it will overwrite the token within the buffer with '*' to prevent leaking of the secret token. (gpg_ctx_parse_status): Pass TRUE to next_token() when reading the SESSION_KEY token. 2016-12-02 Jeffrey Stedfast * gmime/gmime-gpg-context.c (gpg_ctx_free): Free the session_key. (gpg_ctx_get_argv): Pass --show-session-key to gpg if requested. (gpg_ctx_parse_status): Decode the session-key sent by gpg. (gpg_decrypt): Set the session_key on the decrypt result. (g_mime_gpg_context_get_retrieve_session_key): Added. (g_mime_gpg_context_set_retrieve_session_key): Added. * gmime/gmime-crypto-context.c (g_mime_decrypt_result_set_session_key): Added. (g_mime_decryption_result_get_session_key): Added. Thanks to Daniel Kahn Gillmor for this patch. 2016-12-02 Jeffrey Stedfast * gmime/gmime-gpg-context.c (g_mime_gpg_context_new): Allow NULL for the gpg path in order to use the default gpg path (i.e. "gpg"). * tests/test-pgp*.c: Updated unit tests to pass NULL for the gpg path so that running the unit tests don't depend on a specific location of gpg. Thanks to Daniel Kahn Gillmor for this patch. 2016-08-30 Jeffrey Stedfast * gmime/gmime-multipart.c (read_random_pool): Only initialized srand() once. 2016-07-19 Jeffrey Stedfast * gmime/gmime-gpg-context.c (gpg_ctx_get_argv): Always use --batch mode and don't pass --yes. 2016-07-14 Jeffrey Stedfast * gmime/gmime-parser.c (parser_construct_part): When parsing individual mime parts, do not treat them as top-level mime parts of a message. When decrypting mime parts, for example, we need all headers of the decrypted mime part to be included in the GMimeObject returned, otherwise we end up losing data. 2016-03-03 Jeffrey Stedfast * gmime/gmime-utils.c (header_fold_tokens): Fixed folding logic to add a space between two consecutive encoded-word tokens when they will fit on a single line. Thanks to Jaroslav Gratz for discovering this bug. Fixes bug #761263 2016-03-03 Jeffrey Stedfast * gmime/gmime-multipart-signed.c (g_mime_multipart_signed_verify): Fixed a memory leak when verifying S/MIME signatures. Thanks to Minaev Mike for discovering this bug. Fixes bug #760681 2016-01-13 Jeffrey STedfast * gmime/gmime-pkcs7-context.c (key_list_free): Fixed the logic for freeing a list of keys. Thanks to foudfou for this patch. Fixes bug #760573 2015-10-08 Jeffrey Stedfast * gmime/internet-address.c (decode_route): Make sure to free the route in error cases to avoid a memory leak. Fixes bug #756270 2015-04-11 Jeffrey Stedfast * util/url-scanner.c (url_scanner_table_init): Treat all character values >= 128 as url-safe. Fixes bug #738583. 2014-07-18 Jeffrey Stedfast * gmime/gmime-header.c (g_mime_header_list_register_writer): g_hash_table_remove() will g_free() the key for us, so don't do it ourselves (will result in a double-free). 2014-07-17 Jeffrey Stedfast * gmime/gmime-table-private.h: Increased GMIME_FOLD_LEN to 78. 2014-05-24 Jeffrey Stedfast * gmime/gmime-part.c (g_mime_part_is_attachment): New function to determine if a MIME part is an attachment or not. * gmime/gmime-disposition.c (g_mime_content_disposition_is_attachment): New function to determine if the Content-Disposition value matches "attachment".