blob: 880dd823d86bae0127514908b4a2e6c700d6fcb4 [file] [log] [blame]
Scott Bakerc9d3d842021-09-17 11:32:53 -07001// SPDX-FileCopyrightText: 2021 Open Networking Foundation
2//
Sean Condon160ec1d2022-02-08 12:58:25 +00003// SPDX-License-Identifier: Apache-2.0
Scott Bakerc9d3d842021-09-17 11:32:53 -07004
5module aether-subscriber {
6 namespace "http://opennetworking.org/aether/subscriber";
7 prefix sub;
8
9 import apn-profile{ prefix apn; }
10 import qos-profile{ prefix qos; }
11 import up-profile{ prefix up; }
12 import access-profile{ prefix ap; }
13
14 organization "Open Networking Foundation.";
15 contact "Scott Baker";
16 description "To generate JSON from this use command
17 pyang -f jtoxx test1.yang | python3 -m json.tool > test1.json
18 Copied from YangUIComponents project";
19
20 revision "2020-08-18" {
21 description "An Aether Subscriber";
22 reference "RFC 6087";
23 }
24
25 // User Equipment ID (UEID), Basically an IMSI range
26 // examples:
27 // 123456789??????? ... wildcard at the end
28 // 123456???0123455 ... wildcard in the middle
29 // 1234567890000000-123456789000005 ... range
30 typedef ueid {
31 type string {
32 length 1..31;
33 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +000034 description "The typedef for ueid";
Scott Bakerc9d3d842021-09-17 11:32:53 -070035 }
36
37 typedef mcc {
38 type uint32 {
39 range 0..999;
40 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +000041 description "The typedef for mcc";
Scott Bakerc9d3d842021-09-17 11:32:53 -070042 }
43
44 typedef mnc {
45 type uint32 {
46 range 0..999;
47 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +000048 description "The typedef for mnc";
Scott Bakerc9d3d842021-09-17 11:32:53 -070049 }
50
51 typedef tac {
52 type uint32 {
53 range 0..99999999;
54 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +000055 description "The typedef for tac";
Scott Bakerc9d3d842021-09-17 11:32:53 -070056 }
57
58 container subscriber {
59 description "The top level container";
60
61 list ue {
62 key "ueid";
63 description
64 "List of subscriber devices";
65
66 leaf ueid {
PUSHP RAJba2e32f2021-11-02 10:39:24 +000067 type ueid;
Scott Bakerc9d3d842021-09-17 11:32:53 -070068 description "identifier for this subscriber, may or may not be an IMSI";
Scott Bakerc9d3d842021-09-17 11:32:53 -070069 }
70
71 container serving-plmn {
72 leaf mcc {
73 type mcc;
74 description "mobile country code";
75 }
76 leaf mnc {
77 type mnc;
78 description "mobile network code";
79 }
80 leaf tac {
81 type tac;
82 description "type allocation code";
83 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +000084 description "The contaiber for serving-plmn";
Scott Bakerc9d3d842021-09-17 11:32:53 -070085 }
86
87 leaf requested-apn {
88 type string {
89 length 1..31;
90 }
91 description "requested access point name";
92 }
93
94 leaf priority {
95 type uint32 {
96 range 0..1000;
97 }
98 default 0;
99 description
100 "Priority for this subscriber range";
101 }
102
103 leaf enabled {
104 type boolean;
105 default false;
106 description
107 "Enable or disable this ue";
108 }
109
110 container profiles {
111 leaf apn-profile {
112 type leafref {
113 path "/apn:apn-profile/apn:apn-profile/apn:id";
114 }
115 description
116 "Link to apn profile";
117 }
118 leaf up-profile {
119 type leafref {
120 path "/up:up-profile/up:up-profile/up:id";
PUSHP RAJba2e32f2021-11-02 10:39:24 +0000121 }
Scott Bakerc9d3d842021-09-17 11:32:53 -0700122 description
123 "Link to user plane profile";
124 }
125 leaf qos-profile {
126 type leafref {
127 path "/qos:qos-profile/qos:qos-profile/qos:id";
PUSHP RAJba2e32f2021-11-02 10:39:24 +0000128 }
Scott Bakerc9d3d842021-09-17 11:32:53 -0700129 description
130 "Link to qos profile";
131 }
132 list access-profile {
133 key "access-profile";
134 leaf access-profile {
135 type leafref {
136 path "/ap:access-profile/ap:access-profile/ap:id";
PUSHP RAJba2e32f2021-11-02 10:39:24 +0000137 }
Scott Bakerc9d3d842021-09-17 11:32:53 -0700138// type ap:access-profile-id;
139 description
140 "Link to access profile";
141 }
142 leaf allowed {
143 type boolean;
144 default true;
145 description
146 "Allow or disallow this ue to use this access profile";
147 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +0000148 description "The list for access-profile";
Scott Bakerc9d3d842021-09-17 11:32:53 -0700149 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +0000150 description "The container for profiles";
Scott Bakerc9d3d842021-09-17 11:32:53 -0700151 }
152 }
PUSHP RAJba2e32f2021-11-02 10:39:24 +0000153 }
Scott Bakerc9d3d842021-09-17 11:32:53 -0700154}