[Ticket#2009013010000513] FreeBSD Port: rancid-2.3.1_3 / Re: hrancid PATCH needed

Network Infrastructure Support network at otrs.ewc.edu
Mon Feb 2 10:03:27 PST 2009


The return codes in hrancid cause problems with at least one model of HP switch we
have on premises. Please see inlined patch. Thanks!

--
 Edward Waters College Information Technology
 Tookes Building - 1660 Kings Road, Jacksonville, FL 32209 USA
 Email: support at otrs.ewc.edu - Web: http://otrs.ewc.edu/otrs/customer.pl
--

*** hrancid.dist Fri Jan 30 14:24:34 2009
--- hrancid Fri Jan 30 14:25:53 2009
***************
*** 145,155 ****
      while (<INPUT>) {
   tr/\015//d;
   last if(/^$prompt/);
   next if(/^(\s*|\s*$cmd\s*)$/);
   return(-1) if (/command authorization failed/i);
!  return(-1) if /^(Invalid|Ambiguous) input:/i;
  
   s/^image//i;
   s/^\s*//g;
  
   ProcessHistory("COMMENTS","keysort","C1", ";Image: $_") && next;
--- 145,155 ----
      while (<INPUT>) {
   tr/\015//d;
   last if(/^$prompt/);
   next if(/^(\s*|\s*$cmd\s*)$/);
   return(-1) if (/command authorization failed/i);
!  return(1) if /^(Invalid|Ambiguous) input:/i;
  
   s/^image//i;
   s/^\s*//g;
  
   ProcessHistory("COMMENTS","keysort","C1", ";Image: $_") && next;
***************
*** 184,194 ****
      while (<INPUT>) {
   tr/\015//d;
   last if (/^$prompt/);
   next if (/^(\s*|\s*$cmd\s*)$/);
   return(-1) if (/command authorization failed/i);
!  return(-1) if /^(Invalid|Ambiguous) input:/i;
  
   /memory\s+-\s+total\s+:\s+(\S+)/i &&
       ProcessHistory("COMMENTS","keysort","B0",";Memory: $1\n");
   /serial\s+number\s+:\s+(\S+)/i &&
       ProcessHistory("COMMENTS","keysort","A1",";Serial Number: $1\n");
--- 184,194 ----
      while (<INPUT>) {
   tr/\015//d;
   last if (/^$prompt/);
   next if (/^(\s*|\s*$cmd\s*)$/);
   return(-1) if (/command authorization failed/i);
!  return(1) if /^(Invalid|Ambiguous) input:/i;
  
   /memory\s+-\s+total\s+:\s+(\S+)/i &&
       ProcessHistory("COMMENTS","keysort","B0",";Memory: $1\n");
   /serial\s+number\s+:\s+(\S+)/i &&
       ProcessHistory("COMMENTS","keysort","A1",";Serial Number: $1\n");
***************
*** 228,238 ****
      while (<INPUT>) {
   tr/\015//d;
   last if (/^$prompt/);
   next if (/^(\s*|\s*$cmd\s*)$/);
   return(-1) if (/command authorization failed/i);
!  return(-1) if /^(Invalid|Ambiguous) input:/i;
  
   s/stacking - (Stacking Status).*/$1/i;
   s/\s*members unreachable .*$//i;
  
   ProcessHistory("COMMENTS","keysort","F0",";$_");
--- 228,238 ----
      while (<INPUT>) {
   tr/\015//d;
   last if (/^$prompt/);
   next if (/^(\s*|\s*$cmd\s*)$/);
   return(-1) if (/command authorization failed/i);
!  return(1) if /^(Invalid|Ambiguous) input:/i;
  
   s/stacking - (Stacking Status).*/$1/i;
   s/\s*members unreachable .*$//i;
  
   ProcessHistory("COMMENTS","keysort","F0",";$_");


More information about the freebsd-ports mailing list