Only attach floating IPs to instances that belong to the cluster
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 72/100
Direzione di ricerca
Read internal/provider/load_balancer.go and internal/provider/instances_v2.go, starting with EnsureLoadBalancer, UpdateLoadBalancer, and getInstance. Trace how the configured project and node identity are available when checking the ProviderID instance. Done when out-of-project or node-mismatched instances cannot receive floating IPs, and the ProviderID lookup rejects instances outside the configured project.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Context
EnsureLoadBalancer and UpdateLoadBalancer (internal/provider/load_balancer.go) pick the first node by name and pass the instance ID from its Spec.ProviderID straight to FloatingIpAttach. Nothing checks that the instance belongs to the cluster. Anyone who can register a Node with a name that sorts first can point every LoadBalancer floating IP at an instance of their choosing.
Nexus already rejects attaching a floating IP to an instance in another project, so the reachable targets are other instances in the CCM's project.
getInstance (internal/provider/instances_v2.go) has a related gap. When a node has a ProviderID, it looks up the instance by ID without a project. That means InstanceExists, InstanceShutdown, and InstanceMetadata accept an instance from any project the token can see.
Scope
- Before attaching a floating IP, confirm the target instance is in the configured project and corresponds to the node, for example by checking that the instance name matches the node name.
- In
getInstance, check the instance's project against the configured project on the ProviderID path too.
Done when
A node whose ProviderID points at an instance outside the configured project, or at an instance that doesn't match the node, never receives a floating IP and isn't reported as existing.
- Lingua principale
- Go
- Stelle
- 6
- Fork
- 2
- Merge medio
- 2h 47m
- PR unite (30g)
- 6
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di oxidecomputer/oxide-cloud-controller-manager
-
Kubernetes Cloud Controller Manager (CCM)
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
Kubernetes Cloud Controller Manager (CCM)
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
Documentation Kubernetes Cloud Controller Manager (CCM)
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
-
Documentation Kubernetes Cloud Controller Manager (CCM)
Difficoltà 2/5 1-3 ore Idoneità per principianti 90/100
-
Bug Kubernetes Cloud Controller Manager (CCM)
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
Tutte le issue di oxidecomputer/oxide-cloud-controller-manager
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
hivecommons/hive#19912 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
siyuan-note/siyuan#21692 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
rudderlabs/rudder-server#7641 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
pkgmanager: getCratesLatest panics with index out of range on 404 or empty crates.io responsesAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
ossf/package-analysis#1222 ·
I maintainer di solito rispondono entro 1 giorno