public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb•auug.org.au>
To: John Johansen <john.johansen@canonical•com>
Cc: Linux Next Mailing List <linux-next@vger•kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger•kernel.org>
Subject: linux-next: manual merge of the apparmor tree with Linus' tree
Date: Thu, 20 Jun 2019 13:40:18 +1000	[thread overview]
Message-ID: <20190620134018.65643fb4@canb.auug.org.au> (raw)

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

Hi all,

Today's linux-next merge of the apparmor tree got a conflict in:

  security/apparmor/include/policy.h

between commit:

  23375b13f98c ("apparmor: fix PROFILE_MEDIATES for untrusted input")

from Linus' tree and commit:

  06c13f554a71 ("apparmor: re-introduce a variant of PROFILE_MEDIATES_SAFE")

from the apparmor 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.

-- 
Cheers,
Stephen Rothwell

diff --cc security/apparmor/include/policy.h
index b5b4b8190e65,9af2114e1bf0..000000000000
--- a/security/apparmor/include/policy.h
+++ b/security/apparmor/include/policy.h
@@@ -213,14 -217,13 +213,22 @@@ static inline struct aa_profile *aa_get
  	return labels_profile(aa_get_newest_label(&p->label));
  }
  
 -#define PROFILE_MEDIATES(P, T)  ((P)->policy.start[(unsigned char) (T)])
 +static inline unsigned int PROFILE_MEDIATES(struct aa_profile *profile,
 +					    unsigned char class)
 +{
 +	if (class <= AA_CLASS_LAST)
 +		return profile->policy.start[class];
 +	else
 +		return aa_dfa_match_len(profile->policy.dfa,
 +					profile->policy.start[0], &class, 1);
++}
++
+ /* safe version of POLICY_MEDIATES for full range input */
+ static inline unsigned int PROFILE_MEDIATES_SAFE(struct aa_profile *profile,
+ 						 unsigned char class)
+ {
+ 	return aa_dfa_match_len(profile->policy.dfa,
+ 				profile->policy.start[0], &class, 1);
  }
  
  static inline unsigned int PROFILE_MEDIATES_AF(struct aa_profile *profile,

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

             reply	other threads:[~2019-06-20  3:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-20  3:40 Stephen Rothwell [this message]
  -- strict thread matches above, loose matches on Subject: below --
2019-04-11  2:24 linux-next: manual merge of the apparmor tree with Linus' tree 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=20190620134018.65643fb4@canb.auug.org.au \
    --to=sfr@canb$(echo .)auug.org.au \
    --cc=john.johansen@canonical$(echo .)com \
    --cc=linux-kernel@vger$(echo .)kernel.org \
    --cc=linux-next@vger$(echo .)kernel.org \
    /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