Project

General

Profile

Actions

Bug #4168

closed

Napatech: Double release of packet possible in certain error cases.

Added by Jeff Lucovsky about 4 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Affected Versions:
Effort:
Difficulty:
Label:

Description

        p->ReleasePacket = NapatechReleasePacket;
        p->ntpv.nt_packet_buf = packet_buffer;
        p->ntpv.stream_id = ntv->stream_id;
        p->datalink = LINKTYPE_ETHERNET;

        if (unlikely(PacketSetData(p, (uint8_t *)NT_NET_GET_PKT_L2_PTR(packet_buffer), NT_NET_GET_PKT_WIRE_LENGTH(packet_buffer)))) {
            TmqhOutputPacketpool(ntv->tv, p);
            NT_NetRxRelease(ntv->rx_stream, packet_buffer);
            SCReturnInt(TM_ECODE_FAILED);
         }

When "PacketSetData" fails, the packet buffer will be released twice
- TmqhOutputPacketpool calls "p->ReleasePacket" which calls "NT_NetRxRelease"
- Direct call to NT_NetRxRelease


Related issues 1 (0 open1 closed)

Copied from Suricata - Bug #4018: Napatech: Double release of packet possible in certain error cases.ClosedPhil YoungActions
Actions #1

Updated by Jeff Lucovsky about 4 years ago

  • Copied from Bug #4018: Napatech: Double release of packet possible in certain error cases. added
Actions #2

Updated by Jeff Lucovsky about 4 years ago

  • Status changed from Assigned to In Review
Actions #4

Updated by Jeff Lucovsky about 4 years ago

  • Status changed from In Review to Closed
Actions

Also available in: Atom PDF