Re: [PATCH 4.14] atm:idt77252: Fix a kernel address leakage in idt77252

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

 



On Thu, Apr 18, 2019 at 03:17:21PM +0800, Fuqian Huang wrote:
> From: Fuqian Huang <huangfq.daxian@xxxxxxxxx>
> 
> As there is still no hash for %p to print the address in linux 4.14,
> the address of function idt77252_init will be printed to syslog.
> Outputting kernel addresses will reveal the locations of kernel code
> and data. This case is similar to CVE-2018-7273[1].
> 
> Also, there is no need to print the address of
> function idt77252_init in idt77252_init.
> Just remove the print statement.
> 
> [1] https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-7273
> 
> Cc: <Stable@xxxxxxxxxxxxxxx> # v4.14+
> Signed-off-by: Fuqian Huang <huangfq.daxian@xxxxxxxxx>
> ---
>  drivers/atm/idt77252.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c
> index 47f3c4a..76e7736 100644
> --- a/drivers/atm/idt77252.c
> +++ b/drivers/atm/idt77252.c
> @@ -3743,8 +3743,6 @@ static int __init idt77252_init(void)
>  {
>  	struct sk_buff *skb;
> 
> -	printk("%s: at %p\n", __func__, idt77252_init);

If you look at commit ad67b74d2469 ("printk: hash addresses printed with
%p"), I think you missed about 14000 other instances you need to fix up :)

I suggest, if you really care about this issue in your 4.14-based kernel
tree, that you just backport these pointer printk patches and be done
with it.  That's too big of a change to accept into the 4.14.y LTS
kernel, but as the lifespan for 4.14.y running on a "general purpose"
system is probably only a few more months at most, I would recomment
just using 4.19.y instead as this isn't an issue at all there.

thanks,

greg k-h



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux