Re: [PATCHv2 net] net: sched: set xt_tgchk_param par.net properly in ipt_init_target

2017-08-08 Thread Xin Long
On Tue, Aug 8, 2017 at 5:30 PM, Jiri Pirko wrote: > Tue, Aug 08, 2017 at 04:13:27AM CEST, lucien@gmail.com wrote: >>Now xt_tgchk_param par in ipt_init_target is a local varibale, >>par.net is not initialized there. Later when xt_check_target >>calls target's checkentry in

Re: [PATCHv2 net] net: sched: set xt_tgchk_param par.net properly in ipt_init_target

2017-08-07 Thread Jiri Pirko
Tue, Aug 08, 2017 at 04:13:27AM CEST, lucien@gmail.com wrote: >Now xt_tgchk_param par in ipt_init_target is a local varibale, >par.net is not initialized there. Later when xt_check_target >calls target's checkentry in which it may access par.net, it >would cause kernel panic. > >Jaroslav found

[PATCHv2 net] net: sched: set xt_tgchk_param par.net properly in ipt_init_target

2017-08-07 Thread Xin Long
Now xt_tgchk_param par in ipt_init_target is a local varibale, par.net is not initialized there. Later when xt_check_target calls target's checkentry in which it may access par.net, it would cause kernel panic. Jaroslav found this panic when running: # ip link add TestIface type dummy # tc