Top Description Fields Constructors Methods
org.bouncycastle.tls

public Class TlsUtils

extends Object
Class Inheritance
Imports
java.io.ByteArrayInputStream, .ByteArrayOutputStream, .EOFException, .IOException, .InputStream, .OutputStream, java.math.BigInteger, java.util.Enumeration, .Hashtable, .Vector, org.bouncycastle.asn1.ASN1Encoding, .ASN1InputStream, .ASN1Integer, .ASN1Object, .ASN1ObjectIdentifier, .ASN1Primitive, .ASN1Sequence, org.bouncycastle.asn1.bsi.BSIObjectIdentifiers, org.bouncycastle.asn1.eac.EACObjectIdentifiers, org.bouncycastle.asn1.nist.NISTObjectIdentifiers, org.bouncycastle.asn1.oiw.OIWObjectIdentifiers, org.bouncycastle.asn1.pkcs.PKCSObjectIdentifiers, .RSASSAPSSparams, org.bouncycastle.asn1.x509.X509ObjectIdentifiers, org.bouncycastle.asn1.x9.X9ObjectIdentifiers, org.bouncycastle.tls.crypto.Tls13Verifier, .TlsAgreement, .TlsCertificate, .TlsCipher, .TlsCrypto, .TlsCryptoParameters, .TlsCryptoUtils, .TlsDHConfig, .TlsECConfig, .TlsEncryptor, .TlsHash, .TlsHashOutputStream, .TlsKemConfig, .TlsSecret, .TlsStreamSigner, .TlsStreamVerifier, .TlsVerifier, org.bouncycastle.util.Arrays, .Integers, org.bouncycastle.util.encoders.Hex, org.bouncycastle.util.io.Streams

Some helper functions for the TLS API.

Field Summary

Modifier and TypeField and Description
private static final Hashtable<K, V>
private static final Vector<E>
private static byte[]
private static byte[]
public static final byte[]
public static final int[]
public static final long[]
public static final short[]
public static final String[]
pack-priv static final short
pack-priv static final short

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private static void
private static void
addCertSigAlgOID(Hashtable<K, V> h, ASN1ObjectIdentifier oid, short hashAlgorithm, short signatureAlgorithm)

public static void
public static void
addIfSupported(Vector<E> supportedGroups, TlsCrypto crypto, int namedGroup)

public static void
addIfSupported(Vector<E> supportedGroups, TlsCrypto crypto, int[] namedGroups)

pack-priv static Hashtable<K, V>
addKeyShareToClientHello(TlsClientContext clientContext, TlsClient client, Hashtable<K, V> clientExtensions)

pack-priv static Hashtable<K, V>
addKeyShareToClientHelloRetry(TlsClientContext clientContext, Hashtable<K, V> clientExtensions, int keyShareGroup)

pack-priv static void
addPreSharedKeyToClientExtensions(TlsPSK[] psks, Hashtable<K, V> clientExtensions)

pack-priv static OfferedPsks.BindersConfig
addPreSharedKeyToClientHello(TlsClientContext clientContext, TlsClient client, Hashtable<K, V> clientExtensions, int[] offeredCipherSuites)

pack-priv static OfferedPsks.BindersConfig
addPreSharedKeyToClientHelloRetry(TlsClientContext clientContext, OfferedPsks.BindersConfig clientBinders, Hashtable<K, V> clientExtensions)

public static boolean
addToSet(Vector<E> s, int i)

pack-priv static void
private static boolean
pack-priv static byte[]
calculateEndPointHash(TlsContext context, TlsCertificate certificate, byte[] enc)

pack-priv static byte[]
calculateEndPointHash(TlsContext context, TlsCertificate certificate, byte[] enc, int encOff, int encLen)

public static byte[]
calculateExporterSeed(SecurityParameters securityParameters, byte[] context)

private static byte[]
calculateFinishedHMAC(SecurityParameters securityParameters, TlsSecret baseKey, byte[] transcriptHash)

private static byte[]
calculateFinishedHMAC(int prfCryptoHashAlgorithm, int prfHashLength, TlsSecret baseKey, byte[] transcriptHash)

pack-priv static TlsSecret
calculateMasterSecret(TlsContext context, TlsSecret preMasterSecret)

pack-priv static byte[]
calculatePSKBinder(TlsCrypto crypto, boolean isExternalPSK, int pskCryptoHashAlgorithm, TlsSecret earlySecret, byte[] transcriptHash)

pack-priv static byte[]
calculateSignatureHash(TlsContext context, SignatureAndHashAlgorithm algorithm, byte[] extraSignatureInput, DigestInputBuffer buf)

pack-priv static byte[]
calculateVerifyData(TlsContext context, TlsHandshakeHash handshakeHash, boolean isServer)

private static void
checkClientCertificateType(CertificateRequest certificateRequest, short clientCertificateType, short alertDescription)

private static void
checkDowngradeMarker(byte[] randomBlock, byte[] downgradeMarker)

pack-priv static void
checkDowngradeMarker(ProtocolVersion version, byte[] randomBlock)

pack-priv static void
checkExtensionData13(Hashtable<K, V> extensions, int handshakeType, short alertDescription)

public static void
checkPeerSigAlgs(TlsContext context, TlsCertificate[] peerCertPath)

Check the signature algorithm for certificates in the peer's CertPath as specified in RFC 5246 7.4.2, 7.4.4, 7.4.6 and similar rules for earlier TLS versions.

private static void
private static void
pack-priv static void
checkTlsFeatures(Certificate serverCertificate, Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions)

public static void
checkUint16(int i)

public static void
checkUint16(long i)

public static void
checkUint24(int i)

public static void
checkUint24(long i)

public static void
checkUint32(long i)

public static void
checkUint48(long i)

public static void
checkUint64(long i)

public static void
checkUint8(short i)

public static void
checkUint8(int i)

public static void
checkUint8(long i)

public static SignatureAndHashAlgorithm
chooseSignatureAndHashAlgorithm(TlsContext context, Vector<E> sigHashAlgs, short signatureAlgorithm)

public static SignatureAndHashAlgorithm
chooseSignatureAndHashAlgorithm(ProtocolVersion negotiatedVersion, Vector<E> sigHashAlgs, short signatureAlgorithm)

public static byte[]
clone(byte[] data)

public static String[]
private static void
collectKeyShares(TlsClientContext clientContext, int[] supportedGroups, Vector<E> keyShareGroups, Hashtable<K, V> clientAgreements, Vector<E> clientShares)

pack-priv static byte[]
concat(byte[] a, byte[] b)

public static boolean
constantTimeAreEqual(int len, byte[] a, int aOff, byte[] b, int bOff)

pack-priv static boolean
contains(short[] buf, int off, int len, short value)

pack-priv static boolean
contains(int[] buf, int off, int len, int value)

pack-priv static boolean
containsAll(short[] container, short[] elements)

public static boolean
containsAnySignatureAlgorithm(Vector<E> supportedSignatureAlgorithms, short signatureAlgorithm)

public static boolean
containsNonAscii(byte[] bs)

public static boolean
pack-priv static boolean
containsNot(short[] buf, int off, int len, short value)

public static boolean
containsSignatureAlgorithm(Vector<E> supportedSignatureAlgorithms, SignatureAndHashAlgorithm signatureAlgorithm)

public static byte[]
copyOfRangeExact(byte[] original, int from, int to)

private static Hashtable<K, V>
private static Vector<E>
private static TlsHash
createHash(TlsCrypto crypto, short hashAlgorithm)

private static TlsHash
createHash(TlsCrypto crypto, SignatureAndHashAlgorithm signatureAndHashAlgorithm)

private static TlsKeyExchange
createKeyExchangeClient(TlsClient client, int keyExchange)

private static TlsKeyExchange
createKeyExchangeServer(TlsServer server, int keyExchange)

public static byte[]
decodeOpaque16(byte[] buf)

public static byte[]
decodeOpaque16(byte[] buf, int minLength)

public static byte[]
decodeOpaque8(byte[] buf)

public static byte[]
decodeOpaque8(byte[] buf, int minLength)

public static int
decodeUint16(byte[] buf)

public static int[]
public static long
decodeUint32(byte[] buf)

public static short
decodeUint8(byte[] buf)

public static short[]
pack-priv static TlsSecret
deriveSecret(SecurityParameters securityParameters, TlsSecret secret, String label, byte[] transcriptHash)

pack-priv static TlsSecret
deriveSecret(int prfCryptoHashAlgorithm, int prfHashLength, TlsSecret secret, String label, byte[] transcriptHash)

