diff --git a/build.gradle b/build.gradle
index 8a16054d7..11177e658 100644
--- a/build.gradle
+++ b/build.gradle
@@ -63,8 +63,7 @@ dependencies {
compileOnly "com.google.guava:guava:33.7.2-jre"
compileOnly "io.netty:netty-handler:4.2.19.Final"
compileOnly "com.google.code.gson:gson:2.15.0"
- compileOnly "org.cloudburstmc.netty:netty-transport-raknet:2.0.0.CR4-20260921.144528-1"
- compileOnly "org.cloudburstmc.netty:netty-transport-nethernet:2.0.0.CR4-20260921.144528-1"
+ compileOnly "org.cloudburstmc.netty:netty-transport-nethernet:2.0.0.CR6-20261030.131938-23"
api("io.netty:netty-codec-http:4.2.19.Final") {
transitive = false
diff --git a/src/main/java/net/raphimc/viabedrock/netty/raknet/AesEncryptionCodec.java b/src/main/java/net/raphimc/viabedrock/netty/raknet/AesEncryptionCodec.java
deleted file mode 100644
index 2b486d548..000000000
--- a/src/main/java/net/raphimc/viabedrock/netty/raknet/AesEncryptionCodec.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * This file is part of ViaBedrock - https://github.com/RaphiMC/ViaBedrock
- * Copyright (C) 2023-2026 RK_01/RaphiMC and contributors
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-package net.raphimc.viabedrock.netty.raknet;
-
-import com.google.common.primitives.Longs;
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.ByteBufUtil;
-import io.netty.channel.ChannelHandlerContext;
-import io.netty.handler.codec.ByteToMessageCodec;
-import io.netty.handler.codec.CorruptedFrameException;
-
-import javax.crypto.Cipher;
-import javax.crypto.NoSuchPaddingException;
-import javax.crypto.SecretKey;
-import javax.crypto.spec.IvParameterSpec;
-import java.nio.ByteBuffer;
-import java.security.InvalidAlgorithmParameterException;
-import java.security.InvalidKeyException;
-import java.security.MessageDigest;
-import java.security.NoSuchAlgorithmException;
-import java.util.Arrays;
-import java.util.List;
-
-public class AesEncryptionCodec extends ByteToMessageCodec {
-
- private final SecretKey secretKey;
- private final Cipher inCipher;
- private final Cipher outCipher;
- private final MessageDigest sha256;
- private long sentPacketCounter;
- private long receivedPacketCounter;
-
- public AesEncryptionCodec(final SecretKey secretKey) throws NoSuchPaddingException, NoSuchAlgorithmException, InvalidAlgorithmParameterException, InvalidKeyException {
- final byte[] iv = new byte[16];
- System.arraycopy(secretKey.getEncoded(), 0, iv, 0, 12);
- iv[15] = 2;
-
- this.secretKey = secretKey;
- this.inCipher = Cipher.getInstance("AES/CTR/NoPadding");
- this.inCipher.init(Cipher.DECRYPT_MODE, secretKey, new IvParameterSpec(iv));
- this.outCipher = Cipher.getInstance("AES/CTR/NoPadding");
- this.outCipher.init(Cipher.ENCRYPT_MODE, secretKey, new IvParameterSpec(iv));
- this.sha256 = MessageDigest.getInstance("SHA-256");
- }
-
- @Override
- protected void encode(final ChannelHandlerContext ctx, final ByteBuf in, final ByteBuf out) throws Exception {
- final byte[] hash = this.generateHash(in, this.sentPacketCounter++);
-
- final ByteBuffer inBuffer = in.nioBuffer();
- out.ensureWritable(in.readableBytes() + 8);
-
- this.outCipher.update(inBuffer, out.nioBuffer(0, in.readableBytes()));
- this.outCipher.update(ByteBuffer.wrap(hash), out.nioBuffer(in.readableBytes(), 8));
- out.writerIndex(in.readableBytes() + 8);
- }
-
- @Override
- protected void decode(final ChannelHandlerContext ctx, final ByteBuf in, final List