RFR: 8300872: WebView's ColorChooser fails to initialize when running in security context [v3]

Michael Strauß mstrauss at openjdk.org
Sun Mar 5 04:07:18 UTC 2023


On Fri, 3 Mar 2023 19:22:04 GMT, Jose Pereda <jpereda at openjdk.org> wrote:

>> This PR removes an unnecessary check that was added as part of [JDK-8267551](https://bugs.openjdk.org/browse/JDK-8267551).
>> 
>> As commented in the [issue](https://bugs.openjdk.org/browse/JDK-8300872), there were no failing/passing tests before/after these lines were added, and there are no actual tests that get into the case.
>> 
>> The mentioned check caused, as a side effect, the JDK-8300872 issue, as running under a (deprecated) security manager fails with:
>> 
>> java.security.AccessControlException: access denied ("java.io.FilePermission" "jrt:/javafx.controls/com/sun/javafx/scene/control/skin/modena/pattern-transparent.png" "read")
>> ...
>> at javafx.graphics/javafx.scene.image.Image.validateUrl(Image.java:1127)
>> ...
>> 
>> when `File::exists` is evaluated over an image bundled in a jar.
>
> Jose Pereda has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Address feedback

Marked as reviewed by mstrauss (Committer).

I think that I added the call to `File.exists` to quickly detect whether a URL refers to a file on disk, but that seems unnecessary in retrospect.

-------------

PR: https://git.openjdk.org/jfx/pull/1042


More information about the openjfx-dev mailing list