PKA: Fix NULL pointer kfree() issue

Bug #1931584 reported by Mahantesh Salimath
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux-bluefield (Ubuntu)
Invalid
Undecided
Unassigned
Focal
Fix Released
Medium
Mahantesh Salimath

Bug Description

SRU Justification:

[Impact]
* Should not free NULL pointer. If the pointer is NULL as a result of memory allocation (kmalloc()),
  only return an error code and don't free (kfree()) a NULL pointer. Even though kfree() won't perform
  any operation if NULL is passed, this is not a good practice.

[Fix]
* Don't free NULL pointer "pka: Fix NULL pointer kfree() issue"

[Test Case]
* No change in functionality.

[Regression Potential]
* Regression can be considered very low as the pointer won't be kfree()'d only in the case of it
  being NULL. This is functionally equivalent to passing NULL pointer to kfree() as no operation will be
  performed in this case.

CVE References

Stefan Bader (smb)
Changed in linux-bluefield (Ubuntu Focal):
assignee: nobody → Mahantesh Salimath (mahantesh92)
importance: Undecided → Medium
status: New → In Progress
Changed in linux-bluefield (Ubuntu):
status: New → Invalid
Tim Gardner (timg-tpi)
Changed in linux-bluefield (Ubuntu Focal):
status: In Progress → Fix Committed
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote :

This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-focal' to 'verification-done-focal'. If the problem still exists, change the tag 'verification-needed-focal' to 'verification-failed-focal'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: verification-needed-focal
tags: added: verification-done-focal
removed: verification-needed-focal
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (28.8 KiB)

This bug was fixed in the package linux-bluefield - 5.4.0-1016.19

---------------
linux-bluefield (5.4.0-1016.19) focal; urgency=medium

  [ Ubuntu: 5.4.0-80.90 ]

  * CVE-2021-33909
    - SAUCE: seq_file: Disallow extremely large seq buffer allocations

linux-bluefield (5.4.0-1015.18) focal; urgency=medium

  * focal/linux-bluefield: 5.4.0-1015.18 -proposed tracker (LP: #1934322)

  [ Ubuntu: 5.4.0-79.88 ]

  * focal/linux: 5.4.0-79.88 -proposed tracker (LP: #1934343)
  * lxd exec fails (LP: #1934187)
    - SAUCE: Revert "proc: Check /proc/$pid/attr/ writes against file opener"

linux-bluefield (5.4.0-1014.17) focal; urgency=medium

  * focal/linux-bluefield: 5.4.0-1014.17 -proposed tracker (LP: #1932457)

  * Change CONFIG_NF_CONNTRACK to y (LP: #1932042)
    - [Config] CONFIG_NF_CONNTRACK=y

  * Enable features for supporting PXE installer (LP: #1932035)
    - [Config] enable ISO9660, bcache, and zfs support

  * PKA: Fix NULL pointer kfree() issue (LP: #1931584)
    - pka: Fix NULL pointer kfree() issue

  [ Ubuntu: 5.4.0-78.87 ]

  * focal/linux: 5.4.0-78.87 -proposed tracker (LP: #1932478)
  * Packaging resync (LP: #1786013)
    - [Packaging] resync getabis
    - [Packaging] update helper scripts
    - update dkms package versions
  * Disable hv-kvp-daemon.service on certain instance types (LP: #1932081)
    - [Packaging]: Add kernel command line condition to hv-kvp-daemon service
  * QLogic Direct-Connect host can't discover SCSI-FC or NVMe/FC devices
    (LP: #1860724)
    - scsi: qla2xxx: Serialize fc_port alloc in N2N
    - scsi: qla2xxx: Set Nport ID for N2N
    - scsi: qla2xxx: Fix point-to-point (N2N) device discovery issue
    - scsi: qla2xxx: Fix N2N and NVMe connect retry failure
  * [SRU] Add support for E810 NIC to Ice Driver in Focal (LP: #1912511)
    - ice: add additional E810 device id
  * Focal update: v5.4.124 upstream stable release (LP: #1931166)
    - ALSA: hda/realtek: Headphone volume is controlled by Front mixer
    - ALSA: usb-audio: scarlett2: Fix device hang with ehci-pci
    - ALSA: usb-audio: scarlett2: Improve driver startup messages
    - cifs: set server->cipher_type to AES-128-CCM for SMB3.0
    - NFSv4: Fix a NULL pointer dereference in pnfs_mark_matching_lsegs_return()
    - iommu/vt-d: Fix sysfs leak in alloc_iommu()
    - perf intel-pt: Fix sample instruction bytes
    - perf intel-pt: Fix transaction abort handling
    - perf scripts python: exported-sql-viewer.py: Fix copy to clipboard from Top
      Calls by elapsed Time report
    - perf scripts python: exported-sql-viewer.py: Fix Array TypeError
    - perf scripts python: exported-sql-viewer.py: Fix warning display
    - proc: Check /proc/$pid/attr/ writes against file opener
    - net: hso: fix control-request directions
    - ath10k: Validate first subframe of A-MSDU before processing the list
    - dm snapshot: properly fix a crash when an origin has no snapshots
    - drm/amdgpu/vcn1: add cancel_delayed_work_sync before power gate
    - drm/amdgpu/vcn2.0: add cancel_delayed_work_sync before power gate
    - drm/amdgpu/vcn2.5: add cancel_delayed_work_sync before power gate
    - selftests/gpio: Use TEST_GEN_PROGS_EXTENDED
    - selftests/gpi...

Changed in linux-bluefield (Ubuntu Focal):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.