public static byte[]
encodeOpaque16(byte[] buf)

public static byte[]
encodeOpaque24(byte[] buf)

public static byte[]
encodeOpaque8(byte[] buf)

public static void
encodeSupportedSignatureAlgorithms(Vector<E> supportedSignatureAlgorithms, OutputStream output)

public static byte[]
encodeUint16(int uint)

public static byte[]
public static byte[]
public static byte[]
encodeUint24(int uint)

public static byte[]
encodeUint32(long uint)

public static byte[]
encodeUint8(short uint)

public static byte[]
public static byte[]
pack-priv static TlsCredentialedSigner
establish13ClientCredentials(TlsAuthentication clientAuthentication, CertificateRequest certificateRequest)

pack-priv static void
establish13PhaseApplication(TlsContext context, byte[] serverFinishedTranscriptHash, RecordStream recordStream)

pack-priv static void
establish13PhaseEarly(TlsContext context, byte[] clientHelloTranscriptHash, RecordStream recordStream)

pack-priv static void
establish13PhaseHandshake(TlsContext context, byte[] serverHelloTranscriptHash, RecordStream recordStream)

pack-priv static void
establish13PhaseSecrets(TlsContext context, TlsSecret pskEarlySecret, TlsSecret sharedSecret)

pack-priv static TlsCredentialedSigner
private static void
establish13TrafficSecrets(TlsContext context, byte[] transcriptHash, TlsSecret phaseSecret, String clientLabel, String serverLabel, RecordStream recordStream)

pack-priv static TlsCredentials
establishClientCredentials(TlsAuthentication clientAuthentication, CertificateRequest certificateRequest)

pack-priv static void
establishClientSigAlgs(SecurityParameters securityParameters, Hashtable<K, V> clientExtensions)

pack-priv static TlsCredentials
pack-priv static void
establishServerSigAlgs(SecurityParameters securityParameters, CertificateRequest certificateRequest)

pack-priv static DigitallySigned
private static byte[]
generate13CertificateVerify(TlsCrypto crypto, TlsCredentialedSigner credentialedSigner, String contextString, TlsHandshakeHash handshakeHash, SignatureAndHashAlgorithm signatureAndHashAlgorithm)

pack-priv static DigitallySigned
generateCertificateVerifyClient(TlsClientContext clientContext, TlsCredentialedSigner clientAuthSigner, SignatureAndHashAlgorithm clientAuthAlgorithm, TlsStreamSigner clientAuthStreamSigner, TlsHandshakeHash handshakeHash)

public static TlsSecret
generateEncryptedPreMasterSecret(TlsContext context, TlsEncryptor encryptor, OutputStream output)

Generate a pre_master_secret and send it encrypted to the server.

pack-priv static void
generateServerKeyExchangeSignature(TlsContext context, TlsCredentialedSigner credentials, byte[] extraSignatureInput, DigestInputBuffer digestBuffer)

private static byte[]
pack-priv static SignatureAndHashAlgorithm
public static int
getCipherType(int cipherSuite)

public static int
getCommonCipherSuite13(ProtocolVersion negotiatedVersion, int[] peerCipherSuites, int[] localCipherSuites, boolean useLocalOrder)

public static int[]
getCommonCipherSuites(int[] peerCipherSuites, int[] localCipherSuites, boolean useLocalOrder)

pack-priv static byte[]
public static Vector<E>
public static Vector<E>
public static Vector<E>
public static SignatureAndHashAlgorithm
getDefaultSignatureAlgorithm(short signatureAlgorithm)

public static Vector<E>
getDefaultSignatureAlgorithms(short signatureAlgorithm)

public static Vector<E>
public static int
getEncryptionAlgorithm(int cipherSuite)

public static int
getEncryptionAlgorithmType(int encryptionAlgorithm)

public static byte[]
getExtensionData(Hashtable<K, V> extensions, Integer extensionType)

public static int
getKeyExchangeAlgorithm(int cipherSuite)

public static Vector<E>
getKeyExchangeAlgorithms(int[] cipherSuites)

public static short
getLegacyClientCertType(short signatureAlgorithm)

public static short
getLegacySignatureAlgorithmClient(short clientCertificateType)

public static short
getLegacySignatureAlgorithmClientCert(short clientCertificateType)

