Re: [PATCH v20 10/15] migration/channel: check that transfer is UNIX socket when "local" set

Peter Xu <[email protected]>
Newsgroups gmane.comp.emulators.qemu
Message-ID <[email protected]>
On Mon, Aug 17, 2026 at 09:15:17PM +0300, Vladimir Sementsov-Ogievskiy wrote:
> > We only need to touch migration_capabilities_and_transport_compatible()?
> > It should work for both, and fail QMP commands directly might also be
> > slightly better.
> 
> 
> Hm. Actually, migration_capabilities_and_transport_compatible() only sees
> the parsed MigrationAddress, before any QIOChannel is created. At that
> point we can't call qio_channel_has_feature(ioc, QIO_CHANNEL_FEATURE_FD_PASS),
> because there is no ioc yet..
> 
> So, at least, we can't check, is passed from user fd is a UNIX socket
> for SOCKET_ADDRESS_TYPE_FD case.

Maybe have one extra step for FD with socket_sockaddr_to_address()?

-- 
Peter Xu
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.