Go Back   Velocity Reviews > General Computer Discussion > Software
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread
Old 08-20-2009, 03:03 PM   #1
Default ASP.Net Session Cookie Lost on mozilla/netscape After return from cross domain


Hi All,

I am suffering from a problem as described followed,

I have made an forms authenticated application and this is tied up with an payment gateway provider for money transections.
process flow is

1. user book any thing on my site then go to checkout option
2. On checkout i m redirecting my user to PG site with post values and post method.
3. User successfully reached at PG site , there he login and Pay his billed amount. then PG site redirect user to my site same as post method with posted values.
4. Problem Starts here , that when user come back to my site application redirect user to login.(only in mozilla and Netscape Browser)

I have tryed following things.

1. use Cookie mode="URI" (but now IE creates same prob)
2. Set auth cookie and make expiration long.
3. IIS session extented for 1 hour.

and many approchechs...........

Please reply as soon as possible.

Thanks in advanced
Saurabh Mishra


saurabhm
saurabhm is offline   Reply With Quote
Old 09-02-2009, 01:40 PM   #2
biorezonanta
Junior Member
 
Join Date: Sep 2009
Location: bucuresti, sector 4 romania
Posts: 1
Send a message via ICQ to biorezonanta Send a message via Yahoo to biorezonanta
Default
hi, i have a question , if i know the ip can i found the address of computer ?
thank you ,


biorezonanta
biorezonanta is offline   Reply With Quote
Old 09-11-2009, 06:27 AM   #3
vzagkid@gmail.com
Junior Member
 
Join Date: Sep 2009
Posts: 1
Default How to get vistor location ( country, state and city )
How get the vistor(Client) location based on Client IP?
i have to implement this in asp.net

Thanks in Advance
Vkid


vzagkid@gmail.com
vzagkid@gmail.com is offline   Reply With Quote
Old 09-18-2009, 12:36 PM   #4
saurabhm
Junior Member
 
Join Date: Aug 2009
Posts: 4
Default Silly Problem Solved.
Thanks for reply & sorry for replying late,

I would have done that by many other process like save context in db before redirecting and after come back can re generate the session on the basis of
IP, cookie etc but in all that process i had to loss previous session, which are very essential for my app.

anyway but after some time of posting here, i had found the reason and solution of this 'Silly problem' .

The Problem is basically related to domain name means URL,
my app does not redirect the request like

(I) abc-com To (II) www--abc-com

When user loggin by the (I) the browser makes session cookie with domain without 'www' but payment gateway redirect to (II) means with 'www' so browser makes another session cookie as different domain.

Resolution

I modified my app from global.asax in method of Application_Request to redirect user from first request to www .(if not coming) with status code "301".
below is the code.

void Application_BeginRequest(object ob, EventArgs e)
{
if (HttpContext.Current.Request.Url.ToString().ToLowe r().Contains("--abc-com"))
{
HttpContext.Current.Response.Status ="301 Moved Permanently";
HttpContext.Current.Response.AddHeader("Location", Request.Url.ToString().ToLower().Replace("--abc-com","--www-abc-com"));
}
}
---> ---->

"Small things makes more trouble then bigger,
Like You can sit on the top of mountain,
but you cant sit on the top of needle."


saurabhm
saurabhm is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Cross Domain Connection Issue bfullen Software 0 06-09-2008 07:25 PM
session from asp to asp.net imman General Help Related Topics 0 02-20-2008 06:27 PM
ASP.NET Server controls on cross post back Fachmann Software 1 12-18-2007 08:48 PM
Session handling in ASP.Net 2.0 rammca Software 0 10-25-2006 08:00 AM
Storing class with session (ASP.Net) bqmassey Software 0 09-22-2006 05:37 PM




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46