Linux-HyperV Archive on lore.kernel.org
 help / color / Atom feed
From: Stephen Hemminger <sthemmin@microsoft.com>
To: Andres Beltran <lkmlabelt@gmail.com>
Cc: KY Srinivasan <kys@microsoft.com>,
	Haiyang Zhang <haiyangz@microsoft.com>,
	Wei Liu <wei.liu@kernel.org>,
	"linux-hyperv@vger.kernel.org" <linux-hyperv@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Michael Kelley <mikelley@microsoft.com>,
	Andrea Parri <parri.andrea@gmail.com>,
	Saruhan Karademir <skarade@microsoft.com>
Subject: RE: [PATCH] hv_utils: Add validation for untrusted Hyper-V values
Date: Wed, 29 Jul 2020 16:22:18 +0000
Message-ID: <BN6PR21MB083600994098D204DF141AB3CC700@BN6PR21MB0836.namprd21.prod.outlook.com> (raw)
In-Reply-To: <CAGpZZ6un6VT2ZVje0tVXbZkvH_HH+pn2Du6WPa5qeJDOz7rUmg@mail.gmail.com>

Ok at least use the ratelimit form of kernel logging.

Netdev_err_ratelimited...

-----Original Message-----
From: Andres Beltran <lkmlabelt@gmail.com> 
Sent: Wednesday, July 29, 2020 9:10 AM
To: Stephen Hemminger <sthemmin@microsoft.com>
Cc: KY Srinivasan <kys@microsoft.com>; Haiyang Zhang <haiyangz@microsoft.com>; Wei Liu <wei.liu@kernel.org>; linux-hyperv@vger.kernel.org; linux-kernel@vger.kernel.org; Michael Kelley <mikelley@microsoft.com>; Andrea Parri <parri.andrea@gmail.com>; Saruhan Karademir <skarade@microsoft.com>
Subject: Re: [PATCH] hv_utils: Add validation for untrusted Hyper-V values

On Tue, Jul 28, 2020 at 5:04 PM Stephen Hemminger
<sthemmin@microsoft.com> wrote:
>
> You may want to use one of the macros that prints this once only.
> This is a "should never happen" type error, so if something goes wrong it might happens so much that journal/syslog would get overloaded.

Certainly, printing error messages once would be ideal if we were only
dealing with Linux kernel bugs. But under the assumption that Hyper-V
can send bogus values at any time, I think it would be better to print
error messages every time so that we are aware of malicious/erroneous
data sent by the host.

      reply index

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-28 20:44 Andres Beltran
     [not found] ` <BN6PR21MB08361CE726C8D3541E657054CC730@BN6PR21MB0836.namprd21.prod.outlook.com>
2020-07-29 16:10   ` Andres Beltran
2020-07-29 16:22     ` Stephen Hemminger [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BN6PR21MB083600994098D204DF141AB3CC700@BN6PR21MB0836.namprd21.prod.outlook.com \
    --to=sthemmin@microsoft.com \
    --cc=haiyangz@microsoft.com \
    --cc=kys@microsoft.com \
    --cc=linux-hyperv@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkmlabelt@gmail.com \
    --cc=mikelley@microsoft.com \
    --cc=parri.andrea@gmail.com \
    --cc=skarade@microsoft.com \
    --cc=wei.liu@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Linux-HyperV Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-hyperv/0 linux-hyperv/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-hyperv linux-hyperv/ https://lore.kernel.org/linux-hyperv \
		linux-hyperv@vger.kernel.org
	public-inbox-index linux-hyperv

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-hyperv


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git