/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 plugins.d/password-request.c

  • Committer: Teddy Hogeborn
  • Date: 2008-08-29 05:53:59 UTC
  • Revision ID: teddy@fukt.bsnet.se-20080829055359-wkdasnyxtylmnxus
* mandos.xml (EXAMPLE): Replaced all occurences of command name with
                        "&COMMANDNAME;".

* plugins.d/password-prompt.c (main): Improved some documentation
                                      strings.  Do perror() of
                                      tcgetattr() fails.  Add debug
                                      output if interrupted by signal.
                                      Loop over write() instead of
                                      using fwrite() when outputting
                                      password.  Add debug output if
                                      getline() returns 0, unless it
                                      was caused by a signal.  Add
                                      exit status code to debug
                                      output.

* plugins.d/password-prompt.xml: Changed all single quotes to double
                                 quotes for consistency.  Removed
                                 <?xml-stylesheet>.
  (ENTITY TIMESTAMP): New.  Automatically updated by Emacs time-stamp
                      by using Emacs local variables.
  (/refentry/refentryinfo/title): Changed to "Mandos Manual".
  (/refentry/refentryinfo/productname): Changed to "Mandos".
  (/refentry/refentryinfo/date): New; set to "&TIMESTAMP;".
  (/refentry/refentryinfo/copyright): Split copyright holders.
  (/refentry/refnamediv/refpurpose): Improved wording.
  (SYNOPSIS): Fix to use correct markup.  Add short options.
  (DESCRIPTION, OPTIONS): Improved wording.
  (OPTIONS): Improved wording.  Use more correct markup.  Document
             short options.
  (EXIT STATUS): Add text.
  (ENVIRONMENT): Document use of "cryptsource" and "crypttarget".
  (FILES): REMOVED.
  (BUGS): Add text.
  (EXAMPLE): Added some examples.
  (SECURITY): Added text.
  (SEE ALSO): Remove reference to mandos(8).  Add reference to
              crypttab(5).

Show diffs side-by-side

added added

removed removed

Lines of Context:
774
774
    const char *pubkeyname = "pubkey.txt";
775
775
    const char *seckeyname = "seckey.txt";
776
776
    mandos_context mc = { .simple_poll = NULL, .server = NULL,
777
 
                          .dh_bits = 1024, .priority = "SECURE256"
778
 
                          ":!CTYPE-X.509:+CTYPE-OPENPGP" };
 
777
                          .dh_bits = 1024, .priority = "SECURE256"};
779
778
    bool gnutls_initalized = false;
780
779
    
781
780
    {
818
817
        /* Get the INPUT argument from `argp_parse', which we know is
819
818
           a pointer to our plugin list pointer. */
820
819
        switch (key) {
821
 
        case 128:               /* --debug */
 
820
        case 128:
822
821
          debug = true;
823
822
          break;
824
 
        case 'c':               /* --connect */
 
823
        case 'c':
825
824
          connect_to = arg;
826
825
          break;
827
 
        case 'i':               /* --interface */
 
826
        case 'i':
828
827
          interface = arg;
829
828
          break;
830
 
        case 'd':               /* --keydir */
 
829
        case 'd':
831
830
          keydir = arg;
832
831
          break;
833
 
        case 's':               /* --seckey */
 
832
        case 's':
834
833
          seckeyname = arg;
835
834
          break;
836
 
        case 'p':               /* --pubkey */
 
835
        case 'p':
837
836
          pubkeyname = arg;
838
837
          break;
839
 
        case 129:               /* --dh-bits */
 
838
        case 129:
840
839
          errno = 0;
841
840
          mc.dh_bits = (unsigned int) strtol(arg, NULL, 10);
842
841
          if (errno){
844
843
            exit(EXIT_FAILURE);
845
844
          }
846
845
          break;
847
 
        case 130:               /* --priority */
 
846
        case 130:
848
847
          mc.priority = arg;
849
848
          break;
850
849
        case ARGP_KEY_ARG: