From 9ea6ec850e82d19cbfa8a07a279d89321672d7e1 Mon Sep 17 00:00:00 2001 From: Alberto Ponces Date: Fri, 5 Jan 2024 11:14:04 +0000 Subject: [PATCH] feat: Sync with latest sources of TrebleDroid --- ...crease-default-log_level-to-get-actual-selinux-err.patch | 2 +- ...vert-libsepol-Make-an-unknown-permission-an-error-.patch | 2 +- ...rkaround-device-phh-treble-conflict-with-SELinux-p.patch | 6 +++--- ...low-devices-virtual-block-genfscon-conflict-seen-o.patch | 2 +- ...if-service-is-rcs-accept-conflict.-Seen-on-Moto-E5.patch | 2 +- .../0006-Allow-mismatches-of-exfat-genfscon.patch | 2 +- .../0007-Fix-boot-on-Moto-devices-using-unknown-class.patch | 2 +- ...prove-SELinux-policy-workaround-on-device-phh-treb.patch | 2 +- ...low-sys-vm-watermark_scale_factor-conflict-seen-on.patch | 2 +- .../0010-Allow-conflict-on-fuseblk.patch | 2 +- 10 files changed, 12 insertions(+), 12 deletions(-) diff --git a/patches/trebledroid/platform_external_selinux/0001-Increase-default-log_level-to-get-actual-selinux-err.patch b/patches/trebledroid/platform_external_selinux/0001-Increase-default-log_level-to-get-actual-selinux-err.patch index 9b8dc0c0..4e3211f0 100644 --- a/patches/trebledroid/platform_external_selinux/0001-Increase-default-log_level-to-get-actual-selinux-err.patch +++ b/patches/trebledroid/platform_external_selinux/0001-Increase-default-log_level-to-get-actual-selinux-err.patch @@ -9,7 +9,7 @@ Subject: [PATCH 01/10] Increase default log_level to get actual selinux error 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/secilc/secilc.c b/secilc/secilc.c -index 80d3583d..a51630b2 100644 +index 80d3583d7..a51630b2c 100644 --- a/secilc/secilc.c +++ b/secilc/secilc.c @@ -107,7 +107,7 @@ int main(int argc, char *argv[]) diff --git a/patches/trebledroid/platform_external_selinux/0002-Revert-libsepol-Make-an-unknown-permission-an-error-.patch b/patches/trebledroid/platform_external_selinux/0002-Revert-libsepol-Make-an-unknown-permission-an-error-.patch index 90eca3ac..7a69e815 100644 --- a/patches/trebledroid/platform_external_selinux/0002-Revert-libsepol-Make-an-unknown-permission-an-error-.patch +++ b/patches/trebledroid/platform_external_selinux/0002-Revert-libsepol-Make-an-unknown-permission-an-error-.patch @@ -14,7 +14,7 @@ This is required because some targets calls undefined permissions: 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/libsepol/cil/src/cil_resolve_ast.c b/libsepol/cil/src/cil_resolve_ast.c -index d2bfdc81..91fa1075 100644 +index d2bfdc812..91fa10759 100644 --- a/libsepol/cil/src/cil_resolve_ast.c +++ b/libsepol/cil/src/cil_resolve_ast.c @@ -136,14 +136,18 @@ static int __cil_resolve_perms(symtab_t *class_symtab, symtab_t *common_symtab, diff --git a/patches/trebledroid/platform_external_selinux/0003-Workaround-device-phh-treble-conflict-with-SELinux-p.patch b/patches/trebledroid/platform_external_selinux/0003-Workaround-device-phh-treble-conflict-with-SELinux-p.patch index 3c70bded..058113a2 100644 --- a/patches/trebledroid/platform_external_selinux/0003-Workaround-device-phh-treble-conflict-with-SELinux-p.patch +++ b/patches/trebledroid/platform_external_selinux/0003-Workaround-device-phh-treble-conflict-with-SELinux-p.patch @@ -18,7 +18,7 @@ simply ignore them. 3 files changed, 28 insertions(+), 6 deletions(-) diff --git a/libsepol/cil/src/cil_binary.c b/libsepol/cil/src/cil_binary.c -index 40615db2..74a52956 100644 +index 40615db29..74a529565 100644 --- a/libsepol/cil/src/cil_binary.c +++ b/libsepol/cil/src/cil_binary.c @@ -511,13 +511,17 @@ int cil_typealias_to_policydb(policydb_t *pdb, struct cil_alias *cil_alias) @@ -50,7 +50,7 @@ index 40615db2..74a52956 100644 return rc; } diff --git a/libsepol/cil/src/cil_build_ast.c b/libsepol/cil/src/cil_build_ast.c -index 4177c9f6..118de1f5 100644 +index 4177c9f67..118de1f54 100644 --- a/libsepol/cil/src/cil_build_ast.c +++ b/libsepol/cil/src/cil_build_ast.c @@ -116,7 +116,7 @@ int cil_add_decl_to_symtab(struct cil_db *db, symtab_t *symtab, hashtab_key_t ke @@ -79,7 +79,7 @@ index 4177c9f6..118de1f5 100644 /* multiple_decls is enabled and works for this datum type, add node */ cil_list_append(prev->nodes, CIL_NODE, node); diff --git a/libsepol/cil/src/cil_resolve_ast.c b/libsepol/cil/src/cil_resolve_ast.c -index 91fa1075..d20fb7ee 100644 +index 91fa10759..d20fb7eea 100644 --- a/libsepol/cil/src/cil_resolve_ast.c +++ b/libsepol/cil/src/cil_resolve_ast.c @@ -522,7 +522,13 @@ static int cil_resolve_aliasactual(struct cil_tree_node *current, void *extra_ar diff --git a/patches/trebledroid/platform_external_selinux/0004-Allow-devices-virtual-block-genfscon-conflict-seen-o.patch b/patches/trebledroid/platform_external_selinux/0004-Allow-devices-virtual-block-genfscon-conflict-seen-o.patch index 6674c640..9c83a1fe 100644 --- a/patches/trebledroid/platform_external_selinux/0004-Allow-devices-virtual-block-genfscon-conflict-seen-o.patch +++ b/patches/trebledroid/platform_external_selinux/0004-Allow-devices-virtual-block-genfscon-conflict-seen-o.patch @@ -10,7 +10,7 @@ Change-Id: I06e4e9d5b82d61a8aeab595b47e2589249675895 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/libsepol/cil/src/cil_post.c b/libsepol/cil/src/cil_post.c -index a7c66ead..99410da0 100644 +index a7c66eadb..99410da07 100644 --- a/libsepol/cil/src/cil_post.c +++ b/libsepol/cil/src/cil_post.c @@ -491,7 +491,23 @@ static int cil_post_genfscon_context_compare(const void *a, const void *b) diff --git a/patches/trebledroid/platform_external_selinux/0005-if-service-is-rcs-accept-conflict.-Seen-on-Moto-E5.patch b/patches/trebledroid/platform_external_selinux/0005-if-service-is-rcs-accept-conflict.-Seen-on-Moto-E5.patch index 05017bda..7fde8e87 100644 --- a/patches/trebledroid/platform_external_selinux/0005-if-service-is-rcs-accept-conflict.-Seen-on-Moto-E5.patch +++ b/patches/trebledroid/platform_external_selinux/0005-if-service-is-rcs-accept-conflict.-Seen-on-Moto-E5.patch @@ -9,7 +9,7 @@ Change-Id: I0cc2d0fad83f403f2b5d7458039b1564ce5ed9dd 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/libselinux/src/label_backends_android.c b/libselinux/src/label_backends_android.c -index 77f7a1eb..55a30944 100644 +index 77f7a1eba..55a30944e 100644 --- a/libselinux/src/label_backends_android.c +++ b/libselinux/src/label_backends_android.c @@ -62,14 +62,24 @@ static int nodups_specs(struct saved_data *data) diff --git a/patches/trebledroid/platform_external_selinux/0006-Allow-mismatches-of-exfat-genfscon.patch b/patches/trebledroid/platform_external_selinux/0006-Allow-mismatches-of-exfat-genfscon.patch index 1676c775..30ff75c8 100644 --- a/patches/trebledroid/platform_external_selinux/0006-Allow-mismatches-of-exfat-genfscon.patch +++ b/patches/trebledroid/platform_external_selinux/0006-Allow-mismatches-of-exfat-genfscon.patch @@ -8,7 +8,7 @@ Subject: [PATCH 06/10] Allow mismatches of exfat genfscon 1 file changed, 4 insertions(+) diff --git a/libsepol/cil/src/cil_post.c b/libsepol/cil/src/cil_post.c -index 99410da0..7f614c03 100644 +index 99410da07..7f614c039 100644 --- a/libsepol/cil/src/cil_post.c +++ b/libsepol/cil/src/cil_post.c @@ -502,6 +502,10 @@ static int cil_post_genfscon_context_compare(const void *a, const void *b) diff --git a/patches/trebledroid/platform_external_selinux/0007-Fix-boot-on-Moto-devices-using-unknown-class.patch b/patches/trebledroid/platform_external_selinux/0007-Fix-boot-on-Moto-devices-using-unknown-class.patch index eb8121e1..f0aea0b6 100644 --- a/patches/trebledroid/platform_external_selinux/0007-Fix-boot-on-Moto-devices-using-unknown-class.patch +++ b/patches/trebledroid/platform_external_selinux/0007-Fix-boot-on-Moto-devices-using-unknown-class.patch @@ -31,7 +31,7 @@ Change-Id: I66339857634ebfdba359f12a99dfd0bff709d80b 1 file changed, 24 insertions(+) diff --git a/libsepol/cil/src/cil_build_ast.c b/libsepol/cil/src/cil_build_ast.c -index 118de1f5..77e130d1 100644 +index 118de1f54..77e130d1e 100644 --- a/libsepol/cil/src/cil_build_ast.c +++ b/libsepol/cil/src/cil_build_ast.c @@ -462,6 +462,14 @@ int cil_gen_class(struct cil_db *db, struct cil_tree_node *parse_current, struct diff --git a/patches/trebledroid/platform_external_selinux/0008-Improve-SELinux-policy-workaround-on-device-phh-treb.patch b/patches/trebledroid/platform_external_selinux/0008-Improve-SELinux-policy-workaround-on-device-phh-treb.patch index b974a250..9213c2e4 100644 --- a/patches/trebledroid/platform_external_selinux/0008-Improve-SELinux-policy-workaround-on-device-phh-treb.patch +++ b/patches/trebledroid/platform_external_selinux/0008-Improve-SELinux-policy-workaround-on-device-phh-treb.patch @@ -10,7 +10,7 @@ This fixes boot on many Samsung devices as exiting with SEPOL_EEXIST will preven 1 file changed, 1 deletion(-) diff --git a/libsepol/cil/src/cil_build_ast.c b/libsepol/cil/src/cil_build_ast.c -index 77e130d1..daf8b8b3 100644 +index 77e130d1e..daf8b8b30 100644 --- a/libsepol/cil/src/cil_build_ast.c +++ b/libsepol/cil/src/cil_build_ast.c @@ -141,7 +141,6 @@ int cil_add_decl_to_symtab(struct cil_db *db, symtab_t *symtab, hashtab_key_t ke diff --git a/patches/trebledroid/platform_external_selinux/0009-Allow-sys-vm-watermark_scale_factor-conflict-seen-on.patch b/patches/trebledroid/platform_external_selinux/0009-Allow-sys-vm-watermark_scale_factor-conflict-seen-on.patch index d9cac791..2fa819e0 100644 --- a/patches/trebledroid/platform_external_selinux/0009-Allow-sys-vm-watermark_scale_factor-conflict-seen-on.patch +++ b/patches/trebledroid/platform_external_selinux/0009-Allow-sys-vm-watermark_scale_factor-conflict-seen-on.patch @@ -9,7 +9,7 @@ Subject: [PATCH 09/10] Allow /sys/vm/watermark_scale_factor conflict -- seen 1 file changed, 9 insertions(+) diff --git a/libsepol/cil/src/cil_post.c b/libsepol/cil/src/cil_post.c -index 7f614c03..1703b3b6 100644 +index 7f614c039..1703b3b6d 100644 --- a/libsepol/cil/src/cil_post.c +++ b/libsepol/cil/src/cil_post.c @@ -502,6 +502,15 @@ static int cil_post_genfscon_context_compare(const void *a, const void *b) diff --git a/patches/trebledroid/platform_external_selinux/0010-Allow-conflict-on-fuseblk.patch b/patches/trebledroid/platform_external_selinux/0010-Allow-conflict-on-fuseblk.patch index af274f80..cfbc0dca 100644 --- a/patches/trebledroid/platform_external_selinux/0010-Allow-conflict-on-fuseblk.patch +++ b/patches/trebledroid/platform_external_selinux/0010-Allow-conflict-on-fuseblk.patch @@ -8,7 +8,7 @@ Subject: [PATCH 10/10] Allow conflict on fuseblk 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libsepol/cil/src/cil_post.c b/libsepol/cil/src/cil_post.c -index 1703b3b6..5428005d 100644 +index 1703b3b6d..5428005d6 100644 --- a/libsepol/cil/src/cil_post.c +++ b/libsepol/cil/src/cil_post.c @@ -511,7 +511,7 @@ static int cil_post_genfscon_context_compare(const void *a, const void *b)