From .exe to .dll menu

Shout-Out

User Tag List

Results 1 to 15 of 15
  1. #1
    2Old4this's Avatar Private
    Reputation
    1
    Join Date
    Jun 2011
    Posts
    4
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    From .exe to .dll

    Hello, today I have a small bot that use CTM and follows a simple waypoint-path. I do this by using the read/write-memory from a .exe file. I'm curious to take the next step and make one .Dll with a endscene hook. What is the biggest difference to be in WoW's process space?. What I'm looking for is some tips/keywords.I know how to implement the dll and the hook, but I feel like a noob when it comes to wow-specifik stuff. Humbly grateful for some advice so I start in the right direction.

    ..:: 2Old4This :confused:

    From .exe to .dll
  2. #2
    streppel's Avatar Active Member
    Reputation
    78
    Join Date
    Mar 2007
    Posts
    196
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the biggest difference: you can use luafunctions and create a much better bot this way

    if i were you i'd being wiritng the hook and the lua handler(alogn with getting return values), then you have the most important stuff done and you can focus on more important things like a good logic and navigation

  3. #3
    2Old4this's Avatar Private
    Reputation
    1
    Join Date
    Jun 2011
    Posts
    4
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the reply Streppel, tonight it will be to start testing some lua_dostring things.

    ..:: 2Old4This

  4. #4
    flo8464's Avatar Active Member
    Reputation
    30
    Join Date
    Apr 2009
    Posts
    434
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The biggest difference is that you are not running in your own context, which is highly dangerous in terms of safe programming.
    You have to deal with threads you can't controll and you maybe don't even know about, functions you don't know exactly etc.

    To write something safe and stable in the context of a foreign process is a hell of work, most people fail at it.
    Hey, it compiles! Ship it!

  5. #5
    streppel's Avatar Active Member
    Reputation
    78
    Join Date
    Mar 2007
    Posts
    196
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    idk how it is for wow exactly, but for the game i'm devloping a bot for, it is more or less the same if you are IP or OOP(using asm injection and createremotethread). in both cases it fails miserably when doing something bad(aka calling engine functions while not making sure that it's threadsafe with hooking something)

  6. #6
    Thongs's Avatar Member
    Reputation
    10
    Join Date
    Oct 2006
    Posts
    51
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by streppel View Post
    idk how it is for wow exactly, but for the game i'm devloping a bot for, it is more or less the same if you are IP or OOP(using asm injection and createremotethread). in both cases it fails miserably when doing something bad(aka calling engine functions while not making sure that it's threadsafe with hooking something)
    If you're using ASM injection and CreateRemoteThread you're not out of process.

  7. #7
    Bananenbrot's Avatar Contributor
    Reputation
    153
    Join Date
    Nov 2009
    Posts
    384
    Thanks G/R
    1/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I would call that kind of out of process "observing" as oppossed to a "passive" bot.
    We really shouldn't start that debate again in this thread...

  8. #8
    flo8464's Avatar Active Member
    Reputation
    30
    Join Date
    Apr 2009
    Posts
    434
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Bananenbrot View Post
    I would call that kind of out of process "observing" as oppossed to a "passive" bot.
    We really shouldn't start that debate again in this thread...
    There is nothing to debate.
    Why should there be a difference between injecting executable code directly and making the dynamic loader load some code from a library?
    Is library injection without LoadLibrary/dlopen ("manual mapping") also observing ?
    Hey, it compiles! Ship it!

  9. #9
    Bananenbrot's Avatar Contributor
    Reputation
    153
    Join Date
    Nov 2009
    Posts
    384
    Thanks G/R
    1/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I only introduced these terms to differentiate between meanings of "out of process".
    Note that I do not see any advantage to be observing over to be truly injected into the process.
    It's only about terms: How else would you describe those hack'ish runtime compiled asm injecting beasts?
    The main logic is certainly not executed inside the process.
    Therefore, I propose to use those 3 different terms, they are just un-misunderstandable: "passive", "observing" (ok, beat me on this one) and "injected"/"in process".

    Based on my understanding, manual mapping is being injected, because your main logic really runs inside the process.

  10. #10
    2Old4this's Avatar Private
    Reputation
    1
    Join Date
    Jun 2011
    Posts
    4
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Do not fight now guys, I appreciate your help so far. Know that in/out of process is a sacred issue

    ..:: 2Old4This

  11. #11
    Cypher's Avatar Kynox's Sister's Pimp
    Reputation
    1358
    Join Date
    Apr 2006
    Posts
    5,368
    Thanks G/R
    0/6
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by flo8464 View Post
    There is nothing to debate.
    Why should there be a difference between injecting executable code directly and making the dynamic loader load some code from a library?
    Is library injection without LoadLibrary/dlopen ("manual mapping") also observing ?
    ^ This.

    Code injection is code injection. The only time it makes a difference is when your bot is public, and you're comparing DLL injection to manual mapping (or ASM injection). In this one case, the DLL is slightly more detectable because DLLs loaded by the Windows PE loader are backed by a kernel section object, which can be detected (yes, this is even if you unlink yourself from the PEB loader list... nowadays everyone knows about the section object detection trick, so PEB unlinking is pointless). However, you're already detectable either way via memory hashing etc, so if you're public you'd need to hook the same APIs regardless (section objects that back memory regions are queried via NtQueryVirtualMemory, which is the same API you'd need to hook to hide your memory block anyway -- among others).

    Tl;dr: In a public bot, manually mapping a DLL is slightly better than regular injection, but it doesn't matter anyway, as there are a thousand other ways to detect your code. (e.g. I'm in ur stack, tracin ur function callz.)

  12. #12
    Bananenbrot's Avatar Contributor
    Reputation
    153
    Join Date
    Nov 2009
    Posts
    384
    Thanks G/R
    1/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I think we are talking at cross-purposes... You are right of course, but what I meant is more pragmatic.
    Think of Thongs:
    Originally Posted by Thongs View Post
    If you're using ASM injection and CreateRemoteThread you're not out of process.
    But is this real injection from a pragmatic point of view? Sure, it injects some dirty codecaves to call engine functions, but is the devil really "inside" the process?
    What about an out of process bot that only writes to the global CTM struct. There is not much injection going on (despite those memory writes).
    The main logic is executed in a seperate process. Codecaves are dumb, as are simple memory writes. It's more like a doctor who is modifying his patients internals, while he's narcotized (SuspendThread). The doctor is "observing", but not passive.

    Nothing from the "all or nothing" point of view regarding security while injecting here, just some more vocabulary to avoid misunderstandings. Maybe call it "ASM injection" to make it more clearly, but "Observing" was only one adjective that fit better to a dll name for me :P
    Last edited by Bananenbrot; 06-30-2011 at 03:44 AM.

  13. #13
    streppel's Avatar Active Member
    Reputation
    78
    Join Date
    Mar 2007
    Posts
    196
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i would rep you bananenbrot but i can't again yet
    injection is good for private things, so lets get back to topic now

    2old4this how is it going?

  14. #14
    Thongs's Avatar Member
    Reputation
    10
    Join Date
    Oct 2006
    Posts
    51
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Keep in mind what my initial post was responding to; streppel claimed that whether you're in or out of process, if you make a mistake you're basically going to crash WoW. If you were truly out of process, a mistake in your code wouldn't do this at all, though.

    Like flo said, there isn't any debate as to whether or not injecting ASM, or even writing values to memory, is in process. It absolutely is. I understand that you can separate OOP, 'observing', and in-process, but that doesn't change the fact that 'observing' still IS in-process. 'Observing' would be a category within in-process - but you can't be 'observing' without being in-process. I know that you understand this, though, Bananenbrot.

    I come to this forum to learn - everything I've ever done regarding programming and computer science in general has stemmed from this forum, as my bots were my first and only application I've written. As long as people continue to be told that they're safe as long as they don't inject a DLL, the longer it will take for them to truly understand what they're doing.

  15. #15
    2Old4this's Avatar Private
    Reputation
    1
    Join Date
    Jun 2011
    Posts
    4
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The only problem with this site is that when you are looking for one thing you'll find 10 new things you want to watch . Perhaps a luxury problem, searched information about lua_dostring but finding myself sitting in IDA and OllyDbg trying to understand how certain functions work. But these have to be clearly the most fun way to learn things about programming. Perhaps the best thing is to write down a list of things to do, so you do not float out with lots of other interesting things you find along the way.

    ..:: 2Old4This

Similar Threads

  1. [How-To] Extract AHK from EXE
    By lyan123 in forum Overwatch Exploits|Hacks
    Replies: 23
    Last Post: 09-09-2016, 03:00 PM
  2. Incorrect Hex from Enum (referenced DLL) but correct when decompiled
    By WiNiFiX in forum WoW Bots Questions & Requests
    Replies: 1
    Last Post: 12-17-2015, 12:29 PM
  3. [CODE] Dumping Python Modules (from an injected DLL)
    By GliderPro in forum Programming
    Replies: 0
    Last Post: 04-08-2009, 02:20 PM
  4. Help plz about Mysql.exe on the repack from ac-web
    By aznboy in forum World of Warcraft Emulator Servers
    Replies: 1
    Last Post: 11-06-2007, 10:39 PM
  5. Protect any .exe from Warden using Innerspace!
    By Nonominator in forum World of Warcraft Bots and Programs
    Replies: 13
    Last Post: 05-20-2007, 10:11 PM
All times are GMT -5. The time now is 12:25 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search