]> granicus.if.org Git - sudo/commitdiff
Rename plugin "args" to "options"
authorTodd C. Miller <Todd.Miller@courtesan.com>
Thu, 15 Mar 2012 16:32:31 +0000 (12:32 -0400)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Thu, 15 Mar 2012 16:32:31 +0000 (12:32 -0400)
16 files changed:
common/sudo_conf.c
doc/sample.sudo.conf
doc/sudo.cat
doc/sudo.man.in
doc/sudo.pod
doc/sudo_plugin.cat
doc/sudo_plugin.man.in
doc/sudo_plugin.pod
doc/sudoers.cat
doc/sudoers.man.in
doc/sudoers.pod
include/sudo_conf.h
include/sudo_plugin.h
src/load_plugins.c
src/sudo.c
src/sudo_plugin_int.h

index dded1a80c5d71d1fd0c3eccca05fa33d0347582f..bf34254bce558e78955951138ca7019c83a4c162 100644 (file)
@@ -205,9 +205,9 @@ set_plugin(const char *entry)
 {
     struct plugin_info *info;
     const char *name, *path, *cp, *ep;
-    char **args = NULL;
+    char **options = NULL;
     size_t namelen, pathlen;
-    unsigned int nargs;
+    unsigned int nopts;
 
     /* Parse Plugin line */
     name = entry;
@@ -218,34 +218,34 @@ set_plugin(const char *entry)
     while (isblank((unsigned char)*path))
        path++;
     if ((cp = strpbrk(path, " \t")) != NULL) {
-       /* Convert extra args to an array. */
+       /* Convert any options to an array. */
        pathlen = (size_t)(cp - path);
        while (isblank((unsigned char)*cp))
            cp++;
-       /* Count number of args and allocate array. */
-       for (ep = cp, nargs = 1; (ep = strpbrk(ep, " \t")) != NULL; nargs++) {
+       /* Count number of options and allocate array. */
+       for (ep = cp, nopts = 1; (ep = strpbrk(ep, " \t")) != NULL; nopts++) {
            while (isblank((unsigned char)*ep))
                ep++;
        }
-       args = emalloc2(nargs + 1, sizeof(*args));
-       /* Fill in args array, there is at least one element. */
-       for (nargs = 0; (ep = strpbrk(cp, " \t")) != NULL; ) {
-           args[nargs++] = estrndup(cp, (size_t)(ep - cp));
+       options = emalloc2(nopts + 1, sizeof(*options));
+       /* Fill in options array, there is at least one element. */
+       for (nopts = 0; (ep = strpbrk(cp, " \t")) != NULL; ) {
+           options[nopts++] = estrndup(cp, (size_t)(ep - cp));
            while (isblank((unsigned char)*ep))
                ep++;
            cp = ep;
        }
-       args[nargs++] = estrdup(cp);
-       args[nargs] = NULL;
+       options[nopts++] = estrdup(cp);
+       options[nopts] = NULL;
     } else {
-       /* No extra args. */
+       /* No extra options. */
        pathlen = strlen(path);
     }
 
     info = emalloc(sizeof(*info));
     info->symbol_name = estrndup(name, namelen);
     info->path = estrndup(path, pathlen);
-    info->args = args;
+    info->options = options;
     info->prev = info;
     info->next = NULL;
     tq_append(&sudo_conf_data.plugins, info);
@@ -353,7 +353,7 @@ done:
        info = emalloc(sizeof(*info));
        info->symbol_name = "sudoers_policy";
        info->path = SUDOERS_PLUGIN;
-       info->args = NULL;
+       info->options = NULL;
        info->prev = info;
        info->next = NULL;
        tq_append(&sudo_conf_data.plugins, info);
@@ -362,7 +362,7 @@ done:
        info = emalloc(sizeof(*info));
        info->symbol_name = "sudoers_io";
        info->path = SUDOERS_PLUGIN;
-       info->args = NULL;
+       info->options = NULL;
        info->prev = info;
        info->next = NULL;
        tq_append(&sudo_conf_data.plugins, info);
index 34be4bd3e2ce11380c967e69ceaeea22ccd36a79..3672bcbad94560ff9b010aaaf3b35f528a6f3940 100644 (file)
@@ -2,7 +2,7 @@
 # Sample /etc/sudo.conf file
 #
 # Format:
-#   Plugin plugin_name plugin_path plugin_args ...
+#   Plugin plugin_name plugin_path plugin_options ...
 #   Path askpass /path/to/askpass
 #   Path noexec /path/to/sudo_noexec.so
 #   Debug sudo /var/log/sudo_debug all@warn
@@ -13,7 +13,7 @@
 # The plugin_path is relative to ${prefix}/libexec unless fully qualified.
 # The plugin_name corresponds to a global symbol in the plugin
 #   that contains the plugin interface structure.
-# The plugin_args are optional.
+# The plugin_options are optional.
 #
 # The sudoers plugin is used by default if no Plugin lines are present.
 Plugin sudoers_policy sudoers.so
index 6fb8db536347ce97fe482ae9e5197c52054e0331..c32092beee90009637cb04e207d0237298cf6377 100644 (file)
@@ -326,7 +326,7 @@ P\bPL\bLU\bUG\bGI\bIN\bNS\bS
         # Default /etc/sudo.conf file
         #
         # Format:
-        #   Plugin plugin_name plugin_path plugin_args ...
+        #   Plugin plugin_name plugin_path plugin_options ...
         #   Path askpass /path/to/askpass
         #   Path noexec /path/to/sudo_noexec.so
         #   Debug sudo /var/log/sudo_debug all@warn
@@ -336,7 +336,7 @@ P\bPL\bLU\bUG\bGI\bIN\bNS\bS
         #   fully qualified.
         # The plugin_name corresponds to a global symbol in the plugin
         #   that contains the plugin interface structure.
-        # The plugin_args are optional.
+        # The plugin_options are optional.
         #
         Plugin policy_plugin sudoers.so
         Plugin io_plugin sudoers.so
@@ -624,4 +624,4 @@ D\bDI\bIS\bSC\bCL\bLA\bAI\bIM\bME\bER\bR
 
 
 
-1.8.5                           March 14, 2012                        SUDO(1m)
+1.8.5                           March 15, 2012                        SUDO(1m)
index e2051c8a127e90f9c92c12c2f85468412a93e670..856164e35e1f05927bee086827bf8752782ca42f 100644 (file)
 .\" ========================================================================
 .\"
 .IX Title "SUDO @mansectsu@"
-.TH SUDO @mansectsu@ "March 14, 2012" "1.8.5" "MAINTENANCE COMMANDS"
+.TH SUDO @mansectsu@ "March 15, 2012" "1.8.5" "MAINTENANCE COMMANDS"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
@@ -526,7 +526,7 @@ which corresponds to the following \fI@sysconfdir@/sudo.conf\fR file.
 \& # Default @sysconfdir@/sudo.conf file
 \& #
 \& # Format:
-\& #   Plugin plugin_name plugin_path plugin_args ...
+\& #   Plugin plugin_name plugin_path plugin_options ...
 \& #   Path askpass /path/to/askpass
 \& #   Path noexec /path/to/sudo_noexec.so
 \& #   Debug sudo /var/log/sudo_debug all@warn
@@ -536,7 +536,7 @@ which corresponds to the following \fI@sysconfdir@/sudo.conf\fR file.
 \& #   fully qualified.
 \& # The plugin_name corresponds to a global symbol in the plugin
 \& #   that contains the plugin interface structure.
-\& # The plugin_args are optional.
+\& # The plugin_options are optional.
 \& #
 \& Plugin policy_plugin sudoers.so
 \& Plugin io_plugin sudoers.so
index 50769f1a361b274bb54d9d60809a4e1be50a796f..b9f7578b783bd77d93c73466f296ebce67faa604 100644 (file)
@@ -421,7 +421,7 @@ which corresponds to the following F<@sysconfdir@/sudo.conf> file.
  # Default @sysconfdir@/sudo.conf file
  #
  # Format:
- #   Plugin plugin_name plugin_path plugin_args ...
+ #   Plugin plugin_name plugin_path plugin_options ...
  #   Path askpass /path/to/askpass
  #   Path noexec /path/to/sudo_noexec.so
  #   Debug sudo /var/log/sudo_debug all@warn
@@ -431,7 +431,7 @@ which corresponds to the following F<@sysconfdir@/sudo.conf> file.
  #   fully qualified.
  # The plugin_name corresponds to a global symbol in the plugin
  #   that contains the plugin interface structure.
- # The plugin_args are optional.
+ # The plugin_options are optional.
  #
  Plugin policy_plugin sudoers.so
  Plugin io_plugin sudoers.so 
index 2cdff1bda2b91bee72b073bc8ab858f54987b550..6ceba0f2f5bfadea64d738648722732ce8c54684 100644 (file)
@@ -32,8 +32,8 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
        io_plugin in the plugin shared object.  The _\bp_\ba_\bt_\bh may be fully qualified
        or relative.  If not fully qualified it is relative to the
        _\b/_\bu_\bs_\br_\b/_\bl_\bo_\bc_\ba_\bl_\b/_\bl_\bi_\bb_\be_\bx_\be_\bc directory.  Any additional parameters after the _\bp_\ba_\bt_\bh
-       are passed as arguments to the plugin's _\bo_\bp_\be_\bn function.  Lines that
-       don't begin with Plugin, Path, Debug or Set are silently ignored.
+       are passed as options to the plugin's _\bo_\bp_\be_\bn function.  Lines that don't
+       begin with Plugin, Path, Debug or Set are silently ignored.
 
        The same shared object may contain multiple plugins, each with a
        different symbol name.  The shared object file must be owned by uid 0
@@ -45,7 +45,7 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
         # Default /etc/sudo.conf file
         #
         # Format:
-        #   Plugin plugin_name plugin_path optional_args
+        #   Plugin plugin_name plugin_path plugin_options ...
         #   Path askpass /path/to/askpass
         #   Path noexec /path/to/sudo_noexec.so
         #   Debug sudo /var/log/sudo_debug all@warn
@@ -55,7 +55,7 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
         #   fully qualified.
         # The plugin_name corresponds to a global symbol in the plugin
         #   that contains the plugin interface structure.
-        # The plugin_args are optional.
+        # The plugin_options are optional.
         #
         Plugin sudoers_policy sudoers.so
         Plugin sudoers_io sudoers.so
@@ -74,7 +74,7 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
             int (*open)(unsigned int version, sudo_conv_t conversation,
                         sudo_printf_t plugin_printf, char * const settings[],
                         char * const user_info[], char * const user_env[],
-                        char * const plugin_args[]);
+                        char * const plugin_options[]);
             void (*close)(int exit_status, int error);
             int (*show_version)(int verbose);
             int (*check_policy)(int argc, char * const argv[],
@@ -106,7 +106,7 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
             int (*open)(unsigned int version, sudo_conv_t conversation,
                         sudo_printf_t plugin_printf, char * const settings[],
                         char * const user_info[], char * const user_env[],
-                        char * const plugin_args[]);
+                        char * const plugin_options[]);
 
            Returns 1 on success, 0 on failure, -1 if a general error occurred,
            or -2 if there was a usage error.  In the latter case, s\bsu\bud\bdo\bo will
@@ -319,17 +319,17 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
                equal sign ('=') since the _\bn_\ba_\bm_\be field will never include one
                itself but the _\bv_\ba_\bl_\bu_\be might.
 
-           plugin_args
+           plugin_options
                Any (non-comment) strings immediately after the plugin path are
                treated as arguments to the plugin.  These arguments are split
                on a white space boundary and are passed to the plugin in the
                form of a NULL-terminated array of strings.  If no arguments
-               were specified, _\bp_\bl_\bu_\bg_\bi_\bn_\b__\ba_\br_\bg_\bs will be the NULL pointer.
+               were specified, _\bp_\bl_\bu_\bg_\bi_\bn_\b__\bo_\bp_\bt_\bi_\bo_\bn_\bs will be the NULL pointer.
 
-               NOTE: the _\bp_\bl_\bu_\bg_\bi_\bn_\b__\ba_\br_\bg_\bs parameter is only available starting with
-               API version 1.2.  A plugin m\bmu\bus\bst\bt check the API version specified
-               by the s\bsu\bud\bdo\bo front end before using _\bp_\bl_\bu_\bg_\bi_\bn_\b__\ba_\br_\bg_\bs.  Failure to do
-               so may result in a crash.
+               NOTE: the _\bp_\bl_\bu_\bg_\bi_\bn_\b__\bo_\bp_\bt_\bi_\bo_\bn_\bs parameter is only available starting
+               with API version 1.2.  A plugin m\bmu\bus\bst\bt check the API version
+               specified by the s\bsu\bud\bdo\bo front end before using _\bp_\bl_\bu_\bg_\bi_\bn_\b__\bo_\bp_\bt_\bi_\bo_\bn_\bs.
+               Failure to do so may result in a crash.
 
        close
             void (*close)(int exit_status, int error);
@@ -730,7 +730,7 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
             int (*open)(unsigned int version, sudo_conv_t conversation
                         sudo_printf_t plugin_printf, char * const settings[],
                         char * const user_info[], int argc, char * const argv[],
-                        char * const user_env[], char * const plugin_args[]);
+                        char * const user_env[], char * const plugin_options[]);
             void (*close)(int exit_status, int error); /* wait status or error */
             int (*show_version)(int verbose);
             int (*log_ttyin)(const char *buf, unsigned int len);
@@ -777,7 +777,7 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
             int (*open)(unsigned int version, sudo_conv_t conversation
                         sudo_printf_t plugin_printf, char * const settings[],
                         char * const user_info[], int argc, char * const argv[],
-                        char * const user_env[], char * const plugin_args[]);
+                        char * const user_env[], char * const plugin_options[]);
 
            The _\bo_\bp_\be_\bn function is run before the _\bl_\bo_\bg_\b__\bi_\bn_\bp_\bu_\bt, _\bl_\bo_\bg_\b__\bo_\bu_\bt_\bp_\bu_\bt or
            _\bs_\bh_\bo_\bw_\b__\bv_\be_\br_\bs_\bi_\bo_\bn functions are called.  It is only called if the
@@ -854,17 +854,17 @@ D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
                equal sign ('=') since the _\bn_\ba_\bm_\be field will never include one
                itself but the _\bv_\ba_\bl_\bu_\be might.
 
-           plugin_args
+           plugin_options
                Any (non-comment) strings immediately after the plugin path are
                treated as arguments to the plugin.  These arguments are split
                on a white space boundary and are passed to the plugin in the
                form of a NULL-terminated array of strings.  If no arguments
-               were specified, _\bp_\bl_\bu_\bg_\bi_\bn_\b__\ba_\br_\bg_\bs will be the NULL pointer.
+               were specified, _\bp_\bl_\bu_\bg_\bi_\bn_\b__\bo_\bp_\bt_\bi_\bo_\bn_\bs will be the NULL pointer.
 
-               NOTE: the _\bp_\bl_\bu_\bg_\bi_\bn_\b__\ba_\br_\bg_\bs parameter is only available starting with
-               API version 1.2.  A plugin m\bmu\bus\bst\bt check the API version specified
-               by the s\bsu\bud\bdo\bo front end before using _\bp_\bl_\bu_\bg_\bi_\bn_\b__\ba_\br_\bg_\bs.  Failure to do
-               so may result in a crash.
+               NOTE: the _\bp_\bl_\bu_\bg_\bi_\bn_\b__\bo_\bp_\bt_\bi_\bo_\bn_\bs parameter is only available starting
+               with API version 1.2.  A plugin m\bmu\bus\bst\bt check the API version
+               specified by the s\bsu\bud\bdo\bo front end before using _\bp_\bl_\bu_\bg_\bi_\bn_\b__\bo_\bp_\bt_\bi_\bo_\bn_\bs.
+               Failure to do so may result in a crash.
 
        close
             void (*close)(int exit_status, int error);
