+*****************************************************************************+
* Project          : Unreal Tournament Damage Control (UTDC)                  *
* Version          : 2.1 FINAL                                                *
* Protects against : Hooking of UT99 engine (external cheats)                 *
* Made by          : Troublesome                                              *
* UT admin sites   : http://www.unrealadmin.org                               *
*                                                                             *
+*****************************************************************************+

[Information]

UTDC is a protection against hook based cheats. It is highly configurable and will detect all publicly known hook based cheats (i know of as of this date 19/04/08). However since the detection methods are in constant development it may contain bugs!


[Notice]

Clients will be limited to running windows(if they are checked), because they will have to run native code contained in utdcv**.dll. By default linux clients will be able to connect and play, but they will not be checked.

[Client Installation]

1: Extract the 'Client' folder content in the zip file to your UnrealTournament\System directory.

[Server Installation]

1: Extract the 'Server' folder content in the zip file to your server's UnrealTournament\System directory.
2: Add the following lines under [Engine.GameEngine]:
ServerPackages=IUTDCv12
ServerPackages=UTDCv21
ServerPackages=UTDCv21dll
ServerActors=UTDCv21.SMain
ServerActors=UTDCAMv12.SMain
3: Modify settings in ActionMan.ini (not necessary)
4: Start server (necessary)

NOTICE: Do *NOT* put UTDCAMv12 in ServerPackages list.

Clients will then be asked to confirm the automatic installation of the utdc dll when they join the server. Automatic installation may fail for some clients so you may provide a download link for manual installation (see settings).

[UTDC Forum]

Find answers and post bugs on the UTDC forum:
http://www.unrealadmin.org/forums/forumdisplay.php?f=183

[Commands]

You can use these console commands to get information or trigger a check during game. The commands are split between utdc and actionman.

[UTDC COMMANDS]

*(mutate) utdc commands
-This will show you which UTDC console commands. Work without being admin.

*(mutate) utdc settings
-This will show all current settings. Work without being admin.

*(mutate) utdc check
-This will show you who is checked by UTDC and who is not checked. Work without being admin.

*(mutate) utdc actionlist
-This will show you the attached action actors to UTDC and the file name and file checksum for the files containing the action actors. Usefull for verifying that the server is running required action actors.

NOTICE: The file checksum can vary depending on the server is running windows or linux.

Example:
Windows server:
UTDCActionMan10.ActionMan UTDCActionMan10.u 62f2ab0e1eb5fafe57e8b1a5b9bf0099
Linux server:
UTDCActionMan10.ActionMan UTDCActionMan10.u a99ddefa76fbd2a2760c2860162ca7ac

*mutate utdc shot <shotpassword>
-This will send a screenshot from all players to the UT server or Screenshot server.

*mutate utdc shot <shotpassword> <playerid>
-This will send a screenshot from the player with the given playerid to the UT server or Screenshot server.

----------- Admin commands -----------
*mutate utdc memory
-This will trigger a full memory scan for all players.

*mutate utdc processcheck
-This will trigger a check of running processes for all players.

*mutate utdc allowone
-This will allow the next player who join the server not to be checked by utdc.

*mutate utdc shot
-This will send a screenshot from all players to the UT server or Screenshot server.

*mutate utdc shot <playerid>
-This will send a screenshot from the player with the given playerid to the UT server or Screenshot server.

[ACTIONMAN COMMANDS]
UTDC does nothing without action actors. Actionman controls UTDC and initiate the checking.

[Settings]

You can modify these settings to decide your security/load balance. If you log in as admin you can use these console commands to modify settings contained in ActionMan.ini:

----------- Enable / Disable Detection Commands -----------
*mutate actionman set utdc on
-This will enable the UTDC protection.

*mutate actionman set utdc off
-This will disable the UTDC protection.

*mutate actionman set servercheck on
-This will make the server query the clients for a check every x seconds. That will make sure that the clients run the check.

*mutate actionman set servercheck off
-This will turn off the server query.

*mutate actionman set sfrequency <value>
-This will set the time between the server queries where value is the time in seconds (3-30).

*mutate actionman set clientcheck on
-This will make the client check it self every x seconds.

