MCPcopy
hub / github.com/grpc/grpc-go / aes128gcm

Struct aes128gcm

credentials/alts/internal/conn/aes128gcm.go:37–44  ·  view source on GitHub ↗

aes128gcm is the struct that holds necessary information for ALTS record. The counter value is NOT included in the payload during the encryption and decryption operations.

Source from the content-addressed store, hash-verified

35// The counter value is NOT included in the payload during the encryption and
36// decryption operations.
37type aes128gcm struct {
38 // inCounter is used in ALTS record to check that incoming counters are
39 // as expected, since ALTS record guarantees that messages are unwrapped
40 // in the same order that the peer wrapped them.
41 inCounter Counter
42 outCounter Counter
43 aead cipher.AEAD
44}
45
46// NewAES128GCM creates an instance that uses aes128gcm for ALTS record.
47func NewAES128GCM(side core.Side, key []byte) (ALTSRecordCrypto, error) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected