2009-01-24 Sergey Poznyakoff * src/diskio.c (archive_single_file): Fix errno value (ENOENT instead of EACCESS). Do not update STAT_ARCHIVES. (make_signame): New function. (archive_file): Use make_signame. (do_rmsymlink_file): Take 2nd argument, specifying whether to emit warning on errno==ENOENT. Update STAT_RMSYMLINKS. (rmsymlink_file): Attempt to remove .sig as well, if archive_signatures is set. Do not update STAT_RMSYMLINKS. 2009-01-22 Sergey Poznyakoff * configure.ac, NEWS: Version 1.2 * doc/wydawca.texi: Document new features. * src/wydawca.c (archive_signatures): New variable. * src/wydawca.h (SUF_SIG,SUF_SIG_LEN,SUF_DIR,SUF_DIR_LEN): New macros. (archive_signatures): New variable. * src/config.c: New configuration file statement archive-signatures. * src/process.c (SUF_SIG,SUF_DIR): Move to src/wydawca. * src/diskio.c (backup_file): Do not update statistics. (do_archive_file): Unlink the file after archivation. (archive_single_file): New function. (archive_file): Implicitly archive .sig file, if archive_signatures is set. * src/triplet.c (check_triplet_state): Call verify_directive_file. (triplet_processor): Remove call to verify_directive_file. 2009-01-17 Sergey Poznyakoff * src/config.c (_cfg_raw_read): Fix missing return value. * src/diskio.c (symlink_file): Silently remove existing symlink target. * NEWS: Update. 2008-09-03 Sergey Poznyakoff * configure.ac, NEWS: Version 1.0.90 * doc/wydawca.texi: Mention changes in detailed statistics logging. * etc/wydawca.rc: Remove gray's email * src/wydawca.c (logstats): Log detailed statistics only if at least one counter is not zero. 2008-08-23 Sergey Poznyakoff -= Release 1.0 =- * src/wydawca.c (enable_sendfile): New global. * src/wydawca.h: Likewise. * src/config.c (enable-sendfile): New statement. * src/diskio.c (copy_file): Use enable_sendfile to decide whether to use sendfile. * doc/wydawca.texi: Document enable-sendfile. 2008-07-15 Sergey Poznyakoff * src/wydawca.h (register_message_template): New prototype. * src/verify.c (fill_project_name): Fix return value. * src/config.c (_cfg_raw_read): Remove unused variables. * src/directive.c (directive_version_in_range_p): Version is unsigned. * src/mail.c (do_notify): Remove unused variable. * src/diskio.c (copy_file): Fall back to user-space copying if sendfile fails with EINVAL. Always remove destination file on failure. * src/triplet.c (expand_triplet_upload): Initialize exp->value. 2007-11-19 Sergey Poznyakoff * configure.ac: Use AM_GNU_MAILUTILS * README-hacking: Note mailutils. 2007-09-23 Sergey Poznyakoff * src/verify.c: Add a fixme comment * src/triplet.c (triplet_processor): First check the state of a triplet. Call verify_directive file only if it is triplet_directive or triplet_complete (expand_triplet_full,expand_triplet_upload): Fix coredump if one of components is missing. 2007-09-07 Sergey Poznyakoff Prepared for the release. 2007-09-06 Sergey Poznyakoff * bootstrap: Update * doc/wydawca.texi: Update * src/wydawca.h (notify_project_owner): Remove (enum notification_target): New data type (find_message_template, register_notification) (notification_event_str, notification_target_str): New functions. * src/config.c: Redo message template statements * src/mail.c: Redo notifications * src/mail.h (admin_stat_message_template): Change data type (owner_notification_flags,user_message_template): Remove * src/wydawca.rc: Moved to ... * etc/wydawca.rc: ... here * etc/messages.rc: New file 2007-09-05 Sergey Poznyakoff * doc/wydawca.texi: Update. * src/wydawca.c, src/config.c: Take into account the latest changes to GSC. 2007-09-04 Sergey Poznyakoff * src/config.c: Implement include statements * src/wydawca.rc: Fix typo * doc/wydawca.texi, src/wydawca.c, src/wydawca.rc: Update. 2007-09-01 Sergey Poznyakoff Moved to a separate repository. 2007-08-26 Sergey Poznyakoff * src/wydawca.h (struct file_triplet): New member user (fill_project_name): New function * src/verify.c (get_project_name): Rename to fill_project_name, remove static qualifier. * src/wydawca.rc: Update * src/mail.c (notify_owner): Notify only the submitter on ev_success, ev_bad_directive_signature and ev_bad_detached_signature (should it be made configurable?) (notify): Call fill_project_name * src/triplet.c (hash_triplet_free): Free trp->user (expand_user_real_name, expand_user_email): Change data indices to match those of project_owner_method. Implement project owner notifications. * src/wydawca.c (syslog_printer): Reduce the number of memory reallocations (make_stat_expansion): Update * src/method.c: Implement a new framework: methods may return 2-dimensional arrays of strings. * src/sql.c, src/sql.h: Implement the new method framework. * src/verify.c (expand_param): kw_expansion may provide expansion functions. An additional argument supplies user-defined data for expansions. (escape_kwexp): Extern (free_kwexp): Improve (get_project_name): New function (make_default_kwexp): New function (check_access_rights): Call get_project_name. Use make_default_kwexp to initialize expansions (verify_directive_file): Use make_default_kwexp to initialize expansions * src/wydawca.h (NITEMS): New macro (enum access_method_type): New members: ncol, nrow (struct directory_pair): New members url,project_owner_method, user_data_method (struct file_info): Replace mtime, uid with struct stat sb (struct file_triplet): New members project, dpair, user_data (TRIPLET_UID): Take into account the changes to struct file_info (enum notification_event): New data type (notify_project_owner, notify_admin, notify): New functions (struct kw_expansion): New members static_p, expand and data. (escape_kwexp,make_default_kwexp): New proto (expand_param): Change signature (triplet_expand_param): New function (method_result): Change prototype (method_num_rows,method_num_cols): New functions * src/config.c: New statements project-owner, user-data, admin-address, mail-user, user-message directory can take an optional argument specifying base URL for notification messages * src/gpg.c (verify_directive_signature): Expand directives even if the signature does not match. Useful for notifications. Add notifications. * src/process.c: Add notifications. * src/directive.c: Add notifications * src/wydawca.rc: Update * src/mail.c, src/mail.h: Implement project owner notifications * src/triplet.c (triplet_expand_param): New function 2007-08-25 Sergey Poznyakoff * configure.ac: Require mailutils for wydawca * bootstrap: Require inttostr and strftime * src/mail.h: New file * src/mail.c: New file * src/Makefile.am: Add mail.c and mail.h * src/wydawca.c: Include mail.h (stat_mask_p, make_stat_expansion): New functions (logstats): Call mail_stats (main): Call initialize mailer subsystem * src/sql.c, src/sql.h: Keep usage reference count. Do not deinitialize unless it falls to 0. Do not initialize if it is > 0. * src/verify.c (expand_param): Rewrite to allow long keywords All callers updated. * src/wydawca.h (struct access_method): Keep reference count (struct directory_pair): verify_method and gpg_key_method are pointers to structs. (struct kw_expansion): kw is char* (count_collected_triplets): New function (method_new): New function * src/config.c: reimplement verify-user and gpg-key New keywords mailer, admin-address, from-address, mail-admin-stat and admin-stat-message * src/process.c: Close methods only when their reference count is 0. * src/method.c: Likewise. (method_new): New function * src/wydawca.rc: Update * src/diskio.c: Minor changes * src/triplet.c (count_collected_triplets): New function * src/wydawca.c, src/config.c, src/gpg.c: New stat types STAT_ACCESS_VIOLATIONS and STAT_BAD_SIGNATURES. * src/wydawca.h (expand_param): New function (struct kw_expansion): New data type * src/verify.c (expand_param): Rewrite. (verify_directive_file): Call check_access_rights. 2007-08-24 Sergey Poznyakoff * src/Makefile.am, lib/Makefile.am, jabberd/Makefile.am: Fix include dirs * src/wydawca.c: Use gsc_version to display program version. * doc/gsc.texi: Update * bootstrap: Add vasprintf Implement final statistics. * src/wydawca.c (log_to_stderr): Init to -1 (autodetect) (wydawca_stat,syslog_include_prio,print_stats): New variables (version): Update (main): New options --cron, --syslog Autodetect log_to_stderr value, unless set explicitly (syslog_printer): Output priority string if requested by syslog_include_prio Print final statistics (logmsg): Update statistics (logstats): New function * src/wydawca.h (enum wydawca_stat): New type (STAT_MASK, STAT_MASK_NONE, STAT_MASK_ALL, UPDATE_STATS): New defines (syslog_include_prio,wydawca_stat,print_stats): New globals * src/config.c: New statements "syslog-print-priority" and "statistics" (get_backup_version): Fix handling of ARGMATCH result. * src/directive.c: Update statistics * src/diskio.c: Likewise * src/triplet.c: Likewise * src/wydawca.rc: Update 2007-08-23 Sergey Poznyakoff Improve safety checks; implement symlink/rmsymlink/archive directives; Fix directive signature verification. 2007-08-22 Sergey Poznyakoff * src/exec.c: New file * src/diskio.c, src/directive.c: Implement all directives 2007-08-21 Sergey Poznyakoff * src/wydawca.c (usage): Update New option --lint (tar_command_name): New variable * src/wydawca.h: include backupfile.h (enum archive_type,struct archive_descr): New data types (struct directory_pair.archive): New member (safe_file_name): New function (move_file): Redo prototype (start_prog,log_output): New declarations * src/config.c: Include argmatch.h (safe_file_name): New function (archive,umask,tar-program): New configuration file statemenst * src/gpg.c (start_prog,log_output): Remove static qualifiers * src/directive.c (process_directives): Update * src/wydawca.rc: Update * src/diskio.c (move_file): Implement archiving and backups 2007-08-20 Sergey Poznyakoff * src/sql.c (trim_length): Move to verify.c * src/verify.c (trim_length, trim) (check_access_rights): New functions (expand_param): Export (verify_triplet): Call verify_directive_format and check_access_rights * src/wydawca.h (trim_length, trim, directive_parse) (directive_get_value, directive_pack_version) (directive_version_in_range_p, verify_directive_format) (directive_first, directive_next, process_directives) (create_directory, move_file): New functions (MIN_DIRECTIVE_VERSION,MAX_DIRECTIVE_VERSION) (MKDIR_PERMISSIONS,CREAT_PERMISSIONS): New defines * src/gpg.c (wydawca_gpg_homedir): Return a meaningful value (verify_directive_signature): Call directive_parse * src/process.c (parse_file_name): Return void * src/directive.c: New file * src/diskio.c: New file * src/triplet.c (triplet_processor): Call process_directives (enumerate_triplets): Arg is not const * src/Makefile.am: Add new sources * src/triplet.c (triplet_processor): Minor fix * src/verify.c (verify_triplet): Save owner gid in reg. Call verify_detached_signature * src/wydawca.h (struct file_register): New member gid. (verify_detached_signature): New function * src/gpg.c (verify_detached_signature): New function 2007-08-19 Sergey Poznyakoff * wydawca: New module Local Variables: mode: change-log version-control: never End: