KSPP / linux

Linux kernel source tree (Kernel Self Protection Project)
https://kernsec.org/wiki/index.php/Kernel_Self_Protection_Project
Other
80 stars 5 forks source link

Replace one-element array with flexible-array member in fs/nfsd/xdr4.h #298

Closed GustavoARSilva closed 1 year ago

GustavoARSilva commented 1 year ago

diff --git a/fs/nfsd/xdr4.h b/fs/nfsd/xdr4.h
index 510978e602da..68072170eac8 100644
--- a/fs/nfsd/xdr4.h
+++ b/fs/nfsd/xdr4.h
@@ -899,7 +899,7 @@ struct nfsd4_operation {
 struct nfsd4_cb_recall_any {
        struct nfsd4_callback   ra_cb;
        u32                     ra_keep;
-       u32                     ra_bmval[1];
+       u32                     ra_bmval[];
 };
GustavoARSilva commented 1 year ago

See resolution: https://lore.kernel.org/linux-hardening/136d72e5-287c-ebaf-c1e1-92b10e68ba8d@embeddedor.com/