Game Blockage....

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Marshmello

    Game Blockage....

    Hey there,

    alright so I have been working on a project for awhile. I used a very easy scripting language to write a program that detected the full
    screen window class and would close the window and lock keyboard and mouse stopping the user from game play... fast forward to now I now have the scipt much more efficient.
    as of now it is still in AutoHotkey script and im hoping to port it to C++. How is works now is it checks the time and if approriate allows the games other wise it will run taskkill via command line and run a command simmilar to this "Taskkill /F /FI "Modules eq d3d9.dll" /FI "imagename ne Exception.exe" "
    this kills all programs using the directx dll d3d9.dll with the exception of exception.exe. anyways what Im trying to do is have it check the time if the time isn't between say 12:20PM TO 1:05:PM it will run the command line provided mines a bit longer with more exceptions.. but if it is between those times have it do nothing... the last part im tryin
    to do is put in this code I borrowed to make it unkillable...

    #include <windows.h>
    #include <stdio.h>

    typedef VOID ( _stdcall *RtlSetProcessI sCritical ) (
    IN BOOLEAN NewValue,
    OUT PBOOLEAN OldValue, // (optional)
    IN BOOLEAN IsWinlogon );

    BOOL EnablePriv(LPCS TR lpszPriv) // by Napalm
    {
    HANDLE hToken;
    LUID luid;
    TOKEN_PRIVILEGE S tkprivs;
    ZeroMemory(&tkp rivs, sizeof(tkprivs) );

    if(!OpenProcess Token(GetCurren tProcess(), (TOKEN_ADJUST_P RIVILEGES | TOKEN_QUERY), &hToken))
    return FALSE;

    if(!LookupPrivi legeValue(NULL, lpszPriv, &luid)){
    CloseHandle(hTo ken); return FALSE;
    }

    tkprivs.Privile geCount = 1;
    tkprivs.Privile ges[0].Luid = luid;
    tkprivs.Privile ges[0].Attributes = SE_PRIVILEGE_EN ABLED;

    BOOL bRet = AdjustTokenPriv ileges(hToken, FALSE, &tkprivs, sizeof(tkprivs) , NULL, NULL);
    CloseHandle(hTo ken);
    return bRet;
    }

    BOOL ProtectProcess( ) // by _FIL73R_
    {
    HANDLE hDLL;
    RtlSetProcessIs Critical fSetCritical;

    hDLL = LoadLibraryA("n tdll.dll");
    if ( hDLL != NULL )
    {
    EnablePriv(SE_D EBUG_NAME);
    (fSetCritical) = (RtlSetProcessI sCritical) GetProcAddress( (HINSTANCE)hDLL , "RtlSetProcessI sCritical" );
    if(!fSetCritica l) return 0;
    fSetCritical(1, 0,0);
    return 1;
    } else
    return 0;
    }

    int main (void)
    {
    ProtectProcess( );
    while(1)
    {
    // do your virus thingy
    }
    return 0;
    }

    I know im asking alot but any help would be amazing thanks in advance...
  • Gernot Frisch

    #2
    Re: Game Blockage....

    I know im asking alot but any help would be amazing thanks in advance...
    There's not a single questionmark in your long post.

    Comment

    Working...