PHP Session Fixation / Hijacking

Ok, there are two separate but related problems, and each is handled differently. Session Fixation This is where an attacker explicitly sets the session identifier of a session for a user. Typically in PHP it’s done by giving them a url like http://www.example.com/index…?session_name=sessionid. Once the attacker gives the url to the client, the attack is … Read more

PHP session lost after redirect

First, carry out these usual checks: Make sure session_start(); is called before any sessions are being called. So a safe bet would be to put it at the beginning of your page, immediately after the opening <?php declaration before anything else. Also ensure there are no whitespaces/tabs before the opening <?php declaration. After the header … Read more

What is the difference between server side cookie and client side cookie?

HTTP COOKIES Cookies are key/value pairs used by websites to store state information on the browser. Say you have a website (example.com), when the browser requests a webpage the website can send cookies to store information on the browser. Browser request example: GET /index.html HTTP/1.1 Host: www.example.com Example answer from the server: HTTP/1.1 200 OK … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)