mirror of
https://github.com/BeamMP/BeamMP-Launcher.git
synced 2025-07-03 00:16:50 +00:00
add check for key data before post
This commit is contained in:
parent
8b650dc00a
commit
bce68eee92
@ -374,6 +374,13 @@ void CheckKey() {
|
||||
Key.read(&Buffer[0], std::streamsize(Size));
|
||||
Key.close();
|
||||
|
||||
for (char& c : Buffer) {
|
||||
if (!std::isalnum(c) && c != '-') {
|
||||
UpdateKey("");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
Buffer = HTTP::Post("https://auth.beammp.com/userlogin",
|
||||
R"({"pk":")" + Buffer + "\"}");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user