-
Notifications
You must be signed in to change notification settings - Fork 20.6k
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
WSS not working #16423
Comments
You need to use a proxy like Nginx to configure the SSL certificates needed to setup WSS. |
@suspended is right. We don't offer secure WebSocket because that would require configuration of certificates. |
ashishb
added a commit
to celo-org/celo-monorepo
that referenced
this issue
Sep 18, 2019
I was trying to use infura-like setup with `ws` (Web sockets). Since `ws` sends plain-text, it does not work in prouduction. We cannot use `wss` since it is not supported natively by geth - ethereum/go-ethereum#16423 Even K8s only supports https. To avoid this issue, I shifted to https. Subscriptions don't work with https, so, a crude polling mechanism to check for transaction confirmations. Also, in this commit, change the nonce count to include "pending" transactions, so that, multiple transactions can be sent without waiting for completion.
ashishb
added a commit
to celo-org/celo-monorepo
that referenced
this issue
Sep 27, 2019
I was trying to use infura-like setup with `ws` (Web sockets). Since `ws` sends plain-text, it does not work in prouduction. We cannot use `wss` since it is not supported natively by geth - ethereum/go-ethereum#16423 Even K8s only supports https. To avoid this issue, I shifted to https. Subscriptions don't work with https, so, a crude polling mechanism to check for transaction confirmations. Also, in this commit, change the nonce count to include "pending" transactions, so that, multiple transactions can be sent without waiting for completion.
ashishb
added a commit
to celo-org/celo-monorepo
that referenced
this issue
Oct 1, 2019
* Remove private key from logging * Make infura setup work with https I was trying to use infura-like setup with `ws` (Web sockets). Since `ws` sends plain-text, it does not work in prouduction. We cannot use `wss` since it is not supported natively by geth - ethereum/go-ethereum#16423 Even K8s only supports https. To avoid this issue, I shifted to https. Subscriptions don't work with https, so, a crude polling mechanism to check for transaction confirmations. Also, in this commit, change the nonce count to include "pending" transactions, so that, multiple transactions can be sent without waiting for completion. * Handle nonce related to simultaneous transactions Handle the case when too many transactions are sent close to each other. Geth has `web3.eth.getTransactionCount(account, 'pending')` but even that only seems to work once the transactions have made to the transaction pool. Therefore, for transactions sent too close to each other, which is the case for SMS verification transactions, maintain a local nonce and ensure that new Nonce is equal or greater than local nonce. * Increment nonce before sending transaction Otherwise, the next transaction might not get the right nonce. * Fix some issues pointed by Rossy * Remove artifical wait
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm able to geth a ws server running with the following command:
geth --rpc --ws --wsaddr="0.0.0.0" --wsorigins "*"
And I'm able to properly connect to
ws://IP_ADDRESS:8546
But I'm unable to connect to a secure websocket
wss://IP_ADDRESS:8546
System information
Geth version:
1.8.2-stable-b8b9f7f4
OS & Version: Ubuntu
Expected behaviour
should properly connect to wss endpoint
Actual behaviour
receive
(Opcode -1)
when trying to connect to wss endpointThe text was updated successfully, but these errors were encountered: