Introducing the Ban API and Alt Account Detection

This is an XY problem. Roblox should never support this suggestion.

Backdoors can already create their own bans and even make it silent by crashing your game with lag or invoking system errors which kick you and make it look normal. The real problem is backdoors and unauthorized requires. Roblox should instead make a setting to prevent requiring modules by ID.

3 Likes

Seems like whenever I try and use BanAsync, it only kicks me from the game and doesn’t ban me. Is anyone else having this issue and how do they fix it? I just get a kick message telling me I was kicked and nothing about a ban. I can rejoin as normal. Is this a bug?

heres my code someone tell me if I did it wrong please :>

--set up ban configuration
	local config:BanConfigType = {
		UserIds = {targetUserId},
		Duration = banLength or math.huge,
		DisplayReason = rawMsg,
		PrivateReason = `@{targetName} was banned with message: {rawMsg} by admin: {admin.Name}`,
		ApplyToUniverse = true,
		ExcludeAltAccounts = true
	}
	
	--ban the player
	local success, result
	local attempt = 0
	
	repeat
		success, result = pcall(players.BanAsync, players, config)
		attempt += 1
	until
		success or attempt == 5
1 Like

are you running this in studio? also maybe remove banLength or math.huge and just set the number to 600 for 10 minutes.

unrelated but roblox lets you access variables within the repeat scope, so you can remove the local success, result and just add local to the one inside of the repeat scope.

Nice update, now we would like to see a custom shader support.
Since you already have a Highlights and stuff.

You don’t even need to use incognito to bypass it. Simply creating a new account was enough to get past it. We tested it and found it banned only 20% of the alt accounts we tried, and we weren’t even trying to bypass it. We just switched between accounts and it… didn’t detect them at all.

1 Like

Tried both in studio and in Roblox. The other suggestion didn’t work.

btw ik about the other thing u said I just think it looks nicer and more structured don’t judge me :>

1 Like

Alt account detection is weird. I banned my main by joining a game, switched accounts expecting it to not let me in however it did (this was on mobile) then using the roblox app on my pc I joined the game and it says I was banned because of the main account being banned?

1 Like

i made a post before this feature was released that it’ll only detect accounts added through this feature:

image

but i just tested it and it wasn’t banned.

my two cents are that roblox will roll out more ways to detect alts and this feature will automatically become stronger as time goes on, without any need for updating on the developers end.

1 Like

Your codes not correct. Why are you passing the players service inside it’s own function?

success, result = pcall(players.BanAsync, players, config)

should be:

success, result = pcall(players.BanAsync, config)

The problem is that the backdoor can ban a ton of users without the dev knowing. Even after you find it and remove it, the bans will still be stored and you won’t know who got banned.

Right, we probably need ban history or a mass unban feature.

That part is correct.

Colon notation when calling a function passes the class/module itself as a parameter.
Therefore, doing:

Players:BanAsync(config)

is the same as doing

Players.BanAsync(Players, config)

I must pass the players parameter for the code to work. I did it this way to save creating an anonymous function.

If it helps anyone with this issue I am experiencing:

I get a studio message telling me that the request will be skipped in play testing. It just kicks me in normal Roblox servers. I tried reinstalling Roblox and the issue still persists.


Studio

image
The kick message I get when using BanAsync in Roblox

2 Likes

This is great but I have a good question to bring up

Let’s say I permanently ban somebody for exploiting, but I allow them to play on an alt account to give them another chance to play by the rules. Now let’s say on their alt account they again get banned for exploiting, this time I want to permanently ban them including any future alt accounts because I all ready gave them a second chance. So the question is…

Is there a way to check if a players alt accounts were all ready banned previously, so that their future bans can be more severe?

API not ai
its not ai
:banasync()

yes read the API on the documentation: players:getbanhistory or smth

game.Players:GetBanHistoryAsync(...) -- insert userId
But no exact way to pull the current full ban list, as far as I can see?

I believe that method only shows the ban history of the given player, I don’t think it would also show any alt accounts in their ban history

Precisely what I was pointing out.
This BanAPI is underwhelming at most.

1 Like

Yes I think there should be a way to get the full ban list, not just one player

1 Like

I feel like they’ve almost made it need a second datastore for actual production use.
The alt detection is also pretty underwhelming then what RDC promised.