Neutron Default Deny Security Groups vs Admin-Controlled Floating IP Delegation
0 reputation · 16 Jul 2023, 04:22 UTC
0 reputation · 16 Jul 2023, 04:22 UTC
The objective is to prevent accidental public internet exposure of tenant instances in an OpenStack environment.
One strategy relies on Neutron's default deny-ingress security groups. While this provides a stateful safety net, it does not prevent a user from associating a floating IP or creating a permissive 0.0.0.0/0 rule, which would override the default posture.
An alternative strategy involves strict administrative control over external networks and floating IP policies. By limiting the access_as_external RBAC permission and restricting create_floatingip via oslo.policy, the cloud provider can structurally prevent tenants from exposing ports without manual approval.
The trade-off lies between tenant self-service flexibility and the risk of accidental exposure through delegated RBAC permissions.
Yes—if the goal is to eliminate accidental public exposure, restrict floating IP creation and association to administrators. Yes—oslo.policy can block non-admin floating IP actions while leaving tenant internal networking untouched.
Neutron security groups default to deny-ingress, but that firewall is enforced at the port level and remains under tenant control. A project member can create a permissive rule such as 0.0.0.0/0 and attach it to an instance. The floating IP is the actual public entry point; without it, an instance on a tenant network is unreachable from the internet regardless of security group contents.
Authorization in Neutron is driven by oslo.policy. On the neutron-server, edit policy.yaml (or policy.json on older releases) to scope the floating IP API calls:
"floatingip:create": "role:admin",
"floatingip:associate": "role:admin"
Tenants retain the ability to create networks, ports, routers, and security groups for internal use. Only the north-south bridge is gated behind administrative approval.
This guidance assumes a standard OpenStack deployment with Neutron ML2 and policy defined in policy.yaml. After changing the policy file, restart neutron-server so the rules are reloaded. To verify, attempt openstack floating ip create as a non-admin tenant user; the API should return 403 Forbidden. Then confirm that East-West traffic between instances on the same tenant network still succeeds.
Floating IP restrictions do not prevent exposure when a tenant port is attached directly to a provider network that supplies a routable public IP. If your environment uses shared or provider external networks for direct attachment, the policy above is necessary but not sufficient. Are any tenant ports attached directly to provider networks that receive public IPs without floating IPs?
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.