×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
I have taken the approach of creating a session table after the user authenticates initially.
In the table I usually store the userid, generated session id (guid) a source IP address (can be spoofed, but harder to do) and any other session related values I might want in there.
The session ID and source IP info is usually enough to constitute a valid session (unless IP spoofed) unless you're a banking institution where that might not hold up.
If a hit comes in that's not from a valid session id/ip combo the session is immediately removed from the table and session invalidated on next attempt to access a page or data.
The same concept also works nicely when you want to limit the number of users logged into an app for a particular user ID.
If user logs in a second time from another device you can invalidate their first session.
Feel free to poke holes in this strategy.
I'm always looking for better options and of course OAuth seems to be one of those these days.
Regards,
Richard Schoen
Web:
http://www.richardschoen.net
Email: richard@xxxxxxxxxxxxxxxxx
------------------------------
message: 4
date: Thu, 30 Jan 2020 16:13:20 -0700
from: Nathan Andelin <nandelin@xxxxxxxxx>
subject: Re: [WEB400] Apache authentication efficiency
On Thu, Jan 30, 2020 at 4:00 PM B Stone <bvstone@xxxxxxxxx> wrote:
Would you be against rolling your own using cookies/tokens?
Just about everyone in the world does that. But it doesn't address the original question of checking the user's credentials and checking their authority to resources on every request ;-)
If you go that route, the token that you generate (and carry from request to request) needs to be secure enough that no other client can duplicate it.
As an Amazon Associate we earn from qualifying purchases.