Re: Access control on a commercial website.
- From: The Natural Philosopher <a@xxx>
- Date: Sun, 05 Aug 2007 20:53:35 +0100
Rik wrote:
On Sun, 05 Aug 2007 17:02:31 +0200, The Natural Philosopher <a@xxx> wrote:
Randy Webb wrote:
Everything on the client side is "utterly insecure". Security has to be managed on the server. Use Sessions and Timeouts and your chances increase.
Yes, but how?
Its all fine to use a password, but every new web page is a new session..
No, it shouldn't, it should be a continued session, identified by a suitable large random string that has got nothing to do with either the user, his location, his rights, or any other data.
how can I be sure it comes from a previously logged in person, not a random spoofer?
Because, on the server you have a list of sessions which _have_ identified themselves. In PHP, I thought the 'standard' id for a session was a string of 32 alphanumeric characters, which is somehere in the neighbourhood of 36^32 => 6.3e49 possible id's. How many id's of that do you actually expect to be logged in at any time? Chances someone magically guesses the id of a currently logged in user is very, very small. Brute force it may be possible to cycle through all id's untill you got something that works (keep in mind authenticated sessions time out, so they might be unlucky also).
Use HTTPS, a session-cookie, a suitable fast timeout, and some mechanism to prevent brute force attacks (count failed logins/random id's from an address and institute a time-out comes to mind).
OK, With Marcs link I had just about got there before I read your post.
You have confirmed the basic approach clearly tho, for which many thanks are due.
Session-hijacking is possible, but very rare (well, if you use HTTPS instead of HTTP). Ask a username/password again for any major alterations/highly classified material, and you'll be fine.
There is no '100%' security, but 99,999% is quite possible.
This has got nothing to do with javascript anymore BTW.
Nope. I suspected i wouldn't have anyway, but rightly, I suspected someone here would have the complete answer,so lets consider it case closed, many thanks issued to Marc and yourself, and back to the Mysteries of InnerHTML etc. etc.
.
- References:
- Access control on a commercial website.
- From: The Natural Philosopher
- Re: Access control on a commercial website.
- From: Randy Webb
- Re: Access control on a commercial website.
- From: The Natural Philosopher
- Re: Access control on a commercial website.
- From: Rik
- Access control on a commercial website.
- Prev by Date: Re: Access control on a commercial website.
- Next by Date: Re: Announcing a new online book: Eloquent JavaScipt
- Previous by thread: Re: Access control on a commercial website.
- Next by thread: enabling all fields on a form
- Index(es):
Relevant Pages
|