Questions tagged [java]

Java is an object-oriented language and runtime environment (JRE). Java programs are platform independent, because they are compiled to bytecode and their execution is handled by a Virtual Machine called the Java VM or JVM.

Filter by
Sorted by
Tagged with
1
vote
1answer
27 views

Are there any Java decompilers accurate enough that if I recompiled the result, it should be identical to the original program?

I am trying to decompile minecraft, to see if I can analyze the code to make a few small changes, but I need a decompiler good enough so I can recompile it in a way that will work. I have tried ...
0
votes
0answers
15 views

Obfuscated Config Files: EHI Files for HTTP Injector

So I have an ehi file, which is a configuration file for an Android App called HTTP Injector. Of course when I try to see it as a simple text, I just get random characters. What tool could I use to ...
1
vote
0answers
41 views

Calling functions of a shared object (.so) extracted from an APK

Decompiling a regular Android application I noticed that its code uses some native functions. So, unpacking the (.apk) file I found the usual "lib" folder and under that a series of folders for ...
0
votes
0answers
46 views

How to guess the key of XOR encryption in java?

I am trying to find the key of XOR encrypted string in java. It is very much probable that the key is eight characters long. I have the encrypted string. I am not able to understand how to go ...
0
votes
1answer
173 views

Ghidra pseudocode to Java/C

