feat: Add getCSOutbound & getCSInbound methods to HandshakeResult

This commit is contained in:
Emil Ivanichkov 2024-01-26 17:48:49 +02:00
parent 38f213559b
commit 26218bb08a

View File

@ -47,6 +47,14 @@ export class HandshakeResult {
constructor(private csOutbound: CipherState, private csInbound: CipherState) {} constructor(private csOutbound: CipherState, private csInbound: CipherState) {}
getCSOutbound(): CipherState {
return this.csOutbound;
}
getCSInbound(): CipherState {
return this.csInbound;
}
// Noise specification, Section 5: // Noise specification, Section 5:
// Transport messages are then encrypted and decrypted by calling EncryptWithAd() // Transport messages are then encrypted and decrypted by calling EncryptWithAd()
// and DecryptWithAd() on the relevant CipherState with zero-length associated data. // and DecryptWithAd() on the relevant CipherState with zero-length associated data.