Re: [PATCH v2 net-next 2/2] kcm: Check if sk_user_data already set in kcm_attach

2018-01-26 Thread Eric Dumazet
On Wed, 2018-01-24 at 12:35 -0800, Tom Herbert wrote: > This is needed to prevent sk_user_data being overwritten. > The check is done under the callback lock. This should prevent > a socket from being attached twice to a KCM mux. It also prevents > a socket from being attached for other use cases o

Re: [PATCH v2 net-next 2/2] kcm: Check if sk_user_data already set in kcm_attach

2018-01-24 Thread Eric Dumazet
On Wed, 2018-01-24 at 12:35 -0800, Tom Herbert wrote: > This is needed to prevent sk_user_data being overwritten. > The check is done under the callback lock. This should prevent > a socket from being attached twice to a KCM mux. It also prevents > a socket from being attached for other use cases o

[PATCH v2 net-next 2/2] kcm: Check if sk_user_data already set in kcm_attach

2018-01-24 Thread Tom Herbert
This is needed to prevent sk_user_data being overwritten. The check is done under the callback lock. This should prevent a socket from being attached twice to a KCM mux. It also prevents a socket from being attached for other use cases of sk_user_data as long as the other cases set sk_user_data und