summaryrefslogtreecommitdiffstats
path: root/nat/nat-api/src/main/yang/vpp-nat@2017-08-04.yang
blob: b0f7ea3816b69445171fd58c8e4155ebe6db7a5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
module vpp-nat {
  yang-version 1;
  namespace "urn:opendaylight:params:xml:ns:yang:vpp:nat";
  prefix "vpp-nat";

  import ietf-nat {
    prefix "nat";
  }
  import yang-ext {
    prefix "ext";
  }

  description "Augmentations to ietf-nat model providing vpp specific attributes.";

  revision "2017-08-04" {
    description "Initial revision of vpp-nat model.";
  }

  typedef nat-pool-type {
    type enumeration {
      enum "nat44";
      enum "nat64";
    }
  }

  grouping external-ip-address-pool-vpp-attributes {
    leaf pool-type {
      type nat-pool-type;
      description
        "Indicates whether the pool is designated to be used for nat44 or nat64.";
      reference
        "https://git.fd.io/vpp/tree/src/plugins/nat/nat.api";
    }
  }

  augment /nat:nat-config/nat:nat-instances/nat:nat-instance/nat:external-ip-address-pool {
    ext:augment-identifier "external-ip-address-pool-config-augmentation";

    uses external-ip-address-pool-vpp-attributes;
  }

  augment /nat:nat-state/nat:nat-instances/nat:nat-instance/nat:nat-current-config/nat:external-ip-address-pool {
    ext:augment-identifier "external-ip-address-pool-state-augmentation";

    uses external-ip-address-pool-vpp-attributes;
  }
}