Giter Site home page Giter Site logo

Patching libg.so about coc-proxy-csharp HOT 6 CLOSED

clugh avatar clugh commented on June 27, 2024
Patching libg.so

from coc-proxy-csharp.

Comments (6)

clugh avatar clugh commented on June 27, 2024

dd actually does the patching. xxd is simply used to write the key to a file using its hex representation and read them back out for verification. That said, you can use the hex editor of your choice to manually update the key in libg.so, though this method is more prone to human error. If you use this method, note that the offsets are listed in base 10 (decimal), so you may need to convert them to hexadecimal before using them.

To do this with HxD:

  1. Open libg.so.
  2. Click Search -> Goto... in the menu bar.
  3. Enter the Offset, check the dec radio button, and click Ok.
  4. With the new key in your clipboard, click Edit -> Paste write.

Note: Be sure that the key is pasted into the hex values on the left, not the ASCII representation on the right.

from coc-proxy-csharp.

mathieu95 avatar mathieu95 commented on June 27, 2024

I did just that, and when I try to lunch CoC, it just returns to main screen of android. If I restart, I can lunch clash of clan and everything works, but I don't see anything on coc-proxy-csharp except "Listening on 0.0.0.0:9339

UPDATE: Now I am stuck on Loading, it seems that it is unable to connect to the proxy

from coc-proxy-csharp.

clugh avatar clugh commented on June 27, 2024

Sounds like you aren't properly routing the packets. What method are you using? Are the client and proxy on the same local network? If not, are you forwarding port 9339?

For simplicity, I suggest using Hosts Editor (requires root). Do the initial tests on an unpatched version of game, so if your base loads, you'll know the packets aren't being rerouted. If it fails, the proxy should have a note about not being able to decrypt the login packet; otherwise, it isn't receiving the packets.

from coc-proxy-csharp.

mathieu95 avatar mathieu95 commented on June 27, 2024

So it seems like the packets are being received, now I am getting this error:

Listening on 0.0.0.0:9339 ...
System.IO.DirectoryNotFoundException: Could not find a part of the path 'D:\CoC\coc-proxy-csharp\bin\messages\definitions'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileSystemEnumerableIterator1.CommonInit() at System.IO.FileSystemEnumerableIterator1..ctor(String path, String originalUserPath, String searchPattern, SearchOption searchOption, SearchResultHandler`1 resultHandler, Boolean checkHost)
at System.IO.Directory.GetDirectories(String path)
at coc_messages_csharp.Definitions.read() in D:\CoC\coc-proxy-csharp\messages\Definitions.cs:line 11
at coc_proxy_csharp.State..ctor() in D:\CoC\coc-proxy-csharp\State.cs:line 16
at coc_proxy_csharp.Server.AcceptCallback(IAsyncResult ar) in D:\CoC\coc-proxy-csharp\Server.cs:line 52

EDIT: I fixed this part. I got another error. I will attempt to fix it and will update if I need any help

Thanks for being so helpful <3

from coc-proxy-csharp.

clugh avatar clugh commented on June 27, 2024

Do you mind posting your solution, in case anyone else stumbles on the same error and ends up here?

From the sound of it, you hadn't initialized the repo's submodules:

https://git-scm.com/book/en/v2/Git-Tools-Submodules#Cloning-a-Project-with-Submodules

from coc-proxy-csharp.

mathieu95 avatar mathieu95 commented on June 27, 2024

I don't know what caused my first issue, but I managed to fix it simply by putting the messages folder in the D:\CoC\coc-proxy-csharp\bin\

My other issue consisted of not having the pulling and pushing to the right path using adb, since I am using Kitkat I needed to use the path listed on the wiki

from coc-proxy-csharp.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.