I am currently using AWStats to analyze the apache logs for a server that redirects links, etc from iOS apps to the app store (so we can track clickthrough). In AWStats, however, all of this traffic is grouped into 'Mac OS X' in the Operating Systems category. This obviously isn't very helpful for us. What we really want is not only detection of iPhone vs. iPod Touch vs. iPad, but also iOS version numbers, hardware generational differences, etc.
I don't think generational differences (iPhone 3G vs. iPhone 4, for example) can be easily retrieved through http logs, but I know that iOS versions are right in the user agent string.
None of my attempts to get AWStats to recognize iOS have worked at all, though. I moved the line that's supposed to do the trick up above Mac OS X, to no avail. Has anyone managed to do this, in AWStats or otherwise? I'd be fine moving to a different system, if that's what it takes.
For the record, browser detection works fine, it can easily distinguish between mozilla, safari, iPhone safari, and iPad safari.