[SCSI] libiscsi_tcp: fix max_r2t manipulation
Problem description from Xi Wang: A large max_r2t could lead to integer overflow in subsequent call to iscsi_tcp_r2tpool_alloc(), allocating a smaller buffer than expected and leading to out-of-bounds write. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
This commit is contained in:
committed by
James Bottomley
parent
df1c7baba1
commit
1304be5fe0
@ -128,7 +128,7 @@ extern void iscsi_tcp_conn_teardown(struct iscsi_cls_conn *cls_conn);
|
||||
/* misc helpers */
|
||||
extern int iscsi_tcp_r2tpool_alloc(struct iscsi_session *session);
|
||||
extern void iscsi_tcp_r2tpool_free(struct iscsi_session *session);
|
||||
|
||||
extern int iscsi_tcp_set_max_r2t(struct iscsi_conn *conn, char *buf);
|
||||
extern void iscsi_tcp_conn_get_stats(struct iscsi_cls_conn *cls_conn,
|
||||
struct iscsi_stats *stats);
|
||||
#endif /* LIBISCSI_TCP_H */
|
||||
|
Reference in New Issue
Block a user