extract out gateways