mirror of
https://github.com/WiiLink24/wfc-server.git
synced 2026-08-24 01:24:16 -05:00
GPCM: Log profile ID from mkw_malicious_packet
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package gpcm
|
||||
|
||||
import (
|
||||
"strconv"
|
||||
"wwfc/common"
|
||||
"wwfc/logging"
|
||||
"wwfc/qr2"
|
||||
@@ -32,6 +33,21 @@ func (g *GameSpySession) handleWWFCReport(command common.GameSpyCommand) {
|
||||
|
||||
qr2.ProcessUSER(g.User.ProfileId, g.QR2IP, packet)
|
||||
break
|
||||
|
||||
case "mkw_malicious_packet":
|
||||
if g.GameName != "mariokartwii" {
|
||||
logging.Warn(g.ModuleName, "Ignoring mkw_malicious_packet from wrong game")
|
||||
continue
|
||||
}
|
||||
|
||||
profileId, err := strconv.ParseUint(value, 10, 32)
|
||||
if err != nil {
|
||||
logging.Error(g.ModuleName, "Error decoding mkw_malicious_packet:", err.Error())
|
||||
continue
|
||||
}
|
||||
|
||||
logging.Warn(g.ModuleName, "Malicious packet from", aurora.BrightCyan(strconv.FormatUint(profileId, 10)))
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user