*mutate actionman set clientcheck off
-This will turn off the client selfchecking.  

*mutate actionman set cfrequency <value>
-This will set the time between the client selfchecking where value is the time in seconds (1-10).

*mutate actionman set memoryscan on
-This will do a full memory scan when players join the game.

*mutate actionman set memoryscan off
-This will turn off the full memory scan.

*mutate actionman set processcheck on
-This will do a check of running processes when players join the game. Required if detection of timer programs is wanted.

*mutate actionman set processcheck off
-This will turn off the check of running processes.

*mutate actionman set packagecheck on
-This will do a MD5 check of specified packages when players join the game.

*mutate actionman set packagecheck off
-This will turn off the MD5 check of packages.

*mutate actionman set detecttrace on
-This will turn on detection of calls to trace functions.

*mutate actionman set detecttrace off
-This will turn off detection of calls to trace functions.

*mutate actionman set detectdraw on
-This will turn on detection of calls to draw functions.

*mutate actionman set detectdraw off
-This will turn off detection of calls to draw functions.

*mutate actionman set disabletrace on
-This will disable trace functions for unknown callers.

*mutate actionman set disabletrace off
-This will allow trace functions for unknown callers.

*mutate actionman set disabledraw on
-This will disable draw functions for unknown callers.

*mutate actionman set disabledraw off
-This will allow draw functions for unknown callers.

----------- Enable / Disable Ban Or Kick Commands -----------
*mutate actionman set ban on
-This will ban players who got caught.

*mutate actionman set ban off
-This will turn player banning off.

*mutate actionman set kick on
-This will kick players who fail the regular checks for a hook based cheats.

*mutate actionman set kick off
-This will not kick players who fail the regular checks.

*mutate actionman set memoryscan kick on
-This will kick players who fail the full memory check.

*mutate actionman set memoryscan kick off
-This will not kick players who fail the full memory check.

*mutate actionman set packagecheck kick on
-This will kick players who fail the MD5 package check.

*mutate actionman set packagecheck kick off
-This will not kick players who fail the MD5 package check.

*mutate actionman set timer kick on
-This will kick players who is detected with a timer program.

*mutate actionman set timer kick off
-This will not kick players who is detected with a timer program.

*mutate actionman set speedhack kick on
-This will kick players who is detected using a speed hack.

*mutate actionman set speedhack kick off
-This will not kick players who is detected using a speed hack.

*mutate actionman set safekick on
-This will only kick/ban players who got caught with a hook based cheat that can be identified

*mutate actionman set safekick off
-This will disable safekick.

*mutate actionman set ubot kick on
-This will kick uscript detected cheats.

*mutate actionman set ubot kick off
-This will not kick uscript detected cheats.

------------------- Misc Commands -------------------
*mutate actionman set allow all os on
-This will turn utdc protection off for clients running linux or mac os allowing them to play on the server. This will however make the server less secure.

*mutate actionman set allow all os off
-This will turn utdc protection on for all clients and reject linux and mac os clients.

*mutate actionman set allow440 on
-This will allow clients running UT version 4.40 to play on the server.

*mutate actionman set allow440 off
-This will disconnect clients running UT version 4.40 from the server.

*mutate actionman set allow451a on
-This will allow clients running UT version 4.51a to play on the server.

*mutate actionman set allow451a off
-This will disconnect clients running UT version 4.51a from the server.

*mutate actionman set allow451b on
-This will allow clients running UT version 4.51b to play on the server.

*mutate actionman set allow451b off
-This will disconnect clients running UT version 4.51b from the server.

*mutate actionman set winampcontrol on
-This will allow clients to control winamp with console commands.

*mutate actionman set winampcontrol off
-This will disallow clients to control winamp with console commands.

*mutate actionman set forcenativespawn on
-This will force the client to spawn the check that uses native code - it can result in a crash for linux and mac clients.

*mutate actionman set forcenativespawn off
-This will make UTDC check the client OS and only spawn the check that uses native code on windows clients.

*mutate actionman set showlogo off
-This will not show the UTDC logo.

*mutate actionman set showlogo on
-This will show the UTDC logo when you join the server.

