From: Kevin
Or (if I understand correctly, @Brandon knows for sure and I may have misunderstood his description on the matter) OGL/DX interception could be detected if the Virtual Tables are left with a different read/write level than originally set, or if their address size changes.
That's pretty much right. Though, powerbot doesn't use VTables or anything like that. Java can't access or modify it. The JVM takes care of that. But yeah, when you modify memory, if you don't put back the same permissions, it can either cause access violations or a user can check it and ban you. But that would only apply to native code (not Java code). So in other words, it only applies to hooking/intercepting.
For Smart and all the other crap, Benland already said a couple ways of detecting Smart.. We all know why it's detectable and how to detect it.. Powerbot and the others are different though..
For the SRL botwatch competition, I came up with a couple that I was actually testing..
1. Modify Jaclib to actually use the mouse-hook that's already in it and dormant so that it actually works. Add a keyboard hook using SetWindowsHookEx..
2. Read the title of the current applet's owner/parent. (can be spoofed easily but still viable).
3. Read the class of the owner/parent. Cannot be spoofed because you cannot spoof Window classes in Java. For example, to detect Smart and powerbot, I called GetWindowClass from JNI and it printed "SunAwtFrame".. Obviously RS doesn't run in any JFrames.. Calling it on the browser gives a class of Chrome_Win_1 and SunAwtCanvas.. Which is legit.
4. Use GetPackages from the java class to get a list of all packages and check against known packages.
5. Check running processes and perform memory scans (warden and punkbuster does this and is perfectly legal if Jagex adds it to the TOS).
6. Perform runtime integrity checks such as hash checking to check if anything has been modified.
7. Check if the window is not visible and receiving commands..
8. Check the applet's components.. Powerbot likes to add listeners and menus and a whole bunch of stuff to the applet.
Everything is EASY on WINDOWS.. I don't know linux enough to say anything about that..
IMO, since most bots are ran on Windows, they should take out the windows client base first.. JacLib.dll has so much potential seeing as barely anyone knows Assembly, C or C++ well enough to remove whatever checks they can shove in there.. They already have a mouse hook in there which is apparently not in use at all or does nothing..
Jagex can stick shared memory stuff in the client and mess with smart's communication system too.. Which would include modifying colours that smart gives to Simba from the Smart.pid files, mouse coords, everything..
For powerbot, it might be harder since they don't use anything native and they can remove a lot using injection.. so I'd say integrity checks for them or Jaclib all the way.. Jagex just needs to step it up and a lot of bots can go down easily (especially on windows). Whatever Jagex is doing right now for PB, it certainly seems to be working :l
I had an example of sticking stuff in Jaclib for my SRL botwatch draft.. Some results (skydrive):
http://1drv.ms/1cVr4KGDunno why the question marks are in the file though.. Might just be my buffer is larger than needed and it writes null chars to the file :l