Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

Java 

Decompilation advice needed

Hypothetically, I decompile a runnable jar using JD-GUI, and if I wished to use it.

How would I know the versions of the libraries it uses?
For example, if it uses apache commons and google commons, how can I tell the EXACT version?
You can't just by decompiling. The only giveaways are the methods and fields used in the library.
(Jan 23, 2017 01:26 AM)Aussie Wrote:  Hypothetically, I decompile a runnable jar using JD-GUI, and if I wished to use it.

How would I know the versions of the libraries it uses?
For example, if it uses apache commons and google commons, how can I tell the EXACT version?
The only way to tell is by whatever one is bundled with the library, or what's on the classpath. Your bet bet would be to look at each libraries manifest and see if they've included the version there


(Jan 23, 2017 09:56 AM)GenericSkid Wrote:  You can't just by decompiling. The only giveaways are the methods and fields used in the library.
Ignore this guy, he's retarded.

[Image: 4jbrxO5.png]
Fully scriptable botting/cheating software for games such as Albion Online, Rust, and SMITE.
(Jan 23, 2017 10:50 AM)3cli‌‌pse Wrote:  The only way to tell is by whatever one is bundled with the library, or what's on the classpath. Your bet bet would be to look at each libraries manifest and see if they've included the version there

What if the library isn't bundled? OP said nothing about having the libraries, just the application that uses them.

Your solution only works if he has the libraries. Depending on how Op obtained the file he may or may not have them.
(Jan 23, 2017 11:47 AM)GenericSkid Wrote:  What if the library isn't bundled? OP said nothing about having the libraries, just the application that uses them.

Your solution only works if he has the libraries. Depending on how Op obtained the file he may or may not have them.

Looking at what fields and methods are referenced is literally retarded, and you can't base your decision off that. The only way to tell what version of an API is being used it to fucking look at the one that came with it 👍

For fields: none should be referenced at all, as jvm folds all constants references at bytecode level, and no decent api publicly exposes member variables
For methods: They should generally always be there, even if underlying code has changed, it's the purposes of writing getters/setters in the first place.

As usual you don't think though what you're talking about, and make yourself seem god damn retarded Pankake.

[Image: 4jbrxO5.png]
Fully scriptable botting/cheating software for games such as Albion Online, Rust, and SMITE.
(Jan 23, 2017 12:11 PM)3cli‌‌pse Wrote:  Looking at what fields and methods are referenced is literally retarded, and you can't base your decision off that. The only way to tell what version of an API is being used it to fucking look at the one that came with it 👍

For fields: none should be referenced at all, as jvm folds all constants references at bytecode level, and no decent api publicly exposes member variables
For methods: They should generally always be there, even if underlying code has changed, it's the purposes of writing getters/setters in the first place.

As usual you don't think though what you're talking about, and make yourself seem god damn retarded Pankake.

Ignore this retard, his college didn't even teach him about NoSQL 🤣

You need to inspect the code written, and decide how retarded it is. More retarded = older libraries
(Jan 23, 2017 12:11 PM)3cli‌‌pse Wrote:  Looking at what fields and methods are referenced is literally retarded, and you can't base your decision off that. The only way to tell what version of an API is being used it to fucking look at the one that came with it 👍

Some libraries add/remove/deprecate methods and classes in between versions every now and then and based on that information you can ballpark what version of the library is used if you don't have direct access to the library itself.

(Jan 23, 2017 12:15 PM)clrlslwi Wrote:  Ignore this retard

Pls no use of the "R-word" it offend me and my kind.

(Jan 23, 2017 12:15 PM)clrlslwi Wrote:  You need to inspect the code written, and decide how retarded it is. More retarded = older libraries

Perfect solution 👍
Fuck it, just use the newest lib, shit should work no matter what. And no API removes methods, like ever. Only get marked at deprecated. And in the off chance something was removed, just go back one major revision and try again.

[Image: 4jbrxO5.png]
Fully scriptable botting/cheating software for games such as Albion Online, Rust, and SMITE.
(Jan 23, 2017 12:29 PM)GenericSkid Wrote:  Perfect solution 👍

My advice is solid, bro. R words don't use build tools, meaning they never get updated cus they manually include them, and are too lazy to update them.
Haha, I switched to maven, and I set the library at the highest, and kept downgrading until all the errors went poof! All done without the use of the 'R-word'

Thanks fellas, but I have new issues now. Unfortunately


Possibly Related Threads...
Thread / Author Replies Views Last Post
[.NET] by OmbraAug 6, 2014 04:23 AM 11 374 Aug 6, 2014 04:23 AM
Last Post: Washi
[C#] by JavaProphetOct 15, 2013 03:51 PM 6 1,254 Oct 15, 2013 03:51 PM
Last Post: JavaProphet
[C] by IluminiOct 11, 2011 06:23 PM 1 55 Oct 11, 2011 06:23 PM
Last Post: Shihanus