Is the tag in a MAC scheme a fixed size? I've been reading up on MAC schemes. But I cannot seem to find out whether the tag's that are output by running MAC(m) is of a fixed size?
I can find a lot of stuff talking about the tag space being a specific size, which would indicate that the tag must have a specific length, but I could not find whether there are any rules for it.
A MAC is a type of function, that returns an authenticator given a message and a secret.
The output length is a property of a function, not a constant for all MACs.
With constructions such as HMAC, the output length is directly dependent on the underlying hash function. Other constructions such as KMAC can produce an arbitrary long output.
And no matter what the output size is, an application can always truncate it if needed.
Of course, the shorter the MAC is, the less secure it becomes. If a MAC is used in an online protocol, and an adversary has very limited time and allowed attempts, forgery may not be practical even with a short MAC. If offline attacks are practical, you’d better size the MAC for 128 bit security. The maximum length of a message also plays a role. The shorter the messages are, the more difficult forgery is.
So, there’s no fixed size for MACs. It depends on the actual functions and in what context they are used.