Project

General

Profile

Actions

Optimization #8754

open
AK CT

Optimizing behavior in case of iplen_smaller_than_hlen

Optimization #8754: Optimizing behavior in case of iplen_smaller_than_hlen

Added by Artem Kartunchikov about 1 month ago. Updated 28 days ago.

Status:
Triaged
Priority:
Normal
Target version:
Effort:
medium
Difficulty:
Label:

Description

I dont this it is a bug

We discussed it here

https://forum.suricata.io/t/problem-with-iplen-smaller-than-hlen/6191

Attach two pcap with iplen_smaller_than_hlen error

I think one of the problem is that a broken packet is Client-hello, so tls parser cant do its job correctly

As I understend iplen_smaller_than_hlen mean

IP header Total Lenght (TL) smaller than IP header lenght

I look into RFC6274 and RFC791, this check is suggested by section 3.2. RFC6274

For obvious reasons, the Internet header cannot be larger than the
whole Internet datagram of which it is part. Therefore, the
following check should be enforced:

IHL * 4 <= Total Length

This needs to refer to the size of the datagram as specified by
the sender in the Total Length field, since link layers might have
added some padding (see Section 3.4).
If the packet does not pass this check, it should be dropped, and
this event should be logged (e.g., a counter could be incremented
reflecting the packet drop).

But it seams that some vendors dont follow this RFC (


Files

dcerpc.pcap (29.8 KB) dcerpc.pcap Artem Kartunchikov, 07/22/2026 02:57 PM
mtls (1).pcap (6.11 KB) mtls (1).pcap Artem Kartunchikov, 07/22/2026 02:57 PM

SB Updated by Shivani Bhardwaj 30 days ago Actions #1

  • Status changed from New to Triaged

Hi @s1ncr would you like to submit a patch for this?

PA Updated by Philippe Antoine 28 days ago Actions #2

  • Assignee set to Community Ticket
Actions

Also available in: PDF Atom