Fix sql injection in bug command
This commit is contained in:
@@ -49,7 +49,7 @@ public class Errors {
|
||||
for(Entry<String, Object> date : data) {
|
||||
dataText += date.getKey() + ":" + date.getValue().toString() + ";";
|
||||
}
|
||||
Core.getMySql().queryUpdate("INSERT INTO serverBugs(player, msg, data, timestamp) VALUES ((SELECT id FROM players WHERE uuid = '" + uuid.toString() + "'), '" + msg + "', '" + dataText + "', '" + System.currentTimeMillis() / 1000 + "')");
|
||||
Core.getMySql().queryUpdate("INSERT INTO serverBugs(player, msg, data, timestamp) VALUES ((SELECT id FROM players WHERE uuid = '" + uuid.toString() + "'), '" + Core.getMySql().escapeString(msg) + "', '" + dataText + "', '" + System.currentTimeMillis() / 1000 + "')");
|
||||
}
|
||||
|
||||
public static Entry<String, Object> make(String key, Object value) {
|
||||
|
||||
Reference in New Issue
Block a user