diff options
author | Kangjie Lu <kangjielu@gmail.com> | 2016-06-02 04:11:20 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-06-02 21:32:37 -0700 |
commit | 4116def2337991b39919f3b448326e21c40e0dbb (patch) | |
tree | 7ccdfaac2b0c0dc732a14d0db3c89abea1dfa5db /net | |
parent | 5d2be1422e02ccd697ccfcd45c85b4a26e6178e2 (diff) | |
download | linux-4116def2337991b39919f3b448326e21c40e0dbb.tar.gz linux-4116def2337991b39919f3b448326e21c40e0dbb.tar.bz2 linux-4116def2337991b39919f3b448326e21c40e0dbb.zip |
rds: fix an infoleak in rds_inc_info_copy
The last field "flags" of object "minfo" is not initialized.
Copying this object out may leak kernel stack data.
Assign 0 to it to avoid leak.
Signed-off-by: Kangjie Lu <kjlu@gatech.edu>
Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/rds/recv.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/rds/recv.c b/net/rds/recv.c index c0be1ecd11c9..8413f6c99e13 100644 --- a/net/rds/recv.c +++ b/net/rds/recv.c @@ -561,5 +561,7 @@ void rds_inc_info_copy(struct rds_incoming *inc, minfo.fport = inc->i_hdr.h_dport; } + minfo.flags = 0; + rds_info_copy(iter, &minfo, sizeof(minfo)); } |