dpkt icon indicating copy to clipboard operation
dpkt copied to clipboard

in Diameter it dont calculate the filling bits in the first AVP to generate the second

Open kbandla opened this issue 9 years ago • 1 comments

From [email protected] on April 15, 2011 16:51:21

What steps will reproduce the problem? diam = dpkt.diameter.Diameter(eth.ip.tcp.data) diam.avps [AVP(code=263, flags=64, len=38, data='ggsnv9vlz1;3511161808;190;6943'), AVP(flags=1, len=147456, data='\x00\x0c\x00\x00\x00\x04\x00\x00\x01\x08@\x00\x00\x12ggsnv9vlz1\x00\x00\x00\x00\x01(@\x00\x00"[email protected]\x00\x00\x00\x00\x01\x1b@\x00\x00#[email protected]\x00\x00\x00\x01\xcd@\x00\x00\x0fcontext\x00\x00\x00\x01\xa0@\x00\x00\x0c\x00\x00\x00\x02\x00\x00\x01\x9f@\x00\x00\x0c\x00\x00\x07)\x00\x00\x01%@\x00\x00\x13vlzfedsdp2c\x00\x00\x00\x01\x16@\x00\x00\x0c\xd1<\xf76\x00\x00\x007@\x00\x00\x0c\xd1P+\xc4\x00\x00\x01\xbb@\x00\x0........... the First AVP is fine, but the second is not. Because it doesn't skip the filling bits from the first AVP to generate it. What is the expected output? What do you see instead? this sould be the second AVP AVP(code=258, flags=64, len=12, data='\x00\x00\x00\x04') What version of the product are you using? On what operating system? 1.6

Sorry for my english

Original issue: http://code.google.com/p/dpkt/issues/detail?id=70

kbandla avatar Jun 04 '15 01:06 kbandla

From [email protected] on April 18, 2011 07:25:29

Here is the problem: while self.data: avp = AVP(self.data) l.append(avp) self.data = self.data[len(avp):] self.data = self.avps = l

when data is splited, it should be done counting the filling bits

kbandla avatar Jun 04 '15 01:06 kbandla