# Can I fake a "session" number?

**URL:** <https://boards.straightdope.com/t/can-i-fake-a-session-number/381904>\
**Category:** Factual Questions\
**Created:** [November 27, 2006, 3:40am UTC](https://boards.straightdope.com/t/can-i-fake-a-session-number/381904 "2006-11-27T03:40:52Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Surbey](https://avatars.discourse-cdn.com/v4/letter/s/4491bb/32.png) [@Surbey](https://boards.straightdope.com/u/Surbey)\
**Post date:** [November 27, 2006, 3:40am UTC](https://boards.straightdope.com/t/can-i-fake-a-session-number/381904/1 "2006-11-27T03:40:52Z")

</div>

I’m trying to link to a website and it requires passing script information to the site as there is no set URL. Now, I can basically understand most of the information that is being sent to the server for a return website. However, the information that is being sent also includes a session number. I thought it would be fine but after a week the session number has aparently expired. I’ve back-tracked on the site as far as I can go and I can’t find where it is assigning the session number. Any ideas? Probably not… but its worth a shot.

---

<div class="post-metadata">

**Author:** ![FatBaldGuy](https://avatars.discourse-cdn.com/v4/letter/f/ecd19e/32.png) [@FatBaldGuy](https://boards.straightdope.com/u/FatBaldGuy)\
**Post date:** [November 27, 2006, 3:53am UTC](https://boards.straightdope.com/t/can-i-fake-a-session-number/381904/2 "2006-11-27T03:53:25Z")

</div>

The session number is assigned by the host server when you first load a page on the site. This is used mostly by secure web sites or others that need to retain information from one page to the next.

When you load a second page on the site, normally the server has no way to distinguish between your mouse click and someone else’s, since it has been several seconds (at least) since you first loaded the page. To a computer, that’s an eternity.

When you load the first page, the server passes the session number back to you along with other information which you don’t normally see. When you click on a link to another page on the same site, the first page constructs your URL to include the session number, so that the second page will know who is calling and will retain your information when populating subsequent pages.

The session number will be different each time you access the first page of the web site.

So, to answer your question, no you can’t fake it.

---

<div class="post-metadata">

**Author:** ![Surbey](https://avatars.discourse-cdn.com/v4/letter/s/4491bb/32.png) [@Surbey](https://boards.straightdope.com/u/Surbey)\
**Post date:** [November 27, 2006, 4:18am UTC](https://boards.straightdope.com/t/can-i-fake-a-session-number/381904/3 "2006-11-27T04:18:21Z")

</div>

k, thanks. My father kind of explained it to me as well.

---

<div class="post-metadata">

**Author:** ![Mbossa](https://avatars.discourse-cdn.com/v4/letter/m/73ab20/32.png) [@Mbossa](https://boards.straightdope.com/u/Mbossa)\
**Post date:** [November 27, 2006, 5:40pm UTC](https://boards.straightdope.com/t/can-i-fake-a-session-number/381904/4 "2006-11-27T17:40:47Z")

</div>

Have you tried removing the session number from the URL? If all the necessary information is being passed through other parts of the URL, the server _might_ just assign a new session number.

---

<div class="post-metadata">

**Author:** ![Surbey](https://avatars.discourse-cdn.com/v4/letter/s/4491bb/32.png) [@Surbey](https://boards.straightdope.com/u/Surbey)\
**Post date:** [November 28, 2006, 5:31am UTC](https://boards.straightdope.com/t/can-i-fake-a-session-number/381904/5 "2006-11-28T05:31:40Z")

</div>

no, it doesn’t assign a new one. If I don’t provide the session number in the argument, it won’t accept the server request. Pretty stupid.
