From 7f47fe61220c683a74bfd739ea37d7fa039be186 Mon Sep 17 00:00:00 2001 From: tujingwei Date: Tue, 19 Nov 2024 10:03:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8D=95=E5=8F=B7=EF=BC=9A#IB47UB=20=E6=8F=8F?= =?UTF-8?q?=E8=BF=B0=EF=BC=9Akasan=20=E5=8E=8B=E6=B5=8B=E6=97=B6code=5Fsig?= =?UTF-8?q?n=20=E5=87=BA=E7=8E=B0=E5=86=85=E5=AD=98=E8=B6=8A=E7=95=8C=20?= =?UTF-8?q?=E9=97=AE=E9=A2=98=E6=A0=B9=E5=9B=A0=EF=BC=9A=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E6=80=81=E6=95=B0=E6=8D=AE=E6=8B=B7=E8=B4=9D=E5=88=B0=E5=86=85?= =?UTF-8?q?=E6=A0=B8=E6=80=81=E6=97=B6=EF=BC=8C=E5=AD=97=E7=AC=A6=E4=B8=B2?= =?UTF-8?q?=E7=BB=93=E6=9D=9F=E7=AC=A6=E6=B2=A1=E6=9C=89=E8=80=83=E8=99=91?= =?UTF-8?q?=20=E8=A7=A3=E5=86=B3=E6=96=B9=E6=A1=88=EF=BC=9A=E5=8A=A0?= =?UTF-8?q?=E5=85=A5=E7=BB=93=E6=9D=9F=E7=AC=A6=20=E6=98=AF=E5=90=A6?= =?UTF-8?q?=E5=AE=8C=E6=88=90=E7=BC=96=E7=A8=8B=E8=A7=84=E8=8C=83=E8=87=AA?= =?UTF-8?q?=E6=A3=80=EF=BC=9AY=20=E6=98=AF=E5=90=A6=E7=BC=96=E7=A8=8B?= =?UTF-8?q?=E4=B8=94=E9=AA=8C=E8=AF=81=E9=80=9A=E8=BF=87=EF=BC=9AY=20?= =?UTF-8?q?=E5=BD=B1=E5=93=8D=E7=9A=84=E8=AE=BE=E5=A4=87=E4=B8=8E=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E8=8C=83=E5=9B=B4=EF=BC=9Ark3568=20=E5=92=8C7885=20?= =?UTF-8?q?=E5=9B=A2=E9=98=9F=EF=BC=9AH?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: tujingwei --- code_sign/code_sign_ioctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code_sign/code_sign_ioctl.c b/code_sign/code_sign_ioctl.c index 16e640c..79f1238 100644 --- a/code_sign/code_sign_ioctl.c +++ b/code_sign/code_sign_ioctl.c @@ -213,7 +213,7 @@ int parse_cert_source(unsigned long args, struct cert_source **_source) goto copy_source_failed; } - source->subject = kzalloc(info.signing_length, GFP_KERNEL); + source->subject = kzalloc(info.signing_length + 1, GFP_KERNEL); if (!source->subject) { ret = -ENOMEM; goto copy_source_failed; @@ -225,7 +225,7 @@ int parse_cert_source(unsigned long args, struct cert_source **_source) goto copy_subject_failed; } - source->issuer = kzalloc(info.issuer_length, GFP_KERNEL); + source->issuer = kzalloc(info.issuer_length + 1, GFP_KERNEL); if (!source->issuer) { ret = -ENOMEM; goto copy_subject_failed; -- Gitee