From: Antonio Quartulli <ordex@autistici.org>
To: The list for a Better Approach To Mobile Ad-hoc Networking
<b.a.t.m.a.n@lists.open-mesh.org>
Subject: Re: [B.A.T.M.A.N.] [PATCH] batman-adv: Do not add multicast MAC addresses to translation table
Date: Wed, 17 Oct 2012 15:36:40 +0200 [thread overview]
Message-ID: <20121017133640.GR7023@ritirata.org> (raw)
In-Reply-To: <1350479255-904-1-git-send-email-linus.luessing@web.de>
[-- Attachment #1: Type: text/plain, Size: 1293 bytes --]
On Wed, Oct 17, 2012 at 03:07:35PM +0200, Linus Lüssing wrote:
> The current translation table mechanism is not suitable for multicast
> addresses and we are currently flooding such frames anyway.
>
> Therefore this patch prevents multicast MAC addresses being added to the
> translation table.
>
> Signed-off-by: Linus Lüssing <linus.luessing@web.de>
> ---
> soft-interface.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/soft-interface.c b/soft-interface.c
> index 2d1f895..9955319 100644
> --- a/soft-interface.c
> +++ b/soft-interface.c
> @@ -180,7 +180,8 @@ static int batadv_interface_tx(struct sk_buff *skb,
> goto dropped;
>
> /* Register the client MAC in the transtable */
> - batadv_tt_local_add(soft_iface, ethhdr->h_source, skb->skb_iif);
> + if (!is_multicast_ether_addr(ethhdr->h_source))
> + batadv_tt_local_add(soft_iface, ethhdr->h_source, skb->skb_iif);
How can the source address be multicast? Usually multicast addresses are found
in the destination field...
Is there any scenario where this is possible? I am wondering whether we should
directly drop packet having mcast address as source..
Cheers,
--
Antonio Quartulli
..each of us alone is worth nothing..
Ernesto "Che" Guevara
[-- Attachment #2: Type: application/pgp-signature, Size: 198 bytes --]
next prev parent reply other threads:[~2012-10-17 13:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-17 13:07 [B.A.T.M.A.N.] [PATCH] batman-adv: Do not add multicast MAC addresses to translation table Linus Lüssing
2012-10-17 13:36 ` Antonio Quartulli [this message]
2012-10-17 18:43 ` "Linus Lüssing"
2012-10-17 18:48 ` Antonio Quartulli
2012-11-13 10:04 ` Marek Lindner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20121017133640.GR7023@ritirata.org \
--to=ordex@autistici.org \
--cc=b.a.t.m.a.n@lists.open-mesh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox