modem: Allow tests to change KI

This is useful for tests that wants to fake a bad KI to test if auth and
encryption are working correctly.

Change-Id: I40cfed6f6b9239eea2b97ffa010b98c78f0cb9cb
diff --git a/src/osmo_gsm_tester/ofono_client.py b/src/osmo_gsm_tester/ofono_client.py
index 60f98df..00cfd47 100644
--- a/src/osmo_gsm_tester/ofono_client.py
+++ b/src/osmo_gsm_tester/ofono_client.py
@@ -318,6 +318,7 @@
     'convenience for ofono Modem interaction'
     msisdn = None
     sms_received_list = None
+    _ki = None
 
     def __init__(self, conf):
         self.conf = conf
@@ -394,7 +395,12 @@
             raise log.Error('No IMSI')
         return imsi
 
+    def set_ki(self, ki):
+        self._ki = ki
+
     def ki(self):
+        if self._ki is not None:
+            return self._ki
         return self.conf.get('ki')
 
     def _on_netreg_property_changed(self, name, value):