Speculation:  inject LUA? menu

Shout-Out

User Tag List

Page 1 of 2 12 LastLast
Results 1 to 15 of 25
  1. #1
    amadmonk's Avatar Active Member
    Reputation
    124
    Join Date
    Apr 2008
    Posts
    772
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Speculation: inject LUA?

    Here's an odd thought I've been toying with. LUA is insanely easy to host. What would be the benefits/possibilities of injecting a LUA host into WoW.exe?

    But wait, you say, there's already a LUA hosted in WoW. Yes, but it's a crippled LUA possibly tied to Warden checks. An injected LUA couldn't bypass the Warden checks in cfuncs, but you'd know that anything you called in YOUR LUA would be as safe as your cave was. Also, dealing with the WoW LUA stack would no longer be a problem since you could (in theory) just snatch the stack for your own LUA.

    Also, the benefits of having a scripting engine tied to your hack shouldn't be underestimated; this makes changing hacks trivial (no need to unload DLL's and reinject), it shortens the development cycle for behavioral changes (for bots and such).

    It's probably not on anyone's to-do list, and it might even be impossible (if hosting two LUA instances isn't possible), but it's an interesting thought-experiment...
    Don't believe everything you think.

    Speculation:  inject LUA?
  2. #2
    Shynd's Avatar Contributor
    Reputation
    97
    Join Date
    May 2008
    Posts
    393
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It'd definitely be interesting. You could expose all kinds of functionality that's not there, such as timing functions (Sleep) and memory read/write. Plus being able to call WoW's LUA through FrameScript_Execute and pop the return values off of the stack at will, along with wrappers around the engine functions that would be necessary (EnumVisibleObjects, etc.), it would be very interesting and a lot less of a pain in the ass.

    Hell, check if bot.lua has changed on disk every frame and, if it has, stop the bot, discard the old one, load the new one, and, voila!, you can instantly make changes and debug.

    I like the idea (as if that wasn't obvious).

  3. #3
    mgX's Avatar Member
    Reputation
    39
    Join Date
    Feb 2008
    Posts
    98
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    and how would you deal with exposing methods to the lua interface?

    seriously, might aswell just inject a dll and get it overwith....

  4. #4
    Shynd's Avatar Contributor
    Reputation
    97
    Join Date
    May 2008
    Posts
    393
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I believe he's talking about injecting a DLL compiled with the LUA library that exposes whatever interfaces and loads the necessary .lua files from disk. It would make runtime-recompilation a breeze, as well as switching between hacks (as he stated).

    Distribute the library with a skeleton LUA fishbot, or something, and you can get all kinds of people who are otherwise incapable of writing their own shit up to their necks in contributing to the community. I don't know if any of you have been around long enough to remember with ForceShock was the biggest thing in WoW botting, but it had a huge contributing community simply because of the ease of tweaking LUA source. I, for one, think this is a good idea if brought to a release-quality library.

  5. #5
    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)
    I'm going to be doing this for my hack framework. You are indeed correct that a scripting engine is great to have.

    Just look at InnerSpce, LavishScript is awesome to test that your code is working correctly.

    "It's probably not on anyone's to-do list, and it might even be impossible (if hosting two LUA instances isn't possible), but it's an interesting thought-experiment..."
    It's possible, and it's on mine. Assuming we're talking about a LUA engine that exposes methods in your own code, and not attempting to expose the methods in WoW and run those.

  6. #6
    Apoc's Avatar Angry Penguin
    Reputation
    1388
    Join Date
    Jan 2008
    Posts
    2,750
    Thanks G/R
    0/13
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Cypher View Post
    I'm going to be doing this for my hack framework. You are indeed correct that a scripting engine is great to have.

    Just look at InnerSpce, LavishScript is awesome to test that your code is working correctly.

    "It's probably not on anyone's to-do list, and it might even be impossible (if hosting two LUA instances isn't possible), but it's an interesting thought-experiment..."
    It's possible, and it's on mine. Assuming we're talking about a LUA engine that exposes methods in your own code, and not attempting to expose the methods in WoW and run those.
    Why? It would be awesome to be able to expose WoW's methods via Lua. (Even moreso than they already are.)

  7. #7
    lanman92's Avatar Active Member
    Reputation
    50
    Join Date
    Mar 2007
    Posts
    1,033
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Wow. It's easy to load lua into WoW. I just got my lua calling console functions. Time to write some lua bot sexiness...

  8. #8
    amadmonk's Avatar Active Member
    Reputation
    124
    Join Date
    Apr 2008
    Posts
    772
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm glad to realize that my vague idea that this might be useful wasn't totally insane.

    I'm also glad that Cypher and others are working on it, since along with getting my packet-sniff multibot running, someday finishing my encryption call gate that I've since realized is useless (thanks for taking the wind out of my sails, Cypher), and eventually writing a hypervisor (oh yeah, and a Wine stealth module), I'm running short of time to, say, go to work and earn a living...
    Don't believe everything you think.

  9. #9
    amadmonk's Avatar Active Member
    Reputation
    124
    Join Date
    Apr 2008
    Posts
    772
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Cypher View Post
    I'm going to be doing this for my hack framework. You are indeed correct that a scripting engine is great to have.

    Just look at InnerSpce, LavishScript is awesome to test that your code is working correctly.

    "It's probably not on anyone's to-do list, and it might even be impossible (if hosting two LUA instances isn't possible), but it's an interesting thought-experiment..."
    It's possible, and it's on mine. Assuming we're talking about a LUA engine that exposes methods in your own code, and not attempting to expose the methods in WoW and run those.
    Yeah, sometimes scripting languages rock. Like, say, for making a behavior tree engine that uses coroutines for decision blocks (thanks, www.aigamedev.com!). Getting basic yield-based coroutines (or pseudocoroutines) working in C# took me the better part of two days, whereas it took me all of a half hour in LUA...
    Don't believe everything you think.

  10. #10
    lanman92's Avatar Active Member
    Reputation
    50
    Join Date
    Mar 2007
    Posts
    1,033
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You have some serious goals there. I've been contemplating about Wine, seems like it would be a fun project. Bit rusty with my unix though... I'm going to make a API(similar to WoW's, but with functions that are actually USEFUL) in Lua. Been waiting for an idea, and this seems feasable

  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 Apoc View Post
    Why? It would be awesome to be able to expose WoW's methods via Lua. (Even moreso than they already are.)
    I guess. But primarily I want it so I can easily test my code. Basically its going to be for my framework what LavishScript is for InnerSpace (except that I don't intend to write bots in it, it will be used for what it's supposed to be used for, quick and dirty testing :P).

    Originally Posted by amadmonk View Post
    I'm glad to realize that my vague idea that this might be useful wasn't totally insane.

    I'm also glad that Cypher and others are working on it, since along with getting my packet-sniff multibot running, someday finishing my encryption call gate that I've since realized is useless (thanks for taking the wind out of my sails, Cypher), and eventually writing a hypervisor (oh yeah, and a Wine stealth module), I'm running short of time to, say, go to work and earn a living...
    Real work sucks.

    What do you wanna do a Wine stealth module for? Do you actually intend to run bots/hacks under Wine or is it just for fun and practice?


    Originally Posted by amadmonk View Post
    Yeah, sometimes scripting languages rock. Like, say, for making a behavior tree engine that uses coroutines for decision blocks (thanks, www.aigamedev.com!). Getting basic yield-based coroutines (or pseudocoroutines) working in C# took me the better part of two days, whereas it took me all of a half hour in LUA...
    I actually just want it for quick and dirty testing of my code.

    For example, at my console I'd like to be able to do:
    echo Target.Health
    or w/e the lua syntax is. Assuming I've exposed an object "target" and member "health".

  12. #12
    ramey's Avatar Member
    Reputation
    45
    Join Date
    Jan 2008
    Posts
    320
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I've been writing a framework too.

    It is a bit like Innerspace. It has modules, to extend functionality etc.

    It is also using Lua as the scripting language, and at the moment I have most of the core done, which is the helper classes(findpattern etc) lua vm, and the general managers for the lua scripts/modules.

    It is coming along nicely, and amadmonk you're right, scripting languages are very powerful because you can test scripts so fast.

    At the moment once a script will be loaded in console it will register the dependant modules it needs to function, and load those before the script at runtime. If another script is loaded, it will register the dependant modules again( for ex. WoW, Warden modules) and it will load them if they aren't already loaded. If I unload one script it will unload the modules that it depended on only if it is the only script needing that module.

    So basically, it will keep module loading to bare minimum. All this functionality is done, bit dirty code in places but I'm happy with it!

    At the moment the syntax is like Core.Log:Write(); include(); etc.

    I'm looking forward to writing my modules, even though it will be a fair amount of work - the project is surprisingly fun to do!

    I might end up releasing without a warden module, which wouldn't be too hard to do yourself, or i might even release with it.. doubt that though.

  13. #13
    tanis2000's Avatar Active Member
    Reputation
    39
    Join Date
    Feb 2009
    Posts
    123
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Any scripting language will do the trick. I'm using CS-Script as I'm mainly writing stuff in C# and it's nice to have C# as your scripting language too. At some point I'll plug in LUA too so that you can choose which way to go. It's always good when you need to do some tests and you can as well use it to write your own bot behavior.

  14. #14
    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)
    I just got lua working about 5 minutes ago.

    Simply exposing and calling a test function atm. But obviously now that I have that working I can go about writing a proper wrapper around it and exposing all my APIs.

    Screenshot of the first test:

  15. #15
    amadmonk's Avatar Active Member
    Reputation
    124
    Join Date
    Apr 2008
    Posts
    772
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Nice... that was fast. Gotta love those DX libs

    It'll be interesting to see how easy it is to inject your own cfuncs, and whether/if you can interact smoothly with WoW's LUA. I wonder if you can make a semi-generic hook framework for your LUA scripts?
    Don't believe everything you think.

Page 1 of 2 12 LastLast

Similar Threads

  1. Lua injection return value.
    By LogicWin in forum WoW Bots Questions & Requests
    Replies: 1
    Last Post: 03-28-2011, 09:45 AM
  2. C# Lua Wrapper (No ASM, Requires injected CLR)
    By Apoc in forum WoW Memory Editing
    Replies: 29
    Last Post: 02-04-2011, 02:52 PM
  3. Unlock Protected LUA with a Patch? (Without Injecting code?)
    By Zeroi9 in forum WoW Memory Editing
    Replies: 15
    Last Post: 03-30-2009, 05:58 PM
  4. [Lua] Error while injecting
    By Nilrac in forum WoW EMU Questions & Requests
    Replies: 7
    Last Post: 03-25-2009, 12:07 PM
All times are GMT -5. The time now is 04:14 PM. 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