Skip to content

Commit 8e3fbf8

Browse files
Salva Peiródavem330
Salva Peiró
authored andcommitted
hamradio/yam: fix info leak in ioctl
The yam_ioctl() code fails to initialise the cmd field of the struct yamdrv_ioctl_cfg. Add an explicit memset(0) before filling the structure to avoid the 4-byte info leak. Signed-off-by: Salva Peiró <speiro@ai2.upv.es> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent e9db5c2 commit 8e3fbf8

File tree

1 file changed

+1
-0
lines changed
  • drivers/net/hamradio

1 file changed

+1
-0
lines changed

Diff for: drivers/net/hamradio/yam.c

+1
Original file line numberDiff line numberDiff line change
@@ -1057,6 +1057,7 @@ static int yam_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
10571057
break;
10581058

10591059
case SIOCYAMGCFG:
1060+
memset(&yi, 0, sizeof(yi));
10601061
yi.cfg.mask = 0xffffffff;
10611062
yi.cfg.iobase = yp->iobase;
10621063
yi.cfg.irq = yp->irq;

0 commit comments

Comments
 (0)