Linux s390 Architecture development
 help / color / mirror / Atom feed
* [PATCH v6 0/2] Improve code in zcrypt msg type 6 handling
@ 2026-07-27  8:31 Harald Freudenberger
  2026-07-27  8:31 ` [PATCH v6 1/2] s390/zcrypt: Improve CCA CPRB length and overflow checks Harald Freudenberger
  2026-07-27  8:32 ` [PATCH v6 2/2] s390/zcrypt: Improve EP11 " Harald Freudenberger
  0 siblings, 2 replies; 7+ messages in thread
From: Harald Freudenberger @ 2026-07-27  8:31 UTC (permalink / raw)
  To: dengler, fcallies
  Cc: freude, linux-s390, Heiko Carstens, Vasily Gorbik,
	Alexander Gordeev

Rework the limit and overflow checks in the both functions
xcrb_msg_to_type6_ep11cprb_msgx() and xcrb_msg_to_type6cprb_msgx().

Changelog:

v1: initial version, one patch dealing with overflow checks around
    the use of the CEIL4 macro in zcrypt_msgtype6.c
v2: Sashiko found a regression: The check
      if (ap_msg->len > ap_msg->bufsize)
    was missing in the rework. Added again this important check.
v3: - Split into two patches  - one for CCA one for EP11
    - rework upper limit/overflow check 
    - add lower limit check
v4: - tried to address all the remaining complains from sashiko.
v5: - Yea, sashiko still found out that the min req size needs
      to take the minimal payload header into account. Fixed.
v6: - And finally add padding zeros when there is a gap between
      user space provided message size and rounded message size
      in kernel.

Harald Freudenberger (2):
  s390/zcrypt: Improve CCA CPRB length and overflow checks
  s390/zcrypt: Improve EP11 CPRB length and overflow checks

 drivers/s390/crypto/zcrypt_msgtype6.c | 101 ++++++++++++++------------
 1 file changed, 55 insertions(+), 46 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-07-27 12:14 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-27  8:31 [PATCH v6 0/2] Improve code in zcrypt msg type 6 handling Harald Freudenberger
2026-07-27  8:31 ` [PATCH v6 1/2] s390/zcrypt: Improve CCA CPRB length and overflow checks Harald Freudenberger
2026-07-27  8:47   ` sashiko-bot
2026-07-27 12:11   ` Holger Dengler
2026-07-27  8:32 ` [PATCH v6 2/2] s390/zcrypt: Improve EP11 " Harald Freudenberger
2026-07-27  8:45   ` sashiko-bot
2026-07-27 12:14   ` Holger Dengler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox