From 7ad939bbe01aed2425509371be150026cdc3d412 Mon Sep 17 00:00:00 2001 From: sigonasr2 Date: Wed, 30 May 2018 22:29:16 -0500 Subject: [PATCH] Initial Commit. Setup template Window, memory retrival. --- RabiTracker/.classpath | 8 + .../New_Builder (7).launch | 13 ++ RabiTracker/.gitignore | 1 + RabiTracker/.project | 27 ++++ .../.settings/org.eclipse.jdt.core.prefs | 11 ++ RabiTracker/RabiTracker.jar | Bin 0 -> 11826 bytes RabiTracker/projectBuilder.xml | 18 +++ RabiTracker/src/RabiTracker/MemoryData.java | 151 ++++++++++++++++++ .../src/RabiTracker/MemoryManager.java | 98 ++++++++++++ RabiTracker/src/RabiTracker/Window.java | 92 +++++++++++ RabiTracker/src/sig/modules/utils/Module.java | 64 ++++++++ .../src/sig/modules/utils/MyKernel32.java | 81 ++++++++++ .../src/sig/modules/utils/MyUser32.java | 12 ++ RabiTracker/src/sig/modules/utils/Psapi.java | 57 +++++++ .../src/sig/modules/utils/PsapiTools.java | 104 ++++++++++++ 15 files changed, 737 insertions(+) create mode 100644 RabiTracker/.classpath create mode 100644 RabiTracker/.externalToolBuilders/New_Builder (7).launch create mode 100644 RabiTracker/.gitignore create mode 100644 RabiTracker/.project create mode 100644 RabiTracker/.settings/org.eclipse.jdt.core.prefs create mode 100644 RabiTracker/RabiTracker.jar create mode 100644 RabiTracker/projectBuilder.xml create mode 100644 RabiTracker/src/RabiTracker/MemoryData.java create mode 100644 RabiTracker/src/RabiTracker/MemoryManager.java create mode 100644 RabiTracker/src/RabiTracker/Window.java create mode 100644 RabiTracker/src/sig/modules/utils/Module.java create mode 100644 RabiTracker/src/sig/modules/utils/MyKernel32.java create mode 100644 RabiTracker/src/sig/modules/utils/MyUser32.java create mode 100644 RabiTracker/src/sig/modules/utils/Psapi.java create mode 100644 RabiTracker/src/sig/modules/utils/PsapiTools.java diff --git a/RabiTracker/.classpath b/RabiTracker/.classpath new file mode 100644 index 0000000..a02fbb3 --- /dev/null +++ b/RabiTracker/.classpath @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/RabiTracker/.externalToolBuilders/New_Builder (7).launch b/RabiTracker/.externalToolBuilders/New_Builder (7).launch new file mode 100644 index 0000000..2018445 --- /dev/null +++ b/RabiTracker/.externalToolBuilders/New_Builder (7).launch @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/RabiTracker/.gitignore b/RabiTracker/.gitignore new file mode 100644 index 0000000..ae3c172 --- /dev/null +++ b/RabiTracker/.gitignore @@ -0,0 +1 @@ +/bin/ diff --git a/RabiTracker/.project b/RabiTracker/.project new file mode 100644 index 0000000..404d98e --- /dev/null +++ b/RabiTracker/.project @@ -0,0 +1,27 @@ + + + RabiTracker + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.ui.externaltools.ExternalToolBuilder + full,incremental, + + + LaunchConfigHandle + <project>/.externalToolBuilders/New_Builder (7).launch + + + + + + org.eclipse.jdt.core.javanature + + diff --git a/RabiTracker/.settings/org.eclipse.jdt.core.prefs b/RabiTracker/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000..bb35fa0 --- /dev/null +++ b/RabiTracker/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,11 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.8 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.8 diff --git a/RabiTracker/RabiTracker.jar b/RabiTracker/RabiTracker.jar new file mode 100644 index 0000000000000000000000000000000000000000..304237de4fa0efd4faf957888ba718a20e04310e GIT binary patch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WNe4t9+;*X;Gu9I)uw?boS&BY_77RF!xhJO?Y^~Tg9Y|$8QOTt*| zN=EQLLX6~c11*zWWNX()>?MH>NZ*HH82X}I+*(?u?J;El^v7{k!3hV)8D43qBUU1> zce!#;2jY66tS3K3cm_N!KW*}#eDT03Tn&xZzkB~ZL|)37g8$xfQ+ui*Vz{jE4ql-0 z^2rEJ(Aj2+_G4AOdJ?WjhSE1u)+?54V>>vRNvjA|Lz;%@9a-$vGuq}=b-U$J8Qs2$ zqVWOZ>(%nAg;U%aQ*o~VLZsv-@}3H;{Pm57FK*o7=dSmVVjl*GE(I!*n}VC7!hXCQ zk-;G_A^*4h^W~iUQc%H8g@1nkN8$OG81!$~Kg&UXI{YkozO*l&|8f0I9Qu3Xf6{gS z%l%)C=e<<_Tjlw8+ke)1{_-4qss5$<{NElwb)SEgpAUNRQvIDg|Gk%g(t-Z+#C^Gu z{_gp=D)jG`|EvrBchfK9B=zF|`&0g3mFTa&{8^Xy3k&<@X8b$WA5@CJgZ(M{{R`~r zWrThQ`#l%_JIbH(5Wi5GF#a?=zh@c~p!UN&{ z8Si)Y=$~l+Bq4sG72y8~?SD}c|HS?0MfDf%(o16J|33A_J(B+k c_1oP;K^po+4gm&+^70~jNiIE6|NQm;0PYn!k^lez literal 0 HcmV?d00001 diff --git a/RabiTracker/projectBuilder.xml b/RabiTracker/projectBuilder.xml new file mode 100644 index 0000000..f354878 --- /dev/null +++ b/RabiTracker/projectBuilder.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/RabiTracker/src/RabiTracker/MemoryData.java b/RabiTracker/src/RabiTracker/MemoryData.java new file mode 100644 index 0000000..deadbe4 --- /dev/null +++ b/RabiTracker/src/RabiTracker/MemoryData.java @@ -0,0 +1,151 @@ +package RabiTracker; + +import sig.modules.RabiRibi.OffsetHelper; + +public enum MemoryData { + MONEY(0xD654CC), + PLAYTIME(0xD642D8), + HEALTHUP_START(0xD6342C), + HEALTHUP_END(0xD6342C), + ATTACKUP_START(0xD6352C), + ATTACKUP_END(0xD63628), + MANAUP_START(0xD6362C), + MANAUP_END(0xD63728), + REGENUP_START(0xD6372C), + REGENUP_END(0xD63828), + PACKUP_START(0xD6382C), + PACKUP_END(0xD63928), + /*ENTITY_ARRAY(0x0096DA3C), //Erina Data Pointer. + ERINA_HP(0x4D8), + ERINA_MAXHP(0x4E8), + ERINA_XPOS(0xC), + ERINA_YPOS(0x10), + ERINA_XSPEED(0x470), //Relative to Entity Array. + ERINA_YSPEED(0x474), //Relative to Entity Array. + MAPID(0xA600AC), + CAMERA_XPOS(0x991AF4), + CAMERA_YPOS(0xABD0A4), + //ENTITY_SIZE(0x704), + ENTITY_ID(0x4F4), + ENTITY_HP(0x4D8), + ENTITY_MAXHP(0x4E8), + ENTITY_ISACTIVE(0x674), + ENTITY_ANIMATION(0x678), + ENTITY_XPOS(0xC), + ENTITY_YPOS(0x10), + ENTITY_COLOR(0x1C), + TRANSITION_COUNTER(0xA7661C),*/ + //WARP_TRANSITION_COUNTER(0,0x582CE0+OffsetHelper.KEY_ITEM_OFFSET_V185_TO_V1851), //Detects pausing + + + + GAME_DIFFICULTY(0xD64338), + GAME_LOOP(0xD6D05C), + + HAMMER(0xD632B0), + AIR_JUMP(0xD632B4), + SLIDING_POWDER(0xD632B8), + CARROT_BOMB(0xD632BC), + HOURGLASS(0xD632C0), + SPEED_BOOST(0xD632C4), + AUTO_EARRINGS(0xD632C8), + RIBBON(0xD632CC), + SOUL_HEART(0xD632D0), + RABI_SLIPPERS(0xD632D4), + BUNNY_WHIRL(0xD632D8), + QUICK_BARETTE(0xD632DC), + BOOK_OF_CARROT(0xD632E0), + CHAOS_ROD(0xD632E4), + HAMMER_WAVE(0xD632E8), + HAMMER_ROLL(0xD632EC), + LIGHT_ORB(0xD632F0), + WATER_ORB(0xD632F4), + FIRE_ORB(0xD632F8), + NATURE_ORB(0xD632FC), + P_HAIRPIN(0xD63300), + SUNNY_BEAM(0xD63304), + PLUS_NECKLACE(0xD63308), + CYBER_FLOWER(0xD6330C), + HEALING_STAFF(0xD63310), + MAX_BRACELET(0xD63314), + EXPLODE_SHOT(0xD63318), + AIR_DASH(0xD6331C), + BUNNY_STRIKE(0xD63320), + STRANGE_BOX(0xD63324), + WALL_JUMP(0xD63328), + SPIKE_BARRIER(0xD6332C), + BUNNY_AMULET(0xD63330), + CHARGE_RING(0xD63334), + CARROT_SHOOTER(0xD63338), + SUPER_CARROT(0xD6333C), + RUMI_DONUT(0xD63340), + RUMI_CAKE(0xD63344), + GOLD_CARROT(0xD63348), + COCOA_BOMB(0xD6334C), + UNKNOWN_ITEM1(0xD63350), + TROPHY(0xD63354), + EXCLAMATION_POINT(0xD63358), + UNKNOWN_ITEM2(0xD6335C), + UNKNOWN_ITEM3(0xD63360), + UNKNOWN_ITEM4(0xD63364), + RAINBOW_MAGIC(0xD63368), + UNKNOWN_ITEM5(0xD6336C), + UNKNOWN_ITEM6(0xD63370), + UNKNOWN_ITEM7(0xD63374), + UNKNOWN_ITEM8(0xD63378), + UNKNOWN_ITEM9(0xD6337C), + UNKNOWN_ITEM10(0xD63380), + UNKNOWN_ITEM11(0xD63384), + UNKNOWN_ITEM12(0xD63388), + UNKNOWN_ITEM13(0xD6338C), + UNKNOWN_ITEM14(0xD63390), + /*DLC_ITEM1(0xD63394,0xD63394+OffsetHelper.KEY_ITEM_OFFSET_V175_TO_V1851), + DLC_ITEM2(0xD63398,0xD63398+OffsetHelper.KEY_ITEM_OFFSET_V175_TO_V1851),*/ + BUNNY_CLOVER(0xD6339C), + FAIRYS_FLUTE(0), + BUNNY_MEMORIES(0), + WIND_BLESSING(0), + DLC_ITEM4(0xD633A0), + BADGE_HEALTH_PLUS(0xD633AC), + BADGE_HEALTH_SURGE(0xD633B0), + BADGE_MANA_PLUS(0xD633B4), + BADGE_MANA_SURGE(0xD633B8), + BADGE_CRISIS_BOOST(0xD633BC), + BADGE_ATK_GROW(0xD633C0), + BADGE_DEF_GROW(0xD633C4), + BADGE_ATK_TRADE(0xD633C8), + BADGE_DEF_TRADE(0xD633CC), + BADGE_ARM_STRENGTH(0xD633D0), + BADGE_CARROT_BOOST(0xD633D4), + BADGE_WEAKEN(0xD633D8), + BADGE_SELF_DEFENSE(0xD633DC), + BADGE_ARMORED(0xD633E0), + BADGE_LUCKY_SEVEN(0xD633E4), + BADGE_HEX_CANCEL(0xD633E8), + BADGE_PURE_LOVE(0xD633EC), + BADGE_TOXIC_STRIKE(0xD633F0), + BADGE_FRAME_CANCEL(0xD633F4), + BADGE_HEALTH_WAGER(0xD633F8), + BADGE_MANA_WAGER(0xD633FC), + BADGE_STAMINA_PLUS(0xD63400), + BADGE_BLESSED(0xD63404), + BADGE_HITBOX_DOWN(0xD63408), + BADGE_CASHBACK(0xD6340C), + BADGE_SURVIVAL(0xD63410), + BADGE_TOP_FORM(0xD63414), + BADGE_TOUGH_SKIN(0xD63418), + BADGE_ERINA_BADGE(0xD6341C), + BADGE_RIBBON_BADGE(0xD63420), + BADGE_AUTO_TRIGGER(0xD63424), + BADGE_LILITHS_GIFT(0xD63428), + //13413E8 + ITEM_PERCENT(0), + MAP_PERCENT(0), + RAINBOW_EGG_COUNT(0xD65FD4), + PAUSED(0), + ; + + public MemoryData(long baseAddress) { + + } +} diff --git a/RabiTracker/src/RabiTracker/MemoryManager.java b/RabiTracker/src/RabiTracker/MemoryManager.java new file mode 100644 index 0000000..8d1ec11 --- /dev/null +++ b/RabiTracker/src/RabiTracker/MemoryManager.java @@ -0,0 +1,98 @@ +package RabiTracker; + +import java.io.File; +import java.io.IOException; +import java.net.MalformedURLException; +import java.net.URL; +import java.util.List; +import java.util.concurrent.Executors; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.TimeUnit; + +import com.sun.jna.Pointer; +import com.sun.jna.platform.win32.Kernel32; +import com.sun.jna.platform.win32.WinNT; +import com.sun.jna.platform.win32.WinNT.HANDLE; + +import sig.modules.utils.PsapiTools; + +public class MemoryManager { + final int PROCESS_PERMISSIONS = WinNT.PROCESS_QUERY_INFORMATION | WinNT.PROCESS_VM_READ; + boolean foundRabiRibi = false; + int rabiRibiPID = -1; + long rabiRibiMemOffset = 0; + public HANDLE rabiribiProcess = null; + + MemoryManager() { + CheckRabiRibiClient(); + + ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1); + scheduler.scheduleWithFixedDelay(()->{ + CheckRabiRibiClient(); + if (foundRabiRibi) { + /*myProfile.uploadProfile(); + getSessionList(); + getMessageUpdates(); + //trimeadProfile.downloadProfile(); + firstCheck=true; + if (mySession!=null) { + File file = new File(sigIRC.BASEDIR+"sigIRC/tmp.data"); + try { + org.apache.commons.io.FileUtils.copyURLToFile(new URL("http://45.33.13.215/rabirace/send.php?key=keepalivesession&session="+mySession.getID()),file); + } catch (MalformedURLException e) { + e.printStackTrace(); + } catch (IOException e) { + e.printStackTrace(); + } + }*/ + } + }, 5000, 5000, TimeUnit.MILLISECONDS); + } + + private void CheckRabiRibiClient() { + List pids; + try { + pids = PsapiTools.getInstance().enumProcesses(); + boolean found=false; + for (Integer pid : pids) { + HANDLE process = Kernel32.INSTANCE.OpenProcess(PROCESS_PERMISSIONS, true, pid); + List hModules; + try { + hModules = PsapiTools.getInstance().EnumProcessModules(process); + for(sig.modules.utils.Module m: hModules){ + //System.out.println(m.getFileName()+":"+m.getEntryPoint()); + if (m.getFileName().contains("rabiribi")) { + found=true; + if (!foundRabiRibi) { + rabiRibiMemOffset = Pointer.nativeValue(m.getLpBaseOfDll().getPointer()); + System.out.println("Found an instance of Rabi-Ribi at 0x"+Long.toHexString(rabiRibiMemOffset)+" | File:"+m.getFileName()+","+m.getBaseName()); + rabiRibiPID=pid; + foundRabiRibi=true; + rabiribiProcess=process; + break; + } + break; + } + } + if (found) { + break; + } + } catch (Exception e) { + e.printStackTrace(); + } + if (process!=null) { + Kernel32.INSTANCE.CloseHandle(process); + } + } + if (!found && foundRabiRibi) { + foundRabiRibi=false; + System.out.println("Rabi-Ribi process lost."); + } else + if (!foundRabiRibi) { + System.out.println("Failed to find Rabi-Ribi."); + } + } catch (Exception e) { + e.printStackTrace(); + } + } +} diff --git a/RabiTracker/src/RabiTracker/Window.java b/RabiTracker/src/RabiTracker/Window.java new file mode 100644 index 0000000..52e9e76 --- /dev/null +++ b/RabiTracker/src/RabiTracker/Window.java @@ -0,0 +1,92 @@ +package RabiTracker; + +import java.awt.Color; +import java.awt.Graphics; +import java.util.Calendar; +import java.util.Timer; + +import javax.swing.JFrame; +import javax.swing.JPanel; + +class DrawingPanel extends JPanel { + Window parent; + + public DrawingPanel(Window parent) { + this.parent = parent; + } + + public void paintComponent(Graphics g) { + super.paintComponent(g); + + parent.drawGUI(g); + + parent.frames++; + } +} + +public class Window extends JFrame{ + final static String WINDOW_TITLE = "Rabi Tracker v1.0"; + public static int MAX_FPS = 60; + + public static int TICK = 0; + + JFrame window = new JFrame("Rabi Tracker v1.0"); + DrawingPanel panel = new DrawingPanel(this); + + MemoryManager mem = new MemoryManager(); + + int timer = Calendar.getInstance().get(Calendar.SECOND); + public int frames = 0; + + public void setTitle(String str) { + window.setTitle(WINDOW_TITLE+" "+str); + } + + public void drawGUI(Graphics g) { + + } + + + public void display() { + window.setSize(640, 480); + window.setResizable(true); + window.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); + + panel.setSize(640, 480); + panel.setBackground(Color.MAGENTA); + + window.getContentPane().add(panel); + window.setVisible(true); + } + + private void runTick() { + Window.TICK++; + panel.repaint(); + } + + public void update() { + int new_val = Calendar.getInstance().get(Calendar.SECOND); + int current_tick = Calendar.getInstance().get(Calendar.MILLISECOND); + if (new_val!=timer) { + setTitle("- "+frames+" FPS"); + frames=0; + timer = new_val; + } + try { + runTick(); + Thread.sleep((long)(1000d/MAX_FPS)); + } catch (InterruptedException e) { + e.printStackTrace(); + } + } + + public static void main(String[] args) { + System.setProperty("sun.java2d.opengl", "True"); + + Window program = new Window(); + program.display(); + while (true) { + program.update(); + } + } +} diff --git a/RabiTracker/src/sig/modules/utils/Module.java b/RabiTracker/src/sig/modules/utils/Module.java new file mode 100644 index 0000000..87c545d --- /dev/null +++ b/RabiTracker/src/sig/modules/utils/Module.java @@ -0,0 +1,64 @@ +package sig.modules.utils; + +import sig.modules.utils.Psapi.LPMODULEINFO; +import com.sun.jna.platform.win32.WinDef.HMODULE; +import com.sun.jna.platform.win32.WinNT.HANDLE; + +public class Module { + private HANDLE hProcess; + private HMODULE hModule; + private HANDLE lpBaseOfDll = null; + private int SizeOfImage = 0; + private HANDLE EntryPoint = null; + + private PsapiTools psapi = PsapiTools.getInstance(); + + protected Module() { + } + + public Module(HANDLE hProcess, HMODULE hModule) { + this.hProcess = hProcess; + this.hModule = hModule; + } + + public HMODULE getPointer() { + return hModule; + } + + public String getFileName() { + return psapi.GetModuleFileNameExA(hProcess, hModule); + } + + public String getBaseName() { + return psapi.GetModuleBaseNameA(hProcess, hModule); + } + + private void GetModuleInformation() { + if (lpBaseOfDll == null) { + try { + LPMODULEINFO x = psapi.GetModuleInformation(hProcess, hModule); + lpBaseOfDll = x.lpBaseOfDll; + SizeOfImage = x.SizeOfImage; + EntryPoint = x.EntryPoint; + } catch (Exception e) { + e.printStackTrace(); + } + } + } + + public HANDLE getLpBaseOfDll() { + GetModuleInformation(); + return lpBaseOfDll; + } + + public int getSizeOfImage() { + GetModuleInformation(); + return SizeOfImage; + } + + public HANDLE getEntryPoint() { + GetModuleInformation(); + return EntryPoint; + } + +} diff --git a/RabiTracker/src/sig/modules/utils/MyKernel32.java b/RabiTracker/src/sig/modules/utils/MyKernel32.java new file mode 100644 index 0000000..5dcf32e --- /dev/null +++ b/RabiTracker/src/sig/modules/utils/MyKernel32.java @@ -0,0 +1,81 @@ +package sig.modules.utils; + +import com.sun.jna.Memory; +import com.sun.jna.Native; +import com.sun.jna.platform.win32.Kernel32; +import com.sun.jna.ptr.IntByReference; + +public interface MyKernel32 extends Kernel32 { + final Kernel32 INSTANCE = (Kernel32) Native.loadLibrary ("kernel32", Kernel32.class); + +// BOOL WINAPI WriteProcessMemory( +// __in HANDLE hProcess, +// __in LPVOID lpBaseAddress, +// __in LPCVOID lpBuffer, +// __in SIZE_T nSize, +// __out SIZE_T *lpNumberOfBytesWritten +// ); + boolean WriteProcessMemory(HANDLE p, int address, HANDLE buffer, int size, IntByReference written); + + +// BOOL WINAPI ReadProcessMemory( +// __in HANDLE hProcess, +// __in LPCVOID lpBaseAddress, +// __out LPVOID lpBuffer, +// __in SIZE_T nSize, +// __out SIZE_T *lpNumberOfBytesRead +// ); + boolean ReadProcessMemory(HANDLE hProcess, int inBaseAddress, Memory outputBuffer, int nSize, IntByReference outNumberOfBytesRead); + + +// HANDLE WINAPI OpenProcess( +// __in DWORD dwDesiredAccess, +// __in BOOL bInheritHandle, +// __in DWORD dwProcessId +// ); + HANDLE OpenProcess(int desired, boolean inherit, int pid); + + +// BOOL WINAPI EnumProcessModules( +// _In_ HANDLE hProcess, +// _Out_ HMODULE *lphModule, +// _In_ DWORD cb, +// _Out_ LPDWORD lpcbNeeded +// ); + boolean EnumProcessModules(HANDLE hProcess, HMODULE lphModule, int cb, int lpcbNeeded); + + +// DWORD WINAPI GetModuleFileName( +// _In_opt_ HMODULE hModule, +// _Out_ LPTSTR lpFilename, +// _In_ DWORD nSize +// ); + + int GetModuleFileName(HMODULE hModule, String lpFilename, int size); + +// DWORD WINAPI GetModuleFileNameEx( +// _In_ HANDLE hProcess, +// _In_opt_ HMODULE hModule, +// _Out_ LPTSTR lpFilename, +// _In_ DWORD nSize +// ); + + +// BOOL WINAPI GetModuleHandleEx( +// _In_ DWORD dwFlags, +// _In_opt_ LPCTSTR lpModuleName, +// _Out_ HMODULE *phModule +// ); + + int GetModuleHandleExA(int permissions, String lpFilename, HMODULE module); + +// BOOL WINAPI EnumProcesses( +// _Out_ DWORD *pProcessIds, +// _In_ DWORD cb, +// _Out_ DWORD *pBytesReturned +// ); + + boolean EnumProcesses(int[] processIds, int cb, int bytesReturned); + + int GetLastError(); +} \ No newline at end of file diff --git a/RabiTracker/src/sig/modules/utils/MyUser32.java b/RabiTracker/src/sig/modules/utils/MyUser32.java new file mode 100644 index 0000000..68c3e68 --- /dev/null +++ b/RabiTracker/src/sig/modules/utils/MyUser32.java @@ -0,0 +1,12 @@ +package sig.modules.utils; + +import com.sun.jna.Native; +import com.sun.jna.platform.win32.User32; + +public interface MyUser32 extends User32 { + final User32 INSTANCE = (User32) Native.loadLibrary ("user32", User32.class); + boolean ShowWindow(HWND hWnd, int nCmdShow); + boolean SetForegroundWindow(HWND hWnd); + HWND FindWindowA(String lpClassName, String lpWindowName); + +} diff --git a/RabiTracker/src/sig/modules/utils/Psapi.java b/RabiTracker/src/sig/modules/utils/Psapi.java new file mode 100644 index 0000000..712db65 --- /dev/null +++ b/RabiTracker/src/sig/modules/utils/Psapi.java @@ -0,0 +1,57 @@ +package sig.modules.utils; + +import java.util.Arrays; +import java.util.List; + +import com.sun.jna.Native; +import com.sun.jna.Structure; +import com.sun.jna.platform.win32.WinDef.HMODULE; +import com.sun.jna.platform.win32.WinNT.HANDLE; +import com.sun.jna.ptr.IntByReference; +import com.sun.jna.win32.StdCallLibrary; + +public interface Psapi extends StdCallLibrary{ + Psapi INSTANCE = (Psapi) Native.loadLibrary("Psapi", Psapi.class); + + /* + * http://msdn.microsoft.com/en-us/library/ms682629(VS.85).aspx + */ + boolean EnumProcesses(int[] pProcessIds, int cb, IntByReference pBytesReturned); + + + /* + * http://msdn.microsoft.com/en-us/library/ms682631(VS.85).aspx + */ + boolean EnumProcessModules(HANDLE hProcess, HMODULE[] lphModule, int cb, IntByReference lpcbNeededs); + + boolean EnumProcessModulesEx(HANDLE hProcess, HMODULE[] lphModule, int cb, IntByReference lpcbNeededs, int flags); + + + /* + * http://msdn.microsoft.com/en-us/library/ms683198(VS.85).aspx + */ + int GetModuleFileNameExA(HANDLE hProcess, HMODULE hModule, byte[] lpImageFileName, int nSize); + + int GetModuleBaseNameA(HANDLE hProcess, HMODULE hModule, byte[] lpImageFileName, int nSize); + + + /* + * http://msdn.microsoft.com/en-us/library/ms684229(VS.85).aspx + */ + public static class LPMODULEINFO extends Structure { + public HANDLE lpBaseOfDll; + public int SizeOfImage; + public HANDLE EntryPoint; + @Override + protected List getFieldOrder() { + return Arrays.asList(new String[] { "lpBaseOfDll", "SizeOfImage", "EntryPoint"}); + } +} + + /* + * http://msdn.microsoft.com/en-us/library/ms683201(VS.85).aspx + */ + boolean GetModuleInformation(HANDLE hProcess, HMODULE hModule, LPMODULEINFO lpmodinfo, int cb); + + +} diff --git a/RabiTracker/src/sig/modules/utils/PsapiTools.java b/RabiTracker/src/sig/modules/utils/PsapiTools.java new file mode 100644 index 0000000..529bb6f --- /dev/null +++ b/RabiTracker/src/sig/modules/utils/PsapiTools.java @@ -0,0 +1,104 @@ +package sig.modules.utils; + +import java.util.LinkedList; +import java.util.List; + +import sig.modules.utils.Psapi.LPMODULEINFO; +import com.sun.jna.Native; +import com.sun.jna.platform.win32.Kernel32; +import com.sun.jna.platform.win32.WinDef.HMODULE; +import com.sun.jna.platform.win32.WinNT.HANDLE; +import com.sun.jna.ptr.IntByReference; + +public class PsapiTools { + private static PsapiTools INSTANCE=null; + private static Psapi psapi = Psapi.INSTANCE; + private static Kernel32 k32 = MyKernel32.INSTANCE; + + private PsapiTools(){} + + public static PsapiTools getInstance(){ + if (INSTANCE==null) + INSTANCE=new PsapiTools(); + return INSTANCE; + } + + + public List enumProcesses() throws Exception{ + List list = new LinkedList(); + + int[] pProcessIds = new int[1024]; + IntByReference pBytesReturned = new IntByReference(); + boolean success = psapi.EnumProcesses(pProcessIds, pProcessIds.length*Integer.SIZE/8, pBytesReturned); + if (!success){ + int err=k32.GetLastError(); + throw new Exception("EnumProcesses failed. Error: "+err); + } + + int size = (pBytesReturned.getValue()/(Integer.SIZE/8)); + for (int i=0;i EnumProcessModules(HANDLE hProcess) throws Exception{ + List list = new LinkedList(); + + HMODULE[] lphModule = new HMODULE[1024]; + IntByReference lpcbNeededs= new IntByReference(); + boolean success = psapi.EnumProcessModules(hProcess, lphModule, lphModule.length, lpcbNeededs); + if (!success){ + int err=k32.GetLastError(); + if (err!=6 && err!=299 /*Generic Errors*/) { + throw new Exception("EnumProcessModules failed. Error: "+err); + } + } + for (int i = 0; i < lpcbNeededs.getValue()/4; i++) { + list.add(new Module(hProcess, lphModule[i])); + } + + return list; + } + + public List EnumProcessModulesEx(HANDLE hProcess, int flags) throws Exception{ + List list = new LinkedList(); + + HMODULE[] lphModule = new HMODULE[1024]; + IntByReference lpcbNeededs= new IntByReference(); + boolean success = psapi.EnumProcessModulesEx(hProcess, lphModule, lphModule.length, lpcbNeededs, flags); + if (!success){ + int err=k32.GetLastError(); + throw new Exception("EnumProcessModules failed. Error: "+err); + } + for (int i = 0; i < lpcbNeededs.getValue()/4; i++) { + list.add(new Module(hProcess, lphModule[i])); + } + + return list; +} + + public String GetModuleFileNameExA(HANDLE hProcess, HMODULE hModule){ + byte[] lpImageFileName= new byte[256]; + psapi.GetModuleFileNameExA(hProcess, hModule, lpImageFileName, 256); + return Native.toString(lpImageFileName); + } + + public String GetModuleBaseNameA(HANDLE hProcess, HMODULE hModule){ + byte[] lpImageFileName= new byte[256]; + psapi.GetModuleBaseNameA(hProcess, hModule, lpImageFileName, 256); + return Native.toString(lpImageFileName); +} + + public LPMODULEINFO GetModuleInformation(HANDLE hProcess, HMODULE hModule) throws Exception{ + LPMODULEINFO lpmodinfo = new LPMODULEINFO(); + + boolean success = psapi.GetModuleInformation(hProcess, hModule, lpmodinfo, lpmodinfo.size()); + if (!success){ + int err=k32.GetLastError(); + throw new Exception("GetModuleInformation failed. Error: "+err); + } + return lpmodinfo; + } + +}