lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAM_iQpUyh6BMTWAKNV3=TAQwRfj0M3TVatELvn32njSE6Y8DSg@mail.gmail.com>
Date:   Thu, 30 Apr 2020 18:09:25 -0700
From:   Cong Wang <xiyou.wangcong@...il.com>
To:     Linux Kernel Network Developers <netdev@...r.kernel.org>
Cc:     Jamal Hadi Salim <jhs@...atatu.com>, Jiri Pirko <jiri@...nulli.us>
Subject: Re: [Patch net] net_sched: fix tcm_parent in tc filter dump

On Thu, Apr 30, 2020 at 6:02 PM Cong Wang <xiyou.wangcong@...il.com> wrote:
> diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
> index 55bd1429678f..80e93c96d2b2 100644
> --- a/net/sched/cls_api.c
> +++ b/net/sched/cls_api.c
> @@ -2612,12 +2612,10 @@ static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb)
>                         return skb->len;
>
>                 parent = tcm->tcm_parent;
> -               if (!parent) {
> +               if (!parent)
>                         q = dev->qdisc;
> -                       parent = q->handle;
> -               } else {
> +               else
>                         q = qdisc_lookup(dev, TC_H_MAJ(tcm->tcm_parent));
> -               }
>                 if (!q)
>                         goto out;
>                 cops = q->ops->cl_ops;
> @@ -2633,6 +2631,7 @@ static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb)
>                 block = cops->tcf_block(q, cl, NULL);
>                 if (!block)
>                         goto out;
> +               parent = block->q->handle;

Hmm, block->q could be NULL, I think I should just use q->handle
here.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