bbwsocktest

module
v0.0.0-...-47d40bd Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2022 License: MIT

README

Simple workaround connection to blockbook public nodes

Problem:

  • websocket error handshake

Because:

  • 403 because of cloudflare wants an User-Agent in request header
sequenceDiagram
    autonumber
    participant C as Client
    participant CF as CloudFlare
    participant BB as BlockBook Service

    C->>CF: HTTP Request With Upgrade
    CF->>CF: Check for income connection
    alt Request With User-Agent
        CF->>BB: HTTP Request With Upgrade
        activate BB
        BB->>C: Handshake ....
    else Request without User-Agent
        CF->>C: 403
    end

Solution:

  • Put User-Agent tag in the http header

How to run:

  1. make build-base
  2. make watch-wsclient

Directories

Path Synopsis
cmd
internal

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL