fail deploy when RELP transport is combined with TLS#252
Open
dlinsley wants to merge 1 commit into
Open
Conversation
RELP has no TLS support in this release: TLS directives only affect the omfwd module (TCP/UDP), and RELP's legacy selector syntax has no TLS parameters. Previously transport: relp + tls_enabled: true rendered and deployed successfully while silently shipping logs in cleartext. Raise a template error instead, mirroring the existing UDP+TLS guard, for both the primary transport and RELP fallback servers. Also fix relp-tls.yml, which omitted syslog.address/port and so never actually exercised the relp transport.
jorbaum
approved these changes
Jul 22, 2026
jorbaum
left a comment
Contributor
There was a problem hiding this comment.
LGTM.
Nice find! Looks like this bug has been there for roughly 7 years if I looked correctly. Also nice to see you both applying a minimal fix and proposing how to add tls support in the PR description.
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
Fixes a security defect where
syslog_forwarderconfigured withtransport: relpandtls_enabled: truewould render and deploy successfully while silently shipping logs incleartext.
The
$ActionSendStreamDriver*directives emitted whentls_enabledis true only configurethe netstream driver used by the
omfwdmodule (TCP/UDP@/@@actions). They have noeffect on
omrelp, which is rendered via legacy selector syntax(
*.* :omrelp:<addr>:<port>;Template) — a syntax form with no TLS parameters at all. RELP'sown TLS stack (librelp) can only be configured via RainerScript
(
action(type="omrelp", tls="on", ...)), which this release doesn't use anywhere.This PR adds a fail-fast guard — mirroring the existing UDP+TLS guard already in the
template — so
bosh deploynow fails outright for this combination instead of quietlyrunning an insecure connection. The same guard is added for
fallback_serversentries withtransport: relp, which had the identical hole.Also fixes
tests/manifests/relp-tls.yml, which omittedsyslog.address/syslog.portandtherefore never actually exercised the
relptransport (it silently fell back to thestorer link's default
tcp) — meaning the RELP+TLS combination was previously untestedentirely.
Real RELP TLS support (converting the RELP forwarding rule to RainerScript, wiring cert
properties, reworking fallback-server chaining) is intentionally out of scope for this fix;
it's a larger feature-level change that isn't required to close this security exposure.
Can be introduced in future PR.
Type of change
Note: this is technically breaking for anyone currently (mis)configured with
transport: relp+tls_enabled: true— their next deploy will now fail instead ofsilently running in cleartext. That's the intended outcome.
Testing performed?
tests/acceptance_test.go's "when TLS is configured over relp" context now asserts thatbosh deployfails (mirroring the existingbroken-rules.ymlinvalid-config test) insteadof asserting successful log forwarding.
Checklist:
mainbranch, or relevant version branchIf you have any questions, or want to get attention for a PR or issue please reach out on the #logging-and-metrics channel in the cloudfoundry slack