DO NOT MERGE Enable properties in ext4enc

(cherry-picked from 4e7274551c93e1c064648409f52ca430da647050)

Enables OwnerInfo and pattern suppression

Bug: 18151196

Change-Id: I46144e16cb00319deeb5492ab82c67f5dd43d6d3
diff --git a/cryptfs.c b/cryptfs.c
index 1ab587c..47b19a6 100644
--- a/cryptfs.c
+++ b/cryptfs.c
@@ -3491,6 +3491,10 @@
 /* Return the value of the specified field. */
 int cryptfs_getfield(const char *fieldname, char *value, int len)
 {
+    if (e4crypt_crypto_complete(DATA_MNT_POINT) == 0) {
+        return e4crypt_get_field(DATA_MNT_POINT, fieldname, value, len);
+    }
+
     char temp_value[PROPERTY_VALUE_MAX];
     /* CRYPTO_GETFIELD_OK is success,
      * CRYPTO_GETFIELD_ERROR_NO_FIELD is value not set,
@@ -3552,6 +3556,10 @@
 /* Set the value of the specified field. */
 int cryptfs_setfield(const char *fieldname, const char *value)
 {
+    if (e4crypt_crypto_complete(DATA_MNT_POINT) == 0) {
+        return e4crypt_set_field(DATA_MNT_POINT, fieldname, value);
+    }
+
     char encrypted_state[PROPERTY_VALUE_MAX];
     /* 0 is success, negative values are error */
     int rc = CRYPTO_SETFIELD_ERROR_OTHER;