473,763 Members | 1,333 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

URGENT: Strange Cookie Problem! Production App is Failing!

Gentlemen, your urgent help is needed in solving a STRANGE problem.

I have two servers a dev box, and a production box. On the dev box
everything works fine, in production it hoses:

One of the things a user can do is click a "Change region" link which takes
them to a map of the world. They can then select one of four regions.

When they select a region it takes them to a page which reads a variable and
then sets a cookie which is then referenced throughout the site.

like: cds.asp?r=0 (0,1,2,3 are the valid valies)

NOW I'm not asking you to debug code, as I am POSITIVE it has nothing to do
with that and here's why:

DEV BOX Running:
- Default FTP (All IPs)
- Default SMTP (All IPs)
- Default NNTP (All IPs)
- Default Web Server (IP-1:80)
- New Web Server (IP-2:80)
- New Web Server - Back Door (IP-1:88)
* IP-1 and IP-2 are assigned to the same network card, there is no second
NIC.

All three web servers are pointing at the same physical directory. (The
reason is irrelevant, but if you must know it's because we're using a
security ISAPI filter which screws up Front Page Extensions. SO the second
IP allows FP to connect and the back door allows a script to run)

If I hit the Default Web Server the cookies are updated and everything
changes fine.
If I hit "New Web Server - Back Door" or "New Web Server" the cookie appears
to get updated on the page doing the work (I checked by printing both the
variable and the request.cookie) but then is not for any other pages
referencing it.

My Production server is set up in much the same way.
Jul 19 '05
10 2562
Nope. Your first was correct.

If I hit the code on IP-1 I expect to see it on IP-1

If I hit the code on IP-2 I expect to see it on IP-2

The code sets the cookie when you hit it 1st and then reads it thereafter.
I am not changing IPs or ports half way through the site. If you come in on
IP-1:80 then you stay there, if you come in on IP-1:88 then you stay there,
if you come in on IP-2:80 then you stay there.

(otherwise my answer to question 5 would have to be "Oops, there's the
problem," but it isn't :P)

I also realize that you are used to dealing with people who usually aren't
.... well ... thorough. But I am :)

I based my conclusion below on this article:
http://support.microsoft.com/?id=324337

Although it doesn't seem to match exactly the problem I'm having. Also,
trying their code of:

Response.Cookie s("TestCookie") .Path = "/"

Didn't solve anything either :(

"Aaron Bertrand - MVP" <aa***@TRASHasp faq.com> wrote in message
news:eT******** ******@TK2MSFTN GP09.phx.gbl...
Maybe I've been asking the wrong questions. I was assuming that the same
code, on each server, was behaving differently, depending on the server.

Now, it's my impression that you are setting a cookie on IP-1, and expecting to read it on IP-2, or IP-1:different port #?

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/


"Tony Archer" <me@_N05PAM_ton yarcher.com> wrote in message
news:#V******** ******@TK2MSFTN GP12.phx.gbl...
No, it stays "Internet" the entire time, regardless.

Same issue using Opera to browse.

My personal feeling is that it has to do with how the path for the
cookie is
being stored. My bet is that IIS is for some reason sending the default

web
server as the path and then when it comes time to read the cookie it

cannot
find it under the name it is looking for.

--Tony


Jul 19 '05 #11

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

Similar topics

1
5560
by: Craig Matthews | last post by:
hello, any idea why the following code does not work?!! <? $cookieExpire = 864000000; setcookie("a", "love", $cookieExpire); header("Set-Cookie: lc=50; expires=$cookieExpire");
7
2098
by: Fnark | last post by:
Can anyone tell me why this code does not do what I want it to: <?php if (!isset($_COOKIE)) { setcookie("basket", $item_code, time()+60*60*24*30, "coursework", '', 0) ; } else { setcookie( "basket", $_COOKIE-$item_code ); }
1
1910
by: Spidah | last post by:
I am working on a shopping cart for a client and have struck a weird problem. The client's ssl setup is on a different url to the main site. As a result we get two copies of our shopping cart session cookie generated - one under each url. I gather the script is creating separate sessions for each url. After the customer's payment approval/invoice is generated the cart is supposed to be cleared, but only one of the cookies is being...
5
3493
by: AHN | last post by:
Please tell me somebody what causes the cookie set with <% Response.Cookies("blah") = "Blah blah" Response.Cookies("blah").Expires = DateAdd( "h", 1, Now() ) %> work as supposed on my local server but fail on my site on Brinkster. On the next page it disappears if used with "Expires" attribute set, and is there, if without. It was working some time ago. I was forced to reinstall my OS (W2k, IIS 5.0) since then and already a few days I...
7
1485
by: Thaynann | last post by:
I am developin an application that access a web site, i can get to the first page of the site, but when i POST to get to other pages, it gives me a message (amongst the HTML code) "Session Timed Out" It doesnt happen in IE, unless i leave the site sitting for about 10mins (my code executes in under 10 mins) can anyone help me as to why this happens? Thanx in advance,
1
1541
by: Joe | last post by:
Hi folks, Been looking at this for the day so any ideas would be appreciated. Here's the scenario, bear with me - it looks more complicated than it is :) I have a page templating system that inherits from the page class and adds a mixture of usercontrols and literals when requested. One of the usercontrols is a menu that expands on being clicked using DHTML. What I'm trying to do is to persist the expanded menu to other pages or
17
5215
by: jensen bredal | last post by:
Hello, i'm struggling with a somehow badly understood session scenario. I provide acces to my pages based on form authentication using Session cookies. Som of my pages are supposed to be running continuously and refreshing once an hour. I there set timeout= 61 in <sessionState section and on my page it says <meta http-equiv="refresh" content="3600">. I also set timeout=120 in the <forms section of web.config to make sure
3
1028
by: Shapper | last post by:
Hello, I have a Cookie which can have one or many values. One of this values is "Culture". How can I change the "Culture" value which in inside the cookie? This is what I have: Dim cookie As HttpCookie = Request.Cookies("MyWebSite") If Not cookie Is Nothing Then ' Cookie MyWebSite exists
16
2382
by: Victor | last post by:
I have a strange problem in my website. I configured my website to run under 2 worker processes. (web garden enabled). and I stored my user information in the current httpcontext(like Httpcontext.current.items.add("__currentuser", myUserobject") and retrieve the user object like (user = (UserType)Httpcontext.current.items). the website authentication based on the form authentication. and I used login control and customized the validation...
0
1155
by: bertie.bunch | last post by:
Hi, I have been working on some code that interacts with a website using the HTTPRequest object and I have come across an issue where cookies behave differently in the dotnet framework to the way they behave in Internet Explorer and FireFox. If I visit the website in question, it returns a cookie with a leading
0
9563
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9386
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10145
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9822
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8822
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6642
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5270
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3917
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2793
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.