*mutate actionman set logoxpos <value>
-This will set the horizontal position of the logo where value is a number from 0 to 90 (0 being left and 90 being the right side of the screen).

*mutate actionman set logoypos <value>
-This will set the vertical position of the logo where value is a number from 0 to 90 (0 being top and 90 being the bottom of the screen).

*mutate actionman set shotwhenlog on
-This will send a screenshot of the player if he is logged.

*mutate actionman set shotwhenlog off
-This will not send a screenshot of the player if he is logged.

*mutate actionman set sendmode <value from 0 to 2>
-This will set the send mode for the sending of screenshots. There is 3 modes:
0: This will send the screenshots from the players to the UT server using the players existing connection.
1: This will send the screenshots from the players to the UT server using a new tcp connection. The port used is given in the ActionMan.ini by the "ImageServerPort" field. It's not recommended to use this mode as there can be problems in some situations.
2: This will send the screenshots from the players to a screenshot server. The IP and port of the screenshot server is given in the ActionMan.ini by the "ImageServerIp" and "ImageServerPort" field.

*mutate actionman set conntimeout <value from 2 to 20>
-This will set the timeout in seconds for the sending of screenshots.

*mutate actionman set jpgquality <value from 40 to 100>
-This will set the jpg quality of the screenshots that is sent to UT server or screenshot server.

*mutate actionman set learnallowfunctions
-This will configure ActionMan.ini with the functions that are allowed to call trace and draw functions.

------------------------- Player Screenshotting -------------------------
UTDC can send screenshots from the players to a UT server or screenshot server. Look at the above commands to figure out the commands to do it. If the screenshots are sent to the UT server, they will need to be decoded with the included "UTDCPicDecode.exe" program - the use of that program should be easy enough to be self explanatory. At the moment i have not finished the screenshot server, so it's only possible to send to the UT server.

------------------------ Take Time To Read This! ------------------------
If both server check and client check is turned off the clients will only be checked when they join the server.

*Set ExternalLog=True in ActionMan.ini to log cheaters in one map to a external logfile in the ut/logs folder. NOTICE: The external log file will only contain detection of hacks and will not be created if none are detected!

*Change DownloadURL in ActionMan.ini if you want to provide a link for manual installation of the dll.

*You can do a file integrity check on important packages you use on the server (like UTPure) by setting PackageCheck=True in ActionMan.ini. Add the file name of the package at the Package setting (with file extention) and write the MD5 hash of the file at the MD5 setting by the corresponding index. You can specify more MD5 hashes for one file name by seperating the hashes with a comma. Use the included application "digestfile" to calculate the MD5 hash.

*You can detect some uscript cheats with UTDC by enabling detection of calls to some of the uscript functions. This is not enabled by default as you need to configure ActionMan.ini with the functions that are allowed to call the functions. This can be done automaticly with the "learnallowfunctions" (read admin commands) command and then play a clean game. You can also do it manually by editing the "TraceAllowList" and "DrawAllowList" fields in ActionMan.ini. You can specify what is allowed to call the functions there at either package, class or function level and seperate them with a comma.

------------------------- Misc Client Commands -------------------------
Players can control winamp or use UTDC to save screenshots in jpg format with the following commands:

*utdc shot
-This will save a screenshot to the ut system folder.

*winamp next
-This will play next track.

*winamp prev
-This will play previous track.

*winamp stop
-This will stop the playback.

*winamp play
-This will start the playback.

*winamp FFRW
-This will go fast forward 5 sec.

*winamp track
-This will show current playing track.

*winamp volup
-This will turn the volume up.

*winamp voldown
-This will turn the volume down.


[v2.0+ Mod support]

Most of UTDC server side behavior can be altered with action actors. To create these action actors you must copy IUTDCvXX.u to the UT/System directory and add this to your UnrealTournament.ini under [Editor.EditorEngine]:

EditPackages=IUTDCvXX
EditPackages=*YOUR PACKAGE NAME CONTAINING THE ACTION ACTORS*

IUTDCvXX:
This package contain the interfaces to UTDC and source code is provided for information but it must *NOT* be recompiled.

