Re: [PATCH] eCryptfs: infinite loop due to overflow in ecryptfs_write()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

On 01/19/2012 05:13 PM, Tyler Hicks wrote:
From: Li Wang<liwang@xxxxxxxxxxx>

ecryptfs_write() can enter an infinite loop when truncating a file to a
size larger than 4G. This only happens on architectures where size_t is
represented by 32 bits.

This was caused by a size_t overflow due to it incorrectly being used to
store the result of a calculation which uses potentially large values of
type loff_t.

[tyhicks@xxxxxxxxxxxxx: rewrite subject and commit message]
Signed-off-by: Li Wang<liwang@xxxxxxxxxxx>
Signed-off-by: Yunchuan Wen<wenyunchuan@xxxxxxxxxxxxxx>
Cc: Cong Wang<xiyou.wangcong@xxxxxxxxx>
Signed-off-by: Tyler Hicks<tyhicks@xxxxxxxxxxxxx>

Tyler, thanks for cleaning this up! Looks pretty good now.
To unsubscribe from this list: send the line "unsubscribe ecryptfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at

[LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

Powered by Linux