[dpdk-dev] [PATCH v4 02/18] net/nfp: solve buffer overflow
De Lara Guarch, Pablo
pablo.de.lara.guarch at intel.com
Fri May 11 12:13:58 CEST 2018
Hi,
> -----Original Message-----
> From: De Lara Guarch, Pablo
> Sent: Friday, May 11, 2018 9:58 AM
> To: 'Andy Green' <andy at warmcat.com>; dev at dpdk.org
> Cc: stable at dpdk.org
> Subject: RE: [dpdk-dev] [PATCH v4 02/18] net/nfp: solve buffer overflow
>
>
>
> > -----Original Message-----
> > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Andy Green
> > Sent: Friday, May 11, 2018 2:45 AM
> > To: dev at dpdk.org
> > Subject: [dpdk-dev] [PATCH v4 02/18] net/nfp: solve buffer overflow
> >
> > /home/agreen/projects/dpdk/drivers/net/nfp/nfp_net.c: In function
> > ‘nfp_pf_pci_probe’:
> > /home/agreen/projects/dpdk/drivers/net/nfp/nfp_net.c:3160:
> > 23: error: ‘%s’ directive writing up to 99 bytes into a region of size
> > 76 [- Werror=format-overflow=]
> > sprintf(fw_name, "%s/%s.nffw", DEFAULT_FW_PATH, serial);
> >
> > Note fw_buf still has to increase somewhat even after restricting
> > serial[], since
> > otherwise:
> >
> > /home/agreen/projects/dpdk/drivers/net/nfp/nfp_net.c: In function
> > ‘nfp_pf_pci_probe’:
> > /home/agreen/projects/dpdk/drivers/net/nfp/nfp_net.c:3176:23:
> > error: ‘%s’ directive writing up to 99 bytes into a region of size 76
> > [- Werror=format-overflow=]
> > sprintf(fw_name, "%s/%s", DEFAULT_FW_PATH, card);
> > ^~
> > /home/agreen/projects/dpdk/drivers/net/nfp/nfp_net.c:3262:32:
> > err = nfp_fw_upload(dev, nsp, card_desc);
> > ~~~~~~~~~
> > /home/agreen/projects/dpdk/drivers/net/nfp/nfp_net.c:3176:2:
> > note: ‘sprintf’ output between 25 and 124 bytes into a destination of size 100
> > sprintf(fw_name, "%s/%s", DEFAULT_FW_PATH, card);
> >
> > Signed-off-by: Andy Green <andy at warmcat.com>
>
> Missing fixes line and CC stable.
>
> Fixes: 896c265ef954 ("net/nfp: use new CPP interface")
> Cc: stable at dpdk.org
>
> Acked-by: Pablo de Lara <pablo.de.lara.guarch at intel.com>
Actually, this does not need to be backported to stable, as it was merged in this release.
Sorry about the noise.
More information about the dev
mailing list