Closed Bug 127168 Opened 23 years ago Closed 22 years ago

Redirected images don't work

Categories

(Core :: Networking: HTTP, defect, P3)

x86
Windows NT
defect

Tracking

()

RESOLVED DUPLICATE of bug 121084
mozilla1.4alpha

People

(Reporter: morse, Assigned: jdunn)

References

()

Details

I have a test case set up that consists of an html file that contains an img 
tag.  The src attribute of the img tag points to a perl script.  That script 
does a redirect to another perl script that actually delivers the image.  The 
result is that the image does not get delivered.  This works fine with nav 4.x.

My test is at the following two urls:

   http://warp/u/morse/cookies/imgredir.html -- inside firewall
   http://people.netscape.com/morse/cookies/imgredir.html -- outside firewall

I'm posting two urls because the one outside the firewall won't be usable until 
tomorrow, providing it has no errors.

Here are the files that my test is made up of

1. perl script nph-image.cgi that sets a cookie and delivers an image

   #!/usr/local/bin/perl

   print "HTTP/1.1 200 OK\n";
   print "Content-type: image/jpeg\n";
   print "Connection: close\n";
   print "Set-cookie: imageCookie=imageCookieValue\n";
   print "\n";

   binmode STDOUT;
   open (JPG, "image.jpg");
   binmode JPG;
   print while (<JPG>);
   close (JPG);

2. perl script nph-imageredir.cgi that redirects to the preceding perl script

   #!/usr/local/bin/perl

    print "HTTP/1.1 200 OK\n";
    print "Content-type: image/jpeg\n";
    print "Connection: close\n";
    print "Refresh: 5;URL=nph-image.cgi\n";
    print "\n";

3. html file imgredir.html that displays the redirected cookie-setting image

   <html>
     <body>
       hello
       <img src="nph-imageredir.cgi">
       goodby
     </body>
   </html>
I assigned this initially to necko because I didn't know where else it belongs.  
Darin thinks its outsideo of necko and in the refresh code.  So I'll let him 
reassing as appropriate.

BTW, the behavior is as follows:

Nav 4.x

   I got hello followed by a broken image followed by goodby.  Five seconds
   later the redirect occurred and I saw the actual image.  This is what I
   expected.

Mozilla

   I got hello followed by goodby with no broken image between them.  And no
   redirect ever occured.
Keywords: nsbeta1
Steve:

use standard troubleshooting to isolate the problem.

First, your internal link for warp, well it needs to be an FQDN, like warp.mcom.com.

And in general, I don't recommend to employees (of any company) that the publish
links externally that point to internal systems. If you have a public link, that
should be sufficient for everyon.

Second, go directly to the link to see if it loads.

In this case it does, but it gives a brief error message in text before doing
so. I do not know how the auto-loading code for images would handle that, but
that is the likely problem.
Assignee: new-network-bugs → darin
Component: Networking → Networking: HTTP
QA Contact: benc → tever
We can reproduce this on Linux and MacOSX:
http://demo.activemath.org:8080/ActiveMath/dictionary/c6s3p3_Th1_def_Eulerindicator

The picture on the right, above the painting of Euler, is redirected (it is a
witness to determine wether a note exists). If you open this image standalone in
a Mozilla window, it works, just, not as an image within an HTML page.

The bug started to appear on 1.2beta (and the nightlies at this time).

Note on MacOSX: this occurs withih Mozilla Carbon but not Chimera (whose gui and
network is different...).

Sadly, there was no nightly for MacOSX of the 1.2 branch to be checked. But we
observed it on the nightly obtainable today on MacOSX, namely, the
Mozilla-Carbon-2002-11-20.

(hope it will get fixed for the 1.2 release)
paul:

chimera is based on the mozilla 1.0 branch, so if this is only a recent
regression, then it makes sense that chimera would not have the bug.  as for
getting this fixes in the 1.2 timeframe, that is probably not going to happen. 
AFAIK, we are very close to releasing 1.2 final.

i'll investigate this for mozilla 1.3.
Status: NEW → ASSIGNED
Priority: -- → P3
Target Milestone: --- → mozilla1.3beta
-> suresh for investigation
Assignee: darin → suresh
Status: ASSIGNED → NEW
This doesn't work in MOZILLA_1_0_BRANCH either :( 
Status: NEW → ASSIGNED
Target Milestone: mozilla1.3beta → mozilla1.4alpha
--> jdunn

Talked to jdunn. He thinks this one is probably a dupe of many broken image bugs
(bug 121084, 186409)
Assignee: suresh → jdunn
Status: ASSIGNED → NEW
Marking as dups... bug 121084 & bug 186409
121084 is the redirected image issue
186409 is the feature to a the broken icon to bad image urls'

*** This bug has been marked as a duplicate of 121084 ***
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.