I have some Binary file and I suspected in was created with Java. Is there a way to find out which environment created that file (for example if its Java or gcc). And if it was created with Java, how can I determine the version of the Java.
I know the file
command and the output I get is:
ELF 64-bit LSB executable, x86-64, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), not stripped
It does not say much. So I used the ldd
command:
linux-vdso.so.1 => (0x00007ffff7ffe000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007ffff7dbf000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007ffff7bba000)
libutil.so.1 => /lib64/libutil.so.1 (0x00007ffff79b7000)
librt.so.1 => /lib64/librt.so.1 (0x00007ffff77ae000)
libuuid.so.1 => /lib64/libuuid.so.1 (0x00007ffff75a8000)
libm.so.6 => /lib64/libm.so.6 (0x00007ffff732d000)
libc.so.6 => /lib64/libc.so.6 (0x00007ffff6fb1000)
/lib64/ld-linux-x86-64.so.2 (0x0000555555554000)
Still does not tell me much. Are there other methods?
EDID: I think that my question does meet with the "XY-Problem". I'll try to understand the issue. I'm trying to determine if my tool (lets call it toolA
) uses Java and if it does - does it take it from the enamorment or is it hardcoded. My tool uses other tools so it is possible that one of them uses Java. I have a special tool (lets call it toolX
) which tracks all the touched files while toolA
is running. From the output, I found out that the Java comes from the binary file I talked. I found out that it uses Java1.6
but I'm not sure if it is coming from my environment or if it hardcoded. Also, I can't check if it's hardcoded because it is a Binary file. What to do?