MegaAntiCheat / client-backend

GNU General Public License v3.0
79 stars 19 forks source link

Automatic Votekicks #10

Open Henrik0x7F opened 1 year ago

Henrik0x7F commented 1 year ago

In this video at 13:25 you claim that a player that is on the cheater list will be detected by the client program and it will automatically coordinate a vote kick by users of the program.

This requires:

  1. One of the clients has to start the vote
  2. Other clients have to F1 this vote

Step 1 is fairly straight forward:

Step 2 is not straight forward:

To me it looks like the promise of automatic vote kicks is not possible to be implemented. I would love to be proven wrong though. Does anyone know of alternative solutions?

megascatterbomb commented 1 year ago

The vote command takes only an "option1" or "option2" parameter for F1 or F2 respectively. You don't need an ID to do those.

You're right about everything else though, definitely worth investigating.

Henrik0x7F commented 1 year ago

The vote command takes only an "option1" or "option2" parameter for F1 or F2 respectively. You don't need an ID to do those.

What's your source on this?

megascatterbomb commented 1 year ago

The vote command takes only an "option1" or "option2" parameter for F1 or F2 respectively. You don't need an ID to do those.

What's your source on this?

https://wiki.teamfortress.com/wiki/Voting

Henrik0x7F commented 1 year ago

The TF2 wiki seems to be out of date. The page from the valve developers wiki I linked is more up to date: Vote for an option in a currently running vote. Usage: vote <vote index> <option1-5>

JoshuaVandaele commented 1 week ago

To detect a running vote, I propose multiple solutions:

Bash-09 commented 1 week ago

Coordination will happen via the masterbase, no need to abuse chat.

JoshuaVandaele commented 1 week ago

I thought that was the best option, I was worried it wouldn't be picked for resource usage reasons. If so, the Masterbase would also be able to send the vote ID, resolving both detection of a running vote and the F1'ing of said vote. 👏

JoshuaVandaele commented 1 week ago

Something I just thought about: Are we able to tell if a vote was correctly started? If not, if a vote is "tried" to be started while another vote is running and silently fails, and Masterbase tries to tell other clients to F1, we may end up votekicking someone innocent by mistake

Bash-09 commented 1 week ago

There has already been considerable thought put into this and a protocol proposed.

Iirc it goes something like:

JoshuaVandaele commented 1 week ago

Oh, I was not aware, perhaps this conversation should be cross-referenced here for future contributors to this feature to look into?

Bash-09 commented 1 week ago

The planning for this part has mostly just been done through experimentation and verbal discussion without much documentation so far. I guess you can consider these comments the documentation lol.

JoshuaVandaele commented 1 week ago

I would like to assert for future reference that multiple sources should be checked so that a malicious actor can't upload a fake "correct vote is started" to Masterbase.

And I'd also like to ask why a use a demo file instead of a screenshot? You can use console commands such as "jpeg" to take one

Bash-09 commented 1 week ago

Screenshots and OCR would be extremely unreliable and have many considerations. Demos are officially supported by the game, we already have everything implemented to pull the information out, and all we would need is to add functionality to force a demo chunk to flush (as simple as spam echo a bunch over a few seconds).

The Masterbase will also not be telling the clients that a vote was successfully started, the clients are all independently checking the demo and verifying this on their own.

JoshuaVandaele commented 1 week ago

With validation from @Bash-09, here is the diagram representing the current plan on how this should work:

votekicks drawio

Some of the actions may not end up happening: It may not be necessary for clients to report if a vote was successful or not because that might be implicit in that player being reported as disconnected or not changing.