I'm not an expert with Java, so a lot of this is guesswork and looking around discussion forums.
But hopefully I'm steering you in the right direction.
You have several older versions of Java in your system, and in recent years both Java and MacOS have changed which environment variables, commands, and paths are used for a particular version. It is possible that java_home was not updated? I'd put more trust in what version is reported by the executable.
MacBook:~ me$ java -version
java version "1.8.0_25"
Just to make sure we are on the same page, my /usr/libexec/java_home is a symbolic link to /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java_home
It might not hurt to check your .profile or bashrc files to see if there are any (outdated) Java settings hiding.
Or if the "Current" symbolic link is pointing to the right version:
MacBook:~ me$ cd /System/Library/Frameworks/JavaVM.framework/Versions/
MacBook:Versions me$ ls -al
drwxr-xr-x 10 root wheel 340 Jul 30 2016 A
lrwxr-xr-x 1 root wheel 1 Nov 7 2015 Current -> A
Oracle recommends blowing away old versions of Java (for security reasons). Unfortunately, the Java web site gives instructions for Windows users to remove old Java versions, but the only info they give for Mac users is to uninstall/re-install.
https://www.java.com/en/download/help/mac_uninstall_java.xml
I found this discussion interesting.
http://superuser.com/questions/479372/java-version-reporting-wrong-version-on-ma c-osx-mountain-lion
It is old (Mountain Lion and Java 7), but the point is that even something as simple as installing from different sources (JRE vs. JDK) would make it confusing about which version of Java is being used. (The two install versions use different paths and environment variables.)
Hope something in there helps!