I had a pretty interesting hack case on my ASP.Net MVC site. For this website, I implemented a fairly simple authentication system for my administration area - an encrypted cookie that had an identifying signature for the member. Whenever an administrator visits a website, the cookie will be decrypted and the signature verified. If a coincidence he will not need to enter.
A few days ago, a visitor to my site told me that he was able to enter my site simply by not clicking the referral link on his Statcounter console, which pointed to my administration area (I visited his site from the link inside my admin view).
He just clicked the link in statcounter and he was signed in as admin!
The only way this could happen is that statcounter somehow recorded my cookies and used them when he clicked on the link pointing to my admin!
Is this logical or understandable?
I do not understand what's going on. Do you have any suggestions on how I can protect my site from such things?
Update . I created an IP whitelist system to protect my administrator from unauthorized access. Basically, the server now compares the visitorβs IP address with the whitelist and allows access only if the ip address is in this list. It also supports wildcards, so this will be fine even for dynamic IP addresses.
, , .