Archive

Archive for the ‘Java’ Category

Modifying Oracle’s Java SDK to run Java applications on OS X

August 8, 2015 Leave a comment

As part of releasing the developer betas for OS X 10.11, Apple announced that El Capitan would be the end of the line for the Java 6 runtime and tools provided by Apple, with the clear statement that developers should be moving on to Oracle’s Java tools.

To completely replace Apple’s Java 6 tools, Oracle’s Java JDK (Java SE Development Kit) will need to be installed. This is because the Oracle Java JRE (Java Runtime Environment) on OS X is a browser plug-in for running Java via a web browser and does not include capabilities for running Java desktop apps or command line tools.

By default though, the Oracle JDK does not set several options to advertise the capabilities provided by the JDK to Java apps, which may cause applications that need those capabilities to fail to launch. The capabilities are actually present in the JDK, but those options need to be set before applications will recognize them as available.

To fix this, we need to add the following options to Oracle’s Java JDK:

  • BundledApp
  • JNI

 In turn, enabling these options means they need to be added to the list of JVMCapabilities stored in the following plist file:

/Library/Java/JavaVirtualMachines/jdk_version_info_goes_here.jdk/Contents/Info.plist

Screen Shot 2015 08 08 at 7 39 19 AM

For more details, see below the jump.

Read more…

Oracle’s Java 8 Update 40 has been updated again to …. Java 8 Update 40

March 16, 2015 9 comments

Oracle has released a new update for Java 8, but has continued their recent trend of not bumping the version number. Oracle has put out a new build of Java 8 but didn’t bump the version number from Java 8 Update 40, which makes this the third release of Java 8 Update 40.

At this point, it appears that Oracle is now providing the install application across the board. When you update an existing Java installation on OS X via Oracle’s Java update mechanism, you will receive Oracle’s install application for Java along with the selected option to install the Ask.com browser add-ons. If you download an installer from Java.com, you will also receive this install application.

Screen Shot 2015-03-16 at 3.47.54 PM

Screen Shot 2015-03-13 at 4.03.52 PM

Screen Shot 2015-03-13 at 3.57.05 PM

While the Oracle install application is not a standard installer package, it appears that Oracle had stored an installer package for Java 8 within the install application at the following location:

/path/to/install.app/Contents/Resources/JavaAppletPlugin.pkg


Screen Shot 2015-03-16 at 3.48.18 PM

The JavaAppletPlugin installer package is digitally-signed and does not include the Ask.com browser add-ons.

Screen Shot 2015-03-16 at 3.48.27 PM

The difference between the three Java 8 Update 40 releases

Early March’s Java 8 Update 40 (released on March 4, 2015): Java 8 Update 40 build 25 (1.8.40.25)

Mid-March’s Java 8 Update 40 (released on March 13, 2015): Java 8 Update 40 build 26 (1.8.40.26)

Just-Past-Mid-March’s Java 8 Update 40 (released on March 16, 2015): Java 8 Update 40 build 27 (1.8.40.27)

If you have Java 8 Update 40 installed, you can find out which build you have by running the following command in Terminal:

defaults read /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Info.plist CFBundleVersion

If you have Java 8 Update 40 build 25, the following string will be returned:

1.8.40.25

Screen Shot 2015-03-13 at 3.47.40 PM

If you have Java 8 Update 40 build 26, the following string will be returned:

1.8.40.26

Screen Shot 2015-03-13 at 4.06.45 PM

If you have Java 8 Update 40 build 27, the following string will be returned:

1.8.40.27

Screen Shot 2015-03-16 at 3.51.16 PM

For more details, see below the jump.

Read more…

Oracle’s Java 8 Update 40 has been updated to …. Java 8 Update 40

March 13, 2015 1 comment

Oracle has released a new update for Java 8, but this update has an interesting wrinkle. Oracle has put out a new build of Java 8, but didn’t bump the version number from Java 8 Update 40. So folks who have the previous version of Java 8 Update 40 installed may receive a message to update to Java 8 Update 40 from their current version, which will also be Java 8 Update 40.

For those thinking this sounds familiar, Oracle did the same thing with Java 8 Update 31 in February.

java_8_update_40

The difference between the two Java 8 Update 40 releases

Early March’s Java 8 Update 40 (released on March 3, 2015): Java 8 Update 40 build 25 (1.8.40.25)

Mid-March’s Java 8 Update 40 (released on March 12, 2015): Java 8 Update 40 build 26 (1.8.40.26)

If you have Java 8 Update 40 installed, you can find out which build you have by running the following command in Terminal:

defaults read /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Info.plist CFBundleVersion

If you have Java 8 Update 40 build 25, the following string will be returned:

1.8.40.25

Screen Shot 2015-03-13 at 3.47.40 PM

If you have Java 8 Update 40 build 26, the following string will be returned:

1.8.40.26

Screen Shot 2015-03-13 at 4.06.45 PM

Following installation of Java 8 Update 40 build 26, I tested on a 10.10.2 Mac against the following sites:

Oracle’s Java Test page: https://www.java.com/en/download/help/testvm.xml

Screen Shot 2015-03-13 at 4.10.06 PM

Java Tester’s Java Version page: http://javatester.org/version.html

Screen Shot 2015-03-13 at 4.09.53 PM

In both cases, the Java applets on those sites launched and worked without issue using Java 8 Update 40 build 26 (though the javatester.org applet needed to be whitelisted.)

To make things even more confusing, Oracle is providing a different installer for its update feed than it’s providing at the Java.com download site. When you update an existing Java installation on OS X via Oracle’s Java update mechanism, you will receive Oracle’s install application for Java along with the selected option to install the Ask.com browser add-ons.

Screen Shot 2015-03-13 at 4.05.41 PM

Screen Shot 2015-03-13 at 4.03.52 PM

Screen Shot 2015-03-13 at 3.57.05 PM

If you download an installer from Java.com, you will receive a standard digitally-signed installer package which does not include the Ask.com browser add-ons.

Screen Shot 2015-03-13 at 3.56.36 PM

Screen Shot 2015-03-12 at 7.10.42 AM

Unfortunately, Oracle has not provided any information about why these differences in installation methods exist. To make sure you’re installing Java 8 Update 40 without the Ask.com browser add-ons, I would currently recommend downloading the installer package available via the Java.com download site.

MacJREInstaller and Oracle’s Java install application

March 6, 2015 4 comments

Part of Oracle’s new install application for Java is a binary named MacJREInstaller. This application appears to be what installs Java and governs whether or not the Ask.com toolbar gets deployed.

Screen Shot 2015-03-06 at 4.00.10 PM

For context, MacJREInstaller appears to be the helper tool referenced when the Java install application prompts for admin privileges.

Screen Shot 2015-03-03 at 3.52.13 PM

Based on observation, when running the Java install application, MacJREInstaller appears to run the following tasks:

1. Checks to see if it can contact the internet

2. If it can contact the internet, checks back with Oracle to see what country it’s in. Oracle apparently is selective about which nations it wants to have the Ask.com browser settings and toolbar installed (thanks to a Canadian colleague’s testing, it appears Canada is not one of the nations.)

3. If it determines the Mac in question is in a country where Oracle wants to deploy the Ask.com browser settings and toolbar, a Sponsors.framework.tar file is downloaded to the Mac and uncompressed into /Users/username/Library/Application Support.

Screen Shot 2015-03-06 at 5.04.28 PM

4. Determines which web browser is set as the Mac’s default web browser.

5. Displays the choice for whether or not to install the Ask.com browser settings and toolbar.

Note: By default, the option to install the Ask.com browser settings and toolbar is selected. The person running the install application must uncheck the appropriate checkbox or checkboxes to opt out.

Screen Shot 2015-03-03 at 3.52.38 PM

6. Depending on whether the Ask.com browser settings and toolbar have been chosen for installation, the following actions take place:

If installation of the Ask.com browser settings and toolbar is selected:

A. The Ask.com browser settings and toolbar for the Mac’s default web browser are installed using a tool called APNSetup, which is included in the downloaded Sponsors.framework.

Screen Shot 2015-03-06 at 4.40.28 PM

B. The JavaAppletPlugin installer package stored within the Java install application is installed.

Screen Shot 2015-03-03 at 4.03.38 PM

C. MacJREInstaller checks back with Oracle again to see what country the Mac in question is in.

If installation of the Ask.com browser settings and toolbar is not selected:

A. The JavaAppletPlugin installer package stored within the Java install application is installed.

B. MacJREInstaller checks back with Oracle again to see what country the Mac in question is in.

Note: Even if the installation of the Ask.com browser settings and toolbar is not selected, the Sponsors.framework remains resident on the machine, in /Users/username/Library/Application Support.

7. Once the install process finishes, MacJREInstaller then exits.

For more details, see below the jump.

Read more…

Oracle’s Java 8 Update 40 – The Good, the Bad and the Ugly

March 4, 2015 10 comments

