Diff for /ansh/src/anshd.c between versions 1.1.1.1.2.6 and 1.3.6.1

version 1.1.1.1.2.6, 2011/10/14 12:03:10 version 1.3.6.1, 2015/05/19 23:30:06
Line 12  terms: Line 12  terms:
 All of the documentation and software included in the ELWIX and AITNET  All of the documentation and software included in the ELWIX and AITNET
 Releases is copyrighted by ELWIX - Sofia/Bulgaria <info@elwix.org>  Releases is copyrighted by ELWIX - Sofia/Bulgaria <info@elwix.org>
   
Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011Copyright 2004 - 2015
         by Michael Pounov <misho@elwix.org>.  All rights reserved.          by Michael Pounov <misho@elwix.org>.  All rights reserved.
   
 Redistribution and use in source and binary forms, with or without  Redistribution and use in source and binary forms, with or without
Line 52  intptr_t Kill; Line 52  intptr_t Kill;
 int Verbose;  int Verbose;
 u_int Crypted = 1;  u_int Crypted = 1;
 proc_head_t pH;  proc_head_t pH;
int bpfLEN, Timeout, Daemon = 1;int bpfLEN, Timeout = 300, Daemon = 1;
 char Key[STRSIZ];  char Key[STRSIZ];
   
 static sched_root_task_t *root = NULL;  static sched_root_task_t *root = NULL;
Line 70  Usage() Line 70  Usage()
                 "\t-U <user>\tRun service with other user\n"                  "\t-U <user>\tRun service with other user\n"
                 "\t-C <dir>\tRun service into chroot directory\n"                  "\t-C <dir>\tRun service into chroot directory\n"
                 "\t-k <key>\tService cipher key\n"                  "\t-k <key>\tService cipher key\n"
                "\t-t <timeout>\tTimeout of login if no activity (default is 0 sec)\n"                "\t-t <timeout>\tTimeout of login if no activity (default is 300 sec)\n"
                 "\t-u\t\tSwitch to unencrypted traffic between hosts\n"                  "\t-u\t\tSwitch to unencrypted traffic between hosts\n"
                 "\t-b\t\tRun into batch mode (default is daemon mode)\n"                  "\t-b\t\tRun into batch mode (default is daemon mode)\n"
                 "\t-v\t\tVerbose (more -v, more verbosity ...)\n"                  "\t-v\t\tVerbose (more -v, more verbosity ...)\n"
Line 125  main(int argc, char **argv) Line 125  main(int argc, char **argv)
         char ch, szUser[STRSIZ] = "root", szChroot[STRSIZ] = "/", szDev[STRSIZ] = { 0 };          char ch, szUser[STRSIZ] = "root", szChroot[STRSIZ] = "/", szDev[STRSIZ] = { 0 };
         struct sigaction sact;          struct sigaction sact;
   
         strlcpy(Key, DEFAULT_KEY, sizeof Key);  
   
         Get1stEth(szDev, STRSIZ);          Get1stEth(szDev, STRSIZ);
   
           strlcpy(Key, DEFAULT_KEY, sizeof Key);
   
         while ((ch = getopt(argc, argv, "hvubt:d:U:C:k:")) != -1)          while ((ch = getopt(argc, argv, "hvubt:d:U:C:k:")) != -1)
                 switch (ch) {                  switch (ch) {
                         case 'U':                          case 'U':
Line 254  main(int argc, char **argv) Line 254  main(int argc, char **argv)
         setgid(gid);          setgid(gid);
         setuid(uid);          setuid(uid);
   
        if (schedRead(root, pktRx, (void*) ANSH_ID, h)) {        if (schedRead(root, pktRx, (void*) ANSH_ID, h, NULL, 0)) {
                 schedRun(root, &Kill);                  schedRun(root, &Kill);
         } else          } else
                 ERR("Failed to add reader task #%d - %s\n", sched_GetErrno(), sched_GetError());                  ERR("Failed to add reader task #%d - %s\n", sched_GetErrno(), sched_GetError());

Removed from v.1.1.1.1.2.6  
changed lines
  Added in v.1.3.6.1


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>