01.05.2014, 09:24
I don't know where you got this script, but it's vulnerable to SQL injection. Cookies can be edited on the client side. This only checks if the cookie exists rather than verifying its validity. If I create the 'sessionid' cookie with contents:
The query will look like:
Line 46 is:
Which means that $_userInfo isn't an object, which in turn means that the query above it failed it or returned an empty resultset.
PS: Wrong section.
Код:
0' OR 1=1 --
PHP код:
SELECT * FROM `ucpsessids` WHERE sessid = '0' OR 1=1 --'
PHP код:
$_userName = $_userInfo->Name;
PS: Wrong section.