gRPC: Enable HTTP endpoint with TLS support - #6668
Draft
carbolymer wants to merge 2 commits into
Draft
Conversation
Parse the new RpcEndpoint sum type from node configuration (RpcListenAddress/RpcListenPort) and CLI (--grpc-listen-address/ --grpc-listen-port). A configured listen port makes the gRPC server listen on plaintext TCP instead of the unix socket; configuring both a socket path and a listen port is rejected at configuration parse time. The listen address defaults to 127.0.0.1.
Add RpcTlsCertificateFile/RpcTlsPrivateKeyFile/RpcTlsChainCertificateFiles configuration keys and --grpc-tls-certificate/--grpc-tls-private-key/ --grpc-tls-chain-certificate CLI flags. Certificate and private key must be configured together and require a TCP listen port; violations are rejected at configuration parse time.
carbolymer
force-pushed
the
mgalazyn/feature/enable-rpc-http
branch
from
August 28, 2026 16:16
700ac67 to
299f4a9
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds configuration for the node's gRPC server to listen over HTTP/2 instead of only a unix socket, in plaintext (h2c) or with TLS.
--grpc-listen-address/--grpc-listen-port(config keysRpcListenAddress/RpcListenPort) switch the server from the unix socket to HTTP/2.The listen address accepts an IPv4 or IPv6 address and defaults to
127.0.0.1.--grpc-tls-certificate/--grpc-tls-private-key/--grpc-tls-chain-certificate(config keysRpcTlsCertificateFile/RpcTlsPrivateKeyFile/RpcTlsChainCertificateFiles) switch the HTTP/2 endpoint to TLS.For example, a unix socket path together with a listen port, or a TLS private key without a certificate.
RPC.ServerListeningtrace announces the endpoint the gRPC server is listening on at startup.Also fixes
--portand the tracer socket CLI options.They previously parsed port numbers with a plain
Int/Word16readand silently wrapped out-of-range values, for example70000became4464.They now reject out-of-range and non-decimal input.
This depends on the
RpcEndpoint/RpcTlsFilestypes added in IntersectMBO/cardano-api#1322, which is not yet merged or released to CHaP.The
cardano-rpcbound incardano-node.cabalis still^>= 11.2and needs bumping to^>= 11.3once that release lands.CI will stay red until then.
Checklist
See Running tests for more details
CHANGELOG.mdfor affected packagecardano-node-chairman,cardano-submit-apiandcardano-testnetinstead need achangelog fragment in
<package>/.changes/, because theirCHANGELOG.mdis generatedfrom fragments at release time. Copy
_TEMPLATE.ymlfrom that directory, or runnix run github:input-output-hk/cardano-dev#herald -- new.cabalfiles are updatedhlint. See.github/workflows/check-hlint.ymlto get thehlintversionstylish-haskell. See.github/workflows/stylish-haskell.ymlto get thestylish-haskellversionghc-9.6andghc-9.12Note on CI
If your PR is from a fork, the necessary CI jobs won't trigger automatically for security reasons.
You will need to get someone with write privileges. Please contact IOG node developers to do this
for you.