title: iOS Managed App Config and device enrollment
body: <p>I am in the process of enabling managed app configurations in my app so that if the device was enrolled in to a  MDM program, it can the read managed configurations (as per AppConfig.org standards) and behave accordingly. My app is, however, distributed via. the Apple store and not via. MDM. For devices without MDM enrollment, there is a fall back behavior. </p>
  
  <p>I have looked in to the documentation for Air Watch, Mobile Iron regarding the managed app configuration settings. Also, checked AppConfig.org but couldn't find answers to my questions.</p>
  
  <p>My understanding of AppConfig and MDM is that MDM can securely deliver the configuration dictionary that is set in the MDM server to managed device's  NSUserDefaults and the app can read from it. I am not sure what happens after this to the managed configurations settings in NSUserDefaults, if
   (a) the device gets un-enrolled from MDM 
   (b) MDM un-installs/removes the app 
   (c) User updates the app (assuming MDM allows it) from App Store
   (d) User temporarily disconnects/logs out from MDM client. </p>
  
  <p>Once MDM writes to NSUserDefaults the configuration is available for use by the app, how does MDM control the delivered settings in the above scenarios?  </p>