Ettercap/ettercap — pull request #122 by jacob-baines (2013-03-17 22:21:09+00:00)
Title: Added UA parsing to ec_http.c

There are multiple protocols in which the client advertises the OS they are running. Probably the most popular of these is HTTP via the User-Agent field. While the information in the user agent field isn't always a slam dunk it is typically accurate. As such, I've added parsing of the UA field and added the information to the profile. The current implementation hard codes the strings we are looking for, but this could be changed to a file.conf approach.

I've tested this on Ubuntu on various pcaps. Below are a couple of screenshots from wireshark sample http captures.

![wireshark_http_cap](https://f.cloud.github.com/assets/787916/268712/c3cf9126-8f50-11e2-9d73-4cadaece8651.png)
![wireshark_gzip_cap](https://f.cloud.github.com/assets/787916/268714/cd032d3e-8f50-11e2-9923-ef7e154edd42.png)