Files
app_Settings/res/xml/device_info_phone_status.xml
Raju Yadav 92331e51ea Avoid SElinux denial accessing IMEI information
Set persistent attribute to false so preferences are not
stored in shared preferences, this avoids the SElinux
denial:

  W/SharedPreferenc( 6950): type=1400 audit(0.0:4): avc: \
  denied { search } for name="com.android.settings" \
  dev="mmcblk0p25" ino=48929 scontext=u:r:radio:s0 \
  tcontext=u:object_r:system_app_data_file:s0 tclass=dir\
  op_res=-13 ppid=319 pcomm="main" tgid=1589\
  tgcomm="m.android.phone"

Observed when entering IMEI information in:
Settings > About Phone > Status > IMEI information.

It makes no sense to store this information in shared
preferences anyway so no functinoality is lost with this
change.

(cherrypicked from commit b2ad5bb522)

Change-Id: Id778bbadc8141167d679177b39e1d7a540d5752c
2015-05-07 13:54:54 -07:00

54 lines
2.0 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2014 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.
-->
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:title="@string/imei_information_title">
<!-- This menu item is only for CDMA phone -->
<Preference android:key="min_number"
android:title="@string/status_min_number"
android:summary="@string/device_info_not_available"
android:persistent="false"/>
<!-- This menu item is only for CDMA phone -->
<Preference android:key="prl_version"
android:title="@string/status_prl_version"
android:summary="@string/device_info_not_available"
android:persistent="false"/>
<!-- This menu item is only for CDMA phone -->
<Preference android:key="meid_number"
android:title="@string/status_meid_number"
android:summary="@string/device_info_not_available"
android:persistent="false"/>
<Preference android:key="imei"
android:title="@string/status_imei"
android:summary="@string/device_info_not_available"
android:persistent="false"/>
<Preference android:key="imei_sv"
android:title="@string/status_imei_sv"
android:summary="@string/device_info_not_available"
android:persistent="false"/>
<Preference android:key="icc_id"
android:title="@string/status_icc_id"
android:summary="@string/device_info_not_available"
android:persistent="false"/>
</PreferenceScreen>