Skip to content

feat(fftls,ffresty,ffdns,ffnet) Networking Metrics and IP/Server Configs#218

Merged
EnriqueL8 merged 11 commits into
hyperledger-firefly:mainfrom
kaleido-io:fftls-cert-expires
Jun 24, 2026
Merged

feat(fftls,ffresty,ffdns,ffnet) Networking Metrics and IP/Server Configs#218
EnriqueL8 merged 11 commits into
hyperledger-firefly:mainfrom
kaleido-io:fftls-cert-expires

Conversation

@onelapahead

@onelapahead onelapahead commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

fftls

Like ffresty and other pacakges - a static registration of a metrics registry makes a shared metrics manager subsystem and a single metric with issuer, subject, and type labels. Where the float64 value of the gauge is the Unix timestamp of the expiry date (common pattern in Prom metrics like in FF DX metrics and Besu/Erigon timeSinceLastBlock).

ffdns

A new config and resolver builder for customizing DNS timeouts and (name)servers for lookups. With metrics if enabled (though I don't think most users want DNS metrics always on as its expensive).

ffnet

A custom Dialer with a configurable CIDR denylist for IP ranges to reject. Defaults to empty. Users can configure it to default to specific IANA IP ranges they may need to deny based on their use case (internal service-to-service client can be more permissive than a user-configurable webhooks client needing full SSRF protection).

ffresty

Builds on ffdns and ffnet to embed their configs respectively like it does fftls.

Note that previously we never prescribed netgo - letting the compile time of the runtime determine what DNS implementation is used. When ffdns (timeout, servers, or metrics) is used, netgo must be used and is therefore specified.

Signed-off-by: hfuss <hayden.fuss@kaleido.io>
…work as expected - CA bundles make metrics for all certs, leaf only the leaf w/ a key makes a metric

Signed-off-by: hfuss <hayden.fuss@kaleido.io>
@onelapahead onelapahead requested a review from a team June 9, 2026 18:56
@calbritt

Copy link
Copy Markdown
Contributor

Approved

Signed-off-by: hfuss <hayden.fuss@kaleido.io>
@onelapahead onelapahead changed the title [fftls] Metrics for CA/Client/Server Certificate Expiry [fftls] [[ffresty] Metrics for CA/Client/Server Certificate Expiry and Custom DNS Jun 14, 2026
Signed-off-by: hfuss <hayden.fuss@kaleido.io>

@EnriqueL8 EnriqueL8 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @onelapahead ! A few comments

Comment thread pkg/ffresty/config.go Outdated
Comment thread pkg/ffresty/ffresty.go Outdated
Comment thread pkg/ffresty/ffresty.go Outdated
Comment thread pkg/ffresty/ffresty.go Outdated
@onelapahead onelapahead changed the title [fftls] [[ffresty] Metrics for CA/Client/Server Certificate Expiry and Custom DNS feat(fftls,ffresty,ffdns) Metrics for CA/Client/Server Certificate Expiry and DNS Jun 19, 2026
Signed-off-by: hfuss <hayden.fuss@kaleido.io>
@onelapahead onelapahead changed the title feat(fftls,ffresty,ffdns) Metrics for CA/Client/Server Certificate Expiry and DNS feat(fftls,ffresty,ffdns,ffdns) Networking Metrics and IP/Server Configs Jun 19, 2026
Comment thread pkg/ffnet/config.go Outdated
@onelapahead onelapahead changed the title feat(fftls,ffresty,ffdns,ffdns) Networking Metrics and IP/Server Configs feat(fftls,ffresty,ffdns,ffnet) Networking Metrics and IP/Server Configs Jun 19, 2026
Signed-off-by: hfuss <hayden.fuss@kaleido.io>
Signed-off-by: hfuss <hayden.fuss@kaleido.io>
Signed-off-by: hfuss <hayden.fuss@kaleido.io>
Signed-off-by: hfuss <hayden.fuss@kaleido.io>
Comment thread pkg/ffnet/config.go Outdated
Comment thread pkg/ffnet/ffnet.go Outdated
Comment thread pkg/ffnet/ffnet_test.go Outdated
Comment thread pkg/ffnet/ffnet_test.go Outdated
Comment thread pkg/ffdns/ffdns_test.go Outdated
Comment thread pkg/ffnet/ffnet_test.go
Comment on lines +32 to +49
var testSSRDenylist = []string{
"0.0.0.0/8", // unspecified / "this host" (RFC 1122)
"127.0.0.0/8", // IPv4 loopback
"169.254.0.0/16", // IPv4 link-local, incl. cloud metadata 169.254.169.254
"10.0.0.0/8", // IPv4 private RFC1918
"172.16.0.0/12", // IPv4 private RFC1918
"192.168.0.0/16", // IPv4 private RFC1918
"100.64.0.0/10", // IPv4 CGNAT
"224.0.0.0/4", // IPv4 multicast
"240.0.0.0/4", // IPv4 reserved (incl. 255.255.255.255 broadcast)
"fc00::/7", // IPv6 ULA
"fe00::/8", // IPv6 private RFC4193
"ff00::/8", // IPv6 reserved
"::ffff:127.0.0.1/128", // IPv4-mapped IPv6 loopback
"::1/128", // IPv6 loopback
"::/0", // IPv6 unspecified
"::/128", // IPv6 unspecified
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really like this doc via UT approach 👍

@peterbroadhurst peterbroadhurst left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great - thanks for working through the iterations.

@EnriqueL8 EnriqueL8 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, some copyright updates

Comment thread pkg/ffnet/config.go Outdated
Comment thread pkg/ffnet/ffnet.go Outdated
Comment thread pkg/ffnet/ffnet_test.go Outdated
Signed-off-by: hfuss <hayden.fuss@kaleido.io>
@onelapahead onelapahead requested a review from EnriqueL8 June 23, 2026 18:45

@EnriqueL8 EnriqueL8 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks you @onelapahead !

@EnriqueL8 EnriqueL8 merged commit 7f32ddf into hyperledger-firefly:main Jun 24, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants