Git Product home page Git Product logo

Comments (8)

MarcoFalke avatar MarcoFalke commented on May 23, 2024

If it works with curl, but not with rust, then the problem seems to be in the rust code?

from packaging.

kylezs avatar kylezs commented on May 23, 2024

It works with every other bitcoin node I've tried it against.

from packaging.

MarcoFalke avatar MarcoFalke commented on May 23, 2024

Ok, I may take a look if you provide exact steps to reproduce on localhost.

from packaging.

ahasna avatar ahasna commented on May 23, 2024

After some debugging we noticed that the setup we have in which the bitcoin node is sitting behind a reverse proxy was the issue. We don't exactly know yet why but it looks like the reverse proxy is changing the request which results in it being invalid hence the HTTP 400 error.
Bypassing the reverse proxy and communicating directly with the bitcoin server worked.
However, it is still a mystery how sending the same request using curl through the reverse proxy works.

For context this is the request we used to test:

curl --user username:password -H 'Content-Type: application/json;' -d '{"jsonrpc":"2.0", "id": "1", "method": "getbestblockhash", "params" : []}' https://my-btc-node.mydomain.abc

from packaging.

fanquake avatar fanquake commented on May 23, 2024

Closing for now then. Discussion can continue / it can be re-opened if it's established that there is a bug in Bitcoin Core.

Also, looking at that crate, I assume the README is outdated, as it claims to only support end-of-life versions of Core: https://github.com/rust-bitcoin/rust-bitcoincore-rpc/#supported-bitcoin-core-versions ?

from packaging.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.