-
Notifications
You must be signed in to change notification settings - Fork 58
UnsupportedOperationException in ExternalContext#isSecure when trying to set flash cookie #3535
Comments
Reported by marcelk |
Issue-Links: |
@edburns said: I wish I could give you a "best JIRA sleuthing" award because that is some fantastic research. Your observation is a symptom of a process problem Manfred and I have since fixed. Henceforth, all bug fixes that originate from the bugs filed in the Oracle internal bug tracker will have corresponding JIRA issues. Witness #3489, which I am working on now. |
@edburns said: Committed to branches/MOJARRA_2_1X_ROLLING: SECTION: Modified FilesM jsf-ri/src/main/java/com/sun/faces/context/flash/ELFlash.java
In 2.1 we added ExternalContext.isSecure() but neglected to add The fix is to inspect the return from ExternalContext.getRequest(). A test/agnostic/flash/wrappedExtContext A test/agnostic/flash/wrappedExtContext/src/main/java A
Adding Adding |
@edburns said: |
Marked as fixed on Wednesday, November 19th 2014, 7:05:44 am |
@edburns said: The fix is on 2.1.x. The fix is not on the trunk. The fix is not on 2.2.x. The fix is not on branches/2.1.20. The fix is not on branches/2.2.8. |
marcelk said: By the way, I'm surprised that this fix will be ported to the trunk and to the 2.2.x. In JSF 2.2, the wrapper class has an implementation of isSecure, so I would think that this problem doesn't exist in JSF 2.2 and higher. |
This issue was imported from java.net JIRA JAVASERVERFACES-3531 |
Since Mojarra 2.1.24, the ELFlash class calls isSecure() on the external context in order to determine whether the secure property should be set on the cookie (#2914). This call leads to an UnsupportedOperationException if the application extends ExternalContextWrapper without overriding the isSecure method. The isSecure method should have been defined in the wrapper class, which has been fixed in JSF 2.2.
This problem has already been fixed in the MOJARRA_2_1X_ROLLING branch, but I can only find the SVN commit, not a JIRA issue. The commit, which has been done on June 12th, 2014, refers to "bug18611757" (which I cannot find on the web).
I created this issue so that the bug will be visible in JIRA, with the correct fix version (I guess 2.1.30), and so that it will be mentioned in the release notes.
Affected Versions
[2.1.29]
The text was updated successfully, but these errors were encountered: