Changeset 3207
- Timestamp:
- 07/23/08 21:30:57 (5 years ago)
- Location:
- branch/UMPA/umpa/protocols
- Files:
-
- 2 modified
Legend:
- Unmodified
- Added
- Removed
-
branch/UMPA/umpa/protocols/IP.py
r3206 r3207 25 25 class HIHL(IntField): 26 26 bits = 4 27 auto = True 27 28 def generate_value(self): 28 29 pass … … 31 32 class HTotalLength(Field): 32 33 bits = 16 34 auto = True 33 35 def fillout(self): 34 36 pass … … 36 38 class HIdentification(Field): 37 39 bits = 16 40 auto = True 38 41 def fillout(self): 39 42 pass … … 41 44 class HFragmentOffset(Field): 42 45 bits = 13 46 auto = True 43 47 def fillout(self): 44 48 pass … … 46 50 class HProtocol(Field): 47 51 bits = 8 52 auto = True 48 53 def fillout(self): 49 54 pass … … 51 56 class HHeaderChecksum(Field): 52 57 bits = 16 58 auto = True 53 59 def fillout(self): 54 60 pass … … 56 62 class HPadding(Field): 57 63 bits = 0 64 auto = True 58 65 def fillout(self): 59 66 pass … … 78 85 flags = ('reserved', 'df', 'mf') 79 86 80 fields_list = [ IntField("Version", 4, 4 ), HIHL("IHL"),87 fields_list = [ IntField("Version", 4, 4, True), HIHL("IHL"), 81 88 Flags("TOS",tos), HTotalLength("Total Length"), 82 89 HIdentification("Identification"), -
branch/UMPA/umpa/protocols/_.py
r3206 r3207 33 33 like the one provided by Umit Project. 34 34 """ 35 36 def __init__(self, name, value=None, bits=None ):35 auto = False 36 def __init__(self, name, value=None, bits=None, auto=None): 37 37 self.name = name 38 if auto is not None: 39 self.auto = auto 38 40 39 41 if bits is not None:
