Question

In a website that uses asp.net cookieless session, what is the best way to have the session id recorded in the IIS log files?

For example, if the client requests a page

http://server.tld/(S(kdcwx1552av4iq45uabwa145))/site.aspx

by default, IIS only records

cs-uri-stem 
/site.aspx

in its log-files, i.e. the session id is not recorded (though it may appear in the referrer field).

Is there any build in way to include the session id in the log? If not, I guess a custom ISAPI filter would work?

Thanks

Was it helpful?

Solution

AFAIK the only way to record the session ID would be to record it manually. You could try using:

Response.AppendToLog()
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top