public static short
getLegacySignatureAlgorithmServer(int keyExchangeAlgorithm)

public static short
getLegacySignatureAlgorithmServerCert(int keyExchangeAlgorithm)

public static Vector<E>
public static int
getMACAlgorithm(int cipherSuite)

public static ProtocolVersion
getMinimumVersion(int cipherSuite)

public static Vector<E>
getNamedGroupRoles(int[] cipherSuites)

public static Vector<E>
getNamedGroupRoles(Vector<E> keyExchangeAlgorithms)

public static ASN1ObjectIdentifier
getOIDForHashAlgorithm(short hashAlgorithm)

pack-priv static int
getPRFAlgorithm(SecurityParameters securityParameters, int cipherSuite)

pack-priv static int
getPRFAlgorithm13(int cipherSuite)

pack-priv static int[]
getPRFAlgorithms13(int[] cipherSuites)

pack-priv static TlsSecret
pack-priv static TlsSecret[]
pack-priv static TlsPSKExternal[]
getPSKExternalsClient(TlsClient client, int[] offeredCipherSuites)

pack-priv static Vector<E>
getPSKIndices(TlsPSK[] psks, int prfAlgorithm)

pack-priv static byte[]
pack-priv static TlsSecret
public static SignatureAndHashAlgorithm
getSignatureAndHashAlgorithm(TlsContext context, TlsCredentialedSigner signerCredentials)

Deprecated Will be removed
pack-priv static SignatureAndHashAlgorithm
public static int[]
getSupportedCipherSuites(TlsCrypto crypto, int[] suites)

public static int[]
getSupportedCipherSuites(TlsCrypto crypto, int[] suites, int suitesCount)

public static int[]
getSupportedCipherSuites(TlsCrypto crypto, int[] suites, int suitesOff, int suitesCount)

public static Vector<E>
public static Vector<E>
pack-priv static boolean
public static boolean
hasExpectedEmptyExtensionData(Hashtable<K, V> extensions, Integer extensionType, short alertDescription)

public static boolean
hasSigningCapability(short clientCertificateType)

public static TlsSession
importSession(byte[] sessionID, SessionParameters sessionParameters)

pack-priv static TlsCipher
pack-priv static TlsKeyExchange
pack-priv static TlsKeyExchange
public static boolean
isAEADCipherSuite(int cipherSuite)

public static boolean
isBlockCipherSuite(int cipherSuite)

pack-priv static boolean
pack-priv static boolean
public static boolean
public static boolean
isNullOrEmpty(byte[] array)

public static boolean
isNullOrEmpty(short[] array)

public static boolean
isNullOrEmpty(int[] array)

public static boolean
public static boolean
public static boolean
pack-priv static boolean
isPermittedExtensionType13(int handshakeType, int extensionType)

private static boolean
public static boolean
public static boolean
isSSL(TlsContext context)

public static boolean
isStreamCipherSuite(int cipherSuite)

public static boolean
isSupportedCipherSuite(TlsCrypto crypto, int cipherSuite)

public static boolean
isSupportedKeyExchange(TlsCrypto crypto, int keyExchangeAlgorithm)

public static boolean
public static boolean
public static boolean
public static boolean
public static boolean
public static boolean
public static boolean
public static boolean
public static boolean

Returns:

Whether a server can select the specified cipher suite given the available signature algorithms for ServerKeyExchange.
isValidCipherSuiteForSignatureAlgorithms
(int cipherSuite, Vector<E> sigAlgs)

public static boolean
pack-priv static boolean
isValidCipherSuiteSelection(int[] offeredCipherSuites, int cipherSuite)

pack-priv static boolean
isValidKeyShareSelection(ProtocolVersion negotiatedVersion, int[] clientSupportedGroups, Hashtable<K, V> clientAgreements, int keyShareGroup)

pack-priv static boolean
isValidSignatureAlgorithmForServerKeyExchange(short signatureAlgorithm, int keyExchangeAlgorithm)

public static boolean
isValidSignatureSchemeForServerKeyExchange(int signatureScheme, int keyExchangeAlgorithm)

public static boolean
public static boolean
isValidUint16(long i)

public static boolean
public static boolean
isValidUint24(long i)

public static boolean
isValidUint32(long i)

public static boolean
isValidUint48(long i)

public static boolean
isValidUint64(long i)

public static boolean
isValidUint8(short i)

