Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

JavaFX.MediaPlayer over HTTPS?

I tried to use MediaPlayer to play back a resource defined an HTTPS url, and it says protocol not supported.

In the API reference they state FILE/HTTP/JAR are supported protocols (HTTPS not mentioned).

Is it possible to somehow use urls via HTTPS? This seems quite a big drawback in my opinion...

like image 947
Csabi Avatar asked Feb 06 '13 09:02

Csabi


1 Answers

This was fixed for Java 9, and later backported to Java 8. Java 8 update 91 and later should therefore be working with HTTPS URLs without an issue.

If you're using an old version of Java that doesn't support it, then unfortunately the only option you have is to copy the file over HTTPS to a local temporary file, then play that.

like image 80
Michael Berry Avatar answered Oct 11 '22 08:10

Michael Berry