index 66511f577b2e7ad275c2ca4629bf40c8e907e96a..2565f53190909dae5f597685e536bbf4da1ccb87 100644 (file)
@@ -174,7 +174,7 @@ plugin.  The \fIsymbol_name\fR is the name of the \f(CW\*(C`struct policy_plugin
 or \f(CW\*(C`struct io_plugin\*(C'\fR in the plugin shared object.  The \fIpath\fR
 may be fully qualified or relative.  If not fully qualified it is
 relative to the \fI@prefix@/libexec\fR directory.  Any additional
-parameters after the \fIpath\fR are passed as arguments to the plugin's
+parameters after the \fIpath\fR are passed as options to the plugin's
 \&\fIopen\fR function.  Lines that don't begin with \f(CW\*(C`Plugin\*(C'\fR, \f(CW\*(C`Path\*(C'\fR,
 \&\f(CW\*(C`Debug\*(C'\fR or \f(CW\*(C`Set\*(C'\fR are silently ignored.
 .PP
@@ -189,7 +189,7 @@ This limitation does not apply to I/O plugins.
 \& # Default @sysconfdir@/sudo.conf file
 \& #
 \& # Format:
-\& #   Plugin plugin_name plugin_path optional_args
+\& #   Plugin plugin_name plugin_path plugin_options ...
 \& #   Path askpass /path/to/askpass
 \& #   Path noexec /path/to/sudo_noexec.so
 \& #   Debug sudo /var/log/sudo_debug all@warn
@@ -199,7 +199,7 @@ This limitation does not apply to I/O plugins.
 \& #   fully qualified.
 \& # The plugin_name corresponds to a global symbol in the plugin
 \& #   that contains the plugin interface structure.
-\& # The plugin_args are optional.
+\& # The plugin_options are optional.
 \& #
 \& Plugin sudoers_policy sudoers.so
 \& Plugin sudoers_io sudoers.so
@@ -220,7 +220,7 @@ so that \fBsudo\fR can load it.
 \&     int (*open)(unsigned int version, sudo_conv_t conversation,
 \&                 sudo_printf_t plugin_printf, char * const settings[],
 \&                 char * const user_info[], char * const user_env[],
-\&                 char * const plugin_args[]);
+\&                 char * const plugin_options[]);
 \&     void (*close)(int exit_status, int error);
 \&     int (*show_version)(int verbose);
 \&     int (*check_policy)(int argc, char * const argv[],
@@ -254,7 +254,7 @@ built against.
 \& int (*open)(unsigned int version, sudo_conv_t conversation,
 \&             sudo_printf_t plugin_printf, char * const settings[],
 \&             char * const user_info[], char * const user_env[],
-\&             char * const plugin_args[]);
+\&             char * const plugin_options[]);
 .Ve
 .Sp
 Returns 1 on success, 0 on failure, \-1 if a general error occurred,
@@ -468,17 +468,17 @@ The user's environment in the form of a \f(CW\*(C`NULL\*(C'\fR\-terminated vecto
 When parsing \fIuser_env\fR, the plugin should split on the \fBfirst\fR
 equal sign ('=') since the \fIname\fR field will never include one
 itself but the \fIvalue\fR might.
-.IP "plugin_args" 4
-.IX Item "plugin_args"
+.IP "plugin_options" 4
+.IX Item "plugin_options"
 Any (non-comment) strings immediately after the plugin path are
 treated as arguments to the plugin.  These arguments are split on
 a white space boundary and are passed to the plugin in the form of
 a \f(CW\*(C`NULL\*(C'\fR\-terminated array of strings.  If no arguments were
-specified, \fIplugin_args\fR will be the \s-1NULL\s0 pointer.
+specified, \fIplugin_options\fR will be the \s-1NULL\s0 pointer.
 .Sp
-\&\s-1NOTE:\s0 the \fIplugin_args\fR parameter is only available starting with
+\&\s-1NOTE:\s0 the \fIplugin_options\fR parameter is only available starting with
 \&\s-1API\s0 version 1.2.  A plugin \fBmust\fR check the \s-1API\s0 version specified
-by the \fBsudo\fR front end before using \fIplugin_args\fR.  Failure to
+by the \fBsudo\fR front end before using \fIplugin_options\fR.  Failure to
 do so may result in a crash.
 .RE
 .RS 4
@@ -909,7 +909,7 @@ version 1.2 or higher, \f(CW\*(C`deregister_hooks\*(C'\fR will not be called.
 \&     int (*open)(unsigned int version, sudo_conv_t conversation
 \&                 sudo_printf_t plugin_printf, char * const settings[],
 \&                 char * const user_info[], int argc, char * const argv[],
-\&                 char * const user_env[], char * const plugin_args[]);
+\&                 char * const user_env[], char * const plugin_options[]);
 \&     void (*close)(int exit_status, int error); /* wait status or error */
 \&     int (*show_version)(int verbose);
 \&     int (*log_ttyin)(const char *buf, unsigned int len);
@@ -959,7 +959,7 @@ built against.
 \& int (*open)(unsigned int version, sudo_conv_t conversation
 \&             sudo_printf_t plugin_printf, char * const settings[],
 \&             char * const user_info[], int argc, char * const argv[],
-\&             char * const user_env[], char * const plugin_args[]);
+\&             char * const user_env[], char * const plugin_options[]);
 .Ve
 .Sp
 The \fIopen\fR function is run before the \fIlog_input\fR, \fIlog_output\fR
@@ -1034,17 +1034,17 @@ The user's environment in the form of a \f(CW\*(C`NULL\*(C'\fR\-terminated vecto
 When parsing \fIuser_env\fR, the plugin should split on the \fBfirst\fR
 equal sign ('=') since the \fIname\fR field will never include one
 itself but the \fIvalue\fR might.
-.IP "plugin_args" 4
-.IX Item "plugin_args"
+.IP "plugin_options" 4
+.IX Item "plugin_options"
 Any (non-comment) strings immediately after the plugin path are
 treated as arguments to the plugin.  These arguments are split on
 a white space boundary and are passed to the plugin in the form of
 a \f(CW\*(C`NULL\*(C'\fR\-terminated array of strings.  If no arguments were
-specified, \fIplugin_args\fR will be the \s-1NULL\s0 pointer.
+specified, \fIplugin_options\fR will be the \s-1NULL\s0 pointer.
 .Sp
-\&\s-1NOTE:\s0 the \fIplugin_args\fR parameter is only available starting with
+\&\s-1NOTE:\s0 the \fIplugin_options\fR parameter is only available starting with
 \&\s-1API\s0 version 1.2.  A plugin \fBmust\fR check the \s-1API\s0 version specified
-by the \fBsudo\fR front end before using \fIplugin_args\fR.  Failure to
+by the \fBsudo\fR front end before using \fIplugin_options\fR.  Failure to
 do so may result in a crash.
 .RE
 .RS 4
index c9d831e75871567abdac8c51ac51ad34808215cc..642ad9b6e3282a7d716f86c088929acdcab8da39 100644 (file)
@@ -48,7 +48,7 @@ plugin.  The I<symbol_name> is the name of the C<struct policy_plugin>
 or C<struct io_plugin> in the plugin shared object.  The I<path>
 may be fully qualified or relative.  If not fully qualified it is
 relative to the F<@prefix@/libexec> directory.  Any additional
-parameters after the I<path> are passed as arguments to the plugin's
+parameters after the I<path> are passed as options to the plugin's
 I<open> function.  Lines that don't begin with C<Plugin>, C<Path>,
 C<Debug> or C<Set> are silently ignored.
 
@@ -62,7 +62,7 @@ This limitation does not apply to I/O plugins.
  # Default @sysconfdir@/sudo.conf file
  #
  # Format:
- #   Plugin plugin_name plugin_path optional_args
+ #   Plugin plugin_name plugin_path plugin_options ...
  #   Path askpass /path/to/askpass
  #   Path noexec /path/to/sudo_noexec.so
  #   Debug sudo /var/log/sudo_debug all@warn
@@ -72,7 +72,7 @@ This limitation does not apply to I/O plugins.
  #   fully qualified.
  # The plugin_name corresponds to a global symbol in the plugin
  #   that contains the plugin interface structure.
- # The plugin_args are optional.
+ # The plugin_options are optional.
  #
  Plugin sudoers_policy sudoers.so
  Plugin sudoers_io sudoers.so
@@ -92,7 +92,7 @@ so that B<sudo> can load it.
      int (*open)(unsigned int version, sudo_conv_t conversation,
                  sudo_printf_t plugin_printf, char * const settings[],
                  char * const user_info[], char * const user_env[],
-                 char * const plugin_args[]);
+                 char * const plugin_options[]);
      void (*close)(int exit_status, int error);
      int (*show_version)(int verbose);
      int (*check_policy)(int argc, char * const argv[],
@@ -129,7 +129,7 @@ built against.
  int (*open)(unsigned int version, sudo_conv_t conversation,
              sudo_printf_t plugin_printf, char * const settings[],
              char * const user_info[], char * const user_env[],
-             char * const plugin_args[]);
+             char * const plugin_options[]);
 
 Returns 1 on success, 0 on failure, -1 if a general error occurred,
 or -2 if there was a usage error.  In the latter case, B<sudo> will
@@ -380,17 +380,17 @@ When parsing I<user_env>, the plugin should split on the B<first>
 equal sign ('=') since the I<name> field will never include one
 itself but the I<value> might.
 
-=item plugin_args
+=item plugin_options
 
 Any (non-comment) strings immediately after the plugin path are
 treated as arguments to the plugin.  These arguments are split on
 a white space boundary and are passed to the plugin in the form of
 a C<NULL>-terminated array of strings.  If no arguments were
-specified, I<plugin_args> will be the NULL pointer.
+specified, I<plugin_options> will be the NULL pointer.
 
-NOTE: the I<plugin_args> parameter is only available starting with
+NOTE: the I<plugin_options> parameter is only available starting with
 API version 1.2.  A plugin B<must> check the API version specified
-by the B<sudo> front end before using I<plugin_args>.  Failure to
+by the B<sudo> front end before using I<plugin_options>.  Failure to
 do so may result in a crash.
 
 =back
@@ -850,7 +850,7 @@ version 1.2 or higher, C<deregister_hooks> will not be called.
      int (*open)(unsigned int version, sudo_conv_t conversation
                  sudo_printf_t plugin_printf, char * const settings[],
                  char * const user_info[], int argc, char * const argv[],
-                 char * const user_env[], char * const plugin_args[]);
+                 char * const user_env[], char * const plugin_options[]);
      void (*close)(int exit_status, int error); /* wait status or error */
      int (*show_version)(int verbose);
      int (*log_ttyin)(const char *buf, unsigned int len);
@@ -903,7 +903,7 @@ built against.
  int (*open)(unsigned int version, sudo_conv_t conversation
              sudo_printf_t plugin_printf, char * const settings[],
              char * const user_info[], int argc, char * const argv[],
-             char * const user_env[], char * const plugin_args[]);
+             char * const user_env[], char * const plugin_options[]);
 
 The I<open> function is run before the I<log_input>, I<log_output>
 or I<show_version> functions are called.  It is only called if the
@@ -987,17 +987,17 @@ When parsing I<user_env>, the plugin should split on the B<first>
 equal sign ('=') since the I<name> field will never include one
 itself but the I<value> might.
 
-=item plugin_args
+=item plugin_options
 
 Any (non-comment) strings immediately after the plugin path are
 treated as arguments to the plugin.  These arguments are split on
 a white space boundary and are passed to the plugin in the form of
 a C<NULL>-terminated array of strings.  If no arguments were
-specified, I<plugin_args> will be the NULL pointer.
+specified, I<plugin_options> will be the NULL pointer.
 
-NOTE: the I<plugin_args> parameter is only available starting with
+NOTE: the I<plugin_options> parameter is only available starting with
 API version 1.2.  A plugin B<must> check the API version specified
-by the B<sudo> front end before using I<plugin_args>.  Failure to
+by the B<sudo> front end before using I<plugin_options>.  Failure to
 do so may result in a crash.
 
 =back
index d6e9d45eaa862e9931a9082e688b6fa9e9652c64..e59a198a889b3c48e8d865c32821c8b693b76414 100644 (file)
@@ -1350,7 +1350,7 @@ S\bSU\bUD\bDO\bO.\b.C\bCO\bON\bNF\bF
         # Default /etc/sudo.conf file
         #
         # Format:
-        #   Plugin plugin_name plugin_path plugin_args ...
+        #   Plugin plugin_name plugin_path plugin_options ...
         #   Path askpass /path/to/askpass
         #   Path noexec /path/to/sudo_noexec.so
         #   Debug sudo /var/log/sudo_debug all@warn
@@ -1360,7 +1360,7 @@ S\bSU\bUD\bDO\bO.\b.C\bCO\bON\bNF\bF
         #   fully qualified.
         # The plugin_name corresponds to a global symbol in the plugin
         #   that contains the plugin interface structure.
-        # The plugin_args are optional.
+        # The plugin_options are optional.
         #
         Plugin policy_plugin sudoers.so
         Plugin io_plugin sudoers.so
@@ -1806,4 +1806,4 @@ D\bDI\bIS\bSC\bCL\bLA\bAI\bIM\bME\bER\bR
 
 
 
-1.8.5                           March 14, 2012                      SUDOERS(4)
+1.8.5                           March 15, 2012                      SUDOERS(4)
index ef77a69b0125c45c7cf1c6a914ec627934b795e3..53792d2b28af7374e27f8d8557c3e2bfe3b947aa 100644 (file)
 .\" ========================================================================
 .\"
 .IX Title "SUDOERS @mansectform@"
-.TH SUDOERS @mansectform@ "March 14, 2012" "1.8.5" "MAINTENANCE COMMANDS"
+.TH SUDOERS @mansectform@ "March 15, 2012" "1.8.5" "MAINTENANCE COMMANDS"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
@@ -1644,7 +1644,7 @@ the following \fI@sysconfdir@/sudo.conf\fR file.
 \& # Default @sysconfdir@/sudo.conf file
 \& #
 \& # Format:
-\& #   Plugin plugin_name plugin_path plugin_args ...
+\& #   Plugin plugin_name plugin_path plugin_options ...
 \& #   Path askpass /path/to/askpass
 \& #   Path noexec /path/to/sudo_noexec.so
 \& #   Debug sudo /var/log/sudo_debug all@warn
@@ -1654,7 +1654,7 @@ the following \fI@sysconfdir@/sudo.conf\fR file.
 \& #   fully qualified.
 \& # The plugin_name corresponds to a global symbol in the plugin
 \& #   that contains the plugin interface structure.
-\& # The plugin_args are optional.
+\& # The plugin_options are optional.
 \& #
 \& Plugin policy_plugin sudoers.so
 \& Plugin io_plugin sudoers.so
index e807bbfe77304bc6489f72341cb2c1d99e34224b..841bf742ae990051ef8ebaee64064296f55714aa 100644 (file)
@@ -1606,7 +1606,7 @@ the following F<@sysconfdir@/sudo.conf> file.
  # Default @sysconfdir@/sudo.conf file
  #
  # Format:
- #   Plugin plugin_name plugin_path plugin_args ...
+ #   Plugin plugin_name plugin_path plugin_options ...
  #   Path askpass /path/to/askpass
  #   Path noexec /path/to/sudo_noexec.so
  #   Debug sudo /var/log/sudo_debug all@warn
@@ -1616,7 +1616,7 @@ the following F<@sysconfdir@/sudo.conf> file.
  #   fully qualified.
  # The plugin_name corresponds to a global symbol in the plugin
  #   that contains the plugin interface structure.
- # The plugin_args are optional.
+ # The plugin_options are optional.
  #
  Plugin policy_plugin sudoers.so
  Plugin io_plugin sudoers.so 
index 9e0ea14bbbb9c2e43eb8fb0c280d75f3750b434e..c0dcc5a5f0ffee422d3fb79036d7d60bc834fa10 100644 (file)
@@ -24,7 +24,7 @@ struct plugin_info {
     struct plugin_info *next; /* required */
     const char *path;
     const char *symbol_name;
-    char * const * args;
+    char * const * options;
 };
 TQ_DECLARE(plugin_info)
 
index 828b8507944d5512e84399fffc9d21df2c62c0ea..52dee0adf6bb108e3a4c26b744f42c6d861b6a02 100644 (file)
@@ -117,7 +117,7 @@ struct policy_plugin {
     int (*open)(unsigned int version, sudo_conv_t conversation,
        sudo_printf_t sudo_printf, char * const settings[],
        char * const user_info[], char * const user_env[],
-       char * const plugin_args[]);
+       char * const plugin_plugins[]);
     void (*close)(int exit_status, int error); /* wait status or error */
     int (*show_version)(int verbose);
     int (*check_policy)(int argc, char * const argv[],
@@ -141,7 +141,7 @@ struct io_plugin {
        sudo_printf_t sudo_printf, char * const settings[],
        char * const user_info[], char * const command_info[],
        int argc, char * const argv[], char * const user_env[],
-       char * const plugin_args[]);
+       char * const plugin_plugins[]);
     void (*close)(int exit_status, int error); /* wait status or error */
     int (*show_version)(int verbose);
     int (*log_ttyin)(const char *buf, unsigned int len);
index d85e08910e48a22bb04e174f1c7c8db806fb5f55..45d63a1296f6773b8929a4881af2c417f1ef16c7 100644 (file)
@@ -131,7 +131,7 @@ sudo_load_plugins(struct plugin_container *policy_plugin,
            }
            policy_plugin->handle = handle;
            policy_plugin->name = info->symbol_name;
-           policy_plugin->args = info->args;
+           policy_plugin->options = info->options;
            policy_plugin->u.generic = plugin;
        } else if (plugin->type == SUDO_IO_PLUGIN) {
            container = emalloc(sizeof(*container));
@@ -139,7 +139,7 @@ sudo_load_plugins(struct plugin_container *policy_plugin,
            container->next = NULL;
            container->handle = handle;
            container->name = info->symbol_name;
-           container->args = info->args;
+           container->options = info->options;
            container->u.generic = plugin;
            tq_append(io_plugins, container);
        }
index d075566ea3b02f0c81ec7ea9ae0846b47c2f9cb0..6f5d7a7a10cc352442537512fb1e40bafa8287cb 100644 (file)
@@ -1065,7 +1065,7 @@ policy_open(struct plugin_container *plugin, char * const settings[],
        break;
     default:
        rval = plugin->u.policy->open(SUDO_API_VERSION, sudo_conversation,
-           _sudo_printf, settings, user_info, user_env, plugin->args);
+           _sudo_printf, settings, user_info, user_env, plugin->options);
     }
 
     debug_return_bool(rval);
@@ -1180,7 +1180,7 @@ iolog_open(struct plugin_container *plugin, char * const settings[],
     default:
        rval = plugin->u.io->open(SUDO_API_VERSION, sudo_conversation,
            _sudo_printf, settings, user_info, command_info,
-           argc, argv, user_env, plugin->args);
+           argc, argv, user_env, plugin->options);
     }
     debug_return_bool(rval);
 }
index 62fe31d024100c116cd8dd13b017fd720f27304a..aff2344fb401ca7409cfa136741ba3b75dc418a7 100644 (file)
@@ -84,7 +84,7 @@ struct plugin_container {
     struct plugin_container *prev; /* required */
     struct plugin_container *next; /* required */
     const char *name;
-    char * const *args;
+    char * const *options;
     void *handle;
     union {
        struct generic_plugin *generic;