\documentclass[a4paper, 11pt]{article}
\renewcommand{\familydefault}{\sfdefault}
\usepackage{a4wide}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage{color}
\usepackage{graphicx}
\usepackage{setspace}
\usepackage{ulem}
\usepackage{listings}
\usepackage{float}
\usepackage[rflt]{floatflt}
\usepackage{tabularx}
\setlength{\parindent}{0pt}
\title{Browscap ISAPI-Filter für IIS}
\usepackage[
pdftitle={Browscap ISAPI-Filter für IIS}
pdfsubject={An ISAPI-Filter to use the browscap.ini File Values on the IIS, with any programming language.}
pdfauthor={Udo Schmal}
pdfkeywords={browscap, browscap.ini, Free Pascal, isapi, ISAPI-Filter, IIS, ASP}
]{hyperref}
\definecolor{darkblue}{rgb}{0,0,.5}
\hypersetup{pdftex=true, colorlinks=true, breaklinks=true, linkcolor=darkblue, menucolor=darkblue, pagecolor=darkblue, urlcolor=darkblue}
\begin{document}Browscap ISAPI-Filter für IIS
\singlespacing
{\LARGE \textbf{\label{sec:title}Browscap ISAPI-Filter für IIS}}

An ISAPI-Filter to use the browscap.ini File Values on the IIS, with any programming language.

All you must have to run it:

\href{http://www.gocher.me/downloads/browscap_filter.zip}{browscap\_filter.zip}

The Free Pascal source for the Filter:\newline


\href{http://www.gocher.me/code/browscap_filter.lpr}{browscap\_filter.lpr}

Config file for the ISAPI-Filter (browscap\_filter.Ini):
\begin{lstlisting}[breaklines][browscap]
path=C:\textbackslashinetpub\textbackslashbrowscap.ini
logpath=C:\textbackslashinetpub\textbackslashlogging\textbackslash
debug=1

[fields]
X-Client-Name=Browser
X-Client-Version=Version
X-Client-Is-Mobile-Device=isMobileDevice
X-Client-Is-Tablet=isTablet
X-Client-Is-Crawler=Crawler\end{lstlisting}

Logfile Lines for one request, if debug=1:
\begin{lstlisting}[breaklines]14:40:37:973|User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:29.0) Gecko/20100101 Firefox/29.0
14:40:38:051|add header(X-Client-Name: Firefox)
14:40:38:051|add header(X-Client-Version: 29.0)
14:40:38:051|add header(X-Client-Is-Mobile-Device: false)
14:40:38:051|add header(X-Client-Is-Tablet: false)
14:40:38:051|add header(X-Client-Is-Crawler: false)\end{lstlisting}

ASP (VB-Script) Example:
\begin{lstlisting}[breaklines]\&lt;\%
Response.Write(Replace(Request.ServerVariables(\&quot;ALL\_RAW\&quot;), vbCrLf, \&quot;\&lt;br /\&gt;\&quot;) + \&quot;\&lt;br /\&gt;\&quot;)
Response.Write(\&quot;Name: \&quot; + Request.ServerVariables(\&quot;HTTP\_X\_CLIENT\_NAME\&quot;) + \&quot;\&lt;br/\&gt;\&quot;)
Response.Write(\&quot;Version: \&quot; + Request.ServerVariables(\&quot;HTTP\_X\_CLIENT\_VERSION\&quot;) + \&quot;\&lt;br/\&gt;\&quot;)
Response.Write(\&quot;Mobile: \&quot; + Request.ServerVariables(\&quot;HTTP\_X\_CLIENT\_IS\_MOBILE\_DEVICE\&quot;) + \&quot;\&lt;br /\&gt;\&quot;)
Response.Write(\&quot;Tablet: \&quot; + Request.ServerVariables(\&quot;HTTP\_X\_CLIENT\_IS\_TABLET\&quot;) + \&quot;\&lt;br /\&gt;\&quot;)
Response.Write(\&quot;Crawler: \&quot; + Request.ServerVariables(\&quot;HTTP\_X\_CLIENT\_IS\_CRAWLER\&quot;) + \&quot;\&lt;br /\&gt;\&quot;)\end{lstlisting}

Output:
\begin{lstlisting}[breaklines]Cache-Control: max-age=0
Connection: keep-alive
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: de-de,de;q=0.7,en-us;q=0.3
Cookie: ASPSESSIONIDAQQSDBSS=FBKBCEDCKLICGFBEMGGHBNFF
Host: test.localhost
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:29.0) Gecko/20100101 Firefox/29.0
DNT: 1
X-Client-Name: Firefox
X-Client-Version: 29.0
X-Client-Is-Mobile-Device: false
X-Client-Is-Tablet: false
X-Client-Is-Crawler: false

Name: Firefox
Version: 29.0
Mobile: false
Tablet: false
Crawler: false\end{lstlisting}
\end{document}