Subject: [ipfix] [issue] Use of signed versus unsigned

From: "MEYER,JEFFREY D (HP-Cupertino,ex1)" <[email-masked]>
Date: Fri, 21 Nov 2003 13:14:41 -0800

INFO-20  Use of signed versus unsigned
 
  Description:  Many of the items in the information model specify signed
quantities,
   when these values will never go below zero.  Call them out as unsigned:
   
  - Sign bit on AS numbers x
 
  http://ipfix.doit.wisc.edu/archive/1931.html
<http://ipfix.doit.wisc.edu/archive/1931.html> 
  
  Should be unsigned not int, but may move from 16 to 32 bits.
  
  - Sign and direction on counters x
 
  http://ipfix.doit.wisc.edu/archive/1930.html
<http://ipfix.doit.wisc.edu/archive/1930.html> 
  
  Is there ambiguity in current statements?  Should these be unsigned
quantities?
  
  - ProtocolIdentifier should be of type unsignedByte x
  
  http://ipfix.doit.wisc.edu/archive/1919.html
<http://ipfix.doit.wisc.edu/archive/1919.html> 
    
  currently this is of type int.
        
  - ClassOfService should be unsigned byte v. byte x
  
  http://ipfix.doit.wisc.edu/archive/1919.html
<http://ipfix.doit.wisc.edu/archive/1919.html> 
  
  - RFC791 and RFC1883?
  
  TcpControlBits should be an unsigned byte x
 
  http://ipfix.doit.wisc.edu/archive/1919.html
<http://ipfix.doit.wisc.edu/archive/1919.html> 

  - SamplingInterval should be unsignedInt x
 
  http://ipfix.doit.wisc.edu/archive/1919.html
<http://ipfix.doit.wisc.edu/archive/1919.html> 

  - SamplingAlgorithm as unsignedShort x
 
  http://ipfix.doit.wisc.edu/archive/1919.html
<http://ipfix.doit.wisc.edu/archive/1919.html> 

  - FlowEndState as unsigned (int or short) x
 
  http://ipfix.doit.wisc.edu/archive/1919.html
<http://ipfix.doit.wisc.edu/archive/1919.html> 
  
  - IfIndex (egress and ingress) can be 2**32 x
 
  http://ipfix.doit.wisc.edu/archive/1929.html
<http://ipfix.doit.wisc.edu/archive/1929.html> 
  
  reference RFC2863