mobile: add TLS options to wallet unlocker listener

The wallet unlocker service also requires the TLS certificates to be
added, but this was not set. This commit sets the options similar to
what is done for the regular RPC server.
This commit is contained in:
Johan T. Halseth 2020-01-13 12:21:39 +01:00
parent a870ed5fb7
commit f5a9813304
No known key found for this signature in database
GPG Key ID: 15BAADA29DA20D26

View File

@ -74,6 +74,18 @@ func Start(extraArgs string, unlockerReady, rpcReady Callback) {
// callbacks when the RPC servers are ready to accept calls.
go func() {
<-unlockerListening
// We must set the TLS certificates in order to properly
// authenticate with the wallet unlocker service.
auth, err := lnd.WalletUnlockerAuthOptions()
if err != nil {
unlockerReady.OnError(err)
return
}
// Add the auth options to the listener's dial options.
addWalletUnlockerLisDialOption(auth...)
unlockerReady.OnResponse([]byte{})
}()