From db124cff82f5d869c3f0b0512a73f3969dc18fca Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 2 Apr 2026 09:23:29 +0100 Subject: [PATCH] ax(ueps): rename expectedMAC to expectedMessageAuthCode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit MAC is an abbreviation requiring context; expectedMessageAuthCode matches the established messageAuthCode pattern and is self-describing (AX ยง1). Co-Authored-By: Charon --- pkg/ueps/reader.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/ueps/reader.go b/pkg/ueps/reader.go index 18ee9ca..bba43f6 100644 --- a/pkg/ueps/reader.go +++ b/pkg/ueps/reader.go @@ -112,9 +112,9 @@ func ReadAndVerify(reader *bufio.Reader, sharedSecret []byte) (*ParsedPacket, er messageAuthCode := hmac.New(sha256.New, sharedSecret) messageAuthCode.Write(signedData.Bytes()) messageAuthCode.Write(payload) - expectedMAC := messageAuthCode.Sum(nil) + expectedMessageAuthCode := messageAuthCode.Sum(nil) - if !hmac.Equal(signature, expectedMAC) { + if !hmac.Equal(signature, expectedMessageAuthCode) { return nil, errIntegrityViolation }