I have this piece of code generated from Ghidra void __cdecl FUNCTION(uint *key,uint *text) { undefined uVar1; ushort uVar2; uint *puVar3; uint *puVar4; uint *puVar5; int iVar6; uint ...
1
vote
2answers
125 views

Constant pool error

To debug a jar file, i tried to modify java bytecode using JByteMod tool and print some variable to standard output. The variable i'm trying to print is an ArrayList. Specifically, it's a public ...
0
votes
0answers
76 views

Decoding blob data from a sqlite database into readable format

I have a Sqlite database file that has blob data in it. I only know the the database has blob data and I know what the expected output should be. The blob data's expected output should be a Mac ...
1
vote
0answers
270 views

Debugging Ghidra Script [closed]

I want to write a new script for ghidra to extract variuous information from the binary and store it to an external file for future management. I need to perform the analyisis with Ghidra Headless in ...
0
votes
1answer
43 views

Java obfuscated methods and params

Try to decompile several classes from jar and found this public static final boolean \u2005\u200e; and if (\u2005\u200e) { final boolean \u2005\u200e = tEstPrOJEcTDEV7i.\u2005\u200e; } ...
3
votes
0answers
93 views

Reverse engineering android native packer

im trying to Reverse engineering an android app and the app have 4 folders in the /data/data/{package} folder ├───app_dexprotector │ 823517D25836B88F1C499C02370A047E.dat │ ...
1
vote
0answers
146 views

decompiled android application with only one class [DexProtector]

I'm trying to reverse engineering an android app and it's mostly for an experiment but I have a problem that I can't find a solution or even what is the problem. I decompiled an app with JADX-gui and ...
-1
votes
1answer
53 views

decomplied apk with bad parameters

I'm trying to reverse engineering an android app API so this is what I tried: First the app was using Okhttp certificate pinning and I couldn't track the URLs with Charles then I tried this method ...
2
votes
2answers
222 views

Is PNF's JEB Reverse Engineering platform written in pure Java?

I have seen the JEB decompiler by PNF Software morph from a specialised decompiler to a full fledged reverse engineering platform like Capstone or IDA Pro. While examining the earlier versions of JEB,...
2
votes
1answer
368 views

Find function in a stripped dynamic ELF library

Im currently reverse engineering an android app and this app calls a function named "getUserInfo" in an ARM 32bit ELF library called "libcms.so" via the Java Native Interface. My Problem is: The ...
1
vote
0answers
67 views

Common practices for 'hiding' a class within an Android application?

I've recently gotten into Android reverse engineering, and I've been messing around with some apps lately for education/research purposes to see how some things are done with private (mobile) APIs. ...
0
votes
2answers
318 views

What functions (in which modules) can be hooked by Frida to access unencrypted data of SSL connections in Java programs running under Windows?

There are gazillions of internet resources discussing how to use Frida to hook and otherwise mess around with SSL connections of Java programs running under Android, but seemingly (as far as my google-...
1
vote
1answer
158 views

Reversing a Java digest function, with known public key and source code

A Java application verifies that an XML string that came from a clearnet server (no SSL) has not been tampered, using a message digest. It does so with a public key stored locally, accessed with the ...
1
vote
0answers
49 views

Intercept traffic from exe to my Java server

In Windows 10, I can easily intercept traffic of an application using Proxifier and route it to Charles proxy, so that I can inspect and edit the data. exe -> Proxifier (Socks proxy to localhost:...
0
votes
2answers
256 views

.exe file to .class, decompiled to .java, how to put back to .class?

I'm trying to reverse engineer a very complex .exe to alter its behavior. Ran JWScan that tells me it's been wrapped with Jar2Exe (which I also saw during debugging). Looking at the complex exe with ...
1
vote
1answer
133 views

Reverse Engineering Flat Data File

I'm writing a piece of software that will take positional data from a piece of software called Pyware and put it into a GUI so I can visualize the coordinates and assign each coordinate a color. ...
1
vote
2answers
170 views

Reverse engineer a ARM-v7a function

Currently I am trying to reverse engineer the following armeabi-v7a function: I already wrote the following Java code: static double getFunc(double param0, double param1, double param2, double ...
7
votes
2answers
323 views

Why do obfuscators remove line numbers, and can I safely leave them in?

Application security engineer here. When we compile our java code, we obfuscate it using KlassMaster and have it remove line numbers (see KlassMaster docs) because of a handwavy explanation "it makes ...
1
vote
1answer
194 views

Reversing video protocol for chinese drone so i can view the stream outside of the app

I am trying to view the video stream of the vento protocol air drone on my computer. The final goal is to get the video stream into python or c++ for opencv; however, if i can just view it in a ...
1
vote
0answers
57 views

Is there any way to get value from bytecode under JDWP without access to source?

When I debug android app through jdwp using jdb, it seems I can't get anything from the bytecode level. I know normally it's fine as long as we have the source line info and use a decompiler, but the ...
1
vote
1answer
359 views

How to find the executable code of the native method in the library * .so? (Android)

I'm doing reverse engineering of a mobile application for android and I had a question how to find the executable code of the native method in the library * .so. From the code of the code, the native ...
2
votes
0answers
74 views

How to reverse a java thread to get its origin

I was working on a java application which is run for the first couple of minutes & then application interface hangs. I had open the application in JMC & it shows later I create a thread dump ...
0
votes
1answer
210 views

Android Reverse Engineering Network Traffic Stack Trace

Lets say an Android application sends out a traffic out to the server and expects a Json Response Request: https://server:port/userid=user1&token=randomstring7345 We want to replicate the ...
-1
votes
2answers
41 views

How to view SDK files and is it mandatory to run modified apk on rooted device

I am performing reverse engineering on android apk using apktool. Is there any way I can view the code in SDK/NDK files ? if i make any change in the .smali files is it necessary to run the modified ...
1
vote
2answers
989 views

Patching a class file inside Jar using bytecode

I was trying to patch an application, but the application is required to exact same class size as the original one but editing class file with JByteMod, Recaf or whatsoever always changes the class ...
3
votes
1answer
152 views

Disassemble/decompile arbitrary JVM bytecode

I have an obfuscated java binary which does runtime code injection using java reflection like this. Object o = "a long string"; ((Method)o).invoke(params..); (If I write this in a java file, it ...
2
votes
1answer
124 views

How can I generate the recovery password on a legacy system (Original company is out of business) running on my local machine?

I'm attempting to use a legacy systems recovery feature that typically required calling/faxing a company that is no longer around. Basically, the system was designed to go into a recovery mode and ...
0
votes
1answer
178 views

How can I open id0, id1, nam, so, or til files?

I am attempting to reverse engineer the DYMO Connect app in order to learn how to print to a DYMO LabelWriter Wireless printer. However, the mobile driver for the printer is in several different ...
1
vote
0answers
275 views

Java Bytecode edit

Hi, I would like to edit one compiled java class file & like to insert & edit a couple of lines. I'm trying to make a patch for a software & when I compare this two file the only change I ...
2
votes
1answer
208 views

JAVA Decryption - Reverse engineering an Android application

I am trying to decrypt an encrypted string, but I am stuck in Ciper.doFinal() where the decryption throws a BadPaddingException. The string in question is 3qBogw/PIqpErH/DyEHLTQ==. One thing I know is ...
0
votes
1answer
187 views

How add String.equals to java bytecode (Krakatau)

I use Krakatau to edit java code. class test{ public boolean Func2(String text) { if(text=="aaaaaa") return true; return false; } } When I compile it I get this java bytecode ....
0
votes
1answer
327 views

Compute stack frames while edit java bytecode

I saw here edit java bytecode got error that when editing java bytecode with Krakatau ,it may happend to error on stack frames. The answer there offer to change Krakatau version to 50. If I only ...
1
vote
1answer
425 views

explain java bytecode

I saw java bytecode that need to compare to var, if they equal return true, else ..... if(var1==var2) return true; else { ...} on bytecode aload 1 aload 2 if_acmpne 6 iconst 1 ireturn I ...
1
vote
1answer
432 views

can't edit class file with recaf.0.9 without re-compile

I have this java code public class HelloWorld { public static void main(String[] args) { System.out.println("Hello World!"); } } I compile to class file, run it , and all fine. I ...
-1
votes
1answer
189 views

[B symbol in java bytecode

I looking at java bytecode and understand almost everything. I saw the symbol [B on java bytecode. What does it mean?
-1
votes
1answer
1k views

How to add code to compiled java class

I have java code that is compiled to a .class file. There is a function that gets few parameters and do some action (e.g. get int x and int y and do x+y) I want to add to this .class file code that ...
2
votes
1answer
679 views

How to use Frida on a Java application ? (non Android application)

I am trying to use Frida on a Java application which is obfuscated with ZKM (Zelix KlassMaster). When I attach to the process, it seems the JVM is not loaded: [Local::PID::23585]-> Java.available ...
1
vote
1answer
81 views

Android Intercepts for log the Funtion Calls to javax

Im reversing an apk that uses a native library .so to make calls to some Java methods thru reflexion I know by analysing the app that exist the followings calls: import javax.crypto.Mac; import ...
1
vote
1answer
1k views

How to combine 2 dex files into a single dex file for more complete disassembly by IDA Pro

Most apk files, when disassembled, produces 2 dex files instead of one. However since IDA Pro only allows the loading of one dex file at a time,it may result in missing information as a result of the ...
0
votes
1answer
54 views

Need help understanding “garbage” data in https request

I managed to overcome certificate pinning in an android application and I am now able to view all the HTTPS request in plain text. However, I came across this request that I still do not understand: ...
3
votes
1answer
730 views

How to detect JNI calls from smali code?

In Android, JNI calls could be used to load native code from other sources. From the link http://bobao.360.cn/learning/detail/3765.html, the following sample code shows how a smali code would look ...
1
vote
1answer
221 views

Trying to reverse function to generate certain color strings from an HMAC signature - decompiled code LOOKS right, but my results differ

This might be a bit difficult to follow without context, but the gist of it is the following; I'm trying to reverse a certain application, and part of what I"m attempting to reverse in the app ...
0
votes
2answers
365 views

Smali vs Decompilation for malware detection in apk files

When it comes to reversing apk files, I understand that are mainly 2 approaches. The first involves using a decompilation engine which will try to produce java files which are more readable but can be ...
1
vote
1answer
1k views

How do I Log a String Referenced within a Method - Smali

I have been trying to reverse engineer an Android application and was wondering how I would go about logging a certain string. Here is the method I am trying to log the String from: .method private ...
2
votes
1answer
111 views

Disassembled Java class file differs from Source

While trying to understand a behavior of TestNG I found my self disassembling the .class files. During that, I accidentally noticed that the official binary differs from the one built manually from ...
1
vote
1answer
2k views

Anti-tampering techniques in Android APK's

I'm reverse engineering an Android app, and it has some kind of anti-tamper protection. The problem is that I can't find it anywhere in the smali files. Even if I just re-sign the official APK that I ...