WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED WONTFIX
20200
(Windows only) Java Sound API throws AccessControlException opening URL when action initiated from Javascript.
https://bugs.webkit.org/show_bug.cgi?id=20200
Summary
(Windows only) Java Sound API throws AccessControlException opening URL when ...
Glenn Brauen
Reported
2008-07-28 13:53:48 PDT
The above URL contains an applet that uses Java Sound API to open and play a small .wav file that resides on the originating server of the HTML page (and applet). The playing of the applet can be triggered through either of two buttons: one implemented by the applet itself and another that invokes a Javascript function that then invokes an applet function. Running in Safari on windows, clicking the applet button works (the audio file plays) but clicking the javascript button throws the following exception (they execute the same code in the applet): network: Connecting
http://devel0.gcrc.carleton.ca/webkit_JSA_Windows_AccessControlException/spacemusic2.wav
with proxy=DIRECT java.security.AccessControlException: access denied (java.net.SocketPermission devel0.gcrc.carleton.ca resolve) at java.security.AccessControlContext.checkPermission(Unknown Source) at java.security.AccessController.checkPermission(Unknown Source) at java.lang.SecurityManager.checkPermission(Unknown Source) at java.lang.SecurityManager.checkConnect(Unknown Source) at java.net.InetAddress.getAllByName0(Unknown Source) at java.net.InetAddress.getAllByName(Unknown Source) at java.net.InetAddress.getAllByName(Unknown Source) at java.net.InetAddress.getByName(Unknown Source) at sun.net.www.http.HttpClient.New(Unknown Source) at sun.net.www.http.HttpClient.New(Unknown Source) at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source) at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source) at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source) at java.net.URL.openStream(Unknown Source) at com.sun.media.sound.WaveFileReader.getAudioInputStream(Unknown Source) at javax.sound.sampled.AudioSystem.getAudioInputStream(Unknown Source) at JavaSound_UrlPlayer_Thread.run(Unknown Source) I have tested on Safari 3.1.2 and the latest webkit nightly (
r35406
). Running in any of the following works (both buttons result in audio playing): - Safari on Mac OS X (10.4) - Firefox on Mac OS X (10.4) - Firefox 2 on Windows XP - Firefox 3 on Windows - Internet Explorer on Windows The applet source is linked off the HTML page but I will also attach all of the following to this bug report: - applet source - ant build file - html page - wav file If you want to test with this on another machine (the above URL may occasionally be unavailable because it is a development machine), then dump the attachments to a folder, run the ant build, and make the results available through a web server. Glenn
Attachments
applet source
(2.82 KB, text/plain)
2008-07-28 13:55 PDT
,
Glenn Brauen
no flags
Details
ant build
(704 bytes, text/plain)
2008-07-28 13:56 PDT
,
Glenn Brauen
no flags
Details
html index page
(1.86 KB, text/html)
2008-07-28 13:58 PDT
,
Glenn Brauen
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Glenn Brauen
Comment 1
2008-07-28 13:55:49 PDT
Created
attachment 22527
[details]
applet source
Glenn Brauen
Comment 2
2008-07-28 13:56:32 PDT
Created
attachment 22528
[details]
ant build
Glenn Brauen
Comment 3
2008-07-28 13:58:01 PDT
Created
attachment 22529
[details]
html index page
Glenn Brauen
Comment 4
2008-07-28 14:05:30 PDT
(In reply to
comment #0
)
> The applet source is linked off the HTML page but I will also attach all of the > following to this bug report: > - wav file
I have not attached the wav file. If you need it, you should be able to grab that from
http://devel0.gcrc.carleton.ca/webkit_JSA_Windows_AccessControlException/spacemusic2.wav
. It is an uncompressed wav file. I used this to avoid audio format conversions and ensure that the test case is as simple as possible. Glenn
Alexey Proskuryakov
Comment 5
2023-09-15 08:27:40 PDT
Java applet support is long gone, closing.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug