opentimestamps / java-opentimestamps

Other
40 stars 31 forks source link

Could not connect to local Bitcoin node #55

Closed NicolaPez closed 3 years ago

NicolaPez commented 3 years ago

H there,

sometimes ago I developed a machine that validate my ots file, that return true/false if the validation worked well. Now =I'm tested that code, and i receive this response:

Could not connect to local Bitcoin node
Could not connect to local Bitcoin node
Could not connect to local Bitcoin node
Insight response error: RequestError: Error: getaddrinfo ENOTFOUND btc-bitcore4.trezor.io btc-bitcore4.trezor.io:443
Insight response error: RequestError: Error: getaddrinfo ENOTFOUND btc-bitcore1.trezor.io btc-bitcore1.trezor.io:443
Insight response error: RequestError: Error: getaddrinfo ENOTFOUND btc-bitcore1.trezor.io btc-bitcore1.trezor.io:443
Insight response error: RequestError: Error: getaddrinfo ENOTFOUND btc-bitcore4.trezor.io btc-bitcore4.trezor.io:443
Insight response error: RequestError: Error: getaddrinfo ENOTFOUND btc-bitcore1.trezor.io btc-bitcore1.trezor.io:443
Insight response error: RequestError: Error: getaddrinfo ENOTFOUND btc-bitcore4.trezor.io btc-bitcore4.trezor.io:443
Insight response error: StatusCodeError: 404 - "endpoint does not exist \"/block-index/581162\""
Insight response error: StatusCodeError: 404 - "endpoint does not exist \"/block-index/581162\""
Insight response error: StatusCodeError: 404 - "endpoint does not exist \"/block-index/581162\""
Insight response error: StatusCodeError: 525 - "<html>\r\n<head><title>525 Origin SSL Handshake Error</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>525 Origin SSL Handshake Error</h1></center>\r\n<hr><center>cloudflare-nginx</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 526 - "<html>\r\n<head><title>526 Origin SSL Certificate Error</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>526 Origin SSL Certificate Error</h1></center>\r\n<hr><center>cloudflare-nginx</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 526 - "<html>\r\n<head><title>526 Origin SSL Certificate Error</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>526 Origin SSL Certificate Error</h1></center>\r\n<hr><center>cloudflare-nginx</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 526 - "<html>\r\n<head><title>526 Origin SSL Certificate Error</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>526 Origin SSL Certificate Error</h1></center>\r\n<hr><center>cloudflare-nginx</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 525 - "<html>\r\n<head><title>525 Origin SSL Handshake Error</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>525 Origin SSL Handshake Error</h1></center>\r\n<hr><center>cloudflare-nginx</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 404 - "<html>\r\n<head><title>404 Not Found</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>404 Not Found</h1></center>\r\n<hr><center>nginx/1.14.0 (Ubuntu)</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 404 - "<html>\r\n<head><title>404 Not Found</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>404 Not Found</h1></center>\r\n<hr><center>nginx/1.14.0 (Ubuntu)</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 404 - "<html>\r\n<head><title>404 Not Found</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>404 Not Found</h1></center>\r\n<hr><center>nginx/1.14.0 (Ubuntu)</center>\r\n</body>\r\n</html>\r\n"
Insight response error: StatusCodeError: 525 - "<html>\r\n<head><title>525 Origin SSL Handshake Error</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>525 Origin SSL Handshake Error</h1></center>\r\n<hr><center>cloudflare-nginx</center>\r\n</body>\r\n</html>\r\n"
bitcoin block height 581162 not found

If with the same file I try a validation on https://opentimestamps.org all works well, and the response is about the same block that not found on my machine. This is the response of https://opentimestamps.org:

Bitcoin block 581162 attests existence as of 2019-06-17 CEST

My ots-cli.js is 0.4.3 version, and I sure that my code was worked time ago. Do you have some advice to fix it? Thanks to all.

RCasatta commented 3 years ago

java and javascript are different things

https://github.com/opentimestamps/javascript-opentimestamps/issues/89