

def rule_create(request, **kwargs):
    'Create a firewall rule\n\n    :param request: request context\n    :param name: name for rule\n    :param description: description for rule\n    :param protocol: protocol for rule\n    :param action: action for rule\n    :param source_ip_address: source IP address or subnet\n    :param source_port: integer in [1, 65535] or range in a:b\n    :param destination_ip_address: destination IP address or subnet\n    :param destination_port: integer in [1, 65535] or range in a:b\n    :param shared: boolean (default false)\n    :param enabled: boolean (default true)\n    :return: Rule object\n    '
    body = {
        'firewall_rule': kwargs,
    }
    rule = neutronclient(request).create_firewall_rule(body).get('firewall_rule')
    return Rule(rule)

dataset/ETHPy150Open openstack/horizon/openstack_dashboard/api/fwaas.py rule_create/original