AhMyth icon indicating copy to clipboard operation
AhMyth copied to clipboard

Code Editor 0.7.3^ | Binding Failed

Open Morsmalleo opened this issue 1 year ago • 10 comments

This is an issue with

  • [x] Binding On Launch
  • [x] Binding On Boot

APK Name & Origin

APK Name: Code Editor v0.7.3 APK Origin: APK Pure || Code Editor

To Reproduce

Steps to reproduce the behaviour: 01. Open APK Builder 02. Type in server IP and Port 03. Without permissions 04. Browse for the APK 05. Bind with original APK 06. Building Failed

Logs

_Error: Command failed: java -jar "/root/AhMyth/AhMyth-Server/app/app/Factory/apktool.jar" b "/root/apk/editor" -o "/root/AhMyth/Output/Ahmyth.apk"
Exception in thread "main" org.jf.util.ExceptionWithContext: Exception occurred while writing code_item for method La03;->get()Ljava/lang/Object;
  at org.jf.dexlib2.writer.DexWriter.writeDebugAndCodeItems(DexWriter.java:1047)
  at org.jf.dexlib2.writer.DexWriter.writeTo(DexWriter.java:346)
  at org.jf.dexlib2.writer.DexWriter.writeTo(DexWriter.java:301)
  at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:58)
  at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:37)
  at brut.androlib.Androlib.buildSourcesSmali(Androlib.java:430)
  at brut.androlib.Androlib.buildSources(Androlib.java:361)
  at brut.androlib.Androlib.build(Androlib.java:313)
  at brut.androlib.Androlib.build(Androlib.java:280)
  at brut.apktool.Main.cmdBuild(Main.java:255)
  at brut.apktool.Main.main(Main.java:82)
Caused by: org.jf.util.ExceptionWithContext: Error while writing instruction at code offset 0x2
  at org.jf.dexlib2.writer.DexWriter.writeCodeItem(DexWriter.java:1320)
  at org.jf.dexlib2.writer.DexWriter.writeDebugAndCodeItems(DexWriter.java:1043)
  ... 10 more
Caused by: org.jf.util.ExceptionWithContext: Unsigned short value out of range: 68771
  at org.jf.dexlib2.writer.DexDataWriter.writeUshort(DexDataWriter.java:116)
  at org.jf.dexlib2.writer.InstructionWriter.write(InstructionWriter.java:356)
  at org.jf.dexlib2.writer.DexWriter.writeCodeItem(DexWriter.java:1280)
  ... 11 more_

OS Info

please complete the following information:

  • OS: Debian
  • OS Version: Kali 2022.4

Morsmalleo avatar Jul 24 '22 01:07 Morsmalleo

Unfortunately the upgrades in the new release of AhMyth Android R.A.T (v1.0-beta.4) require the payload files to be thrown into a new smali_classes** folder as they can not be injected into the same smali_classes** folder containing the path to the Launcher Activity file because AhMyth's Apktool will throw an Unsigned Short Value Error if they are injected into the same folder containing the path to the Launcher Activity file.

According to iBotPeaches developer of Apktool, the only way around this error is the work around explained above.

Fortunately though this work around explained by iBotPeaches has been tested manually with th AhMyth payload and it works with almost every APK you do it with, so the next release of AhMyth (which will be titled v1.0-beta.5) will contain the fix for APK's throwing Unsigned Short Value errors.

Morsmalleo avatar Jan 01 '23 09:01 Morsmalleo

Unfortunately the upgrades in the new release of AhMyth Android R.A.T (v1.0-beta.4) require the payload files to be thrown into a new smali_classes** folder as they can not be injected into the same smali_classes** folder containing the path to the Launcher Activity file because AhMyth's Apktool will throw an Unsigned Short Value Error if they are injected into the same folder containing the path to the Launcher Activity file.

According to iBotPeaches developer of Apktool, the only way around this error is the work around explained above.

Fortunately though this work around explained by iBotPeaches has been tested manually with th AhMyth payload and it works with almost every APK you do it with, so the next release of AhMyth (which will be titled v1.0-beta.5) will contain the fix for APK's throwing Unsigned Short Value errors.

Function for this will be done soon

Morsmalleo avatar Feb 14 '23 16:02 Morsmalleo

The same error in all the apks that I have tried. Something new?

SubUrban23 avatar Mar 17 '23 20:03 SubUrban23

The same error in all the apks that I have tried. Something new?

I have a function for handling this error, unfortunately the new function, it doesn't work on all APK files that throw this unsigned short value error, like this one for example, but it does with some others, so I'll have to explore more ways of bypassing this error

Morsmalleo avatar Mar 18 '23 01:03 Morsmalleo

Looking at multidex for the AhMyth payload to bypass the 64bit dalvik method, which is where these unsigned short value out of range errors come from

Morsmalleo avatar Mar 30 '23 04:03 Morsmalleo

Binding problems with this APK have been Fixed in the new release coming soon.

Morsmalleo avatar Jul 02 '23 09:07 Morsmalleo

Binding problems with this APK have been Fixed in the new release coming soon.

Oh Noice . Any Date or Day Please, Cox i am waiting from Long time and that apk binding problem literally killed me. <3

afaan13 avatar Jul 05 '23 12:07 afaan13

Binding problems with this APK have been Fixed in the new release coming soon.

Oh Noice . Any Date or Day Please, Cox i am waiting from Long time and that apk binding problem literally killed me. <3

Yeah should be released Early October Hopefully

Morsmalleo avatar Jul 06 '23 08:07 Morsmalleo

reopened due to major binding bug

Morsmalleo avatar Jul 29 '23 21:07 Morsmalleo

Unfortunately newer updates for the revision of 1.0-beta.5 don't solve the binding problems for this APK, I'm so sorry for any inconvenience.

I will work on solving thing binding problems with this APK as much as possible

Morsmalleo avatar Aug 04 '23 23:08 Morsmalleo