mobile: authenticate with rpc server

This makes the mobile bindings work with TLS and macaroons enabled,
which is supported from falafel 0.6.
This commit is contained in:
Johan T. Halseth committed 2019-12-18 10:28:23 +01:00
1 parent 200161e04c
commit 5be6e1c92e
1 file changed
+13
+13
View File
@@ -79,6 +79,19 @@ func Start(extraArgs string, unlockerReady, rpcReady Callback) {
go func() {
<-rpcListening
// Now that the RPC server is ready, we can get the needed
// authentication options, and add them to the global dial
// options.
auth, err := lnd.AdminAuthOptions()
if err != nil {
rpcReady.OnError(err)
return
}
// Add the auth options to the listener's dial options.
addLightningLisDialOption(auth...)
rpcReady.OnResponse([]byte{})
}()
}