-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
authentication handshake failed: x509: cannot validate certificate for 127.0.0.1 because it doesn\'t contain any IP SANs" #3700
Comments
This is very strange. The error message looks like something that you would get from a gRPC connection, not REST. If you do And is the gRPC connection with lncli still working? Because I think this error might come from the connection to |
@guggero
i thought
I'm not sure about REST is working . |
We use a package called What version of lnd are you using? Can you please try the following:
|
@guggero after i give up on REST i try to use gRPC . how can i var request = {
node_pubkey: <bytes>,
node_pubkey_string: <string>,
local_funding_amount: <int64>,
push_sat: <int64>,
target_conf: <int32>,
sat_per_byte: <int64>,
private: <bool>,
min_htlc_msat: <int64>,
remote_csv_delay: <uint32>,
min_confs: <int32>,
spend_unconfirmed: <bool>,
}
lightning.openChannelSync(request, function(err, response) {
console.log(response);
}) how can i get could you giving me a sample of openChannelSync ? thanks |
I would be interested to know if the above steps would help. So if you ever find time to try, I'd appreciate it. You don't need to provide all parameters, some are optional. I think something like this should work for you (untested):
|
Closing this as it appears to be an issue of user-side code. |
@guggero var pubkey = '02167027b00c59fa2bc40e0adfc3aa1d7046e66b6b233e58595913b48d83f31f27';
var request = {
node_pubkey_string: pubkey,
local_funding_amount: 500,
push_sat: 0,
target_conf: 1,
private: false,
min_confs: 3,
spend_unconfirmed: false
};
lightning.openChannelSync(request, function(err, response) {
console.log(response);
}); and the ERR is I've read #3404 by my pubkey is Hex-encoded string already What is the problem about this error? |
This should work... What version of lnd are you using? And what version of the |
@guggero var grpc = require('grpc');
var protoLoader = require('@grpc/proto-loader');
const packageDefinition = protoLoader.loadSync('./rpc.proto');
const lnrpc = grpc.loadPackageDefinition(packageDefinition).lnrpc; lightning. |
That's fine too. But you didn't answer my question. What version of the code are you using? Are you using the master branch of lnd? Or which commit? |
@guggero
yes i just clone it last week |
Ok, I figured it out. The problem is the
|
Thanks you so much is working very well .
this line took me 2 days :))) |
You're welcome! Well, talking from experience, optimizing the code of a tutorial before you get it fully working is usually a bad idea. And now you know why we didn't use the |
as soon as i can |
I just learned about lightning network.
i start by this cmd
then
then
It works very well with gRPC
But when i try to connect using REST and node it doesn't work
it return
what should i do to connect using REST API . Thanks !!!
The text was updated successfully, but these errors were encountered: