'Callback method to return security group rules for each port.
also convert remote_group_id rule
to source_ip_prefix and dest_ip_prefix rule
:params devices: list of devices
:returns: port correspond to the devices with security group rules'

def security_group_rules_for_devices(self, context, **kwargs):

    devices_info = kwargs.get('devices')
    ports = self._get_devices_info(context, devices_info)
    return self.plugin.security_group_rules_for_ports(context, ports)
