Bug 238641 - netmap: Remove pointer printing in netmap_mem2.c
Summary: netmap: Remove pointer printing in netmap_mem2.c
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Some People
Assignee: Vincenzo Maffione
URL:
Keywords: patch, security
Depends on:
Blocks:
 
Reported: 2019-06-17 06:25 UTC by Fuqian
Modified: 2019-09-07 20:56 UTC (History)
2 users (show)

See Also:
koobs: mfc-stable11?
koobs: mfc-stable12+


Attachments
The patch file (1.03 KB, patch)
2019-06-17 06:25 UTC, Fuqian
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Fuqian 2019-06-17 06:25:18 UTC
Created attachment 205162 [details]
The patch file

There is no need to print the address of ifp
every time when calling netmap_mem_pt_guest_ifp_del.
This will leak the address of ifp to user space.
Comment 1 Conrad Meyer freebsd_committer 2019-06-17 15:33:15 UTC
Hi Fuqian,

Before you spend much more time on this effort, FreeBSD does not use KASLR; kernel pointer disclosures are widespread in FreeBSD and generally not considered a problem.
Comment 2 commit-hook freebsd_committer 2019-07-04 21:32:50 UTC
A commit references this bug:

Author: vmaffione
Date: Thu Jul  4 21:31:50 UTC 2019
New revision: 349753
URL: https://svnweb.freebsd.org/changeset/base/349753

Log:
  netmap: Remove pointer leakage in netmap_mem2.c

  PR:		238641
  Submitted by:	Fuqian Huang <huangfq.daxian@gmail.com>
  Reviewed by:	vmaffione
  MFC after:	1 week

Changes:
  head/sys/dev/netmap/netmap_mem2.c
Comment 3 Kubilay Kocak freebsd_committer freebsd_triage 2019-07-09 02:55:14 UTC
Reopen pending MFC
Comment 4 commit-hook freebsd_committer 2019-07-11 20:15:56 UTC
A commit references this bug:

Author: vmaffione
Date: Thu Jul 11 20:15:00 UTC 2019
New revision: 349921
URL: https://svnweb.freebsd.org/changeset/base/349921

Log:
  MFC r349753

  netmap: Remove pointer leakage in netmap_mem2.c

  PR:             238641
  Submitted by:   Fuqian Huang <huangfq.daxian@gmail.com>
  Reviewed by:    vmaffione

Changes:
_U  stable/12/
  stable/12/sys/dev/netmap/netmap_mem2.c
Comment 5 Kubilay Kocak freebsd_committer freebsd_triage 2019-09-07 10:51:06 UTC
@Vincenzo Is stable/11 affected by this? If not, set mfc-stable11 to -, otherwise we'll leave this open pending that MFC
Comment 6 Conrad Meyer freebsd_committer 2019-09-07 20:56:28 UTC
stable/11 will have no more releases and this bug isn't.