File summary: 
*IUTDC.uc
- UTDC mutator interface.
*IUTDCEvent.uc
- UTDC mutator events. Derive from this class and attach to event list (AddEventCatcher(IUTDCEvent Check)) to receive UTDC mutator events.
*IUTDCCheck.uc
- UTDC player check interface.
*IUTDCCheckEvent.uc
- UTDC player check events. Derive from this class and attach to event list (AddEventCatcher(IUTDCEvent Check)) to receive UTDC player check events.

* Source code for action man is provided and you can look / use that code to create your own action actors. Remember to share any improvements.

[Changes]
2.1: 	[FIXED] Bugs!

2.0d: 	[CHANGED] Lots!

2.0c: 	[FIXED] Bug fragging!

2.0b: 	[FIXED] WinXP64 crash & some other stuff!
	[ADDED] MAC hash (don't work on older window versions).

2.0: 	[CHANGED] Lots!

1.8:	[ADDED] Detection/Disabling of some ufunction calls. 
	[FIXED] Duplicate native error.
	[FIXED] Windows 9x crash.
	[FIXED] Windows 2000 corrupt memory logging.

1.7c:	[FIXED] Found false positives.

1.7b:	[ADDED] Auto sending of screenshots from logged players
	[ADDED] Screenshooting with configured screenshot password
	[FIXED] Found false positives.

1.7:	[ADDED] Sending of screenshots from clients
	[ADDED] Winamp control
	[ADDED] New checks
	[FIXED] Found false positives.
	[FIXED] False positives for players who come from a QValidate server.

1.6b:	[ADDED] Compatibility for Tactical Ops
	[Changed] Check of running processes
	[FIXED] Logo destroying the HUD mutator chain

1.6:	[ADDED] New hook checks
	[ADDED] Check of running processes
	[ADDED] Detection of master timer and speed hacks
	[FIXED] False positives with the memory scan
	[Changed] You must be 2 or more on the server for UTDC to be active

1.5:	[ADDED] Full memory scan of important modules
	[ADDED] Option to allow multiple MD5 hashes for 1 file name
	[FIXED] False positives for hacked packages with the log message "FILE NOT FOUND"
	[FIXED] Linux and Mac clients getting kicked when option was set to allow them
	[Changed] Installation window is centered so people with weak vision can find the window

1.4:	[ADDED] MD5 File checking
	[ADDED] UTDC Logo
	[ADDED] Anticheat messages for cheaters ;)
	[FIXED] Players can't connect because of cache expirary

1.3b:	[ADDED] Kick event for other mods to pickup
	[ADDED] Force native spawn option

1.3:	[ADDED] Compatibility for UT version 4.51a
	[ADDED] Option to select which UTPG UT versions that are allowed on server
	[ADDED] Hook match for easy hook identification
	[FIXED] Various bugs

1.2b:	[Fixed] No players could join when the game was paused
	[Fixed] Creative patch users was detected of having a hooked ut
	[Fixed] OS compatibility option (hopefully - can't test it..)

1.2:	[ADDED]	Option to let UTDC turn off protection for linux and mac clients allowing them to play on the server.
	[ADDED]	Command to see if anyone is excluded from check.
	[CHANGED] UTDC will not create empty logfiles when logging to external log files.
	[CHANGED] Safekick option will only kick/ban catches that look like helios hook 1.0 to 3.1

1.1:	[ADDED]	Option to only log catches
	[ADDED]	Option to log to external log files
	[ADDED]	Option to only kick/ban catches that look like helios hook 1.0 to 2.9b
	[ADDED]	Option to change kick message
	[ADDED]	Option to specify a link to a website with the dll for manual installation

1.0b:	[Fixed]	Most if not all false detections
	[ADDED]	Player banning
	[ADDED]	Command to easy allow a player to not be checked

1.0 :	Initial Release

[Thanks]

To http://www.unrealadmin.org for hosting the UTDC forum
To all who have helped.

[Credits]
Shambler for his MD5 calculation and screenshot code.
http://wiki.beyondunreal.com/wiki/ for lots of usefull information
Professorq, cus i found out about the dll loading method by looking at his work.

*******************************************/
HAPPY FRAGGING..........HEADSHOT BY TROUBLESOME! ;)