Skip to content
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

policy: use TLS/TCP filters from proxy API response #3377

Merged
merged 3 commits into from
Nov 21, 2024

Conversation

zaharidichev
Copy link
Member

@zaharidichev zaharidichev commented Nov 21, 2024

This PR updates the proxy API dependency to a new version that uses filters to express errors for TLS and TCP routes.

This PR depends on linkerd/linkerd2-proxy-api#405

Signed-off-by: Zahari Dichev zaharidichev@gmail.com

Signed-off-by: Zahari Dichev <zaharidichev@gmail.com>
@zaharidichev zaharidichev requested a review from a team as a code owner November 21, 2024 15:04
Signed-off-by: Zahari Dichev <zaharidichev@gmail.com>
Comment on lines -13 to 18
tls::Filter::ForbiddenRoute => {
tls::Filter::Forbidden => {
return Err(errors::TLSForbiddenRoute.into());
}

tls::Filter::InvalidBackend(message) => {
tls::Filter::Invalid(message) => {
return Err(errors::TLSInvalidBackend(message.clone()).into());
Copy link
Member Author

Choose a reason for hiding this comment

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

We can change the name of these error types to be more generic if we want to. We currently return Invalid only if backends are invalid and Forbidden only if a route is forbidden, so this seems fine as it is for now 🤷

@olix0r olix0r enabled auto-merge (squash) November 21, 2024 19:27
@olix0r olix0r merged commit 621ea19 into main Nov 21, 2024
15 checks passed
@olix0r olix0r deleted the zd/transport-filters-api branch November 21, 2024 19:30
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.

2 participants