Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adjust lobby log throttler to always show the last N logs #775

Open
ABCxFF opened this issue May 6, 2024 · 2 comments
Open

Adjust lobby log throttler to always show the last N logs #775

ABCxFF opened this issue May 6, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@ABCxFF
Copy link
Contributor

ABCxFF commented May 6, 2024

Description

If a server crashes, we should send the last N logs of the server no matter what since that usually contains the crash info.

The following is a problematic scenario that can take place with the current lobby's log throttler system:

  1. Malicious user starts attempting to attack server
  2. Connections spam and cause unexpectedly high amounts of logs printed
  3. Logs get ratelimitted
  4. Malicious user successfully crashes the server but stacktrace and final debug information is never shown due to the fact the logs are being truncated by the ratelimitter

Alternatives solutions

Solution would be to strictly save the last 50-100 logs no matter what. If the ratelimit happens to be hit, then only begin deleting logs after they get old aka only delete it's not in the last 50 lines.

Prior art

@ABCxFF ABCxFF added the enhancement New feature or request label May 6, 2024
Copy link

linear bot commented May 6, 2024

Copy link
Member

Will likely go with the last X lines no matter what.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants