Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6820257
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T21:24:12+00:00 2026-05-26T21:24:12+00:00

When cookies are disabled, (and sessions are being used) the default .htaccess file allows

  • 0

When cookies are disabled, (and sessions are being used) the default .htaccess file allows php to append a get variable to the end of the url containing the session id to continue using sessions. Obviously this is a major security flaw, but does this mean (I dont have a custom server to test on and most servers have this off) that somebodies session can be accessed from anywhere, as long as the session is open and one has the id?

for example, say we have Joe, and Joe is logged into a site with a session based login system.
she enabled cookies, and her session Id is 1234.

then we have bob, who lives in africa and stalks Joe. he knows her id is 1234, so he goes to
http://www.unsecuresite.com/index.php?PHPSESSID=1234

on an unsecure site, will this allow him access to her account, giving the php script all of her session variables?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T21:24:13+00:00Added an answer on May 26, 2026 at 9:24 pm

    Yes it is unsecure, especially with using the URL parameter as you say.

    The session module cannot guarantee that the information you store in a session is only viewed by the user who created the session. You need to take additional measures to actively protect the integrity of the session, depending on the value associated with it.

    Assess the importance of the data carried by your sessions and deploy additional protections — this usually comes at a price, reduced convenience for the user. For example, if you want to protect users from simple social engineering tactics, you need to enable session.use_only_cookies. In that case, cookies must be enabled unconditionally on the user side, or sessions will not work.

    There are several ways to leak an existing session id to third parties. A leaked session id enables the third party to access all resources which are associated with a specific id. First, URLs carrying session ids. If you link to an external site, the URL including the session id might be stored in the external site’s referrer logs. Second, a more active attacker might listen to your network traffic. If it is not encrypted, session ids will flow in plain text over the network. The solution here is to implement SSL on your server and make it mandatory for users.

    Source: http://www.php.net/manual/en/session.security.php

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Pretty basic question here. In PHP, if the user's browser has cookies disabled, you
I'm pretty new to PHP and am experimenting with cookies and sessions. So, in
if the user has disabled cookies in the browser, do sessions work? cause i
I got the answer for If I disabled the cookies then using URL ReDirect
How can we manage session Object if the cookies is disabled ?. how url
What options do I have to work around disabled cookies for session management?
For sessions and cookies, is there a difference between example.com and www.example.com? I have
In my PHP application, I used UserName & Pwd and check the user table
I was testing a site with cookies disabled and I noticed HHOJSID parameter in
Whenever cookies are disabled in my browser and then i try to login on

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.