diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2010-12-07 17:58:15 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2010-12-07 18:14:03 +0200 |
commit | 04c2931bb963fefd4654ef2de2cf0667cf8a333d (patch) | |
tree | 6590f36036e32f9aaf84e4eb9355cf810fbfd5e5 /po | |
parent | ac08a8575ae8ea3b85180bd05464a48768f398ee (diff) | |
download | mailutils-04c2931bb963fefd4654ef2de2cf0667cf8a333d.tar.gz mailutils-04c2931bb963fefd4654ef2de2cf0667cf8a333d.tar.bz2 |
Rewrite prog stream support.
Two interfaces are provided: mu_prog_stream_create offers full control
over the program execution environment (i.e. running privileges, cwd,
resource limits) via a set of hints.
A simpler interface, mu_command_stream_create, runs the command in the
current environment.
mu_filter_prog_stream_create is removed, because its functionality can
be achieved by a correspondingly crafted set of hints to
mu_prog_stream_create.
* include/mailutils/prog.h: New file.
* include/mailutils/mailutils.h: Include mailutils/prog.h
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add prog.h
* include/mailutils/stream.h (mu_prog_stream_create)
(mu_filter_prog_stream_create): Remove prototypes.
* include/mailutils/sys/prog_stream.h (_mu_prog_stream): Change structure.
(_mu_prog_limit_codes, _mu_prog_limit_flags): New externs.
* include/mailutils/util.h (mu_set_user_privileges)
(mu_switch_to_privs): New prototypes.
* lib/userprivs.c: Move to libmailutils/base.
* lib/Makefile.am (libmuaux_a_SOURCES): Remove userprivs.c
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add userprivs.c
* libmailutils/base/userprivs.c (mu_set_user_privileges): New function.
(mu_switch_to_privs): Rewrite as another entry point to mu_set_user_privileges.
* libmailutils/stream/prog_stream.c (_mu_prog_limit_flags)
(_mu_prog_limit_codes): New global variables.
(start_program_filter): Use hints to control execution environment.
(_prog_stream_create): Save hints.
(mu_prog_stream_create): Change signature.
(mu_command_stream_create): New function (corresponds to the prior
mu_prog_stream_create).
(mu_filter_prog_stream_create): Remove function.
* comsat/action.c (action_exec): Use new mu_prog_stream_create calling
convention.
* examples/murun.c: Rewrite.
* mh/mhn.c (show_internal): Use new mu_prog_stream_create calling
convention.
* mh/tests/mhn.at: Reflect changes to mhn.
* imap4d/preauth.c: Use mu_command_stream_create.
* libmu_sieve/extensions/pipe.c
* mail/decode.c
* mail/pipe.c
* mail/send.c
* mh/mhl.c
* mu/shell.c
* mail/mail.h: Include mailutils/prog.h
* mh/mh.h
* po/POTFILES.in: Add libmailutils/base/userprivs.c.
Diffstat (limited to 'po')
-rw-r--r-- | po/POTFILES.in | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/po/POTFILES.in b/po/POTFILES.in index d4a1aeb38..3099cf32f 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -118,6 +118,7 @@ mail/unalias.c mail/util.c mail/z.c +libmailutils/base/userprivs.c libmailutils/cfg/driver.c libmailutils/cfg/format.c libmailutils/cfg/lexer.l |