Package net.minecraft.network.encryption
Record Class NetworkEncryptionUtils.SignatureData
java.lang.Object
java.lang.Record
net.minecraft.network.encryption.NetworkEncryptionUtils.SignatureData
- Record Components:
salt-signature-
- Enclosing class:
NetworkEncryptionUtils
public static record NetworkEncryptionUtils.SignatureData(long salt, byte[] signature)
extends Record
A record holding a signature of a data and the salt added while signing. Note that
the signature might not be actually present.
- Mappings:
Namespace Name named net/minecraft/network/encryption/NetworkEncryptionUtils$SignatureDataintermediary net/minecraft/class_3515$class_7425official axl$bnamed saltintermediary comp_739official bnamed signatureintermediary comp_740official c
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.byte[]getSalt()final inthashCode()Returns a hash code value for this object.booleanReturns whether the signature data has a signature.longsalt()Returns the value of thesaltrecord component.byte[]Returns the value of thesignaturerecord component.final StringtoString()Returns a string representation of this record class.static voidwrite(PacketByteBuf buf, NetworkEncryptionUtils.SignatureData signatureData)
-
Field Details
-
salt
private final long saltThe field for thesaltrecord component. -
signature
private final byte[] signatureThe field for thesignaturerecord component. -
NONE
The signature data for data without signatures.- Mappings:
Namespace Name Mixin selector named NONELnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;NONE:Lnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;intermediary field_39040Lnet/minecraft/class_3515$class_7425;field_39040:Lnet/minecraft/class_3515$class_7425;official aLaxl$b;a:Laxl$b;
-
-
Constructor Details
-
SignatureData
- Mappings:
Namespace Name Mixin selector named <init>Lnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;<init>(Lnet/minecraft/network/PacketByteBuf;)Vintermediary <init>Lnet/minecraft/class_3515$class_7425;<init>(Lnet/minecraft/class_2540;)Vofficial <init>Laxl$b;<init>(Lvw;)V
-
SignatureData
public SignatureData(long long2, byte[] byte2)
-
-
Method Details
-
isSignaturePresent
public boolean isSignaturePresent()Returns whether the signature data has a signature.- Returns:
- whether the signature data has a signature
- API Note:
- This does not validate the signature itself.
- Mappings:
Namespace Name Mixin selector named isSignaturePresentLnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;isSignaturePresent()Zintermediary method_43528Lnet/minecraft/class_3515$class_7425;method_43528()Zofficial aLaxl$b;a()Z
-
write
- Mappings:
Namespace Name Mixin selector named writeLnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;write(Lnet/minecraft/network/PacketByteBuf;Lnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;)Vintermediary method_43529Lnet/minecraft/class_3515$class_7425;method_43529(Lnet/minecraft/class_2540;Lnet/minecraft/class_3515$class_7425;)Vofficial aLaxl$b;a(Lvw;Laxl$b;)V
-
getSalt
public byte[] getSalt()- Mappings:
Namespace Name Mixin selector named getSaltLnet/minecraft/network/encryption/NetworkEncryptionUtils$SignatureData;getSalt()[Bintermediary method_43530Lnet/minecraft/class_3515$class_7425;method_43530()[Bofficial bLaxl$b;b()[B
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
salt
public long salt()Returns the value of thesaltrecord component.- Returns:
- the value of the
saltrecord component
-
signature
public byte[] signature()Returns the value of thesignaturerecord component.- Returns:
- the value of the
signaturerecord component
-