Re: MAC / MIC / MD for short messages
- From: tomstdenis@xxxxxxxxx
- Date: 20 May 2006 14:05:45 -0700
Michael Meier wrote:
Avoid MAC'ing small messages. It's inefficient and wastes space. Even
if you did say HMAC-SHA1-32 on 2 byte payloads you are using 200% of
the packet space to store the MAC tag.
I'd use larger packets, or if delivery is guaranteed use a MAC over
several packets. That way you may decode X packets but you will
eventually pick up on the error.
Well, yes the problem is the messages are only very short and only sent
from time to time. So they have to be short and each packet has to be
authenticated by itself. I can't wait for further packets until I know
that the first packet maybe failed authentication...
That's why I was asking if it's ok to use for a 5 Byte packet a MAC of
only e.g. 24 bit instead of 128 bit - or if this is an extremely
security problem.
If it isn't a bandwidth issue why can't you just send the entire MAC?
Keep in mind you should be MAC'ing the payload and a timestamp or
counter. Otherwise people could replay packets.
What cipher you pick depends on your platform. If you're on an 8051The microcontroller will be a 16-bit chip. I hope AES should be working
... well give up. They're useless.
with it, is it?
Would you favour CMAC to an HMAC-MD5? Could you please tell me why?
For a 16-bit processor you should get away with AES provided it has a
decent path to memory.
You could get away with truncated the MAC tag somewhat since your
messages are so short and infrequent. Smallest I would go with is a
64-bit tag. Depends on how many messages you plan on sending per key.
Tom
.
- Follow-Ups:
- Re: MAC / MIC / MD for short messages
- From: Michael Meier
- Re: MAC / MIC / MD for short messages
- References:
- MAC / MIC / MD for short messages
- From: Michael Meier
- Re: MAC / MIC / MD for short messages
- From: tomstdenis
- Re: MAC / MIC / MD for short messages
- From: Michael Meier
- MAC / MIC / MD for short messages
- Prev by Date: Re: MAC / MIC / MD for short messages
- Next by Date: Re: Compression and crypto
- Previous by thread: Re: MAC / MIC / MD for short messages
- Next by thread: Re: MAC / MIC / MD for short messages
- Index(es):
Relevant Pages
|