Commit 22beaf1
committed
Merge: pstore/platform: Add check for kstrdup
MR: https://gitlab.com/redhat/centos-stream/src/kernel/centos-stream-9/-/merge_requests/4322
JIRA: https://issues.redhat.com/browse/RHEL-38128
CVE: CVE-2023-52869
Build Info: https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=61487181
Tested: Did sanity boot testing Intel (intel-arrowlake-s-02) system.
commit a19d48f
Author: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Date: Fri Jun 23 10:27:06 2023 +0800
pstore/platform: Add check for kstrdup
Add check for the return value of kstrdup() and return the error
if it fails in order to avoid NULL pointer dereference.
Fixes: 563ca40 ("pstore/platform: Switch pstore_info::name to const")
Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Link: https://lore.kernel.org/r/20230623022706.32125-1-jiasheng@iscas.ac.cn
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Steve Best <sbest@redhat.com>
Approved-by: Lenny Szubowicz <lszubowi@redhat.com>
Approved-by: Tony Camuso <tcamuso@redhat.com>
Approved-by: David Arcari <darcari@redhat.com>
Approved-by: CKI KWF Bot <cki-ci-bot+kwf-gitlab-com@redhat.com>
Merged-by: Lucas Zampieri <lzampier@redhat.com>1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
561 | 561 | | |
562 | 562 | | |
563 | 563 | | |
| 564 | + | |
| 565 | + | |
564 | 566 | | |
565 | 567 | | |
566 | 568 | | |
| |||
580 | 582 | | |
581 | 583 | | |
582 | 584 | | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
583 | 589 | | |
584 | 590 | | |
585 | 591 | | |
586 | 592 | | |
587 | 593 | | |
| 594 | + | |
588 | 595 | | |
589 | 596 | | |
590 | 597 | | |
| |||
617 | 624 | | |
618 | 625 | | |
619 | 626 | | |
620 | | - | |
| 627 | + | |
621 | 628 | | |
622 | 629 | | |
623 | 630 | | |
| |||
0 commit comments