WifiConfigStoreLegacy: Migration from legacy store

Add a new module |WifiConfigStoreLegacy| to perform the necessary
migration of data from the legacy store files:
1. wpa_supplicant.conf (indirectly via wpa_supplicant ctrl iface)
2. networkHistory.txt
3. ipconfig.txt

The new module exposes 3 methods to help in migration:
1. isStoresPresent() - to indicate the need for migration.
2. read() - to read data from all the store files.
3. removeStores() - to delete all the store files after migration.

This is using the existing store  read methods in WifiNetworkHistory,
WifiSupplicantControl & IpconfigStore.

TODO: Migrate passpoint info later.

BUG: 29337176
TEST: Added a unit test.
TEST: Manual tests using some hacks in WifiConfigManager.

Change-Id: I143a4271cc63573a69a3008396d1396c1f36721b
6 files changed
tree: 128c4e1173c44746a37ded493168ba8111416c21
  1. service/