dash: rename EAP AKA to SessionEstablisher
This commit is contained in:
parent
b2797fa57f
commit
7c0e2af053
2 changed files with 5 additions and 6 deletions
|
@ -16,7 +16,7 @@ import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.io.Chara
|
|||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.message.MessageIO
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.pair.LTKExchanger
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.scan.PodScanner
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.session.EapAkaExchanger
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.session.SessionEstablisher
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.status.ConnectionStatus
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.event.PodEvent
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.pod.command.base.Command
|
||||
|
@ -134,7 +134,7 @@ class OmnipodDashBleManagerImpl @Inject constructor(
|
|||
|
||||
emitter.onNext(PodEvent.EstablishingSession)
|
||||
|
||||
val eapAkaExchanger = EapAkaExchanger(aapsLogger, msgIO, ltk)
|
||||
val eapAkaExchanger = SessionEstablisher(aapsLogger, msgIO, ltk)
|
||||
val sessionKeys = eapAkaExchanger.negotiateSessionKeys()
|
||||
aapsLogger.info(LTag.PUMPCOMM, "CK: ${sessionKeys.ck.toHex()}")
|
||||
aapsLogger.info(LTag.PUMPCOMM, "noncePrefix: ${sessionKeys.noncePrefix.toHex()}")
|
||||
|
|
|
@ -13,7 +13,7 @@ import info.nightscout.androidaps.utils.extensions.toHex
|
|||
import org.spongycastle.util.encoders.Hex
|
||||
import java.security.SecureRandom
|
||||
|
||||
class EapAkaExchanger(private val aapsLogger: AAPSLogger, private val msgIO: MessageIO, private val ltk: PairResult) {
|
||||
class SessionEstablisher(private val aapsLogger: AAPSLogger, private val msgIO: MessageIO, private val ltk: PairResult) {
|
||||
|
||||
var seq = ltk.seq
|
||||
|
||||
|
@ -37,8 +37,7 @@ class EapAkaExchanger(private val aapsLogger: AAPSLogger, private val msgIO: Mes
|
|||
msgIO.sendMesssage(challenge)
|
||||
|
||||
val challengeResponse = msgIO.receiveMessage()
|
||||
processChallengeResponse(challengeResponse)
|
||||
// TODO: what do we have to answer if challenge response does not validate?
|
||||
processChallengeResponse(challengeResponse) //TODO: what do we have to answer if challenge response does not validate?
|
||||
|
||||
seq++
|
||||
var success = eapSuccess()
|
Loading…
Reference in a new issue