473,394 Members | 1,715 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Cookies across sites

Hi,

Is it possible to pass cookies across sites?
for instance i want to pass a session id from htp://server1 to
http://server2.

If I follow the code snippet below

HttpCookie cookie = new HttpCookie("SesID","SomeIDValue");
Response.Cookies.Add(cookie);
Response.Redirect("http://Server2/default.aspx);

I am finding that browser does not pass the cookie set on the Get
Request to Server.

Appreciate your thoughts on this.

- Tariq

Nov 18 '05 #1
2 1179
Tariq wrote:
Hi,

Is it possible to pass cookies across sites?
for instance i want to pass a session id from htp://server1 to
http://server2.

If I follow the code snippet below

HttpCookie cookie = new HttpCookie("SesID","SomeIDValue");
Response.Cookies.Add(cookie);
Response.Redirect("http://Server2/default.aspx);

I am finding that browser does not pass the cookie set on the Get
Request to Server.

Appreciate your thoughts on this.

- Tariq

Luckily it's not possible! Is hase something to do with security ;)
btw: If you find a workaround, send it to bu**@microsoft.com and cc me ;)

//Rutger
Nov 18 '05 #2
On 18 Aug 2004 04:53:08 -0700, Tariq wrote:
Hi,

Is it possible to pass cookies across sites?
for instance i want to pass a session id from htp://server1 to
http://server2.

If I follow the code snippet below

HttpCookie cookie = new HttpCookie("SesID","SomeIDValue");
Response.Cookies.Add(cookie);
Response.Redirect("http://Server2/default.aspx);

I am finding that browser does not pass the cookie set on the Get
Request to Server.

Appreciate your thoughts on this.

- Tariq


Hi,

Cookies can only be accessed from the issued site however if your sites are
at the same domain like:

site1.server.com and site2.server.com set the cookie's domain
property to server.com and it would be accesiable from *.server.com

hope this helps

-Oytun YILMAZ
Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Keon | last post by:
Hoi Is it possible to use cookies between different domains? For my site I use 2 domains; the first for my global site with ASP en HTML the second is for my forum located on "hyperboards" a...
1
by: Jonathan | last post by:
I have been using document.cookie to write and read cookies. Unfortunately, when I open my page in Internet Explorer, I don't see what I wrote to my cookie while in Netscape Navigator. Similarly,...
1
by: Jose Olivas | last post by:
I am setting a cookie on a subdomain: http://store1.mydomain.com Then the store takes me to a shopping cart that is at: http://shopping.mydomain.com Somewhere the following code (taken and...
27
by: Alan Little | last post by:
If I load a JS file from a different domain, the browser requests it via HTTP, so I assume it sends any relevant cookie headers for that domain; why then can I not access them? E.g. suppose I have...
1
by: milindsj | last post by:
Hello, I have a application hosted on tomcat. I use a jsp to set a cookie say channelid. Now I am redirecting this page to some other appliaction which is hosted in tomcat on some other machine....
2
by: Raterus | last post by:
Howdy, I have one IIS Application, with asp/asp.net pages. I set a cookie like so in an ASP page. Response.Cookies("AuthCookie")("hash") = md5(username & Application("HashCode"))...
0
by: vast55555 | last post by:
Hello, I've been reading old posts and articles but haven't found a solution yet for the following. I'd like to authenticate users across two different sites on two different domains--in...
0
by: OG | last post by:
Hello, I would like to share cookies across various web based apps, and from what I understand your apps can do this as long as they all belong to the same domain. For example app1.mydomain.com...
2
by: Mark | last post by:
Assume you have two virtual directories on the same web server and in the same logical web site. One is at www.mywebsite.com/v1/ and the other is at www.mywebsite.com/v2/. If I create a cookie in...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.