note 108537 deleted from security.variables by danbrown

From: Date: Thu, 10 May 2012 16:49:21 +0000
Subject: note 108537 deleted from security.variables by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-187596@lists.php.net to get a copy of this message
Note Submitter: step8601 at email dot com ---- "Now when processing the form... check the value of your token" What if a user legitimately goes to your site and generates a token and then uses that token and adds a dangerous fieldname to a static form that now has a legit token during the session? <form name="newform" action="index.php" method="post"> <input type="text" name="potentialeveilfield" value="" size 30 /> <input type="hidden" name="token" value="<?php echo maketoken(newform, $userid); //$userid here could be user profile id ?>" /> <input type="submit" /> </form> <form name="newform" action="index.php" method="post"> <input type="text" name="potentialeveilfield" value="" size 30 /> <input type="hidden" name="token" value="9l3j34509u0ueroiu34u345" /> <input type="submit" /> </form>

« previous php.notes (#187596) next »