For the past few major releases, Oracle has used a standard installer package to install Java 7 and Java 8. With the release of Java 8 Update 40 though, Oracle changed how Java 8 for Macs is installed. Oracle has now switched to using an application to install Java.

Screen Shot 2015-03-03 at 3.51.52 PM

This switch away from using installer packages is a problem for Mac admins who need to deploy Oracle’s Java 8 in their own environment. However, after doing some research, it looks like it is still possible to deploy Oracle’s Java 8 Update 40 using a standard installer package. For more details, see below the jump.

Read more…

Categories: Java, Mac administration

Oracle’s Java 8 Update 31 has been updated to …. Java 8 Update 31

February 13, 2015 8 comments

Oracle has released a new update for Java 8, but this update has an interesting wrinkle. Oracle has put out a new build of Java 8, but didn’t bump the version number from Java 8 Update 31. So folks who had previously installed Java 8 Update 31 may receive a message to update to Java 8 Update 31 from their current version, which will also be Java 8 Update 31.

This may lead to some confusion.


Update 2-16-2015: It appears that the update feed for Java 8 Update 31 has been updated to reference 1.8.31.13 (aka Java 8 Update 31 build 13):

https://javadl-esd-secure.oracle.com/update/mac/au-1.8.0_31.xml

There’s no information available on why the change was made. My speculation is that Oracle decided that updating the Sparkle feed for Java 8 Update 31 so that it was no longer providing Java 8 Update 31 build 15 as an update for Java 8 Update 31 build 13 was the best way to help avoid future confusion over updates for Java 8 Update 31.

It looks like 1.8.31.15 (aka Java 8 Update 31 build 15) is still the version being provided through the Java download site:

https://www.java.com/download

I checked the update feeds for Java 8 Update 20 and Java 8 Update 05 and both of those feeds are still providing 1.8.31.15 as well:

https://javadl-esd-secure.oracle.com/update/mac/au-1.8.0_05.xml
https://javadl-esd-secure.oracle.com/update/mac/au-1.8.0_20.xml

Unfortunately, there is still no information available about Java 8 Update 31 build 15 and how it differs from Java 8 Update 31 build 13.


java_8_update_31

Build numbers for the two Java 8 Update 31 releases

January’s Java 8 Update 31 (released on January 20, 2015): Java 8 Update 31 build 13

February’s Java 8 Update 31 (released on February 10, 2015): Java 8 Update 31 build 15

If you have Java 8 Update 31 installed, you can find out which build you have by running the following command in Terminal:

defaults read /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Info.plist CFBundleVersion

If you have Java 8 Update 31 build 13, the following string will be returned:

1.8.31.13

Screen Shot 2015-02-13 at 12.39.10 PM

If you have Java 8 Update 31 build 15, the following string will be returned:

1.8.31.15

Screen Shot 2015-02-13 at 12.30.22 PM

Following installation of Java 8 Update 31 build 15, I tested on a 10.10.2 Mac against the following sites:

My work’s Juniper VPN

Oracle’s Java Test page: https://www.java.com/en/download/help/testvm.xml

Screen Shot 2015-02-13 at 12.09.11 PM

Java Tester’s Java Version page: http://javatester.org/version.html

Screen Shot 2015-02-13 at 12.08.47 PM

In all three cases, the Java applets on those sites launched and worked without issue using Java 8 Update 31 build 15 (though the javatester.org applet needed to be whitelisted.)

Categories: Java, Mac administration

Oracle’s Java 8 and Mac OS X 10.7.x

January 10, 2015 Leave a comment

With Oracle’s Java 8, there’s been some confusion as to whether Java 8 runs on Mac OS X 10.7.5. This issue was lent additional urgency in the wake of Oracle’s announcement that they will begin auto-updating Java 7 users to Java 8 starting in January 2015.

The root of the confusion lies in the fact that Oracle has listed two different sets of system requirements on their website for Macs running Java 8 on Mac OS X.

The first set is available via Oracle’s general Java system requirements page. This page states that Java 8 requires the following:

  • Intel-based Mac running Mac OS X 10.8.3+, 10.9+
  • Administrator privileges for installation
  • 64-bit browser

The second set is available via the Java download page for Mac OS X. The system requirements linked from the download page state that Oracle’s Java requires the following:

  • Intel-based Mac running Mac OS X 10.7.3 (Lion) or later.
  • Administrator privileges for installation
  • 64-bit browser

In short, the question of Java 8 support for 10.7.x depended on which system requirement page was correct. For more details, see below the jump.

Read more…

Follow

Get every new post delivered to your Inbox.

Join 226 other followers

%d bloggers like this: