#NEWLINE# def _build_igmp( self ) : #NEWLINE# #INDENT# dl_dst = '11:22:33:44:55:66' #NEWLINE# dl_src = 'aa:bb:cc:dd:ee:ff' #NEWLINE# dl_type = ether . ETH_TYPE_IP #NEWLINE# e = ethernet ( dl_dst , dl_src , dl_type ) #NEWLINE# total_length = ( len ( ipv4 ( ) ) + len ( self . g ) ) #NEWLINE# nw_proto = inet . IPPROTO_IGMP #NEWLINE# nw_dst = '11.22.33.44' #NEWLINE# nw_src = '55.66.77.88' #NEWLINE# i = ipv4 ( total_length = total_length , src = nw_src , dst = nw_dst , proto = nw_proto , ttl = 1 ) #NEWLINE# p = Packet ( ) #NEWLINE# p . add_protocol ( e ) #NEWLINE# p . add_protocol ( i ) #NEWLINE# p . add_protocol ( self . g ) #NEWLINE# p . serialize ( ) #NEWLINE# return p