[BUG] staging: rtl8192e: possible null-pointer dereference in rtllib_wx_set_encode()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

Our static analysis tool finds a possible null-pointer dereference in rtllib_wx.c in Linux 5.14.0-rc3:

The variable (*crypt)->ops is checked in:
342:    if (*crypt && (*crypt)->ops && strcmp((*crypt)->ops->name, "R-WEP") != 0)

This indicates that it can be NULL. If so, null-pointer dereferences will occur:
389:    (*crypt)->ops->set_key()
400:    len = (*crypt)->ops->get_key()

I am not quite sure whether this possible null-pointer dereference is real and how to fix it if it is real.
Any feedback would be appreciated, thanks!

Reported-by: TOTE Robot <oslab@xxxxxxxxxxxxxxx>

Best wishes,
Tuo Li




[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux