0

I have a web-application used only inside the organization. I want to store information about when any IP (not only registered users' but also unauthorized users' too) come to site and when they left it.

I solved this problem only partially. Storing information about starting the session is easy - just ask for IP and save it with some ComeDateTime property. I also solved it for leave-case of registered users : I wrapped the SignOut() with additional functionality I need.

What should I do with unauthorized users? How can I detect when some IP left the site?

Iskander Raimbaev
  • 1,322
  • 2
  • 17
  • 35
  • Since you can't do that reliably for any users (including authenticated once who just close browser)... Here is some existing post http://stackoverflow.com/a/621790/477420 discussing it... If you define "leave" better that "they left it" one could propose some solution. – Alexei Levenkov Nov 15 '16 at 19:05
  • The easiest approach, would be to generate a custom header within IIS which will tell you the IP Address. Then in your code you track every time they hit a page. Then you would be following the user path. – Greg Nov 15 '16 at 19:14

0 Answers0