From: "Daniel P. Berrangé" <berrange@redhat.com>
To: "Alex Bennée" <alex.bennee@linaro.org>
Cc: Stefan Hajnoczi <stefanha@gmail.com>,
Markus Armbruster <armbru@redhat.com>,
qemu-devel@nongnu.org,
"Dr . David Alan Gilbert" <dgilbert@redhat.com>,
P J P <ppandit@redhat.com>
Subject: Re: [Qemu-devel] [PATCH] doc: document that the monitor console is a privileged control interface
Date: Thu, 4 Jul 2019 10:19:21 +0100 [thread overview]
Message-ID: <20190704091921.GE20871@redhat.com> (raw)
In-Reply-To: <87h882w463.fsf@zen.linaroharston>
On Thu, Jul 04, 2019 at 10:16:20AM +0100, Alex Bennée wrote:
>
> Daniel P. Berrangé <berrange@redhat.com> writes:
>
> > On Wed, Jul 03, 2019 at 10:56:05PM +0100, Alex Bennée wrote:
> >>
> >> Daniel P. Berrangé <berrange@redhat.com> writes:
> <snip>
> >> > The reality is that the monitor console (whether QMP or HMP) is
> >> > considered a privileged interface to QEMU and as such must only
> >> > be made available to trusted users. IOW, making it available with
> >> > no authentication over TCP is simply a, very serious, user
> >> > configuration error not a security flaw in QEMU itself.
> >>
> >> Is this the sort of thing we should emit warnings for? I guess this is a
> >> philosophical question as QEMU tends to err towards being taciturn on
> >> the command line unless something is actually wrong (and not just
> >> stupid).
> >>
> >> I wouldn't expect a warning for -serial mon:stdio but maybe a
> >> non-localhost tcp chardev for o+rw socket might be worth a mention? Of
> >> course this sort of sanitising of the command line options does incur
> >> cost and complexity in our option processing.
> >
> > The challenge with issuing warnings is ensuring that we don't give
> > false positives, and that's pretty much impossible IMHO.
> >
> > Even use of plain non-localhost TCP chardevs can be valid in some
> > circumstances. For example it would not be surprising to see it
> > used if QEMU was inside a Kubernetes container, as two containers
> > can communicate with each other over IP & rely on Kubernetes
> > networking layer to provide security
>
> That's certainly a valid setup - you're right this is really a policy
> question. Oh well I guess if your serious about security you read the
> documentation before going to production right ;-)
>
> I assume libvirt et all strive to use secure configurations by default?
Yes, libvirt exclusively uses a UNIX domain socket for the monitor, and
of course even if we used a TCP socket, the SELinux/AppArmour policy
will block any attempts at elevating privs via QMP commands that spawn
processes or try to access arbitrary files.
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2019-07-04 9:20 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-03 13:54 [Qemu-devel] [PATCH] doc: document that the monitor console is a privileged control interface Daniel P. Berrangé
2019-07-03 14:24 ` Philippe Mathieu-Daudé
2019-07-03 14:30 ` Daniel P. Berrangé
2019-07-03 14:41 ` Eric Blake
2019-07-03 16:37 ` no-reply
2019-07-03 21:56 ` Alex Bennée
2019-07-04 8:50 ` Daniel P. Berrangé
2019-07-04 9:16 ` Alex Bennée
2019-07-04 9:19 ` Daniel P. Berrangé [this message]
2019-07-04 9:24 ` Alex Bennée
2019-07-04 1:33 ` no-reply
2019-07-05 7:03 ` Markus Armbruster
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=20190704091921.GE20871@redhat.com \
--to=berrange@redhat.com \
--cc=alex.bennee@linaro.org \
--cc=armbru@redhat.com \
--cc=dgilbert@redhat.com \
--cc=ppandit@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.