public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb•auug.org.au>
To: Andrew Morton <akpm@linux-foundation•org>
Cc: Paul Moore <paul@paul-moore•com>,
	Casey Schaufler <casey@schaufler-ca•com>,
	Linux Kernel Mailing List <linux-kernel@vger•kernel.org>,
	Linux Next Mailing List <linux-next@vger•kernel.org>,
	Yafang Shao <laoar.shao@gmail•com>
Subject: Re: linux-next: manual merge of the security tree with the mm tree
Date: Wed, 20 Nov 2024 14:30:11 +1100	[thread overview]
Message-ID: <20241120143011.100edd4d@canb.auug.org.au> (raw)
In-Reply-To: <20241014144648.1923104a@canb.auug.org.au>

[-- Attachment #1: Type: text/plain, Size: 2628 bytes --]

Hi all,

On Mon, 14 Oct 2024 14:46:48 +1100 Stephen Rothwell <sfr@canb•auug.org.au> wrote:
>
> Today's linux-next merge of the security tree got a conflict in:
> 
>   kernel/auditsc.c
> 
> between commit:
> 
>   cd39427be833 ("auditsc: replace memcpy() with strscpy()")
> 
> from the mm-nonmm-unstable branch of the mm tree and commits:
> 
>   37f670aacd48 ("lsm: use lsm_prop in security_current_getsecid")
>   13d826e564e2 ("audit: change context data from secid to lsm_prop")
> 
> from the security tree.
> 
> I fixed it up (see below) and can carry the fix as necessary. This
> is now fixed as far as linux-next is concerned, but any non trivial
> conflicts should be mentioned to your upstream maintainer when your tree
> is submitted for merging.  You may also want to consider cooperating
> with the maintainer of the conflicting tree to minimise any particularly
> complex conflicts.
> 
> diff --cc kernel/auditsc.c
> index 7adc67d5aafb,f28fd513d047..000000000000
> --- a/kernel/auditsc.c
> +++ b/kernel/auditsc.c
> @@@ -2729,8 -2728,8 +2728,8 @@@ void __audit_ptrace(struct task_struct 
>   	context->target_auid = audit_get_loginuid(t);
>   	context->target_uid = task_uid(t);
>   	context->target_sessionid = audit_get_sessionid(t);
> - 	security_task_getsecid_obj(t, &context->target_sid);
> + 	security_task_getlsmprop_obj(t, &context->target_ref);
>  -	memcpy(context->target_comm, t->comm, TASK_COMM_LEN);
>  +	strscpy(context->target_comm, t->comm);
>   }
>   
>   /**
> @@@ -2756,8 -2755,8 +2755,8 @@@ int audit_signal_info_syscall(struct ta
>   		ctx->target_auid = audit_get_loginuid(t);
>   		ctx->target_uid = t_uid;
>   		ctx->target_sessionid = audit_get_sessionid(t);
> - 		security_task_getsecid_obj(t, &ctx->target_sid);
> + 		security_task_getlsmprop_obj(t, &ctx->target_ref);
>  -		memcpy(ctx->target_comm, t->comm, TASK_COMM_LEN);
>  +		strscpy(ctx->target_comm, t->comm);
>   		return 0;
>   	}
>   
> @@@ -2777,8 -2776,8 +2776,8 @@@
>   	axp->target_auid[axp->pid_count] = audit_get_loginuid(t);
>   	axp->target_uid[axp->pid_count] = t_uid;
>   	axp->target_sessionid[axp->pid_count] = audit_get_sessionid(t);
> - 	security_task_getsecid_obj(t, &axp->target_sid[axp->pid_count]);
> + 	security_task_getlsmprop_obj(t, &axp->target_ref[axp->pid_count]);
>  -	memcpy(axp->target_comm[axp->pid_count], t->comm, TASK_COMM_LEN);
>  +	strscpy(axp->target_comm[axp->pid_count], t->comm);
>   	axp->pid_count++;
>   
>   	return 0;

This is now a conflict between the mm-nonmm-stable tree and Linus' tree.

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2024-11-20  3:30 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-14  3:46 linux-next: manual merge of the security tree with the mm tree Stephen Rothwell
2024-11-20  3:30 ` Stephen Rothwell [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-10-23  1:31 Stephen Rothwell
2024-09-11  4:28 Stephen Rothwell
2024-09-11 20:09 ` Paul Moore
2024-09-16 23:30 ` Stephen Rothwell
2024-09-17  7:51   ` Michal Hocko
2024-09-17  8:02     ` Stephen Rothwell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241120143011.100edd4d@canb.auug.org.au \
    --to=sfr@canb$(echo .)auug.org.au \
    --cc=akpm@linux-foundation$(echo .)org \
    --cc=casey@schaufler-ca$(echo .)com \
    --cc=laoar.shao@gmail$(echo .)com \
    --cc=linux-kernel@vger$(echo .)kernel.org \
    --cc=linux-next@vger$(echo .)kernel.org \
    --cc=paul@paul-moore$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox