Questions tagged [session]

A session refers to the communication between a single client and a server. A session is specific to the user and for each user a new session is created to track all the requests from that user.

From Wikipedia:

A session is a semi-permanent interactive information interchange, also known as a dialogue, a conversation or a meeting, between two or more communicating devices, or between a computer and user (see Login session). A session is set up or established at a certain point in time, and torn down at a later point in time. An established communication session may involve more than one message in each direction. A session is typically, but not always, stateful, meaning that at least one of the communicating parts needs to save information about the session history in order to be able to communicate, as opposed to stateless communication, where the communication consists of independent requests with responses.

An established session is the basic requirement to perform a connection-oriented communication. A session also is the basic step to transmit in connectionless communication modes. However any unidirectional transmission does not define a session.

References:

44567 questions
9
votes
13 answers

TokenMismatchException in VerifyCsrfToken.php line 53 in Laravel 5.1

When I try to login show me token error. I have checked token in view form it's right and when comment \App\Http\Middleware\VerifyCsrfToken::class, in the Kernel.php it makes me login but after Redirect to my dashboard I'm not logged in. I am using…
reza_khalafi
  • 6,230
  • 7
  • 56
  • 82
9
votes
7 answers

Session not saving when moving from ssl to non-ssl

I have a login screen that I force to be ssl, so like this: https://www.foobar.com/login then after they login, they get moved to the homepage: https://www.foobar.com/dashbaord However, I want to move people off of SSL once logged in (to save CPU),…
Justin
  • 2,914
  • 5
  • 41
  • 66
9
votes
3 answers

ZF2 authentication session storage in memcached

In our intranet application(s) we use SSO (single sign on) login while the sessions both on client and auth origin applications are stored in memcached. The sessions are set to live for 12h before the garbage collector may consider them as for…
shadyyx
  • 15,825
  • 6
  • 60
  • 95
9
votes
1 answer

How to set session cookie while extracting contents from URLs using beautiful soup?

Consider the code: from bs4 import BeautifulSoup from urllib.request import urlopen content = urlopen('https://example.net/users/101') soup = BeautifulSoup(content) divTag = soup.find_all("div", {"class":"classname"}) print(divTag) for tag in…
shahnaz shariff
  • 160
  • 1
  • 3
  • 14
9
votes
3 answers

In django : how to renew expiry date for current session?

I have a user logged in. How can i extend/renew expiry date of session received from the request ? Thanks in advance!
Nullpoet
  • 10,949
  • 20
  • 48
  • 65
9
votes
5 answers

Changing expiry on ASP.NET's Session State cookie

I'm using ASP.NET Session State to keep track of logged in users on my site. However, one problem I'm running into is that by default ASP.NET session cookies are set to expire when the browser closes. http://ahb.me/43e I've tried setting my own…
user47322
9
votes
2 answers

How I do do get session in model? CakePHP 3.x

Cakephp 3.x I want to do my captcha custom validation. But I can not access a session. $validator->notEmpty('securityCode', __('not empty message')) ->add('securityCode','custom', ['rule' => function ($value, $context) use ($extra) { …
Sinan Bay
  • 171
  • 4
  • 12
9
votes
3 answers

Laravel 5 - session doesn't work

Here's config/session.php: return [ 'driver' => 'file', 'files' => storage_path().'/framework/sessions', ]; My storage/framework/sessions have 755 permissions. When I put these 2 line in my controller Session::set('aa',…
Limon Monte
  • 52,539
  • 45
  • 182
  • 213
9
votes
2 answers

Laravel's CSRF token and load balancing

Consider this scenario: An application has a login route that is protected by Laravel's CSRF filter: Route::group(array('before' => 'csrf'), function() { Route::post('/doLogin', array('as' => 'doLogin', 'uses' =>…
tmountjr
  • 1,423
  • 2
  • 22
  • 38
9
votes
1 answer

Node, express.session as middleware does not set cookie

this question is related to NodeJS + Express - Apply session middleware to some routes which I first thought would solve my problem. But it did not. I'm trying to build a site where the first default-page show the user info about the site needing to…
northmoose
  • 139
  • 1
  • 1
  • 6
9
votes
7 answers

When using Sessions is bad thing, and whats wrong with it?

I know that in community server which means that you can't use Sessions, and few years ago i remember i was working on a website where we were not allowed to use sessions. In my point of view sessions are a very helpful…
Amr Elgarhy
  • 66,568
  • 69
  • 184
  • 301
9
votes
3 answers

Cross Site History Manipulation resolution

We have developed a new application, and before moving the changes we did a static scan of code using checkmarx. There is a medium level vulnerablity that is found in the code named Cross Site History Manipulation. This is detacted in the JSP page…
Tushar
  • 1,450
  • 6
  • 18
  • 30
9
votes
3 answers

IIS6: PHP Sessions

I have installed PHP to work with IIS6 (with FastCGI). I am capable of viewing a sample test website that shows the PHP info with the following code: Now that this works I tried to migrate my PHP website to IIS6 and here is a…
Alerty
  • 5,945
  • 7
  • 38
  • 62
9
votes
2 answers

How can I share user sessions across multiple domains using Rails?

Is anyone aware of any gems, tutorials, or solutions enabling a user to sign in to a website at one domain and automatically given access to other partner domains in the same session? I have two rails apps running, let's call them App-A and App-B.…
Mark
9
votes
1 answer

How to deal with a front-end that does not share the same domain in Django

I am facing a big problem with my sessions in a Django project. The back-end is hosted at .my-domain.org and the front-end consumes the REST API of the back-end at .front-end.com. In the future, other front-ends on completely different domains might…
Buddyshot
  • 1,614
  • 1
  • 17
  • 44