PHP is not maintaining the HTTP session?
Issue
- The PHP application is not maintaining the HTTP session across the subsequent requests, for example, in the following requests Apache httpd created two different session-id hhf1nnocpngvikd5tihhputul3 and lcj0nt8d5jerp5nv2fe74v2rs5, ideally, it should maintain session-id hhf1nnocpngvikd5tihhputul3 for subsequent requests.
127.0.0.1 - - [28/May/2020:15:47:50 +0530] "GET /test1.php HTTP/1.1" 200 83 "-" "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" Cookie: "-" Set-Cookie: "PHPSESSID=hhf1nnocpngvikd5tihhputul3; path=/" PID: 10773 TID: "139647411562688" TimeTaken: 0
127.0.0.1 - - [28/May/2020:15:48:15 +0530] "GET /test2.php HTTP/1.1" 200 83 "-" "Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" Cookie: "PHPSESSID=lcj0nt8d5jerp5nv2fe74v2rs5" Set-Cookie: "-" PID: 10774 TID: "139647411562688" TimeTaken: 0
Environment
- Red Hat Enterprise Linux (RHEL)
- 7.8 - Red Hat Software Collection (RHSCL)
- httpd24
- rh-php56
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.