From: Adam Witney <awitney@sghms.ac.uk>
To: Digital Wokan <wokan@cox.net>
To: pgsql-php <pgsql-php@postgresql.org>
Subject: Re: Transaction including two web page + timer
Date: Mon, 18 Nov 2002 10:33:44 +0000
Message-ID: <B9FE7288.BB04%a.witney@sghms.ac.uk> (raw)
In-Reply-To: <3DD57E55.8010201@cox.net>
But how then would you perform subsequent database connections? You would
have to keep asking the user for their password on every following web page?
>
> Grrrrrrrrrrrrrrrr! Damn reply-to not set on this list.
>
> Since the first reply went only to Adam and thus will benifit only one
> person, I'll retype it to the best of my memory and try to improve on my
> original reply so others may benefit.
>
> First, a correction to someone else's earlier comment. HTML is a
> document formatting language, not a protocol. HTTP/HTTPS is the
> stateless protocol in question.
>
> Second, it would be better to store a flag that it is a valid user.
> Store the username if it's necessary for tracking changes via a logging
> mechanism, otherwise leave it out as well. This way if someone finds a
> way of dumping session variables, you won't be giving away the keys to
> the kingdom. (For example a debugging script you forgot to delete from
> your production system that lists all the session variables and their
> values.)
> For added protection, you may even store the visitors IP address in a
> session variable to make sure any would-be spoofers not only have to get
> the right sessionid, but would have to spoof the IP address associated
> with that session as well. (Perhaps converting it to a 4 byte integer
> so anyone getting the session variables doesn't recognize it as an IP
> address.)
> aaa.bbb.ccc.ddd -> (aaa*256^3)+(bbb*256^2)+(ccc*256)+ddd
> I'm not sure if that last bit is useful. I don't know if PHP already
> has its own methods for preventing piggybacking onto another person's
> session. I know it can auto-rewrite links to append the sessionid when
> cookies may not be available. If such a page were emailed to another
> person, would the server recognize them as the original user since the
> sessionid being passed may still be valid? (I know, more a question for
> a strictly PHP list as opposed to PGSQL-PHP, but security questions have
> a habit of crossing boundaries.)
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-php@postgresql.org
Cc: awitney@sghms.ac.uk, wokan@cox.net
Subject: Re: Transaction including two web page + timer
In-Reply-To: <B9FE7288.BB04%a.witney@sghms.ac.uk>
References: <3DD57E55.8010201@cox.net> <B9FE7288.BB04%a.witney@sghms.ac.uk>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox