Merge pull request #169 from FoxyYokai/Fix-Duey-Send-Item-Exploit #patch

Fix exploit with Duey Send Items
This commit is contained in:
Ponk
2023-04-16 08:30:05 +02:00
committed by GitHub

View File

@@ -285,6 +285,12 @@ public class DueyProcessor {
if (c.tryacquireClient()) {
try {
int fee = Trade.getFee(sendMesos);
if (sendMessage != null && sendMessage.length() > 100) {
AutobanFactory.PACKET_EDIT.alert(c.getPlayer(), c.getPlayer().getName() + " tried to packet edit with Quick Delivery on duey.");
log.warn("Chr {} tried to use duey with too long of a text", c.getPlayer().getName());
c.disconnect(true, false);
return;
}
if (!quick) {
fee += 5000;
} else if (!c.getPlayer().haveItem(ItemId.QUICK_DELIVERY_TICKET)) {