/mandos/release

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/release

« back to all changes in this revision

Viewing changes to mandos.conf.xml

Convert some programs to use the exit codes from <sysexits.h>.  Change
all programs using the "argp" parsing functions to use them correctly;
checking return value, using argp_error() to report parse errors etc.

* plugin-runner.c: Use <sysexits.h> exit codes.  Always use fallback,
                   even on option errors, except for "--help", etc.
  (getplugin): Make sure "errno" is set correctly on return.
  (main): Declare our own "--help", "--usage", and "--version"
          options which do not cause the fallback to be invoked.
          In all other options, use fallback on any error.
  (parse_opt, parse_opt_config_file): Reset errno at start and return
                                      errno.  No need to check "arg"
                                      for NULL.  New "--help",
                                      "--usage", and "--version"
                                      options.
  (parse_opt): Accept empty string as global option.  Do not print
               errors which will be detected and reported later.  Do
               "argp_error()" on parse error or empty plugin names.
* plugins.d/mandos-client.c: Use <sysexits.h> exit codes.  Do not
                             return successful exit code on "--help",
                             etc. since this would give the wrong
                             message to "plugin-runner".
  (main): Declare our own "--help", "--usage", and "--version"
          options which do not return a successful exit code.
  (parse_opt): Reset errno at start and return errno.  Do
               "argp_error()" on parse errors.  New "--help",
               "--usage", and "--version" options.
* plugins.d/password-prompt.c: Use exit codes from <sysexits.h>.  Do
                               not return successful exit code on
                               "--help", etc. since this would give
                               the wrong message to "plugin-runner".
  (main): Declare our own "--help", "--usage", and "--version" options
          which do not return a successful exit code.  Do
          close(STDOUT_FILENO) after writing to check its return code.
  (parse_opt): Reset errno at start and return errno.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
        "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4
4
<!ENTITY CONFNAME "mandos.conf">
5
5
<!ENTITY CONFPATH "<filename>/etc/mandos/mandos.conf</filename>">
6
 
<!ENTITY TIMESTAMP "2009-01-04">
 
6
<!ENTITY TIMESTAMP "2009-02-25">
7
7
<!ENTITY % common SYSTEM "common.ent">
8
8
%common;
9
9
]>
142
142
        </listitem>
143
143
      </varlistentry>
144
144
      
 
145
      <varlistentry>
 
146
        <term><option>use_ipv6<literal> = </literal>{ <literal
 
147
          >1</literal> | <literal>yes</literal> | <literal
 
148
          >true</literal> | <literal>on</literal> | <literal
 
149
          >0</literal> | <literal>no</literal> | <literal
 
150
          >false</literal> | <literal>off</literal> }</option></term>
 
151
        <listitem>
 
152
          <xi:include href="mandos-options.xml" xpointer="ipv6"/>
 
153
        </listitem>
 
154
      </varlistentry>
 
155
      
145
156
    </variablelist>
146
157
  </refsect1>
147
158
  
179
190
[DEFAULT]
180
191
# A configuration example
181
192
interface = eth0
182
 
address = 2001:db8:f983:bd0b:30de:ae4a:71f2:f672
 
193
address = fe80::aede:48ff:fe71:f6f2
183
194
port = 1025
184
195
debug = true
185
196
priority = SECURE256:!CTYPE-X.509:+CTYPE-OPENPGP
186
197
servicename = Daena
187
198
use_dbus = False
 
199
use_ipv6 = True
188
200
      </programlisting>
189
201
    </informalexample>
190
202
  </refsect1>
225
237
              <para>
226
238
                The clients use IPv6 link-local addresses, which are
227
239
                immediately usable since a link-local addresses is
228
 
                automatically assigned to a network interfaces when it
 
240
                automatically assigned to a network interface when it
229
241
                is brought up.
230
242
              </para>
231
243
            </listitem>