public static boolean
isValidUint8(int i)

public static boolean
isValidUint8(long i)

public static boolean
pack-priv static void
negotiatedCipherSuite(SecurityParameters securityParameters, int cipherSuite)

pack-priv static void
pack-priv static void
pack-priv static void
pack-priv static void
pack-priv static void
pack-priv static CertificateRequest
normalizeCertificateRequest(CertificateRequest certificateRequest, short[] validClientCertificateTypes)

public static Vector<E>
public static TlsSecret
PRF(SecurityParameters securityParameters, TlsSecret secret, String asciiLabel, byte[] seed, int length)

public static TlsSecret
PRF(TlsContext context, TlsSecret secret, String asciiLabel, byte[] seed, int length)

pack-priv static void
processClientCertificate(TlsServerContext serverContext, Certificate clientCertificate, TlsKeyExchange keyExchange, TlsServer server)

pack-priv static short
processClientCertificateTypeExtension(Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions, short alertDescription)

pack-priv static short
processClientCertificateTypeExtension13(Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions, short alertDescription)

pack-priv static short
processMaxFragmentLengthExtension(Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions, short alertDescription)

pack-priv static void
processServerCertificate(TlsClientContext clientContext, CertificateStatus serverCertificateStatus, TlsKeyExchange keyExchange, TlsAuthentication clientAuthentication, Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions)

pack-priv static short
processServerCertificateTypeExtension(Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions, short alertDescription)

pack-priv static short
processServerCertificateTypeExtension13(Hashtable<K, V> clientExtensions, Hashtable<K, V> serverExtensions, short alertDescription)

public static byte[]
readAllOrNothing(int length, InputStream input)

public static ASN1Primitive
readASN1Object(byte[] encoding)

public static ASN1Primitive
readDERObject(byte[] encoding)

Deprecated Will be removed. Use readASN1Object in combination with requireDEREncoding instead
pack-priv static byte[]
public static byte[]
readFully(int length, InputStream input)

public static void
readFully(byte[] buf, InputStream input)

public static int
readInt32(byte[] buf, int offset)

public static byte[]
public static byte[]
readOpaque16(InputStream input, int minLength)

public static byte[]
public static byte[]
readOpaque24(InputStream input, int minLength)

public static byte[]
public static byte[]
readOpaque8(InputStream input, int minLength)

public static byte[]
readOpaque8(InputStream input, int minLength, int maxLength)

public static int
public static int
readUint16(byte[] buf, int offset)

public static int[]
readUint16Array(int count, InputStream input)

public static int
public static int
readUint24(byte[] buf, int offset)

public static long
public static long
readUint32(byte[] buf, int offset)

public static long
public static long
readUint48(byte[] buf, int offset)

public static short
public static short
readUint8(byte[] buf, int offset)

public static short[]
readUint8Array(int count, InputStream input)

public static short[]
public static ProtocolVersion
readVersion(byte[] buf, int offset)

public static ProtocolVersion
pack-priv static TlsAuthentication
receive13ServerCertificate(TlsClientContext clientContext, TlsClient client, ByteArrayInputStream buf, Hashtable<K, V> serverExtensions)

pack-priv static TlsAuthentication
receiveServerCertificate(TlsClientContext clientContext, TlsClient client, ByteArrayInputStream buf, Hashtable<K, V> serverExtensions)

pack-priv static TlsCredentialedAgreement
pack-priv static TlsCredentialedDecryptor
public static void
requireDEREncoding(ASN1Object asn1, byte[] encoding)

pack-priv static TlsCredentialedSigner
pack-priv static short[]
retainAll(short[] retainer, short[] elements)

pack-priv static KeyShareEntry
selectKeyShare(Vector<E> clientShares, int keyShareGroup)

pack-priv static KeyShareEntry
selectKeyShare(TlsCrypto crypto, ProtocolVersion negotiatedVersion, Vector<E> clientShares, int[] clientSupportedGroups, int[] serverSupportedGroups)

pack-priv static int
selectKeyShareGroup(TlsCrypto crypto, ProtocolVersion negotiatedVersion, int[] clientSupportedGroups, int[] serverSupportedGroups)

pack-priv static OfferedPsks.SelectedConfig
selectPreSharedKey(TlsServerContext serverContext, TlsServer server, Hashtable<K, V> clientHelloExtensions, HandshakeMessageInput clientHelloMessage, TlsHandshakeHash handshakeHash, boolean afterHelloRetryRequest)

