1. AWS/Openstack Security Group 및 'Source/Destination Check' / 'Port Security 소개

AWS(Nitro 이전 세대) 와 Openstack 에서 동작하는 가상서버(EC2, Instance)의 네트워크보안을 위하여

Hypervisor(=Xen, KVM) 에서 제공하는 Security Group(=iptables) 와 'Source/Destination Check' / 'Port Security'(=ebtables) 를 사용하게 된다

'Source/Destination Check' / 'Port Security' 의 기능은 해당하는 vNIC(가상서버의 eth0과 1:1 맵핑)에 지정된 IP와 지정된 MAC 통신만을 허용한다.

(1) AWS 'Source/Destination Check' OpenStack 'Port Security'

AWS 'Source/Destination Check' : 기본적으로 Enable 되어 있어서 지정된 IP/MAC 만 허용한다, 필요 시 아래처럼 Disable 할 수 있다

AWS 도 ebtables 를 사용하여 해당 기능을 동작 하는 것으로 보인다

OpenStack 'Port Security'(=ebtables) : 기본적으로 Enable 되어 있어서 지정된 IP/MAC 만 허용한다, 필요 시 아래처럼 Disable 할 수 있다

Openstack의 물리서버에서 ebtables 로 확인 시 아래 처럼 vnic(tap##)에 할당된 IP(10.0.0.50)만 ARP를 허용(ACCEPT)하는 걸 알 수 있다

예를 들면 vnic(=eth0)에 1개의IP 가 아닌 여러개의 IP를 할당 했을 때는 ebtables 확인하면 여러개의 ARP를 허용하는 걸 알 수 있다

# 해당 포트에 여러개의 IP가 허용될수 있게 포트정보를 업데이트(=set)하자
openstack port set --allowed-address ip-address='추가할IP' '포트이름'
openstack port set --allowed-address ip-address=10.0.0.51 testport1
openstack port set --allowed-address ip-address=10.0.0.52 testport1
openstack port set --allowed-address ip-address=10.0.0.53 testport1

(2) AWS/Openstack Security Group

AWS Security Group 은 IP/Port 기반의 허용/차단을 하는 네트워크 보안 기능을 제공한다 (inbound/outbound)

Openstack Security Group 역시 동일한 IP/Port 기반의 허용/차단 기능을 제공한다 (Ingress/Egress)

(3) EC2/Instance OS 내부의 iptables