session

Passing session from one application to another

I want to pass session from one application to other. Like what gmail and orkut is doing, i want to do that. Can anyone have some idea about how to do it? Can it be possible without using any DB. ...

What is the best way to secure a shopping cart within a JAVA/Tomcat website?

I am looking for the best-practice solution regarding how to secure a "shopping-cart" part of an otherwise (relatively) unsecure website. The existing setup in the site uses an unsecure-cookie, and only secures (via SSL) the transaction of credentials. The rest of the site is accessed via HTTP and thus, data is transmitted unsecurely. ...

Session handling in PHP

What is the best & most secure way you've handled sessions in a PHP application? I want to know the best, most robust and secure method there is. :) ...

How to prevent ashx from resetting Session Timeout?

I'm having trouble finding any info on this, which makes me think I'm doing something wrong. I've made an ashx that serves up secured images to our logged-in users. The problem is that a Sql Profiler trace reveals that TempResetTimeout is called in our Session State DB for every image served via this mechanism. This ashx was built to ...

Javascript function: Add CSS Class if session variable not equal to X

I'm looking for some Javascript jedi-master to assist in creating a function that adds a class to a list of elements based on a session variable. In other words: If SESSION['MM_UserGroup'] is not equal to 1, then add the class '.hide-content' to the following elements: .control #nav li#nav-admin .control #nav li#nav-pages or any ele...

How to check if asp session is valid?

Hi, Im using outproc session that is managed by aspnet_state. Sometimes I get run time errors saying that the session is invalid. So I wanted to check if the session is valid for every request I make. But I couldn't find a proper way to do it like in this Question using Java. Here is the code I'm using right now in the page_preinit even...

TempData Like Object in WebForms - Session State for only 1 Additional Request

I would like to store some objects only for one request through the session state. I can't seem to think of an easy way to accomplish this. This is exactly what ASP.NET MVC's TempData object does. Could anyone provide me with a link or some examples of how to have an object in session state only survive one additional request? I was ...

PHP session problems

I am using the following code to invalidate the session. I have linked to logout.php in many pages. If that logout link is clicked the logout.php page is called. The following is the code in logout.php. unset($_SESSION['admin']); session_destroy(); header('Location: index.php'); Once the session is invalidated I want to open the page...

Login system (PHP) Cookies and Sessions

Hi guys, I want to make a login system using cookies/sessions but I'm not sure what security and such is like with them. With sessions, if "login" is set to "yes", can I trust that? Are users able to change what it returns? Should I just store the encrypted password and check it on every page? With cookies, would I have to check for ...

Grails Hibernate Session Read Only

Hi. I have two grails servers: Server - has read/write access to the database Web - has read-only access to the database, and for every write it sends a request to the server The problem: How do I make the Web's domain objects read only in one place (config file) for the entire run of the application, instead of writing caching: 'rea...

Why is IE7 rejecting session cookies from a page in a frame?

I am building a website that is loaded into a frameset by other sites (where the domain names are different for the parent site). This works fine in all browsers (including IE6), except for IE7. It is not registering the session at all and simply does not work. Site is implemented using LAMP, MySQL 5, and PHP 5 - yeah, probably not re...

Communication between two subdomains. Zend Framework.

Hey all, I'm adding a bulletin board to my Zend-driven site, and am using an open source one called Phorum. While it would be theoretically possible to integrate Phorum into my Zend site, it's already self contained, and not designed to run through a controller. My solution was to make a sub-domain for Phorum, which worked quite well...

Castle project per session lifestyle with ASP.NET MVC

Hello, I'm really new to Castle Windsor IoC container. I wanted to know if theres a way to store session variables using the IoC container. I was thinking something in the line of this: I want to have a class to store search options: public interface ISearchOptions{ public string Filter{get;set;} public string SortOrder{get;se...

Struts JSP : set textfield value from session information

Hi, I have a DLPUser object in my session, this DLPUser is basically a container for Strings, ints and some useful info for me. (this is a fragment of code inside my action class in java) Map <String, Object> session = ActionContext.getContext().getSession(); session.put("logged-in","true"); session.put("user", user); //user is DLPUse...

Jetty / Tomcat session saving

Where does Tomcat or Jetty saves the sessionids (without session persistence configuration)? Does it go anywhere in the file system, or does it stay just in memory? ...

Session expires after file download

When a user downloads a file from my ASP.NET application, the session expires a few seconds after they download the file. Before the session expires that can perform any task, but after about 5-10 seconds, the session is restarted and they get logged out. I've created a simple page to demonstrate this. To run this simple page, creat...

php session id not matching.

session id is not unique between 1.php and 2.php. 1.php basically sets $_SESSION['var'] = "hello" and 2.php: print_r($_SESSION['var']) echoing out session_id() shows different id. same browser (firefox). everything was working fine, until I screwed up the .htaccess. I deleted .htaccess and restarted apache2. ...

How can I show session array items in PHP

How can I make something like this below work? <?PHP $_SESSION['signup_errors']['test1']; $_SESSION['signup_errors']['test2']; $_SESSION['signup_errors']['test3']; $_SESSION['signup_errors']['test4']; foreach ($_SESSION['signup_errors'] as $key => &$value) { echo $value; } ?> Warning: Invalid argument supplied for foreach() ...

When do @SessionAttributes in SpringMVC get removed? (With code sample)

Under what exact circumstances do @SessionAttributes get cleared? I've discovered some confusing behaviour when trying to use two models in a page. When I do a GET followed by a POST using this controller... @Controller @RequestMapping("/myPage*") @SessionAttributes(value = {"object1", "object2"}) public class MyController { @Reque...

PHP session id's differ

i am using php 5.2.8 i have index.html, which loads LOAD.PHP from IFRAME. iframe src="load.php"..... i printed out load.php's session id. then i ran another test.php, and printed out it's session id. php session id's were different. therefore, i cannot pass any session variables.... what is happening here ? this problem did not ha...