Results 1 to 6 of 6
  1. #1
    notquin's Avatar
    Join Date
    Sep 2018
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    8

    C# Memory Editing Library

    I needed to create a standalone memory editing library for a few upcoming libraries. I will be integrating it into my DLL injection library in the near future (proof of concept.)

    It features the following memory editing methods

    • Allocate Memory
    • Free Memory
    • Read Memory
    • Write Memory


    Note that you can read / write any datatype and structure as long as it is not a reference type (excluding strings - I have handlers for this as it is a pretty common reference type)

    It also features a pattern scanner that supports wildcard bytes and uses a pretty decent method of scanning (came up with it after a bit of testing) to ensure fast scanning.

    As per usual, the code is clean, modern and commented a lot for beginners.

    You can find the source code on my ******

    And the library is available as a NuGet package

    If you find any bugs please open an issue on my repository (I haven't heavily tested everything / written unit tests yet) and if you have any feature requests either leave a comment here or open an issue on my repository

  2. The Following 2 Users Say Thank You to notquin For This Useful Post:

    inieuwoudt1 (01-19-2019),MikeRohsoft (12-17-2018)

  3. #2
    notquin's Avatar
    Join Date
    Sep 2018
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    8
    - Updated the pattern scanning algorithm to an adaptation of the Bower-Moore algorithm to vastly increase the searching speed (From my testing anywhere from 4 - 20 times as fast depending on the size of the memory region.)

  4. #3
    lolp3's Avatar
    Join Date
    May 2016
    Gender
    male
    Posts
    9
    Reputation
    10
    Thanks
    1
    Checked the code out. Clean and a good example of basic clean coding in play too.

  5. #4
    notquin's Avatar
    Join Date
    Sep 2018
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    8
    Unit Tests finally added.

    Also implemented proper usage of SafeHandles to ensure nothing gets gc'd prematurely.

  6. #5
    notquin's Avatar
    Join Date
    Sep 2018
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    8
    Proper error handling has now been implemented! Exceptions with windows error codes will now be raised when things don't do what they should.

    A tonne of bug fixes have also been applied between the last update and now.

  7. #6
    notquin's Avatar
    Join Date
    Sep 2018
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    8
    More of a quality of life update here

    You can now pattern scan directly with a byte array if you have no need for wildcard bytes

Similar Threads

  1. x64 Memory editing library
    By mrlaee in forum C# Programming
    Replies: 4
    Last Post: 07-19-2016, 12:48 AM
  2. [Q] memory editing
    By ~dNkN! in forum C++/C Programming
    Replies: 4
    Last Post: 07-20-2010, 11:30 PM
  3. [Tutorial] Basic C++ Game Hacking (Memory Editing)
    By Tukjedude in forum C++/C Programming
    Replies: 17
    Last Post: 06-05-2010, 08:23 AM
  4. memory editing idea/help
    By ihacksumtimes in forum Combat Arms Help
    Replies: 1
    Last Post: 01-09-2010, 02:43 AM
  5. Memory editing Last chaos?
    By Darkendnox in forum General Game Hacking
    Replies: 3
    Last Post: 12-09-2006, 08:25 AM