Follow framework refactoring.

Bug: 27531029
Change-Id: I21255335a776cdc7f47b09d110e8334803c414b7
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 289f739..36d5ef6 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -37,8 +37,8 @@
                  android:label="@string/app_label"
                  android:icon="@mipmap/ic_launcher_phone"
                  android:usesCleartextTraffic="true"
-                 android:forceDeviceEncrypted="true"
-                 android:encryptionAware="true">
+                 android:defaultToDeviceProtectedStorage="true"
+                 android:directBootAware="true">
 
         <provider android:name="TelephonyProvider"
                   android:authorities="telephony"
diff --git a/src/com/android/providers/telephony/ProviderUtil.java b/src/com/android/providers/telephony/ProviderUtil.java
index 7053e9a..4234b06 100644
--- a/src/com/android/providers/telephony/ProviderUtil.java
+++ b/src/com/android/providers/telephony/ProviderUtil.java
@@ -113,16 +113,16 @@
     }
 
     public static Context getCredentialEncryptedContext(Context context) {
-        if (context.isCredentialEncryptedStorage()) {
+        if (context.isCredentialProtectedStorage()) {
             return context;
         }
-        return context.createCredentialEncryptedStorageContext();
+        return context.createCredentialProtectedStorageContext();
     }
 
     public static Context getDeviceEncryptedContext(Context context) {
-        if (context.isDeviceEncryptedStorage()) {
+        if (context.isDeviceProtectedStorage()) {
             return context;
         }
-        return context.createDeviceEncryptedStorageContext();
+        return context.createDeviceProtectedStorageContext();
     }
 }