• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Win 8.1 / Java ver 8 / HTM Files

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Java'ers,

I must apologize for posting this as it's not directly programming related however I am a loyal Java user and I thought perhaps that given there are a number of computers whizzes here, someone might may be able to assist me.

I have a laptop running Windows 8.1 and Java Version 8 Update 40. I run a bunch of animations from my hard drive (file extension htm) and until a while ago my animations ran just fine on Internet Explorer, however this latest version of Java has increased security measures so that it seems the only way to run my Java animations now, is to go to the Java Control Panel, and load in the URL's (where the animations originate) into the Exception Site List.

This would be an OK solution except I much prefer to run my animations as stored on my Hard Drive and not from the websites, but I cannot find any way to enable running of my htm files from my hard drive via the Java Control Panel (or otherwise).

I am pretty sure that if I deleted Java Version 8 Update 40 and replaced it with Java Version 6 that I would again be able to run my animations from my hard drive (file extension htm) but the concern would then be that running Java Version 6 could be a security risk, at least that's what the Java website informs re: Java Version 6 versus Java Version 8.

Is there some way I can run a bunch of animations from my hard drive (file extension htm) using Java Version 8 Update 40? I cannot find a way to tell Java Version 8 Update 40 that I want to access files from my Hard Drive and not from a website.

Here is the Oracle Java Archive where you can find Java Version 6 http://www.oracle.com/technetwork/ja...ve-139210.html

Here is one of the websites where I originally downloaded a bunch of animations to my hard drive http://www.walter-fendt.de/

Obliged,

Chum
 
Marshal
Posts: 79177
377
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the Ranch

We doubtless have a better forum for your question only I am not quite sure where it would fit best.
Can you add the exceptions in the form file://...?
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:Welcome to the Ranch

We doubtless have a better forum for your question only I am not quite sure where it would fit best.
Can you add the exceptions in the form file://...?

I'll try it Campbell Ritchie and very much thanks! It does not sound like a simple solution however as I would then have make many single entries to accomplish this.
 
Bartender
Posts: 5167
11
Netbeans IDE Opera Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think the file protocol takes one or three slashes; not two like the http/https/ftp/mailto protocols.
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Campbell Ritchie,
Hmm... I tried the below path, but I am not sure if this was the correct way to parse the path, but in any case it did not work, although it seemed that Java liked the exceptions in the form as per "file://" as it warned me that accessing files could be a danger. Man I hate all these modern nanny software features!

file://C:\Dan\BCIT\Animations\Java Applets on Physics Walter Fendt\Unzipped ph14e\ph14e\generator_e.htm
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Darryl Burke wrote:I think the file protocol takes one or three slashes; not two like the http/https/ftp/mailto protocols.

Hello Darryl Burke, you are right to use one slash, and it worked! The only question that remains is if I can parse it for the entire directory as opposed to each separate file. Thank you so much!
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Darryl Burke, well it seems I cannot parse it for the entire directory as opposed to each separate file. Unless you know how as the following did not work "file:/C:\Dan\BCIT\Animations", do I have to include wildcards or some such after Animations?
 
Campbell Ritchie
Marshal
Posts: 79177
377
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are you using \ in a String literal? You have to escape it to \\.
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:Are you using \ in a String literal? You have to escape it to \\.

Gosh I do not have clue what you meant by this nor how I would accomplish what I may have done. Would you please clarify and help me out, kindly?
 
Bartender
Posts: 1845
10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The Backslash character '\' has a special meaning in java strings as an 'escape' character to include characters that you can't express normally.
For instance "\n" means newline and "\t" means tab etc etc

To actually GET a backslash in a String you have to have two of them: "\\"

So the suggestion is that you try the following variations on your file path:

Replace all '\' with '/' --> "file:/C:/Dan/BCIT/Animations"
Replace all '\' with '\\' --> "file:/C:\\Dan\\BCIT\\Animations"

 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello again, I still need help please and much thanks!

No matter what I try, the Java Control Panel keeps telling me "FILE and HTTP protocols are considered a security risk. We recommend using HTTP sites where available"

Well, I am not interested in loading Java enabled websites at all, I simply want to play all of my Java animation files from my C drive, any time I want, without any hassles, without having to rename them all individually, without having to load them all into the "Exception Site List", without having to reformat anything, etc. As things stand, I cannot even copy-paste the file path into the "Exception Site List" as I have mentioned in my prior posts. There must be a nice simple easy way for me to play any Java file I want from my C drive, any time I want, without any hassles mustn't there? Or maybe there is a simple dedicated Java file player or some such I could download?

I have a very large number of these Java animations files on my C drive, so I need a very simple, very quick method that takes care of everything all at once, without taking much time nor needing to be revisited.

Again very much thanks indeed for your time and understanding, I am pretty frustrated with this excessive level of security for my own Java animation files!
 
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Looks like these "animations" are actually applets, and hence all of the security features. If you don't want to deal with all of that security business, you could rewrite them as Java applications, which don't have those security requirements. Although... you didn't say you wrote the animations so perhaps that isn't a viable solution?
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Paul,
Alas, I have zero Java skills, it was a fellow named Walter Fendt (which you'll note from the prior link) as well as others that have supplied me with the animations. Back to the consideration at hand, is there a nice simple way to allow all my Java animations (applets?) to play without all of that security business or at the least one simple singular edit that will produce the same net effect i.e. can I parse it for the entire directory as opposed to each separate file?

BTW what the heck it that "I agree. Here's the link..." that's always found at the end of this thread?

I am obliged.
 
Paul Clapham
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

D Alder wrote:is there a nice simple way to allow all my Java animations (applets?) to play without all of that security business or at the least one simple singular edit that will produce the same net effect?



Well...... sort of. If you don't mind running them from Walter Fendt's site then he tells you how to deal with the security warnings, but unfortunately in German only:

Außerdem muss die Domain http://www.walter-fendt.de in die Ausnahmeliste des Java Control Panel eingetragen sein.



Meaning that you just have to add the domain "http://www.walter-fendt.de" to the security section in the Java Control Panel. However if you want to run them from your own site, then if you can't make an equivalent file:/ URL work then I guess you're out of luck.
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Paul,

1) I have been able to run individual files in the past directly from my hard drive as my prior text in this here thread indicates.
2) I do not want to run them from my site as you refer, in truth I do not even have nor want a site (or equivalent)
3) I do not want to run them from Walter's site and I would truly hope that I do not need to given 1) above.

Very much thanks, and I am finding it disheartening that (what I thought was) my simple request appears to stump all you very fine and helpful folk, but I am certainly no Java-whiz, so am I to assume it is overwhelmingly complex?
 
Paul Clapham
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It's like this. A few years ago applets were found guilty of being the way that some exploits were propagated to people's computers to do seriously bad things. This made the slogan and buzzword crowd start shouting "Java is insecure!" Which wasn't good for Java the language, so Oracle spent some time making applets more secure. And you're seeing the results.

Most of the security issues involved people casually allowing other people's applets to run on their system without checking to see whether those other people were honourable people or whether they were weaselly bandits. So Oracle decided to discriminate against applets which don't come from secure sites (https), since having a secure site implies that you're an honourable person who has been checked out by the companies who give out security certificates.

However it's still possible for you to run applets from insecure sources, you just have to put that source's domain into the Java security panel on your machine. I don't see why a file:// URL shouldn't work there as long as it's the right one, either.
 
D Alder
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you everyone for your thoughtfulness and kindness. I can run an individual applet if I simply add the exception "file:/" to the front of the path. The only remaining problem if how to have it so I can tell the Java Control Panel Security to allow an entire directory as opposed to just an individual file.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic