This is a network programming question. I need to block all HTTP traffic using a layer 4 firewall (i.e it can look headers only upto TCP/UDP layers ). Is this possible?

As I was searching for a more accurate answer , I got to know that even if we cannot access HTTP header, we can access HTTP message field using layer 4 firewall.