-
Notifications
You must be signed in to change notification settings - Fork 175
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
Added proper SteamID2 and IP address validation to admin ban page / Switch to userid for kickid #485
Conversation
Added http/https distinction in URL where applicable
Added commits to switch to |
This will probably fix issue #474. |
Renamed the for-loop variables by @codacy-bot's recommendations. |
Fixed a bug where a SteamID2 conversion was attempted before checking for an empty string (such as for IP bans). |
web/includes/sb-callback.php
Outdated
|
||
$steam = \SteamID\SteamID::toSteam2(trim($steam)); | ||
$steam = trim($steam); | ||
if ($steam) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use empty()
function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's acts the same for strings, but alright.
Pull has been abandoned and is too far behind master. I'll resync and recreate the patch and pull request. |
Description
Replaces string length tests with regex tests
Fixes not allowing older Steam accounts with a shorter ID length
Includes alternate regex test for community IDs
Switched
kickid
to useuserid
instead of Steam ID due to command breakage for TF2 servers.Motivation and Context
How Has This Been Tested?
Tested on Linux web server
Tested on Linux TF2 game server
Types of changes
Checklist: