diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-07-07 05:21:53 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-07-07 05:21:53 +0000 |
commit | c136bf4c58137c4c61139f075f661a5b5dcabd03 (patch) | |
tree | 24d25def8cdaf44a8d5d5cf1b383a2273dab8f37 | |
parent | 2795fd579bda90ae7acac89e1858262cb7693ce1 (diff) | |
parent | c555067672c78afd1b55a506b3ca283f60b3b1f5 (diff) | |
download | SEPolicy-android14-mainline-uwb-release.tar.gz |
Snap for 10453563 from c555067672c78afd1b55a506b3ca283f60b3b1f5 to mainline-uwb-releaseaml_uwb_341513070aml_uwb_341511050aml_uwb_341310300aml_uwb_341310030aml_uwb_341111010aml_uwb_341011000android14-mainline-uwb-release
Change-Id: I4a4fbd3c2b7eb1d14dd2caf01c964f9da5f24c38
-rw-r--r-- | API-level-policy/33/Android.bp | 15 | ||||
-rw-r--r-- | API-level-policy/33/SEPolicy-33.textproto | 1 | ||||
-rw-r--r-- | API-level-policy/Android.bp | 15 | ||||
-rw-r--r-- | API-level-policy/sepolicy.proto | 27 | ||||
-rw-r--r-- | apex/Android.bp | 2 |
5 files changed, 59 insertions, 1 deletions
diff --git a/API-level-policy/33/Android.bp b/API-level-policy/33/Android.bp index 9c128a2..01fde8e 100644 --- a/API-level-policy/33/Android.bp +++ b/API-level-policy/33/Android.bp @@ -26,6 +26,7 @@ genrule { ":apex_service_contexts-33", ":apex_seapp_contexts-33", ":apex_sepolicy-33.cil", + ":apex_sepolicy-33.decompiled.cil", ":apex_sepolicy.sha256", ":sepolicy_apex_test_file", @@ -68,6 +69,20 @@ prebuilt_etc { filename: "SEPolicy-33.zip.fsv_sig", } +genrule { + name: "SEPolicy-33.pb.gen", + defaults: ["sepolicy_info_bin_gen_default"], + srcs: ["SEPolicy-33.textproto"], + out: ["SEPolicy-33.pb.gen"], +} + +prebuilt_etc { + name: "SEPolicy-33.pb", + src: ":SEPolicy-33.pb.gen", + installable: false, + filename: "SEPolicy-33.pb", +} + // Versions of the most up-to-date apex sepolicies are installed on /system. prebuilt_etc { name: "SEPolicy.zip", diff --git a/API-level-policy/33/SEPolicy-33.textproto b/API-level-policy/33/SEPolicy-33.textproto new file mode 100644 index 0000000..dda0854 --- /dev/null +++ b/API-level-policy/33/SEPolicy-33.textproto @@ -0,0 +1 @@ +packagename: "com.android.sepolicy.sepolicy_33"
\ No newline at end of file diff --git a/API-level-policy/Android.bp b/API-level-policy/Android.bp index 0ab3fa8..c00e6be 100644 --- a/API-level-policy/Android.bp +++ b/API-level-policy/Android.bp @@ -32,7 +32,7 @@ genrule_defaults { tool_files: [":SEPolicyKeyPem", ":SEPolicyCertPem"], // Use fsverity tool to generate the signature file which // will be stored in the apex. - // https://git.kernel.org/pub/scm/linux/kernel/git/ebiggers/fsverity-utils.git/tree/README.md + // https://git.kernel.org/pub/scm/fs/fsverity/fsverity-utils.git/tree/README.md cmd: "$(location fsverity) sign $(in) $(out) " + "--key=$(location :SEPolicyKeyPem) " + "--cert=$(location :SEPolicyCertPem) " + @@ -47,6 +47,19 @@ genrule_defaults { "$(location soong_zip) -o $(out) -C $(genDir)/files -D $(genDir)/files", } +filegroup { + name: "sepolicy_proto_def", + srcs: [ "sepolicy.proto" ], +} + +genrule_defaults { + name: "sepolicy_info_bin_gen_default", + tools: ["aprotoc"], + tool_files: [ ":sepolicy_proto_def" ], + cmd: "$(location aprotoc) --encode=com.android.sepolicy.SepolicyInfo " + + "-I $$(dirname $(location :sepolicy_proto_def)) $(location :sepolicy_proto_def) < $(in) > $(out)", +} + prebuilt_etc { name: "sepolicy_apex_test_file", src: "sepolicy_apex_test_file", diff --git a/API-level-policy/sepolicy.proto b/API-level-policy/sepolicy.proto new file mode 100644 index 0000000..8aff4a8 --- /dev/null +++ b/API-level-policy/sepolicy.proto @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +syntax = "proto2"; + +package com.android.sepolicy; + +option java_package = "com.android.sepolicy"; +option java_outer_classname = "Sepolicy"; + +message SepolicyInfo { + // A packagename to identify a versioned policy. + optional string packagename = 1; +}
\ No newline at end of file diff --git a/apex/Android.bp b/apex/Android.bp index 8c9129c..ebe4a31 100644 --- a/apex/Android.bp +++ b/apex/Android.bp @@ -28,11 +28,13 @@ apex { "SEPolicy-33.zip.sig", "SEPolicy-33.zip.fsv_sig", "SEPolicy-33.zip", + "SEPolicy-33.pb" ], required: [ "SEPolicy.zip.sig", "SEPolicy.zip.fsv_sig", "SEPolicy.zip", + "SEPolicy-33.pb", ], } |