Merge tag 'for-linus-fwctl' of git://git.kernel.org/pub/scm/linux/kernel/git/fwctl/fwctl
Pull fwctl fix from Jason Gunthorpe: - Buffer overflow due to missing input validation in pds * tag 'for-linus-fwctl' of git://git.kernel.org/pub/scm/linux/kernel/git/fwctl/fwctl: fwctl: pds: Validate RPC input size before parsing
This commit is contained in:
commit
f53a244224
1 file changed
+3
@@ -362,6 +362,9 @@ static void *pdsfc_fw_rpc(struct fwctl_uctx *uctx, enum fwctl_rpc_scope scope,
|
||||
void *out = NULL;
|
||||
int err;
|
||||
|
||||
if (in_len < sizeof(*rpc))
|
||||
return ERR_PTR(-EINVAL);
|
||||
|
||||
err = pdsfc_validate_rpc(pdsfc, rpc, scope);
|
||||
if (err)
|
||||
return ERR_PTR(err);
|
||||
|
||||
Reference in new issue
Block a user