sleuthkit / autopsy

Autopsy® is a digital forensics platform and graphical interface to The Sleuth Kit® and other digital forensics tools. It can be used by law enforcement, military, and corporate examiners to investigate what happened on a computer. You can even use it to recover photos from your camera's memory card.
http://www.sleuthkit.org/autopsy/
2.41k stars 597 forks source link

Java Version Confusion (requiring both 8 and 11?) #6472

Closed bannsec closed 3 years ago

bannsec commented 3 years ago

Hey all,

Looking for some guidance here. I've been building a docker version of autopsy and, until recently, it's been building just fine. Unfortunately, recently (I'll have to track back exactly when), I started getting java version errors. Specifically my setup has/is using JDK 8 (as recommended here: https://github.com/sleuthkit/autopsy/blob/develop/Running_Linux_OSX.txt). Lately, I've been getting these errors:

org.netbeans.InvalidException: StandardModule:org.sleuthkit.autopsy.core jarFile: /opt/autopsy/autopsy/modules/org-sleuthkit-autopsy-core.jar: java.lang.UnsupportedClassVersionError: org/sleuthkit/datamodel/SleuthkitJNI has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0

This indicates that my current version (8) cannot support the required version (11). However, if I try running in 11, i get the following:

org.netbeans.InvalidException: StandardModule:org.sleuthkit.autopsy.core jarFile: /opt/autopsy/autopsy/modules/org-sleuthkit-autopsy-core.jar: java.lang.IllegalArgumentException: java.lang.reflect.InvocationTargetException

Which then proceeds for freeze up my X11 for a bit and not open.

What's the recommended solution here? The errors make it seem like a contradiction.

Thanks!

esaunders commented 3 years ago

Yes, it looks like the Java bindings for the latest TSK release were built using Java 11. That's not right.

bcarrier commented 3 years ago

@bannsec Can you try this version? Looks like the build system was using Java 11 (since we are testing that right now).

https://drive.google.com/file/d/1H_LEbeiTfrziTJKIrhsk1bsakKZdQ1DM/view?usp=sharing

If it works, I'll upload it to github.

bannsec commented 3 years ago

Yep, that appears to fix it. Thanks!

rubiodamian commented 3 years ago

Amazing!

esaunders commented 3 years ago

The Java 8 version of the Sleuthkit bindings Debian package was uploaded to GitHub a few hours ago.