minor modifications at encrypt_decrypt_fields