From cb0a699d784468d70c205ccf022697c1cae8df51 Mon Sep 17 00:00:00 2001 From: dowright Date: Tue, 24 Aug 2021 18:25:47 -0700 Subject: [PATCH] work on new packet --- new_packet.pyx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/new_packet.pyx b/new_packet.pyx index fb29ce2..61f238b 100644 --- a/new_packet.pyx +++ b/new_packet.pyx @@ -188,16 +188,16 @@ cdef class CPacket: elif (ip_header.protocol == IPPROTO_UDP): proto_header = ( - ntohs(proto_header.uh_sport), - ntohs(proto_header.uh_dport), - ntohs(proto_header.uh_ulen), - ntohs(proto_header.uh_sum), + ntohs(self.udp_header.uh_sport), + ntohs(self.udp_header.uh_dport), + ntohs(self.udp_header.uh_ulen), + ntohs(self.udp_header.uh_sum), ) elif (ip_header.protocol == IPPROTO_ICMP): proto_header = ( - self.ip_header.type, + self.icmp_header.type, ) return proto_header