Jump to content
Magotchi

Automatically Ban Users of Invalid (Hacked) Items

Recommended Posts

Edit:

I no longer recommend this method. There are now better ways to handle users of hacked weapons in our servers. Ventho's publicvariableval.txt method (with my tweaks to it) is what I now use on US 303. However, the code below may still be useful for other purposes, such as logging or generating a blacklist.

I would have released this publicly about a month ago, but as it's sort of a gray area (some people believe admins can't ban for hacked items, while Rocket has only said players won't be global banned for hacked items), I've kept it to myself and to those that ask. I've decided to just release it, as I believe the benefit to everyone outweighs anything else. As far as my personal policies go for its usage on US 303, I have a warning immediately upon joining about not using invalid items in the server, and I unban anyone that asks, with the understanding that they won't continue to use hacked items.

Script (rename to remove the .txt):

http://callear.org/m...weapons.php.txt

It's written in PHP, so that means it requires PHP (http://windows.php.net/download/). You only need PHP; you don't need a web server.

You also need to be able to run it on the same machine as the server. Although this script could be tweaked to download the logs via FTP, it's outside the scope of my interest in it.

You'll also likely need to have some sort of reasonable log rotation. My logs rotate on every server restart. The script may work with giant log files, but I haven't tested it.

How to use it (how I do it, anyway):

Edit the top of the script to reflect the paths to your RPT log, server_console.log, and your ban file (or any text file you want it to write the ban lines to, as long as the file isn't totally empty).

Every minute, have Task Scheduler run: php -f "C:\Program Files (x86)\Steam\steamapps\common\arma 2 operation arrowhead\ban-players-hacked-weapons.php"

You'll need to adjust the paths according to how you have things set up, including possibly using the full path for PHP, unless you have its directory in the Windows PATH environment variable. The script does not have to be in the game's installation directory; I just happened to put mine there.

Use BattlEye Extended Controls or some other method to run "loadbans" every so often. I run it every minute. This just reloads the bans.txt file, actually banning newly detected players. Using BEC to do that is described at http://code.google.c...ionInstructions .

Optionally, edit the whitelist at the top of the script to your liking. I built that by looking directly at the item spawn lists in the dayz_code.pbo file (inside config.bin, after decompiling it), and then I added some other things I'd missed as I saw them show up. The way I have it set up, it bans anyone with any item or wearing any clothing that isn't in the game.

Keep in mind that since it's just reading their loadout as your server gets it from the hive server, it can't ban people that later get hacked weapons after they've joined, but if they join with hacked equipment, they'll be banned. Venthos' publicvariableval.txt method can detect weapons acquired after a player has joined.

License: You may do whatever you want with this code, as long as you have fun.

Edited by Mister_Magotchi
  • Like 8

Share this post


Link to post
Share on other sites

Stupid idea. Cuz many legit ppl will be banned. Imagne ur little bro find hacked weapon - how he may know its hacked? BOOM Banned. Battleye is piece of shit, deal with it.

Share this post


Link to post
Share on other sites

Solution- don't pick up a hacked weapon, this script should be used, as anyone stupid enough to pick one up should be punished.

Edited by rustledmyjimmies

Share this post


Link to post
Share on other sites

Nice work.

Will probably get me banned too.

But it's still an admins decision if they ban for this or not. ;)

Edited by DomiStyle

Share this post


Link to post
Share on other sites

Alhough it sounds extreme most people playing DayZ, want to play DayZ or have started to play DayZ should have informed themselves about the game in the first place. Luckily i started playing before the hacking became a problem and of course as a person who played a lot of games i know pretty well that it is important to gather information before you try to play a game or at least try to find the official homepage and get info from there.

Share this post


Link to post
Share on other sites

it looks like a great idea to me. I'm going to let the admins on my server know about it.

Share this post


Link to post
Share on other sites

The fact is a LOT of people wouldn't recognise a hacked assault rifle just by looking at it. Only the totally obvious Thermal AS-50 / G36 / PDW SD really stand out.

In my opinion only those who use scripts to spawn weapons into the game illegitimately should be punished.

When the whole purpose is Explore/Loot/Survive, punishing anyone for picking up a better gun isn't appropriate.

I'm personally not keen on taking anything I think may be hacked (I like to think I have morals, YMMV) but I won't go out of my way to learn what is NOT in the game.

Share this post


Link to post
Share on other sites

That's the reason I'm always willing to unban for these, if appealed.

Share this post


Link to post
Share on other sites

That's the reason I'm always willing to unban for these, if appealed.

I have been on the server in your signature, was banned for stealing the heli and all my friends were banned for 'duping'.

I might be off, but I'm pretty sure it was 303 Dallas :/

Share this post


Link to post
Share on other sites

I've never banned anyone for duping or for stealing a helicopter, so you must be remembering a different server.

  • Like 1

Share this post


Link to post
Share on other sites

Good stuff. There is a new anti-cheat coming out that already bans/kick for hacked weapons

Share this post


Link to post
Share on other sites

Good stuff. There is a new anti-cheat coming out that already bans/kick for hacked weapons

I hadn't heard about that. I do know about http://dayzmod.com/forum/index.php?/topic/93007-howto-use-publicvariablevaltxt-to-auto-kick-players-with-hacked-weapons/ , though. Hopefully any new solution would use a whitelist where possible rather than a blacklist.

Share this post


Link to post
Share on other sites

what if a hacker puts a hacked weapon in your back pack?

Share this post


Link to post
Share on other sites

what if a hacker puts a hacked weapon in your back pack?

Thats one reason out of the many that admins are not to ban or kick for possession,hackers do take peoples kits and switch em.it will just turn into a hacker grief tool eventually.And yes admins were told not to perform bans and kicks unless they scripted themselves.

  • Like 1

Share this post


Link to post
Share on other sites

WRONG

Sure i made my own bypass in 2 day...2 DAYS. When i tried to fight with punkbuster it takes few days more. So plz...if u never use C+ or try to make somthing....Just shut up.

Share this post


Link to post
Share on other sites

Thats one reason out of the many that admins are not to ban or kick for possession,hackers do take peoples kits and switch em.it will just turn into a hacker grief tool eventually.And yes admins were told not to perform bans and kicks unless they scripted themselves.

And SA's that allow players to use scripted in weapons are doing a bad job. Hell, you have a "Team" member here saying that it is a great idea, that should tell you something, IT'S WRONG to use them!

BE is a POS, but you shouldn't have to deal with it

Share this post


Link to post
Share on other sites

Now we just need something that detects teleportation and hands out a few more bans for that.

http://dayz-communit...ters/setpos.txt

And yes admins were told not to perform bans and kicks unless they scripted themselves.

Please show us where the DayZ dev. team said this; I don't believe they did.

Edited by Mister_Magotchi

Share this post


Link to post
Share on other sites

Imagne ur little bro find hacked weapon...

Regardless of anything else in the post, I just have to laugh at the "nefarious little bro" persona showing its head. "Little bros" getting peoples accounts banned seems to be a more rampant problem than hackers if you go by the amount of "but it wasn't my fault!" posts on the forums. Ah, hilarious.

  • Like 3

Share this post


Link to post
Share on other sites

I would prefer to kick for a selection of weapons, lets say just the AS50 Thermal and the G36 only. I would prefer to auto-kick a set number of times with warnings and then ban if they continue.

Share this post


Link to post
Share on other sites

That could be done, of course, but it would require a database to be kept of hacked item infractions by GUID, and it would require direct BattlEye RCon interaction via the script. I'm not interested in doing it, but it would probably be a worthwhile effort for those who would prefer it to instantly banning.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×