def ipv4_reassembly(packet, *, count=NotImplemented):
ipv4 = getattr(packet, '<STR_LIT>', None)<EOL>if ipv4 is not None:<EOL><INDENT>if ipv4.df:     <EOL><INDENT>return False, None<EOL><DEDENT>data = dict(<EOL>bufid=(<EOL>ipaddress.ip_address(ipv4.src),                 <EOL>ipaddress.ip_address(ipv4.dst),                 <EOL>ipv4.id,                                        <EOL>TP_PROTO.get(ipv4.p).name,                      <EOL>),<EOL>num=count,                                          <EOL>fo=ipv4.off,                                        <EOL>ihl=ipv4.__hdr_len__,                               <EOL>mf=bool(ipv4.mf),                                   <EOL>tl=ipv4.len,                                        <EOL>header=bytearray(ipv4.pack()[:ipv4.__hdr_len__]),   <EOL>payload=bytearray(ipv4.pack()[ipv4.__hdr_len__:]),  <EOL>)<EOL>return True, data<EOL><DEDENT>return False, None<EOL>
Make data for IPv4 reassembly.