tomoyo: Check address length before reading address family
authorTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Fri, 12 Apr 2019 10:59:36 +0000 (19:59 +0900)
committerJames Morris <jamorris@linux.microsoft.com>
Fri, 10 May 2019 21:58:25 +0000 (14:58 -0700)
commite6193f78bb689f3f424559bb45f4a091c8b314df
tree8c51acf92c910b500cd4622df6e11b949de7118b
parente80b18599a39a625bc8b2e39ba3004a62f78805a
tomoyo: Check address length before reading address family

KMSAN will complain if valid address length passed to bind()/connect()/
sendmsg() is shorter than sizeof("struct sockaddr"->sa_family) bytes.

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: James Morris <jamorris@linux.microsoft.com>
security/tomoyo/network.c