Egress: explicit TCP rules for named in-cluster services (databases, brokers)

Đang mở
#3,243 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
go, kubernetes
Lĩnh vực
backend, networking

Hướng nghiên cứu

Start with docs/egress-traffic.md and trace the actor TCP egress path through the Envoy dataplane and egress gateway. Identify where hostname and port rules are configured and how destinations are resolved; the issue proposes forwarding raw TCP bytes and limiting destinations to Service IPs or an operator CIDR allowlist. Done means explicit rules support named TCP destinations and ports without inspecting the connection.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

area/api area/network kind/feature

Use case

We run test workloads as actors. The tests need backing services such as PostgreSQL and a Kafka-compatible broker. docs/egress-traffic.md asks for an issue with the use case for blocked egress traffic, so here it is.

Today actor TCP egress is redirected to atunnel. The egress gateway supports HTTP/1.1, h2c, intercepted HTTPS and TLS passthrough. Any other TCP connection is accepted and then closed with no bytes. A PostgreSQL SSLRequest sent to a cluster Service through the gateway gets an HTTP 400 back.

So these services must run as extra containers inside the actor. Then all containers share one loopback, and ports collide between the services and the code under test. We hit this with two services that both bind the same admin port.

Request

An explicit TCP rule, for example:

rules:
- tcp:
    hostnames: [postgres.my-namespace.svc.cluster.local]
    ports: {numbers: [5432]}
  • The gateway forwards the bytes without inspecting them. It decides once per connection, on the resolved name and port, so server-first protocols (PostgreSQL, MySQL, SSH) work.
  • An operator can limit these rules to destinations that resolve to cluster Service IPs, or to a configured CIDR allowlist.

This differs from #1341: it does not sniff and does not pass unknown traffic through. A port carries TCP only when a rule names that port.

Tested on v0.6.0, Envoy dataplane, GKE 1.36.

Ngôn ngữ chính
Go
Star
6.1k
Fork
676
Merge trung bình
2 ngày 2 giờ
Pull request đã merge (30 ngày)
528

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của agent-substrate/substrate

Tất cả issue của agent-substrate/substrate

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.