Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP2:GA
qemu-linux-user
0224-libslirp-tftp-check-tftp_input-buff.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0224-libslirp-tftp-check-tftp_input-buff.patch of Package qemu-linux-user
From: Jose R Ziviani <jose.ziviani@suse.com> Date: Thu, 8 Jul 2021 07:51:00 -0600 Subject: libslirp: tftp: check tftp_input buffer size MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Git-commit: 3f17948137155f025f7809fdc38576d5d2451c3d References: bsc#1187366, CVE-2021-3595 Fixes: CVE-2021-3595 Fixes: https://gitlab.freedesktop.org/slirp/libslirp/-/issues/46 Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Jose R Ziviani <jose.ziviani@suse.com> --- slirp/tftp.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/slirp/tftp.c b/slirp/tftp.c index a9bc4bb1b65819f10cb5f3029b9c..f4ce9caaf9d8f9481ce60ca431f5 100644 --- a/slirp/tftp.c +++ b/slirp/tftp.c @@ -439,7 +439,11 @@ static void tftp_handle_error(Slirp *slirp, struct sockaddr_storage *srcsas, void tftp_input(struct sockaddr_storage *srcsas, struct mbuf *m) { - struct tftp_t *tp = (struct tftp_t *)m->m_data; + struct tftp_t *tp = mtod_check(m, offsetof(struct tftp_t, x.tp_buf)); + + if (tp == NULL) { + return; + } switch(ntohs(tp->tp_op)) { case TFTP_RRQ:
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor