Bug 665104 - OpenJDK Firefox Java plugin loses a cookie
Summary: OpenJDK Firefox Java plugin loses a cookie
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: java-1.6.0-openjdk
Version: 14
Hardware: Unspecified
OS: Linux
low
high
Target Milestone: ---
Assignee: Deepak Bhole
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-12-22 18:33 UTC by Mike Grant
Modified: 2011-04-05 21:40 UTC (History)
8 users (show)

Fixed In Version: icedtea-web-1.0.2-2.fc15
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-04-05 21:40:51 UTC
Type: ---


Attachments (Terms of Use)
PHP script to display cookies set in the request made to it. (135 bytes, application/octet-stream)
2010-12-22 18:35 UTC, Mike Grant
no flags Details
PHP script to set 7 cookies. (405 bytes, application/octet-stream)
2010-12-22 18:35 UTC, Mike Grant
no flags Details
Java applet source ; makes a (hardcoded) request to the PHP script that displays cookies set, then redisplays that locally. (1.65 KB, text/x-java)
2010-12-22 18:36 UTC, Mike Grant
no flags Details
HTML page to start Java applet. (138 bytes, text/html)
2010-12-22 18:37 UTC, Mike Grant
no flags Details

Description Mike Grant 2010-12-22 18:33:58 UTC
Description of problem:
The openjdk firefox plugin appears to lose a cookie when making a http request.  This has serious consequences for any web pages with cookie-using applets, frequently resulting in denied requests or broken applets.

Version-Release number of selected component (if applicable):
Majority of testing was against java-1.6.0-openjdk-plugin-1.6.0.0-43.1.8.2.fc13.x86_64 but this has been confirmed on current Fedora 14 rpms too.

How reproducible:
100%

Steps to Reproduce:
1. Load Firefox with the openjdk plugin.  Set some cookies
 - e.g. visit http://rsg.pml.ac.uk/staff/mggr/cookies/cookietest-set.php - this sets 7 cookies named TestCookie[1-7]
2. Confirm they are correctly set
 - e.g. visit http://rsg.pml.ac.uk/staff/mggr/cookies/cookietest-read.php or look at the cookie store in Firefox
3. Run a java applet that makes an HTTP request (including cookies) and note one cookie is missing
 - e.g. visit http://rsg.pml.ac.uk/staff/mggr/cookies/test.html which retrieves and displays the output from the cookietest-read.php link above.  Source of this applet is at http://rsg.pml.ac.uk/staff/mggr/cookies/HelloWorld.java (yeah, I'm not good at Java)
  
Actual results:
Java plugin output shows the webserver saw TestCookie[2-7] (TestCookie1 is missing)

Expected results:
Java plugin output shows the webserver saw TestCookie[1-7]

Additional info:
Attached copies of the relevant testing scripts.  You'll need to build the java class (javac HelloWorld.java).

Using the Sun Java plugin, everything works correctly (all 7 cookies are reported).  This can be tested by: "sudo rpm -e java-1.6.0-openjdk-plugin
; cd ~/.mozilla/plugins ; ln -s SUN_JRE_LOCATION/lib/amd64/libnpjp2.so"

I looked at reporting this upstream, but had some difficulty finding the appropriate location, then some more difficulty building a test environment to confirm this isn't just a Fedora issue.  Please advise whether (and where) I should try upstream or if Fedora can handle this.

Comment 1 Mike Grant 2010-12-22 18:35:15 UTC
Created attachment 470278 [details]
PHP script to display cookies set in the request made to it.

Comment 2 Mike Grant 2010-12-22 18:35:42 UTC
Created attachment 470279 [details]
PHP script to set 7 cookies.

Comment 3 Mike Grant 2010-12-22 18:36:29 UTC
Created attachment 470280 [details]
Java applet source ; makes a (hardcoded) request to the PHP script that displays cookies set, then redisplays that locally.

Comment 4 Mike Grant 2010-12-22 18:37:08 UTC
Created attachment 470281 [details]
HTML page to start Java applet.

Comment 5 Andrew John Hughes 2010-12-22 20:33:02 UTC
Upstream is http://icedtea.classpath.org/bugzilla

Comment 6 Deepak Bhole 2010-12-22 21:37:09 UTC
Thanks for the reproducer! I have replicated and fixed the issue. It will be committed upstream after review:

http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2010-December/011553.html

Comment 7 Fedora Update System 2011-04-04 21:11:38 UTC
icedtea-web-1.0.2-2.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/icedtea-web-1.0.2-2.fc15

Comment 8 Fedora Update System 2011-04-05 21:40:41 UTC
icedtea-web-1.0.2-2.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.