- 27 Oct, 2011 1 commit
-
-
* libmailutils/tests/fsaf.at: New testcase. * libmailutils/tests/fsaf.c: New file. * libmailutils/tests/.gitignore: Add fsaf * libmailutils/tests/Makefile.am: Likewise. * libmailutils/tests/testsuite.at: Include fsaf.at.
Sergey Poznyakoff authored
-
- 25 Oct, 2011 2 commits
-
-
-
* lib/mu_dbm.c: Remove. * lib/mu_dbm.h: Remove. * lib/Makefile.am: Remove mu_dbm.[ch]. * include/mailutils/sys/dbm.h: New file. * include/mailutils/sys/Makefile.am: Add dbm.h * include/mailutils/dbm.h: New file. * include/mailutils/Makefile.am (pkginclude_HEADERS): Add dbm.h. * include/mailutils/types.hin (mu_dbm_file_t): New data type. * libmu_dbm/Makefile.am: New file. * libmu_dbm/berkeley.c: New file. * libmu_dbm/close.c: New file. * libmu_dbm/create.c: New file. * libmu_dbm/datumfree.c: New file. * libmu_dbm/dbm.c: New file. * libmu_dbm/delete.c: New file. * libmu_dbm/destroy.c: New file. * libmu_dbm/errstr.c: New file. * libmu_dbm/fetch.c: New file. * libmu_dbm/firstkey.c: New file. * libmu_dbm/gdbm.c: New file. * libmu_dbm/mudbm.h: New file. * libmu_dbm/ndbm.c: New file. * libmu_dbm/nextkey.c: New file. * libmu_dbm/open.c: New file. * libmu_dbm/safety.c: New file. * libmu_dbm/store.c: New file. * Makefile.am [MU_COND_DBM]: Define LIBMU_DBM_DIR (SUBDIRS): Add $(LIBMU_DBM_DIR) * configure.ac: Revamp DBM support: several database types can be specified at once. (AC_CONFIG_FILES): Build libmu_dbm/Makefile * libmu_sieve/extensions/vacation.c: Remove inclusion of mu_dbm.h. * maidag/Makefile.am (maidag_LDADD): Add DBM libraries. * maidag/maidag.c: ENABLE_DBM instead of USE_DBM * maidag/maidag.h: Include <mailutils/dbm.h> instead of mu_dbm.h. * maidag/mailquota.c (dbm_retrieve_quota): Rewrite using libmu_dbm library calls. * mu/Makefile.am [MU_COND_DBM]: Define DBM_C. (MODULES): Add $(DBM_C). (AM_CPPFLAGS): Define DBMLIBS. * mu/ldflags.c (NEEDAUTH): Change definition. (lib_descr) <weight>: New member. All uses changed. (add_entry): Null arguments ignored. (mutool_ldflags): Rewrite traversal of lib_descr. * mu/dbm.c: New file. * pop3d/Makefile.am (pop3d_LDADD, popauth_LDADD): Add DBM libraries. * pop3d/apop.c: Rewrite using libmu_dbm library calls. * pop3d/bulletin.c: Likewise. * pop3d/logindelay.c: Likewise. * pop3d/pop3d.c: Change USE_DBM to ENABLE_DBM. * pop3d/pop3d.h: Include mailutils/dbm.h instead of mu_dbm.h * pop3d/popauth.c: Rewrite using libmu_dbm library calls. * include/mailutils/cctype.h (MU_CTYPE_ENDLN): New character class. (mu_isendln): New macro. * libmailutils/string/muctype.c (mu_c_tab): Mark \r and \n as MU_CTYPE_ENDLN.
Sergey Poznyakoff authored
-
- 24 Oct, 2011 2 commits
-
-
* include/mailutils/util.h (mu_file_safety_check): Change type of the 3rd argument to uid_t. * libmailutils/base/filesafety.c: Likewise. All uses updated.
Sergey Poznyakoff authored
-
- 23 Oct, 2011 2 commits
-
-
* imap4d/io.c (imap4d_tokbuf_decrlf): New function. (imap4d_tokbuf_expand): Call imap4d_tokbuf_decrlf for literals.
Sergey Poznyakoff authored -
* mh/tests/atlocal.in (mimeflt): ignore stderr, instead of reading input from /dev/null, because this function can theoretically be used as a filter.
Sergey Poznyakoff authored
-
- 22 Oct, 2011 2 commits
-
-
* comsat/comsat.c (main): Use real UID to determine user name. Don't rely on environment variables. * maidag/util.c (maidag_error): Re-initialize va_list before reusing it. * mh/ali.c (ali_print_name_list): Change printing loop to correctly handle empty lists. * mh/mh_whatnow.c (quit): Print newline before returning. * comsat/tests/testsuite.at: Skip tests if run as root. * maidag/tests/forward.at: Skip test if run as root. * mh/tests/ali.at: Ignore comment lines in /etc/passwd and /etc/group. Make sure awk is run with a valid stdin. Some implementations (true awk, in particular) try to close stdin even if it is not used and bail out if unable to do so. * mh/tests/atlocal.in (mimeflt): Make sure awk is run with a valid stdin (see above). * mh/tests/anno.at: Always use semicolon before closing curly brace in sed expressions. * mh/tests/mark.at: Likewise. * mh/tests/pick.at: Likewise. * testsuite/testsuite.inc: Likewise. * mh/tests/comp.at: Reflect changes to mh_whatnow.c. * mh/tests/mhn.at: Don't rely on a particular tar output format.
Sergey Poznyakoff authored -
* include/mailutils/attribute.h (MU_STATUS_BUF_SIZE): Add more status letters. * libmailutils/mailbox/attribute.c (flagtrans): Keep the same ordering as in attribute.h. Add missing attributes. * imap4d/select.c (imap4d_select_status): All flags are now permanent. * imap4d/testsuite/imap4d/IDEF0955.exp: Reflect changes in PERMANENTFLAGS. * imap4d/testsuite/imap4d/IDEF0956.exp: Likewise. * imap4d/testsuite/imap4d/append.exp: Likewise. * imap4d/testsuite/imap4d/create.exp: Likewise. * imap4d/testsuite/imap4d/examine.exp: Likewise. * imap4d/testsuite/imap4d/expunge.exp: Likewise. * imap4d/testsuite/imap4d/fetch.exp: Likewise. * imap4d/testsuite/imap4d/search.exp: Likewise.
Sergey Poznyakoff authored
-
- 21 Oct, 2011 3 commits
-
-
* lib/manlock.c (mailbox_open_and_lock): Open mailbox before retrieving its locker, otherwise it is always NULL. * pop3d/pop3d.c (main): Enforce mandatory locking.
Sergey Poznyakoff authored -
-
- 20 Oct, 2011 2 commits
-
-
* include/mailutils/message.h (MU_MSG_ATTRIBUTE_MODIFIED) (MU_MSG_HEADER_MODIFIED,MU_MSG_BODY_MODIFIED): New flags. * libmailutils/mailbox/message.c (mu_message_is_modified): Return a bitmask from the above values. * libmailutils/property/create.c (mu_property_create_init): Return error code. * include/mailutils/sys/amd.h (_amd_data) <chattr_msg> <capabilities, prop>: New members. <uidvalidity>: Remove. * libmailutils/base/amd.c: Use MH-style proplist to keep the mailbox properties: uidvalidity, last uid and to cache its size. Store message attributes in the message header only if the mailbox implementation is unable to keep them elsewhere. Use chattr_msg method (if provided) to flush changes in message attributes. * libproto/maildir/folder.c (_maildir_list_p): Ignore .mh* and .mu* files. * libproto/mh/folder.c (_mh_list_p): Likewise. * libproto/maildir/mbox.c: Implement all Maildir flags (except P). Implement the chattr_msg method. * libproto/mh/mbox.c: Remove special handling for uidvalidity. * mh/tests/folder.at: Ignore .mu-prop in directory listings.
Sergey Poznyakoff authored -
* libmu_cfg/tls.c (cb2_safety_checks): Fix handling of "all" and "none". * maidag/maidag.c (cb2_forward_file_checks): Likewise. * maidag/forward.c (maidag_forward): Handle MU_ERR_EXISTS return properly.
Sergey Poznyakoff authored
-
- 18 Oct, 2011 1 commit
-
-
- 17 Oct, 2011 1 commit
-
-
Use it in maidag (.forward file safety) and in libmu_auth (TLS files). * include/mailutils/tls.h (mu_tls_module_config): New members for safety check flags. * include/mailutils/util.h (MU_FILE_SAFETY_NONE,MU_FILE_SAFETY_ALL) (MU_FILE_SAFETY_OWNER_MISMATCH) (MU_FILE_SAFETY_GROUP_WRITABLE,MU_FILE_SAFETY_WORLD_WRITABLE) (MU_FILE_SAFETY_GROUP_READABLE,MU_FILE_SAFETY_WORLD_READABLE) (MU_FILE_SAFETY_LINKED_WRDIR) (MU_FILE_SAFETY_DIR_IWGRP,MU_FILE_SAFETY_DIR_IWOTH): New constants. (mu_file_safety_check,mu_file_safety_name_to_code) (mu_file_safety_name_to_error): New protos. * libmailutils/base/checkperms.c: New file. * libmailutils/base/Makefile.am (libbase_la_SOURCES): Add checkperms.c. * libmailutils/diag/errors: Add new error codes. (MU_ERR_UNSAFE_PERMS): change description wording. * libmu_auth/tls.c (mu_check_tls_environment): Use mu_file_safety_check. * libmu_cfg/tls.c (tls_settings): Initialize. (mu_tls_param): New configuration file statements: key-file-safety-checks, cert-file-safety-checks, ca-file-safety-checks. * maidag/forward.c (maidag_forward): Use mu_file_safety_check. * maidag/maidag.c (cb2_forward_file_checks): Use mu_file_safety_name_to_code.
Sergey Poznyakoff authored
-
- 16 Oct, 2011 2 commits
-
-
* scheme/sieve2scm.scmi: Tailor help output to meet help2man expectations. * libmu_scm/mailutils/Makefile.am (EXTRA_DIST): Remove generated file mailutils.scm.
Sergey Poznyakoff authored -
* mh/mhn.c: Open mailbox in read-only mode. * mh/mhseq.c: Likewise. * mh/scan.c: Likewise. * mh/pick.c: If sequences are given, open mailbox for RW, otherwise open it for reading only. * testsuite/testsuite.inc (MUT_MBCHMOD): New macro. (MUT_MBCOPY): Take optional third argument - mailbox mode. * mh/tests/mhl.at: Make sure mailboxes are r/o. * mh/tests/mhn.at: Likewise. * mh/tests/mhseq.at: Likewise. * mh/tests/scan.at: Likewise.
Sergey Poznyakoff authored
-
- 15 Oct, 2011 2 commits
-
-
* libmailutils/base/amd.c (amd_open): Return error if the mailbox cannot be opened for the required access permissions. (amd_message_stream_open): Fix condition for determining r/w access. * mh/mh_list.c (eval_extras): Break the loop if mu_header_aget_field_name fails.
Sergey Poznyakoff authored -
INTERNALDATE now includes a meaningful timezone information (it used to return +0000). Date searches disregard the time and timezone of the INTERNALDATE or Date: header, as mandated by RFC 3501. * libmailutils/base/date.c (mu_parse_ctime_date_time): In the absence of TZ in ctime strings, return local time zone. * imap4d/io.c (imap4d_tokbuf_getline): Kill trailing whitespace. * imap4d/util.c (adjust_tm): New function. (util_parse_internal_date) (util_parse_822_date) (util_parse_ctime_date): Take three arguments, the third one controlling what information to return. All uses updated. * imap4d/fetch.c (_frt_internaldate): Return meaningful timezone. If all else fails, use local TZ. * imap4d/imap4d.h (datetime_parse_mode): New enum. (util_parse_internal_date) (util_parse_822_date) (util_parse_ctime_date): Change signature. * imap4d/search.c (parse_simple_key) (_header_date,cond_before,cond_on,cond_since): Use datetime_date_only mode. * testsuite/spool/search.mbox: New file. * testsuite/spool/DISTFILES: Add search.mbox * imap4d/testsuite/lib/imap4d.exp (imap4d_start): New option -mbox. * imap4d/testsuite/imap4d/search.exp: Rewrite. * imap4d/testsuite/imap4d/create.exp: Account for TZ part in internaldate strings, which may vary. * imap4d/testsuite/imap4d/fetch.exp: Likewise. * imap4d/testsuite/imap4d/list.exp: List the new mailbox.
Sergey Poznyakoff authored
-
- 22 Sep, 2011 1 commit
-
-
* libmailutils/filter/crlfflt.c (_crlf_encoder): Reset state to initial if any character other than \r and \n is read.
Sergey Poznyakoff authored
-
- 09 Sep, 2011 3 commits
-
-
* doc/texinfo/mailutils.texi: Update. * doc/texinfo/rendition.texi: Rewrite.
Sergey Poznyakoff authored -
* doc/texinfo/programs.texi: Use @group inside @cartouche, not vice-versa.
Sergey Poznyakoff authored -
* doc/texinfo/Config: New file. * doc/texinfo/Makefile.am (manual): Use texi2html. * doc/texinfo/gendocs_template: Rewrite. * doc/texinfo/maint.mk: Use VPATH to find source files. Add the `clean' rule.
Sergey Poznyakoff authored
-
- 29 Aug, 2011 3 commits
-
-
* libmailutils/mailbox/header.c (header_read): Always return trailing \n.
Sergey Poznyakoff authored -
* libmailutils/stream/message_stream.c (_message_open): Return MU_ERR_BAD_822_FORMAT if the input is not a valid RFC822.
Sergey Poznyakoff authored
- 28 Aug, 2011 1 commit
- 27 Aug, 2011 1 commit
-
-
- 26 Aug, 2011 1 commit
-
-
* include/mailutils/message.h (mu_message_ref): Change proto. (mu_message_unref): New proto (instead of macro). * include/mailutils/mime.h (mu_mime_ref) (mu_mime_unref, mu_mime_to_message): New protos. * include/mailutils/sys/message.h (MESSAGE_MODIFIED) (MESSAGE_INTERNAL_STREAM): New constants (from mime.c) (MESSAGE_MIME_OWNER): New constant. (_mu_message) <ref_count>: Rename from ref. * include/mailutils/sys/mime.h (MIME_SEEK_ACTIVE): New constant. (_mu_mime) <ref_count>: New member. * libmailutils/mailbox/message.c (MESSAGE_MODIFIED) (MESSAGE_INTERNAL_STREAM): Removed (see above). * libmailutils/mailer/mailer.c (mu_message_unref): New function. (mu_message_destroy): Rewrite. (mu_message_ref): Returns void. (mu_message_lines): Don't access header and body directly to give virtual functions a chance to initialize them. (mu_message_quick_lines): likewise. * libmailutils/mailer/mailer.c (send_fragments): Use mu_mime_to_message instead of mu_message_unref. * libmailutils/mime/mime.c (_mime_append_part): Set offset only if mime->stream is not null. (_mime_body_stream_seek): Implement (albeit inefficiently). (mu_mime_create): Set ref_count. (mu_mime_ref, mu_mime_unref): New functions. (mu_mime_destroy): Reimplement as a wrapper over _mu_mime_free. (mu_mime_get_message): Increase refcount of the message being returned. (mu_mime_to_message): New function. * libmailutils/stream/message_stream.c (_message_open): Handle arbitrary text as RFC822 without headers. * libmu_sieve/actions.c: Unref the message returned by mu_mime_get_message. * libmu_sieve/extensions/vacation.c: Likewise. * mh/mhn.c: Likewise. * libmailutils/stream/stream.c (mu_stream_seek) <MU_SEEK_CUR>: Bugfix.
Sergey Poznyakoff authored
-
- 25 Aug, 2011 1 commit
-
-
* maidag/lmtp.c: Fix typo in a function name. * mh/burst.c (burst_digest): Initialize result.
Sergey Poznyakoff authored
-
- 04 Aug, 2011 1 commit
-
-
* libmailutils/base/assoc.c (first): Set index to max value if tab is NULL to indicate immediate end of iteration. * libmu_auth/sql.c (mu_auth_sql_by_name) (mu_auth_sql_by_uid): Check the return from mu_sql_num_tuples. (mu_sql_getpass): Check the number of returned tuples. Return failure if returned a NULL password. * libmu_scm/mu_message.c (string_sloppy_member): Remove. (mu-message-get-header-fields): Use scm_member instead of string_sloppy_member. * sql/postgres.c (chop): Handle NULL argument.
Sergey Poznyakoff authored
-
- 27 Jul, 2011 1 commit
-
-
- 19 Jul, 2011 1 commit
- 17 Jul, 2011 1 commit
-
-
* libmailutils/base/rfc2047.c (mu_rfc2047_decode): Break if reading from the filter fails. * libmailutils/stream/fltstream.c (filter_read): Treat mu_filter_moreinput in the lastbuf state as error.
Sergey Poznyakoff authored
-
- 14 Jul, 2011 2 commits
-
-
* lib/manlock.c: New file. * lib/Makefile.am (libmuaux_a_SOURCES): Add manlock.c. * lib/muaux.h (manlock_mandatory_locking) (manlock_lock_dir): New externs. (manlock_open_mailbox, manlock_lock) (manlock_touchlock, manlock_unlock): New protos. * libmailutils/base/amd.c (amd_cleanup): Remove unbalanced call to mu_locker_unlock. * libmailutils/base/locker.c (mu_locker_create): Bugfixes. * imap4d/imap4d.c (imap4d_cfg_param): Add mandatory-locking construct. (main): Call manlock_cfg_init. * imap4d/select.c (imap4d_select0): Use mandatory locking if the mailbox is to be opened r/w. * imap4d/rename.c (imap4d_rename): Note FIXME! * imap4d/bye.c: Call manlock_unlock after closing the mailbox. * imap4d/close.c: Likewise. * imap4d/sync.c (imap4d_sync): Call manlock_touchlock. * pop3d/lock.c: Remove. * pop3d/Makefile.am (pop3d_SOURCES): Remove lock.c * pop3d/extra.c (pop3d_abquit): Unlock mailbox. * pop3d/pop3d.c (pop3d_cfg_param): Add mandatory-locking construct. (main): Call manlock_cfg_init. (pop3d_mainloop): Call manlock_touchlock. * pop3d/pop3d.h (pop3d_lock) (pop3d_touchlock, pop3d_unlock): Remove. * pop3d/quit.c (pop3d_quit): Unlock the mailbox. * pop3d/user.c (pop3d_begin_session): Use manlock_open_mailbox.
Sergey Poznyakoff authored
- 07 Jul, 2011 1 commit
-
-
* libmailutils/string/vasnprintf.c (mu_vasnprintf): Operate on a fresh copy of va_alist in each new iteration. * libproto/imap/folder.c: Likewise. * libproto/nntp/nntp_sendline.c: Likewise.
Sergey Poznyakoff authored
-
- 04 Jul, 2011 2 commits
-
-
* include/mailutils/stdstream.h (MU_STDSTREAM_RESET_STRIN) (MU_STDSTREAM_RESET_STROUT,MU_STDSTREAM_RESET_STRERR) (MU_STDSTREAM_RESET_NONE,MU_STDSTREAM_RESET_ALL): New flags. (mu_stdstream_setup): Change signature. All uses updated. * libmailutils/stdstream/basestr.c (mu_stdstream_setup): Use the flags argument to decide whether to close existing streams. Make sure stdstream_flushall enters the onexit queue only once. * libmu_argp/muinit.c (mu_app_init): Don't override variables that may be set by the caller (program_name, tag, streams).
Sergey Poznyakoff authored -
* libmailutils/diag/errors: Fix typo. * libproto/imap/connect.c: Add missing includes. * mh/tests/mhn.at: Add extra argument quoting.
Sergey Poznyakoff authored
-