f5-appsvcs-extension icon indicating copy to clipboard operation
f5-appsvcs-extension copied to clipboard

sourceAddress is combination with Service_Address / Net_Address_List failing

Open c4lcifer opened this issue 1 year ago • 0 comments

Environment

  • Application Services Version: 3.51.0
  • BIG-IP Version: 17.1.1.3

Summary

Declaration failes when using an SourceAddress together with an Service_Address

Steps To Reproduce

Steps to reproduce the behavior:

  1. Submit the following declaration:
{
    "class": "AS3",
    "$schema": "https://raw.githubusercontent.com/F5Networks/f5-appsvcs-extension/master/schema/latest/as3-schema.json",
    "action": "deploy",
    "declaration": {
        "class": "ADC",
        "schemaVersion": "3.12.0",
        "testing_ra_source_2": {
            "class": "Tenant",
            "virtual_ip_2_app": {
                "class": "Application",
                "template": "generic",
                "VA_10_0_0_4": {
                    "class": "Service_Address",
                    "virtualAddress": "10.0.0.4",
                    "trafficGroup": "/Common/traffic-group-1",
                    "routeAdvertisement": "always"
                },
                "virtual_ip": {
                    "class": "Service_HTTP",
                    "virtualAddresses": [
                        {
                            "use": "VA_10_0_0_4"
                        }
                    ],
                    "virtualPort": 80,
                    "persistenceMethods": [],
                    "shareAddresses": true,
                    "sourceAddress": {
                        "use": "vaddress_list_1"
                    },
                    "template": "generic"
                },
                "vaddress_list_1": {
                    "class": "Net_Address_List",
                    "addresses": [
                        "192.168.3.0/24",
                        "192.168.4.0/24"
                    ]
                }
            }
        }
    }
}
  1. Observe the following error response:
{
    "id": "d571ab4e-f486-4e5e-8c8e-e65689d937fc",
    "results": [
        {
            "code": 422,
            "message": "declaration failed",
            "response": "0107176c:3: Invalid Virtual Address, the IP address 10.0.0.4 already exists.",
            "host": "localhost",
            "tenant": "testing_ra_source_2",
            "runTime": 1364,
            "declarationId": "autogen_0f792ce2-747f-4523-9ffd-da5e7b07882d"
        }
    ],
    "declaration": {
        "class": "ADC",
        "schemaVersion": "3.12.0",
        "id": "autogen_0f792ce2-747f-4523-9ffd-da5e7b07882d",
        "updateMode": "selective",
        "controls": {
            "archiveTimestamp": "2024-11-13T15:11:40.422Z"
        }
    }
}

Expected Behavior

Declaration should be successful

Actual Behavior

The BIGIP throws an error stating, that the IP address already exists, even though it doesnt. When you leave our the Source_address, the declaration works just fine:

{
    "class": "AS3",
    "$schema": "https://raw.githubusercontent.com/F5Networks/f5-appsvcs-extension/master/schema/latest/as3-schema.json",
    "action": "deploy",
    "declaration": {
        "class": "ADC",
        "schemaVersion": "3.12.0",
        "testing_ra_source_2": {
            "class": "Tenant",
            "virtual_ip_2_app": {
                "class": "Application",
                "template": "generic",
                "VA_10_0_0_4": {
                    "class": "Service_Address",
                    "virtualAddress": "10.0.0.4",
                    "trafficGroup": "/Common/traffic-group-1",
                    "routeAdvertisement": "always"
                },
                "virtual_ip": {
                    "class": "Service_HTTP",
                    "virtualAddresses": [
                        {
                            "use": "VA_10_0_0_4"
                        }
                    ],
                    "virtualPort": 80,
                    "persistenceMethods": [],
                    "shareAddresses": true,
                    "template": "generic"
                },
                "vaddress_list_1": {
                    "class": "Net_Address_List",
                    "addresses": [
                        "192.168.3.0/24",
                        "192.168.4.0/24"
                    ]
                }
            }
        }
    }
}

Response:

{
    "id": "e282b220-52cb-47db-8926-baff4a7863ed",
    "results": [
        {
            "code": 200,
            "message": "success",
            "lineCount": 23,
            "host": "localhost",
            "tenant": "testing_ra_source_2",
            "runTime": 1125,
            "declarationId": "autogen_92be22d8-66a5-4a80-9109-2411e5856f68"
        }
    ],
    "declaration": {
        "class": "ADC",
        "schemaVersion": "3.12.0",
        "testing_ra_source_2": {
            "class": "Tenant",
            "virtual_ip_2_app": {
                "class": "Application",
                "template": "generic",
                "VA_10_0_0_4": {
                    "class": "Service_Address",
                    "virtualAddress": "10.0.0.4",
                    "trafficGroup": "/Common/traffic-group-1",
                    "routeAdvertisement": "always"
                },
                "virtual_ip": {
                    "class": "Service_HTTP",
                    "virtualAddresses": [
                        {
                            "use": "VA_10_0_0_4"
                        }
                    ],
                    "virtualPort": 80,
                    "persistenceMethods": [],
                    "shareAddresses": true,
                    "template": "generic"
                },
                "vaddress_list_1": {
                    "class": "Net_Address_List",
                    "addresses": [
                        "192.168.3.0/24",
                        "192.168.4.0/24"
                    ]
                }
            }
        },
        "id": "autogen_92be22d8-66a5-4a80-9109-2411e5856f68",
        "updateMode": "selective",
        "controls": {
            "archiveTimestamp": "2024-11-13T15:14:24.943Z"
        }
    }
}

c4lcifer avatar Nov 13 '24 15:11 c4lcifer