diff --git a/frameworks/js/napi/client/cfi_blocklist.txt b/frameworks/js/napi/client/cfi_blocklist.txt index ccd00cd0418ee79e2cd07cd9c256d6f6b9260942..4a07c00f09b300a105bcfb11f0fd427d8e9292c5 100644 --- a/frameworks/js/napi/client/cfi_blocklist.txt +++ b/frameworks/js/napi/client/cfi_blocklist.txt @@ -12,4 +12,7 @@ # limitations under the License. [cfi] -src:*session_manager.cpp \ No newline at end of file +type:*OHOS::UpdateEngine::IUpdater* +src:*session_manager.cpp +src:*update_moudle.cpp +src:*napi_session.cpp diff --git a/services/engine/BUILD.gn b/services/engine/BUILD.gn index 1e3264592ef6a422702fdc2d6ca0ed926e3ac528..e33a1e6d9d7c55a163ee0a7f6c6b302c0bb0eef9 100644 --- a/services/engine/BUILD.gn +++ b/services/engine/BUILD.gn @@ -29,6 +29,13 @@ ohos_prebuilt_etc("updater_sa.cfg") { } ohos_shared_library("$updateengine_library_name") { + sanitize = { + cfi = true + cfi_cross_dso = true + debug = false + blocklist = "./cfi_blocklist.txt" + } + shlib_type = "sa" include_dirs = sa_include_dirs sources = sa_sources diff --git a/services/engine/cfi_blocklist.txt b/services/engine/cfi_blocklist.txt new file mode 100644 index 0000000000000000000000000000000000000000..4b0667797473a146b56d5f173e3fe78165d806d0 --- /dev/null +++ b/services/engine/cfi_blocklist.txt @@ -0,0 +1,15 @@ +# Copyright (C) 2022-2023 Huawei Device Co., Ltd. +# 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. + +[cfi] +src:*progress_thread.cpp \ No newline at end of file