pack-priv static void
sendSignatureInput(TlsContext context, byte[] extraSignatureInput, DigestInputBuffer buf, OutputStream output)

pack-priv static TlsAuthentication
pack-priv static void
trackHashAlgorithmClient(TlsHandshakeHash handshakeHash, SignatureAndHashAlgorithm signatureAndHashAlgorithm)

pack-priv static void
trackHashAlgorithms(TlsHandshakeHash handshakeHash, Vector<E> supportedSignatureAlgorithms)

pack-priv static short[]
truncate(short[] a, int n)

pack-priv static int[]
truncate(int[] a, int n)

private static void
update13TrafficSecret(TlsContext context, boolean forServer)

private static TlsSecret
pack-priv static void
pack-priv static void
pack-priv static TlsCredentialedSigner
pack-priv static CertificateRequest
private static short
validateCertificateType13(short certificateType, short alertDescription)

pack-priv static TlsCredentials
public static Vector<E>
private static void
verify13CertificateVerify(Vector<E> supportedAlgorithms, String contextString, TlsHandshakeHash handshakeHash, TlsCertificate certificate, CertificateVerify certificateVerify)

pack-priv static void
pack-priv static void
pack-priv static void
verifyCertificateVerifyClient(TlsServerContext serverContext, CertificateRequest certificateRequest, DigitallySigned certificateVerify, TlsHandshakeHash handshakeHash)

pack-priv static void
verifyServerKeyExchangeSignature(TlsContext context, InputStream signatureInput, TlsCertificate serverCertificate, byte[] extraSignatureInput, DigestInputBuffer digestBuffer)

public static void
verifySupportedSignatureAlgorithm(Vector<E> supportedSignatureAlgorithms, SignatureAndHashAlgorithm signatureAlgorithm)

pack-priv static void
verifySupportedSignatureAlgorithm(Vector<E> supportedSignatureAlgorithms, SignatureAndHashAlgorithm signatureAlgorithm, short alertDescription)

pack-priv static void
writeDowngradeMarker(ProtocolVersion version, byte[] randomBlock)

pack-priv static void
writeEncryptedPMS(TlsContext context, byte[] encryptedPMS, OutputStream output)

public static void
writeGMTUnixTime(byte[] buf, int offset)

public static void
writeOpaque16(byte[] buf, OutputStream output)

public static void
writeOpaque16(byte[] data, byte[] buf, int off)

public static void
writeOpaque24(byte[] buf, OutputStream output)

public static void
writeOpaque24(byte[] data, byte[] buf, int off)

public static void
writeOpaque8(byte[] buf, OutputStream output)

public static void
writeOpaque8(byte[] data, byte[] buf, int off)

public static void
writeUint16(int i, OutputStream output)

public static void
writeUint16(int i, byte[] buf, int offset)

public static void
writeUint16Array(int[] uints, OutputStream output)

public static void
writeUint16Array(int[] uints, byte[] buf, int offset)

public static void
public static void
writeUint16ArrayWithUint16Length(int[] uints, byte[] buf, int offset)

public static void
writeUint16ArrayWithUint8Length(int[] uints, byte[] buf, int offset)

public static void
writeUint24(int i, OutputStream output)

public static void
writeUint24(int i, byte[] buf, int offset)

public static void
writeUint32(long i, OutputStream output)

public static void
writeUint32(long i, byte[] buf, int offset)

public static void
writeUint48(long i, OutputStream output)

public static void
writeUint48(long i, byte[] buf, int offset)

public static void
writeUint64(long i, OutputStream output)

public static void
writeUint64(long i, byte[] buf, int offset)

public static void
writeUint8(short i, OutputStream output)

public static void
writeUint8(int i, OutputStream output)

public static void
writeUint8(short i, byte[] buf, int offset)

public static void
writeUint8(int i, byte[] buf, int offset)

public static void
writeUint8Array(short[] uints, OutputStream output)

public static void
writeUint8Array(short[] uints, byte[] buf, int offset)

public static void
public static void
writeUint8ArrayWithUint8Length(short[] uints, byte[] buf, int offset)

public static void
public static void
writeVersion(ProtocolVersion version, byte[] buf, int offset)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait