VNFRQTS - Updating Bulleted Requirements
[vnfrqts/requirements.git] / docs / Chapter8.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. http://creativecommons.org/licenses/by/4.0
3 .. Copyright 2017 AT&T Intellectual Property.  All rights reserved.
4
5
6 **Appendix**
7 ===============
8
9 Chef JSON Key Value Description
10 -------------------------------------
11
12 The following provides the key value pairs that must be contained in the
13 JSON file supporting Chef action.
14
15 Table A1. Chef JSON File key value description
16 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
17
18 +----------------+--------------------------+---------+----------------------+
19 | **Field Name** | **Description**          | **Type**| **Comment**          |
20 +================+==========================+=========+======================+
21 | Environment    | A JSON dictionary        | Optional|Depends on VNF action.|
22 |                | representing a Chef      |         |                      |
23 |                | Environment object. If   |         |                      |
24 |                | the VNF action requires  |         |                      |
25 |                | loading or modifying Chef|         |                      |
26 |                | environment attributes   |         |                      |
27 |                | associated with the VNF, |         |                      |
28 |                | all the relevant         |         |                      |
29 |                | information must be      |         |                      |
30 |                | provided in this JSON    |         |                      |
31 |                | dictionary in a structure|         |                      |
32 |                | that conforms to a Chef  |         |                      |
33 |                | Environment Object.      |         |                      |
34 +----------------+--------------------------+---------+----------------------+
35 | Node           | A JSON dictionary        |Mandatory|                      |
36 |                | representing a Chef Node |         |                      |
37 |                | Object.                  |         |                      |
38 |                |                          |         |                      |
39 |                | The Node JSON dictionary |         |                      |
40 |                | must include the run list|         |                      |
41 |                | to be triggered for the  |         |                      |
42 |                | desired VNF action by the|         |                      |
43 |                | push job. It should also |         |                      |
44 |                | include any attributes   |         |                      |
45 |                | that need to be          |         |                      |
46 |                | configured on the Node   |         |                      |
47 |                | Object as part of the VNF|         |                      |
48 |                | action.                  |         |                      |
49 +----------------+--------------------------+---------+----------------------+
50 | NodeList       | Array of FQDNs that      |Mandatory|                      |
51 |                | correspond to the        |         |                      |
52 |                | endpoints (VMs) of a VNF |         |                      |
53 |                | registered with the Chef |         |                      |
54 |                | Server that need to      |         |                      |
55 |                | trigger a chef-client run|         |                      |
56 |                | as part of the desired   |         |                      |
57 |                | VNF action.              |         |                      |
58 +----------------+--------------------------+---------+----------------------+
59 | PushJobFlag    | This field indicates     |Mandatory| If set to “True”,    |
60 |                | whether the VNF action   |         | ONAP will request a  |
61 |                | requires a push Job. Push|         | push job. Ignored    |
62 |                | job object will be       |         | otherwise.           |
63 |                | created by ONAP if       |         |                      |
64 |                | required.                |         |                      |
65 +----------------+--------------------------+---------+----------------------+
66 | CallbackCapable| This field indicates if  | Optional| If Chef cookbook is  |
67 |                | the chef-client run      |         | callback capable, VNF|
68 |                | invoked by push job      |         | owner is required to |
69 |                | corresponding to the VNF |         | set it to “True”.    |
70 |                | action is capable of     |         | Ignored otherwise.   |
71 |                | posting results on a     |         |                      |
72 |                | callback URL.            |         |                      |
73 +----------------+--------------------------+---------+----------------------+
74 | GetOutputFlag  | Flag which indicates     |Mandatory| ONAP will retrieve   |
75 |                | whether ONAP should      |         | output from          |
76 |                | retrieve output generated|         | NodeObject attributes|
77 |                | in a chef-client run from|         | [‘PushJobOutput’] for|
78 |                | Node object attribute    |         | all nodes in NodeList|
79 |                | node[‘PushJobOutput’] for|         | if set to “True”.    |
80 |                | this VNF action (e.g., in|         | Ignored otherwise.   |
81 |                | Audit).                  |         |                      |
82 +----------------+--------------------------+---------+----------------------+
83
84 Chef Template example:
85
86 .. code-block:: chef
87
88  “Environment”:{
89       "name": "HAR",
90       "description": "VNF Chef environment for HAR",
91       "json\_class": "Chef::Environment",
92       "chef\_type": "environment",
93       "default\_attributes": { },
94       "override\_attributes": {
95             “Retry\_Time”:”50”,
96             “MemCache”: “1024”,
97             “Database\_IP”:”10.10.1.5”
98       },
99  }
100  }
101  “Node”: {
102       “name” : “signal.network.com “
103       "chef\_type": "node",
104       "json\_class": "Chef::Node",
105       "attributes": {
106             “IPAddress1”: “192.168.1.2”,
107             “IPAddress2”:”135.16.162.5”,
108             “MyRole”:”BE”
109       },
110       "override": {},
111       "default": {},
112       “normal”:{},
113       “automatic”:{},
114       “chef\_environment” : “\_default”
115       "run\_list": [ "configure\_signal" ]
116       },
117       “NodeList”:[“node1.vnf\_a.onap.com”, “node2.vnf\_a.onap.com”],
118       “PushJobFlag”: “True”
119       “CallbackCapable”:True
120       “GetOutputFlag” : “False”
121  }
122
123 The example JSON file provided by the VNF provider for each VNF action will be
124 turned into a template by ONAP, that can be updated with instance
125 specific values at run-time.
126
127 Some points worth noting regarding the JSON fields:
128
129 a. The JSON file must be created for each action for each VNF.
130
131 b. If a VNF action involves multiple endpoints (VMs) of a VNF, ONAP will
132    replicate the “Node” JSON dictionary in the template and post it to
133    each FQDN (i.e., endpoint) in the NodeList after setting the “name”
134    field in the Node object to be the respective FQDN [1]_. Hence, it
135    is required that all end points (VMs) of a VNF involved in a VNF
136    action support the same set of Node Object attributes.
137
138 The following table describes the JSON dictionary to post in Callback.
139
140 Table A2. JSON Dictionary to Post in Callback
141 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
142
143 +--------------+----------------------------+---------+-----------------------+
144 | **Key**      | **Description**            | **Type**| **Comment**           |
145 +==============+============================+=========+=======================+
146 | RequestId    | A unique string associated |Mandatory|                       |
147 |              | with the original request  |         |                       |
148 |              | by ONAP. This key-value    |         |                       |
149 |              | pair will be provided by   |         |                       |
150 |              | ONAP in the environment of |         |                       |
151 |              | the push job request and   |         |                       |
152 |              | must be returned as part of|         |                       |
153 |              | the POST message.          |         |                       |
154 +--------------+----------------------------+---------+-----------------------+
155 | StatusCode   | An integer that must be set|Mandatory|                       |
156 |              | to 200 if chef-client run  |         |                       |
157 |              | on the node finished       |         |                       |
158 |              | successfully 500 otherwise.|         |                       |
159 +--------------+----------------------------+---------+-----------------------+
160 | StatusMessage| A string which must be set |Mandatory|                       |
161 |              | to ‘SUCCESS’ if StatusCode |         |                       |
162 |              | was 200                    |         |                       |
163 |              |                            |         |                       |
164 |              | Appropriate error message  |         |                       |
165 |              | otherwise.                 |         |                       |
166 +--------------+----------------------------+---------+-----------------------+
167 | Name         | A string which corresponds |Mandatory|                       |
168 |              | to the name of the node    |         |                       |
169 |              | where push job is run. It  |         |                       |
170 |              | is required that the value |         |                       |
171 |              | be retrieved from the node |         |                       |
172 |              | object attributes (where it|         |                       |
173 |              | is always defined).        |         |                       |
174 +--------------+----------------------------+---------+-----------------------+
175 | PushJobOutput| Any output from the        |Optional | Depends on VNF action.|
176 |              | chef-client run that needs |         | If empty, it must not |
177 |              | to be returned to ONAP.    |         | be included.          |
178 +--------------+----------------------------+---------+-----------------------+
179
180 Ansible JSON Key Value Description
181 -------------------------------------------------------------
182
183 The following provides the key value pairs that must be contained in the
184 JSON file supporting Ansible action.
185
186 Table B1. Ansible JSON File key value description
187 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
188
189 +---------------+----------------------+---------+----------------------------+
190 | **Field Name**| **Description**      | **Type**| **Comment**                |
191 +===============+======================+=========+============================+
192 | PlaybookName  | VNF providor must    |Mandatory|Currently following         |
193 |               | list name of the     |         |Ansible standard            |
194 |               | playbook relative    |         |naming, where main          |
195 |               | path used to         |         |playbook is always          |
196 |               | execute the VNF      |         |named site.yml, and         |
197 |               | action.              |         |directory name where        |
198 |               |                      |         |this main playbook resides, |
199 |               |                      |         |is named after the          |
200 |               |                      |         |command/action playbook     |
201 |               |                      |         |performs, in lower case,    |
202 |               |                      |         |example, configure.         |
203 +---------------+----------------------+---------+----------------------------+
204 | Action        | Name of VNF action.  | Optional|                            |
205 +---------------+----------------------+---------+----------------------------+
206 | EnvParameters | A JSON dictionary    | Optional|Depends on the VNF action.  |
207 |               | which should list key|         |                            |
208 |               | value pairs to be    |         |Attribute names (variable   |
209 |               | passed to the Ansible|         |names) passed to Ansible    |
210 |               | playbook. These      |         |shall follow Ansible valid  |
211 |               | values would         |         |variable names: “Variable   |
212 |               | correspond to        |         |names should be letters,    |
213 |               | instance specific    |         |numbers, and underscores.   |
214 |               | parameters that a    |         |Variables should always     |
215 |               | playbook may need to |         |start with a letter.”       |
216 |               | execute an action.   |         |                            |
217 +---------------+----------------------+---------+----------------------------+
218 | NodeList      |Ansible inventory     | Optional|If not provided, pre-loaded |
219 |               |hosts file with       |         |(VNF) inventory hosts       |
220 |               |VNF groups and        |         |file must exist in the      |
221 |               |respective IP         |         |Ansible Server otherwise    |
222 |               |addresses or DNS      |         |request fails.              |
223 |               |supported FQDNs       |         |                            |
224 |               |that the playbook must|         |                            |
225 |               |be executed against.  |         |                            |
226 +---------------+----------------------+---------+----------------------------+
227 | FileParameters| A JSON dictionary    | Optional| Depends on the VNF action  |
228 |               | where keys are       |         | and playbook design.       |
229 |               | filenames and values |         |                            |
230 |               | are contents of      |         |                            |
231 |               | files. The Ansible   |         |                            |
232 |               | Server will utilize  |         |                            |
233 |               | this feature to      |         |                            |
234 |               | generate files with  |         |                            |
235 |               | keys as filenames and|         |                            |
236 |               | values as content.   |         |                            |
237 |               | This attribute can be|         |                            |
238 |               | used to generate     |         |                            |
239 |               | files that a playbook|         |                            |
240 |               | may require as part  |         |                            |
241 |               | of execution.        |         |                            |
242 +---------------+----------------------+---------+----------------------------+
243 | Timeout       | Time (in seconds)    | Optional|                            |
244 |               | that a playbook is   |         |                            |
245 |               | expected to take to  |         |                            |
246 |               | finish execution for |         |                            |
247 |               | the VNF. If playbook |         |                            |
248 |               | execution time       |         |                            |
249 |               | exceeds this value,  |         |                            |
250 |               | Ansible Server will  |         |                            |
251 |               | terminate the        |         |                            |
252 |               | playbook process.    |         |                            |
253 +---------------+----------------------+---------+----------------------------+
254
255 Ansible JSON file example:
256
257 {
258
259       “Action”:”Configure”,
260
261       "PlaybookName": "<VNFCode>/<Version>/ansible/configure/site.yml",
262
263       "NodeList": ["test1.vnf\_b.onap.com", “test2.vnf\_b.onap.com”],
264
265       "Timeout": 60,
266
267       "EnvParameters": {"Retry": 3, "Wait": 5, “ConfigFile”:”config.txt”},
268
269       “FileParameters”:{“config.txt”:”db\_ip=10.1.1.1, sip\_timer=10000”}
270
271 }
272
273 In the above example, the Ansible Server will:
274
275 a. Process the “FileParameters” dictionary and generate a file named
276    ‘config.txt’ with contents set to the value of the ‘config.txt’ key.
277
278 b. Execute the playbook named ‘<VNFCode>/<Version>/ansible/configure/site.yml’
279    on nodes with    FQDNs test1.vnf\_b.onap.com and test2.vnf\_b.onap.com
280    respectively while providing the following key value pairs to the playbook:
281    Retry=3, Wait=5, ConfigFile=config.txt
282
283
284 c. If execution time of the playbook exceeds 60 secs (across all hosts),
285    it will be terminated.
286
287 VNF License Information Guidelines
288 ------------------------------------------------------------
289
290 This Appendix describes the metadata to be supplied for VNF licenses.
291
292 1. General Information
293
294 Table C1 defines the required and optional fields for licenses.
295
296 Table C1. Required Fields for General Information
297 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
298
299 +---------------+-----------------------------------+--------------+----------+
300 | **Field Name**| **Description**                   | **Data Type**| **Type** |
301 +===============+===================================+==============+==========+
302 | VNF Provider  | The name of the VNF provider.     | String       | Mandatory|
303 | Name          |                                   |              |          |
304 +---------------+-----------------------------------+--------------+----------+
305 | VNF Provider  | The name of the product to which  | String       | Mandatory|
306 | Product       | this agreement applies.           |              |          |
307 |               |                                   |              |          |
308 |               | Note: a contract/agreement may    |              |          |
309 |               | apply to more than one VNF        |              |          |
310 |               | provider product. In that case,   |              |          |
311 |               | provide the metadata for each     |              |          |
312 |               | product separately.               |              |          |
313 +---------------+-----------------------------------+--------------+----------+
314 | VNF Provider  | A general description of VNF      | String       | Optional |
315 | Product       | provider software product.        |              |          |
316 | Description   |                                   |              |          |
317 +---------------+-----------------------------------+--------------+----------+
318 | Export Control| ECCNs are 5-character             | String       | Mandatory|
319 | Classification| alpha-numeric designations used on|              |          |
320 | Number (ECCN) | the Commerce Control List (CCL) to|              |          |
321 |               | identify dual-use items for export|              |          |
322 |               | control purposes. An ECCN         |              |          |
323 |               | categorizes items based on the    |              |          |
324 |               | nature of the product, i.e. type  |              |          |
325 |               | of commodity, software, or        |              |          |
326 |               | technology and its respective     |              |          |
327 |               | technical parameters.             |              |          |
328 +---------------+-----------------------------------+--------------+----------+
329 | Reporting     | A list of any reporting           | List of      | Optional |
330 | Requirements  | requirements on the usage of the  | strings      |          |
331 |               | software product.                 |              |          |
332 +---------------+-----------------------------------+--------------+----------+
333
334 1. Entitlements
335
336 Entitlements describe software license use rights. The use rights may be
337 quantified by various metrics: # users, # software instances, # units.
338 The use rights may be limited by various criteria: location (physical or
339 logical), type of customer, type of device, time, etc.
340
341 One or more entitlements can be defined; each one consists of the
342 following fields:
343
344 Table C2. Required Fields for Entitlements
345 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
346
347 +---------------+-----------------------------------+-------------+-----------+
348 | **Field Name**| **Description**                   |**Data Type**| **Type**  |
349 +===============+===================================+=============+===========+
350 | VNF Provider  | Identifier for the entitlement as | String      | Mandatory |
351 | Part Number / | described by the VNF provider in  |             |           |
352 | Manufacture   | their price list / catalog /      |             |           |
353 | Reference     | contract.                         |             |           |
354 | Number        |                                   |             |           |
355 +---------------+-----------------------------------+-------------+-----------+
356 | Description   | Verbiage that describes the       | String      | Optional  |
357 |               | entitlement                       |             |           |
358 +---------------+-----------------------------------+-------------+-----------+
359 | Entitlement   | Each entitlement defined must be  | String      | Mandatory |
360 | Identifier    | identified by a unique value (e.g.|             |           |
361 |               | numbered 1, 2, 3….)               |             |           |
362 +---------------+-----------------------------------+-------------+-----------+
363 | Minimum Order | The minimum number of entitlements| Number      | Mandatory |
364 | Requirement   | that need to be purchased.        |             |           |
365 |               | For example, the entitlements must|             |           |
366 |               | be purchased in a block of 100. If|             |           |
367 |               | no minimum is required, the value |             |           |
368 |               | will be zero.                     |             |           |
369 +---------------+-----------------------------------+-------------+-----------+
370 | Unique        | A list of any reporting           | List of     | Optional  |
371 | Reporting     | requirements on the usage of the  | Strings     |           |
372 | Requirements  | software product. (e.g.: quarterly|             |           |
373 |               | usage reports are required)       |             |           |
374 +---------------+-----------------------------------+-------------+-----------+
375 | License Type  | Type of license applicable to the | String      | Mandatory |
376 |               | software product. (e.g.:          |             |           |
377 |               | fixed-term, perpetual, trial,     |             |           |
378 |               | subscription.)                    |             |           |
379 +---------------+-----------------------------------+-------------+-----------+
380 | License       | Valid values:                     | String      |Conditional|
381 | Duration      |                                   |             |           |
382 |               | **year**, **quarter**, **month**, |             |           |
383 |               | **day**.                          |             |           |
384 |               |                                   |             |           |
385 |               | Not applicable when license type  |             |           |
386 |               | is Perpetual.                     |             |           |
387 +---------------+-----------------------------------+-------------+-----------+
388 | License       | Number of years, quarters, months,| Number      |Conditional|
389 | Duration      | or days for which the license is  |             |           |
390 | Quantification| valid.                            |             |           |
391 |               |                                   |             |           |
392 |               | Not applicable when license type  |             |           |
393 |               | is Perpetual.                     |             |           |
394 +---------------+-----------------------------------+-------------+-----------+
395 | Limits        | see section C.4 for possible      | List        | Optional  |
396 |               | values                            |             |           |
397 +---------------+-----------------------------------+-------------+-----------+
398
399 1. License Keys
400
401 This section defines information on any License Keys associated with the
402 Software Product. A license key is a data string (or a file) providing a
403 means to authorize the use of software. License key does not provide
404 entitlement information.
405
406 License Keys are not required. Optionally, one or more license keys can
407 be defined; each one consists of the following fields:
408
409 Table C3. Required Fields for License Keys
410 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
411
412 +---------------+-----------------------------------+--------------+----------+
413 | **Field Name**| **Description**                   | **Data Type**| **Type** |
414 +===============+===================================+==============+==========+
415 | Description   | Verbiage that describes the       | String       | Mandatory|
416 |               | license key                       |              |          |
417 +---------------+-----------------------------------+--------------+----------+
418 | License Key   | Each license key defined must be  | String       | Mandatory|
419 | Identifier    | identified by a unique value      |              |          |
420 |               | (e.g., numbered 1, 2, 3….)        |              |          |
421 +---------------+-----------------------------------+--------------+----------+
422 | Key Function  | Lifecycle stage (e.g.,            | String       | Optional |
423 |               | Instantiation or Activation) at   |              |          |
424 |               | which the license key is applied  |              |          |
425 |               | to the software.                  |              |          |
426 +---------------+-----------------------------------+--------------+----------+
427 | License Key   | Valid values:                     | String       | Mandatory|
428 | Type          |                                   |              |          |
429 |               | **Universal, Unique**             |              |          |
430 |               |                                   |              |          |
431 |               | **Universal** - a single license  |              |          |
432 |               | key value that may be used with   |              |          |
433 |               | any number of instances of the    |              |          |
434 |               | software.                         |              |          |
435 |               |                                   |              |          |
436 |               | **Unique**- a unique license key  |              |          |
437 |               | value is required for each        |              |          |
438 |               | instance of the software.         |              |          |
439 +---------------+-----------------------------------+--------------+----------+
440 | Limits        | see section C.4 for possible      | List         | Optional |
441 |               | values                            |              |          |
442 +---------------+-----------------------------------+--------------+----------+
443
444 1. Entitlement and License Key Limits
445
446 Limitations on the use of software entitlements and license keys may be
447 based on factors such as: features enabled in the product, the allowed
448 capacity of the product, number of installations, etc... The limits may
449 generally be categorized as:
450
451 -  where (location)
452
453 -  when (time)
454
455 -  how (usages)
456
457 -  who/what (entity)
458
459 -  amount (how much)
460
461 Multiple limits may be applicable for an entitlement or license key.
462 Each limit may further be described by limit behavior, duration,
463 quantification, aggregation, aggregation interval, start date, end date,
464 and threshold.
465
466 When the limit is associated with a quantity, the quantity is relative
467 to an instance of the entitlement or license key. For example:
468
469 -  Each entitlement grants the right to 50 concurrent users. If 10
470    entitlements are purchased, the total number of concurrent users
471    permitted would be 500. In this example, the limit category is
472    **amount**, the limit type is **users**, and the limit
473    **quantification** is **50.**
474
475    Each license key may be installed on 3 devices. If 5 license keys are
476    acquired, the total number of devices allowed would be 15. In this
477    example, the limit category is **usages**, the limit type is
478    **device**, and the limit **quantification** is **3.**
479
480 1. Location
481
482 Locations may be logical or physical location (e.g., site, country). For
483 example:
484
485 -  use is allowed in Canada
486
487 Table C4. Required Fields for Location
488 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
489
490 +------------------+--------------------------------+--------------+----------+
491 | **Field Name**   | **Description**                | **Data Type**| **Type** |
492 +==================+================================+==============+==========+
493 | Limit Identifier | Each limit defined for an      | String       | Mandatory|
494 |                  | entitlement or license key must|              |          |
495 |                  | be identified by a unique value|              |          |
496 |                  | (e.g., numbered 1,2,3…)        |              |          |
497 +------------------+--------------------------------+--------------+----------+
498 | Limit Description| Verbiage describing the limit. | String       | Mandatory|
499 +------------------+--------------------------------+--------------+----------+
500 | Limit Behavior   | Description of the actions     | String       | Mandatory|
501 |                  | taken when the limit boundaries|              |          |
502 |                  | are reached.                   |              |          |
503 +------------------+--------------------------------+--------------+----------+
504 | Limit Category   | Valid value: **location**      | String       | Mandatory|
505 +------------------+--------------------------------+--------------+----------+
506 | Limit Type       | Valid values: **city, county,  | String       | Mandatory|
507 |                  | state, country, region, MSA,   |              |          |
508 |                  | BTA, CLLI**                    |              |          |
509 +------------------+--------------------------------+--------------+----------+
510 | Limit List       | List of locations where the VNF| List of      | Mandatory|
511 |                  | provider Product can be used or| String       |          |
512 |                  | needs to be restricted from use|              |          |
513 +------------------+--------------------------------+--------------+----------+
514 | Limit Set Type   | Indicates if the list is an    | String       | Mandatory|
515 |                  | inclusion or exclusion.        |              |          |
516 |                  |                                |              |          |
517 |                  | Valid Values:                  |              |          |
518 |                  |                                |              |          |
519 |                  | **Allowed**                    |              |          |
520 |                  |                                |              |          |
521 |                  | **Not allowed**                |              |          |
522 +------------------+--------------------------------+--------------+----------+
523 | Limit            | The quantity (amount) the limit| Number       | Optional |
524 | Quantification   | expresses.                     |              |          |
525 +------------------+--------------------------------+--------------+----------+
526
527 1. Time
528
529 Limit on the length of time the software may be used. For example:
530
531 -  license key valid for 1 year from activation
532
533 -  entitlement valid from 15 May 2018 thru 30 June 2020
534
535 Table C5. Required Fields for Time
536 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
537
538 +------------------+-------------------------------+--------------+-----------+
539 | **Field Name**   | **Description**               | **Data Type**| **Type**  |
540 +==================+===============================+==============+===========+
541 | Limit Identifier | Each limit defined for an     | String       | Mandatory |
542 |                  | entitlement or license key    |              |           |
543 |                  | must be identified by a unique|              |           |
544 |                  | value (e.g., numbered)        |              |           |
545 +------------------+-------------------------------+--------------+-----------+
546 | Limit Description| Verbiage describing the limit.| String       | Mandatory |
547 +------------------+-------------------------------+--------------+-----------+
548 | Limit Behavior   | Description of the actions    | String       | Mandatory |
549 |                  | taken when the limit          |              |           |
550 |                  | boundaries are reached.       |              |           |
551 |                  |                               |              |           |
552 |                  | The limit behavior may also   |              |           |
553 |                  | describe when a time limit    |              |           |
554 |                  | takes effect. (e.g., key is   |              |           |
555 |                  | valid for 1 year from date of |              |           |
556 |                  | purchase).                    |              |           |
557 +------------------+-------------------------------+--------------+-----------+
558 | Limit Category   | Valid value: **time**         | String       | Mandatory |
559 +------------------+-------------------------------+--------------+-----------+
560 | Limit Type       | Valid values:                 | String       | Mandatory |
561 |                  | **duration, date**            |              |           |
562 +------------------+-------------------------------+--------------+-----------+
563 | Limit List       | List of times for which the   | List of      | Mandatory |
564 |                  | VNF Provider Product can be   | String       |           |
565 |                  | used or needs to be restricted|              |           |
566 |                  | from use                      |              |           |
567 +------------------+-------------------------------+--------------+-----------+
568 | Duration Units   | Required when limit type is   | String       |Conditional|
569 |                  | duration. Valid values:       |              |           |
570 |                  | **perpetual, year, quarter,   |              |           |
571 |                  | month, day, minute, second,   |              |           |
572 |                  | millisecond**                 |              |           |
573 +------------------+-------------------------------+--------------+-----------+
574 | Limit            | The quantity (amount) the     | Number       | Optional  |
575 | Quantification   | limit expresses.              |              |           |
576 +------------------+-------------------------------+--------------+-----------+
577 | Start Date       | Required when limit type is   | Date         | Optional  |
578 |                  | date.                         |              |           |
579 +------------------+-------------------------------+--------------+-----------+
580 | End Date         | May be used when limit type is| Date         | Optional  |
581 |                  | date.                         |              |           |
582 +------------------+-------------------------------+--------------+-----------+
583
584 1. Usage
585
586 Limits based on how the software is used. For example:
587
588 -  use is limited to a specific sub-set of the features/capabilities the
589    software supports
590
591 -  use is limited to a certain environment (e.g., test, development,
592    production…)
593
594 -  use is limited by processor (vm, cpu, core)
595
596 -  use is limited by software release
597
598 Table C6. Required Fields for Usage
599 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
600
601 +------------------+-------------------------------+---------------+----------+
602 | **Field Name**   | **Description**               | **Data Type** | **Type** |
603 +==================+===============================+===============+==========+
604 | Limit Identifier | Each limit defined for an     | String        | Mandatory|
605 |                  | entitlement or license key    |               |          |
606 |                  | must be identified by a unique|               |          |
607 |                  | value (e.g., numbered)        |               |          |
608 +------------------+-------------------------------+---------------+----------+
609 | Limit Description| Verbiage describing the limit.| String        | Mandatory|
610 +------------------+-------------------------------+---------------+----------+
611 | Limit Behavior   | Description of the actions    | String        | Mandatory|
612 |                  | taken when the limit          |               |          |
613 |                  | boundaries are reached.       |               |          |
614 +------------------+-------------------------------+---------------+----------+
615 | Limit Category   | Valid value: **usages**       | String        | Mandatory|
616 +------------------+-------------------------------+---------------+----------+
617 | Limit Type       | Valid values: **feature,      | String        | Mandatory|
618 |                  | environment, processor,       |               |          |
619 |                  | version**                     |               |          |
620 +------------------+-------------------------------+---------------+----------+
621 | Limit List       | List of usage limits (e.g.,   | List of String| Mandatory|
622 |                  | test, development, vm, core,  |               |          |
623 |                  | R1.2.1, R1.3.5…)              |               |          |
624 +------------------+-------------------------------+---------------+----------+
625 | Limit Set Type   | Indicates if the list is an   | String        | Mandatory|
626 |                  | inclusion or exclusion.       |               |          |
627 |                  |                               |               |          |
628 |                  | Valid Values:                 |               |          |
629 |                  |                               |               |          |
630 |                  | **Allowed**                   |               |          |
631 |                  |                               |               |          |
632 |                  | **Not allowed**               |               |          |
633 +------------------+-------------------------------+---------------+----------+
634 | Limit            | The quantity (amount) the     | Number        | Optional |
635 | Quantification   | limit expresses.              |               |          |
636 +------------------+-------------------------------+---------------+----------+
637
638 1. Entity
639
640 Limit on the entity (product line, organization, customer) allowed to
641 make use of the software. For example:
642
643 -  allowed to be used in support of wireless products
644
645 -  allowed to be used only for government entities
646
647 Table C7. Required Fields for Entity
648 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
649
650 +------------------+--------------------------------+--------------+----------+
651 | **Field Name**   | **Description**                |**Data Type** | **Type** |
652 +==================+================================+==============+==========+
653 | Limit Identifier | Each limit defined for an      | String       | Mandatory|
654 |                  | entitlement or license key must|              |          |
655 |                  | be identified by a unique value|              |          |
656 |                  | (e.g., numbered)               |              |          |
657 +------------------+--------------------------------+--------------+----------+
658 | Limit Description| Verbiage describing the limit. | String       | Mandatory|
659 +------------------+--------------------------------+--------------+----------+
660 | Limit Behavior   | Description of the actions     | String       | Mandatory|
661 |                  | taken when the limit boundaries|              |          |
662 |                  | are reached.                   |              |          |
663 +------------------+--------------------------------+--------------+----------+
664 | Limit Category   | Valid value: **entity**        | String       | Mandatory|
665 +------------------+--------------------------------+--------------+----------+
666 | Limit Type       | Valid values: **product line,  | String       | Mandatory|
667 |                  | organization, internal         |              |          |
668 |                  | customer, external customer**  |              |          |
669 +------------------+--------------------------------+--------------+----------+
670 | Limit List       | List of entities for which the |List of String| Mandatory|
671 |                  | VNF Provider Product can be    |              |          |
672 |                  | used or needs to be restricted |              |          |
673 |                  | from use                       |              |          |
674 +------------------+--------------------------------+--------------+----------+
675 | Limit Set Type   | Indicates if the list is an    | String       | Mandatory|
676 |                  | inclusion or exclusion.        |              |          |
677 |                  |                                |              |          |
678 |                  | Valid Values:                  |              |          |
679 |                  |                                |              |          |
680 |                  | **Allowed**                    |              |          |
681 |                  |                                |              |          |
682 |                  | **Not allowed**                |              |          |
683 +------------------+--------------------------------+--------------+----------+
684 | Limit            | The quantity (amount) the limit| Number       | Optional |
685 | Quantification   | expresses.                     |              |          |
686 +------------------+--------------------------------+--------------+----------+
687
688 1. Amount
689
690 These limits describe terms relative to utilization of the functions of
691 the software (for example, number of named users permitted, throughput,
692 or capacity). Limits of this type may also be relative to utilization of
693 other resources (for example, a limit for firewall software is not based
694 on use of the firewall software, but on the number of network
695 subscribers).
696
697 The metadata describing this type of limit includes the unit of measure
698 (e.g., # users, # sessions, # MB, # TB, etc.), the quantity of units,
699 any aggregation function (e.g., peak or average users), and aggregation
700 interval (day, month, quarter, year, etc.).
701
702 Table C8. Required Fields for Amount
703 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
704
705 +------------------+---------------------------------+-------------+----------+
706 | **Field Name**   | **Description**                 |**Data Type**| **Type** |
707 +==================+=================================+=============+==========+
708 | Limit Identifier | Each limit defined for an       | String      | Mandatory|
709 |                  | entitlement or license key must |             |          |
710 |                  | be identified by a unique value |             |          |
711 |                  | (e.g., numbered)                |             |          |
712 +------------------+---------------------------------+-------------+----------+
713 | Limit Description| Verbiage describing the limit.  | String      | Mandatory|
714 +------------------+---------------------------------+-------------+----------+
715 | Limit Behavior   | Description of the actions taken| String      | Mandatory|
716 |                  | when the limit boundaries are   |             |          |
717 |                  | reached.                        |             |          |
718 +------------------+---------------------------------+-------------+----------+
719 | Limit Category   | Valid value: **amount**         | String      | Mandatory|
720 +------------------+---------------------------------+-------------+----------+
721 | Limit Type       | Valid values: **trunk, user,    | String      | Mandatory|
722 |                  | subscriber, session, token,     |             |          |
723 |                  | transactions, seats, KB, MB, TB,|             |          |
724 |                  | GB**                            |             |          |
725 +------------------+---------------------------------+-------------+----------+
726 | Type of          | Is the limit relative to        | String      | Mandatory|
727 | Utilization      | utilization of the functions of |             |          |
728 |                  | the software or relative to     |             |          |
729 |                  | utilization of other resources? |             |          |
730 |                  |                                 |             |          |
731 |                  | Valid values:                   |             |          |
732 |                  |                                 |             |          |
733 |                  | -  **software functions**       |             |          |
734 |                  |                                 |             |          |
735 |                  | -  **other resources**          |             |          |
736 +------------------+---------------------------------+-------------+----------+
737 | Limit            | The quantity (amount) the limit | Number      | Optional |
738 | Quantification   | expresses.                      |             |          |
739 +------------------+---------------------------------+-------------+----------+
740 | Aggregation      | Valid values: **peak, average** | String      | Optional |
741 | Function         |                                 |             |          |
742 +------------------+---------------------------------+-------------+----------+
743 | Aggregation      | Time period over which the      | String      | Optional |
744 | Interval         | aggregation is done (e.g.,      |             |          |
745 |                  | average sessions per quarter).  |             |          |
746 |                  | Required when an Aggregation    |             |          |
747 |                  | Function is specified.          |             |          |
748 |                  |                                 |             |          |
749 |                  | Valid values: **day, month,     |             |          |
750 |                  | quarter, year, minute, second,  |             |          |
751 |                  | millisecond**                   |             |          |
752 +------------------+---------------------------------+-------------+----------+
753 | Aggregation      | Is the limit quantity applicable| String      | Optional |
754 | Scope            | to a single entitlement or      |             |          |
755 |                  | license key (each separately)?  |             |          |
756 |                  | Or may the limit quantity be    |             |          |
757 |                  | combined with others of the same|             |          |
758 |                  | type (resulting in limit amount |             |          |
759 |                  | that is the sum of all the      |             |          |
760 |                  | purchased entitlements or       |             |          |
761 |                  | license keys)?                  |             |          |
762 |                  |                                 |             |          |
763 |                  | Valid values:                   |             |          |
764 |                  |                                 |             |          |
765 |                  | -  **single**                   |             |          |
766 |                  |                                 |             |          |
767 |                  | -  **combined**                 |             |          |
768 +------------------+---------------------------------+-------------+----------+
769 | Type of User     | Describes the types of users of | String      | Optional |
770 |                  | the functionality offered by the|             |          |
771 |                  | software (e.g., authorized,     |             |          |
772 |                  | named). This field is included  |             |          |
773 |                  | when Limit Type is user.        |             |          |
774 +------------------+---------------------------------+-------------+----------+
775
776 TOSCA model
777 -----------------------------
778
779 Table D1. ONAP Resource DM TOSCA/YAML constructs
780 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
781
782 Standard TOSCA/YAML definitions agreed by VNF SDK Modeling team to be used by
783 VNF vendors to create a standard VNF descriptor.
784
785 All definitions are summarized in the table below based on the agreed ONAP
786 Resource DM TOSCA/YAML constructs for Beijing. Their syntax is specified in
787 ETSI GS NFV-SOL001 stable draft for VNF-D.
788
789 +------------+------------------------------+---------------------------------+
790 | Requirement| Resource IM Info Elements    | TOSCA Constructs as per SOL001  |
791 | Number     |                              |                                 |
792 +============+==============================+=================================+
793 | R-02454    | VNFD.vnfSoftwareVersion      | For VDU.Compute -               |
794 |            |                              | tosca.artifacts.nfv.SwImage     |
795 |            |                              |                                 |
796 |            | SwImageDesc.Version          | For Virtual Storage -           |
797 |            |                              | tosca.artifacts.Deployment.Image|
798 +------------+------------------------------+---------------------------------+
799 | R-03070    | vnfExtCpd's with virtual     | tosca.nodes.nfv.VnfExtCp with a |
800 |            | NetworkInterfaceRequirements | property tosca.datatypes.nfv.\  |
801 |            | (vNIC)                       | VirtualNetworkInterface\        |
802 |            |                              | Requirements                    |
803 +------------+------------------------------+---------------------------------+
804 | R-09467    | VDU.Compute descriptor       | tosca.nodes.nfv.Vdu.Compute     |
805 +------------+------------------------------+---------------------------------+
806 | R-16065    | VDU.Compute. Configurable    | tosca.datatypes.nfv.Vnfc        |
807 |            | Properties                   | ConfigurableProperties          |
808 +------------+------------------------------+---------------------------------+
809 | R-30654    | VNFD.lifeCycleManagement     | Interface construct tosca.\     |
810 |            | Script - IFA011 LifeCycle\   | interfaces.nfv.vnf.lifecycle.Nfv|
811 |            | ManagementScript             | with a list of standard LCM     |
812 |            |                              | operations                      |
813 +------------+------------------------------+---------------------------------+
814 | R-35851    | CPD: VduCp, VnfExtCp,        | tosca.nodes.nfv.VduCp, tosca.\  |
815 |            | VnfVirtualLinkDesc, QoS      | nodes.nfv.VnfVirtualLink,       |
816 |            | Monitoring info element  -   | tosca.nodes.nfv.VnfExtCp        |
817 |            | TBD                          |                                 |
818 +------------+------------------------------+---------------------------------+
819 | R-41215    | VNFD/VDU Profile and scaling | tosca.datatypes.nfv.VduProfile  |
820 |            | aspect                       | and tosca.datatypes.nfv.\       |
821 |            |                              | ScalingAspect                   |
822 +------------+------------------------------+---------------------------------+
823 | R-66070    |  VNFD meta data              | tosca.datatypes.nfv.            |
824 |            |                              | VnfInfoModifiableAttributes -   |
825 |            |                              | metadata?                       |
826 +------------+------------------------------+---------------------------------+
827 | R-96634    | VNFD.configurableProperties  | tosca.datatypes.nfv.Vnf\        |
828 |            | describing scaling           | ConfigurableProperties,         |
829 |            | characteristics.  VNFD.\     | tosca.datatypes.nfv.ScaleInfo   |
830 |            | autoscale defines the rules  |                                 |
831 |            | for scaling based on specific|                                 |
832 |            | VNF  indications             |                                 |
833 +------------+------------------------------+---------------------------------+
834 | ?          |  VDU Virtual Storage         | tosca.nodes.nfv.Vdu.\           |
835 |            |                              | VirtualStorage                  |
836 +------------+------------------------------+---------------------------------+
837 | R-01478    | Monitoring Info Element (TBD)| tosca.capabilities.nfv.Metric - |
838 |            | - SOL001 per VNF/VDU/VLink   | type for monitoring             |
839 | R-01556    | memory-consumption,          |                                 |
840 |            | CPU-utilization,             | monitoring_parameter  of above  |
841 |            | bandwidth-consumption, VNFC  | type per VNF/VDU/VLink          |
842 |            | downtime, etc.               |                                 |
843 +------------+------------------------------+---------------------------------+
844
845
846 Table D2. TOSCA CSAR structure
847 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
848
849 This section defines the requirements around the CSAR structure.
850
851 The table below describes the numbered requirements for CSAR structure as
852 agreed with SDC. The format of the CSAR is specified in SOL004.
853
854 +------------+-------------------------------------+--------------------------+
855 | Requirement| Description                         | CSAR artifact directory  |
856 | Number     |                                     |                          |
857 +============+=====================================+==========================+
858 | R-26881    | The VNF provider MUST provide the   | ROOT\\Artifacts\         |
859 |            | binaries and images needed to       | \\VNF_Image.bin          |
860 |            | instantiate the VNF (VNF and VNFC   |                          |
861 |            | images).                            |                          |
862 +------------+-------------------------------------+--------------------------+
863 | R-30654    | VNFD.lifeCycleManagementScript that | ROOT\\Artifacts\         |
864 |            | includes a list of events and       | \\Informational\         |
865 |            | corresponding management scripts    | \\Install.csh            |
866 |            | performed for the VNF - SOL001      |                          |
867 +------------+-------------------------------------+--------------------------+
868 | R-35851    | All VNF topology related definitions| ROOT\\Definitions\       |
869 |            | in yaml files VNFD/Main Service     | \\VNFC.yaml              |
870 |            | template at the ROOT                |                          |
871 |            |                                     | ROOT\                    |
872 |            |                                     | \\MainService\           |
873 |            |                                     | \\Template.yaml          |
874 +------------+-------------------------------------+--------------------------+
875 | R-40827    | CSAR License directory - SOL004     | ROOT\\Licenses\          |
876 |            |                                     | \\License_term.txt       |
877 +------------+-------------------------------------+--------------------------+
878 | R-77707    | CSAR Manifest file - SOL004         | ROOT\                    |
879 |            |                                     | \\MainServiceTemplate.mf |
880 +------------+-------------------------------------+--------------------------+
881
882
883 Requirement List
884 --------------------------------
885
886 **VNF Development Requirements**
887 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
888
889 VNF Design
890 ~~~~~~~~~~~~~
891
892 R-58421 The VNF **SHOULD** be decomposed into granular re-usable VNFCs.
893
894 R-82223 The VNF **MUST** be decomposed if the functions have
895 significantly different scaling characteristics (e.g., signaling
896 versus media functions, control versus data plane functions).
897
898 R-16496 The VNF **MUST** enable instantiating only the functionality that
899 is needed for the decomposed VNF (e.g., if transcoding is not needed it
900 should not be instantiated).
901
902 R-02360 The VNFC **MUST** be designed as a standalone, executable process.
903
904 R-34484 The VNF **SHOULD** create a single component VNF for VNFCs
905 that can be used by other VNFs.
906
907 R-23035 The VNF **MUST** be designed to scale horizontally (more
908 instances of a VNF or VNFC) and not vertically (moving the existing
909 instances to larger VMs or increasing the resources within a VM)
910 to achieve effective utilization of cloud resources.
911
912 R-30650 The VNF **MUST** utilize cloud provided infrastructure and
913 VNFs (e.g., virtualized Local Load Balancer) as part of the VNF so
914 that the cloud can manage and provide a consistent service resiliency
915 and methods across all VNF's.
916
917 R-12709 The VNFC **SHOULD** be independently deployed, configured,
918 upgraded, scaled, monitored, and administered by ONAP.
919
920 R-37692 The VNFC **MUST** provide API versioning to allow for
921 independent upgrades of VNFC.
922
923 R-86585 The VNFC **SHOULD** minimize the use of state within
924 a VNFC to facilitate the movement of traffic from one instance
925 to another.
926
927 R-65134 The VNF **SHOULD** maintain state in a geographically
928 redundant datastore that may, in fact, be its own VNFC.
929
930 R-75850 The VNF **SHOULD** decouple persistent data from the VNFC
931 and keep it in its own datastore that can be reached by all instances
932 of the VNFC requiring the data.
933
934 R-88199 The VNF **MUST** utilize a persistent datastore service that
935 can meet the data performance/latency requirements. (For example:
936 Datastore service could be a VNFC in VNF or a DBaaS in the Cloud
937 execution environment)
938
939 R-99656 The VNF **MUST** NOT terminate stable sessions if a VNFC
940 instance fails.
941
942 R-84473 The VNF **MUST** enable DPDK in the guest OS for VNF’s requiring
943 high packets/sec performance.  High packet throughput is defined as greater
944 than 500K packets/sec.
945
946 R-54430 The VNF **MUST** use the NCSP’s supported library and compute
947 flavor that supports DPDK to optimize network efficiency if using DPDK. [5]_
948
949 R-18864 The VNF **MUST** NOT use technologies that bypass virtualization
950 layers (such as SR-IOV) unless approved by the NCSP (e.g., if necessary
951 to meet functional or performance requirements).
952
953 R-64768 The VNF **MUST** limit the size of application data packets
954 to no larger than 9000 bytes for SDN network-based tunneling when
955 guest data packets are transported between tunnel endpoints that
956 support guest logical networks.
957
958 R-74481 The VNF **MUST** NOT require the use of a dynamic routing
959 protocol unless necessary to meet functional requirements.
960
961 VNF Resiliency
962 ~~~~~~~~~~~~~~~~~~~~~~~~~
963
964 R-52499 The VNF **MUST** meet their own resiliency goals and not rely
965 on the Network Cloud.
966
967 R-42207 The VNF **MUST** design resiliency into a VNF such that the
968 resiliency deployment model (e.g., active-active) can be chosen at
969 run-time.
970
971 R-03954 The VNF **MUST** survive any single points of failure within
972 the Network Cloud (e.g., virtual NIC, VM, disk failure).
973
974 R-89010 The VNF **MUST** survive any single points of software failure
975 internal to the VNF (e.g., in memory structures, JMS message queues).
976
977 R-67709 The VNF **MUST** be designed, built and packaged to enable
978 deployment across multiple fault zones (e.g., VNFCs deployed in
979 different servers, racks, OpenStack regions, geographies) so that
980 in the event of a planned/unplanned downtime of a fault zone, the
981 overall operation/throughput of the VNF is maintained.
982
983 R-35291 The VNF **MUST** support the ability to failover a VNFC
984 automatically to other geographically redundant sites if not
985 deployed active-active to increase the overall resiliency of the VNF.
986
987 R-36843 The VNF **MUST** support the ability of the VNFC to be deployable
988 in multi-zoned cloud sites to allow for site support in the event of cloud
989 zone failure or upgrades.
990
991 R-92935 The VNF **SHOULD** minimize the propagation of state information
992 across multiple data centers to avoid cross data center traffic.
993
994 R-26371 The VNF **MUST** detect communication failure for inter VNFC
995 instance and intra/inter VNF and re-establish communication
996 automatically to maintain the VNF without manual intervention to
997 provide service continuity.
998
999 R-18725 The VNF **MUST** handle the restart of a single VNFC instance
1000 without requiring all VNFC instances to be restarted.
1001
1002 R-06668 The VNF **MUST** handle the start or restart of VNFC instances
1003 in any order with each VNFC instance establishing or re-establishing
1004 required connections or relationships with other VNFC instances and/or
1005 VNFs required to perform the VNF function/role without requiring VNFC
1006 instance(s) to be started/restarted in a particular order.
1007
1008 R-80070 The VNF **MUST** handle errors and exceptions so that they do
1009 not interrupt processing of incoming VNF requests to maintain service
1010 continuity (where the error is not directly impacting the software
1011 handling the incoming request).
1012
1013 R-32695 The VNF **MUST** provide the ability to modify the number of
1014 retries, the time between retries and the behavior/action taken after
1015 the retries have been exhausted for exception handling to allow the
1016 NCSP to control that behavior, where the interface and/or functional
1017 specification allows for altering behaviour.
1018
1019 R-48356 The VNF **MUST** fully exploit exception handling to the extent
1020 that resources (e.g., threads and memory) are released when no longer
1021 needed regardless of programming language.
1022
1023 R-67918 The VNF **MUST** handle replication race conditions both locally
1024 and geo-located in the event of a data base instance failure to maintain
1025 service continuity.
1026
1027 R-36792 The VNF **MUST** automatically retry/resubmit failed requests
1028 made by the software to its downstream system to increase the success rate.
1029
1030 R-22059 The VNF **MUST NOT** execute long running tasks (e.g., IO,
1031 database, network operations, service calls) in a critical section
1032 of code, so as to minimize blocking of other operations and increase
1033 concurrent throughput.
1034
1035 R-63473 The VNF **MUST** automatically advertise newly scaled
1036 components so there is no manual intervention required.
1037
1038 R-74712 The VNF **MUST** utilize FQDNs (and not IP address) for
1039 both Service Chaining and scaling.
1040
1041 R-41159 The VNF **MUST** deliver any and all functionality from any
1042 VNFC in the pool (where pooling is the most suitable solution). The
1043 VNFC pool member should be transparent to the client. Upstream and
1044 downstream clients should only recognize the function being performed,
1045 not the member performing it.
1046
1047 R-85959 The VNF **SHOULD** automatically enable/disable added/removed
1048 sub-components or component so there is no manual intervention required.
1049
1050 R-06885 The VNF **SHOULD** support the ability to scale down a VNFC pool
1051 without jeopardizing active sessions. Ideally, an active session should
1052 not be tied to any particular VNFC instance.
1053
1054 R-12538 The VNF **SHOULD** support load balancing and discovery
1055 mechanisms in resource pools containing VNFC instances.
1056
1057 R-98989 The VNF **SHOULD** utilize resource pooling (threads,
1058 connections, etc.) within the VNF application so that resources
1059 are not being created and destroyed resulting in resource management
1060 overhead.
1061
1062 R-55345 The VNF **SHOULD** use techniques such as “lazy loading” when
1063 initialization includes loading catalogues and/or lists which can grow
1064 over time, so that the VNF startup time does not grow at a rate
1065 proportional to that of the list.
1066
1067 R-35532 The VNF **SHOULD** release and clear all shared assets (memory,
1068 database operations, connections, locks, etc.) as soon as possible,
1069 especially before long running sync and asynchronous operations, so as
1070 to not prevent use of these assets by other entities.
1071
1072 R-77334 The VNF **MUST** allow configurations and configuration parameters
1073 to be managed under version control to ensure consistent configuration
1074 deployment, traceability and rollback.
1075
1076 R-99766 The VNF **MUST** allow configurations and configuration parameters
1077 to be managed under version control to ensure the ability to rollback to
1078 a known valid configuration.
1079
1080 R-73583 The VNF **MUST** allow changes of configuration parameters
1081 to be consumed by the VNF without requiring the VNF or its sub-components
1082 to be bounced so that the VNF availability is not effected.
1083
1084 R-21558 The VNF **SHOULD** use intelligent routing by having knowledge
1085 of multiple downstream/upstream endpoints that are exposed to it, to
1086 ensure there is no dependency on external services (such as load balancers)
1087 to switch to alternate endpoints.
1088
1089 R-08315 The VNF **SHOULD** use redundant connection pooling to connect
1090 to any backend data source that can be switched between pools in an
1091 automated/scripted fashion to ensure high availability of the connection
1092 to the data source.
1093
1094 R-27995 The VNF **SHOULD** include control loop mechanisms to notify
1095 the consumer of the VNF of their exceeding SLA thresholds so the consumer
1096 is able to control its load against the VNF.
1097
1098 R-73364 The VNF **MUST** support at least two major versions of the
1099 VNF software and/or sub-components to co-exist within production
1100 environments at any time so that upgrades can be applied across
1101 multiple systems in a staggered manner.
1102
1103 R-02454 The VNF **MUST** support the existence of multiple major/minor
1104 versions of the VNF software and/or sub-components and interfaces that
1105 support both forward and backward compatibility to be transparent to
1106 the Service Provider usage.
1107
1108 R-57855 The VNF **MUST** support hitless staggered/rolling deployments
1109 between its redundant instances to allow "soak-time/burn in/slow roll"
1110 which can enable the support of low traffic loads to validate the
1111 deployment prior to supporting full traffic loads.
1112
1113 R-64445 The VNF **MUST** support the ability of a requestor of the
1114 service to determine the version (and therefore capabilities) of the
1115 service so that Network Cloud Service Provider can understand the
1116 capabilities of the service.
1117
1118 R-56793 The VNF **MUST** test for adherence to the defined performance
1119 budgets at each layer, during each delivery cycle with delivered
1120 results, so that the performance budget is measured and the code
1121 is adjusted to meet performance budget.
1122
1123 R-77667 The VNF **MUST** test for adherence to the defined performance
1124 budget at each layer, during each delivery cycle so that the performance
1125 budget is measured and feedback is provided where the performance budget
1126 is not met.
1127
1128 R-49308 The VNF **SHOULD** test for adherence to the defined resiliency
1129 rating recommendation at each layer, during each delivery cycle with
1130 delivered results, so that the resiliency rating is measured and the
1131 code is adjusted to meet software resiliency requirements.
1132
1133 R-16039 The VNF **SHOULD** test for adherence to the defined
1134 resiliency rating recommendation at each layer, during each
1135 delivery cycle so that the resiliency rating is measured and
1136 feedback is provided where software resiliency requirements are
1137 not met.
1138
1139 R-34957 The VNF **MUST** provide a method of metrics gathering for each
1140 layer's performance to identify/document variances in the allocations so
1141 they can be addressed.
1142
1143 R-49224 The VNF **MUST** provide unique traceability of a transaction
1144 through its life cycle to ensure quick and efficient troubleshooting.
1145
1146 R-52870 The VNF **MUST** provide a method of metrics gathering
1147 and analysis to evaluate the resiliency of the software from both
1148 a granular as well as a holistic standpoint. This includes, but is
1149 not limited to thread utilization, errors, timeouts, and retries.
1150
1151 R-92571 The VNF **MUST** provide operational instrumentation such as
1152 logging, so as to facilitate quick resolution of issues with the VNF to
1153 provide service continuity.
1154
1155 R-48917 The VNF **MUST** monitor for and alert on (both sender and
1156 receiver) errant, running longer than expected and missing file transfers,
1157 so as to minimize the impact due to file transfer errors.
1158
1159 R-28168 The VNF **SHOULD** use an appropriately configured logging
1160 level that can be changed dynamically, so as to not cause performance
1161 degradation of the VNF due to excessive logging.
1162
1163 R-87352 The VNF **SHOULD** utilize Cloud health checks, when available
1164 from the Network Cloud, from inside the application through APIs to check
1165 the network connectivity, dropped packets rate, injection, and auto failover
1166 to alternate sites if needed.
1167
1168 R-16560 The VNF **SHOULD** conduct a resiliency impact assessment for all
1169 inter/intra-connectivity points in the VNF to provide an overall resiliency
1170 rating for the VNF to be incorporated into the software design and
1171 development of the VNF.
1172
1173 VNF Security
1174 ~~~~~~~~~~~~~~
1175
1176 R-23740 The VNF **MUST** accommodate the security principle of
1177 “least privilege” during development, implementation and operation.
1178 The importance of “least privilege” cannot be overstated and must be
1179 observed in all aspects of VNF development and not limited to security.
1180 This is applicable to all sections of this document.
1181
1182 R-61354 The VNF **MUST** implement access control list for OA&M
1183 services (e.g., restricting access to certain ports or applications).
1184
1185 R-85633 The VNF **MUST** implement Data Storage Encryption
1186 (database/disk encryption) for Sensitive Personal Information (SPI)
1187 and other subscriber identifiable data. Note: subscriber’s SPI/data
1188 must be encrypted at rest, and other subscriber identifiable data
1189 should be encrypted at rest. Other data protection requirements exist
1190 and should be well understood by the developer.
1191
1192 R-92207 The VNF **SHOULD** implement a mechanism for automated and
1193 frequent "system configuration (automated provisioning / closed loop)"
1194 auditing.
1195
1196 R-23882 The VNF **SHOULD** be scanned using both network scanning
1197 and application scanning security tools on all code, including underlying
1198 OS and related configuration. Scan reports shall be provided. Remediation
1199 roadmaps shall be made available for any findings.
1200
1201 R-46986 The VNF **SHOULD** have source code scanned using scanning
1202 tools (e.g., Fortify) and provide reports.
1203
1204 R-55830 The VNF **MUST** distribute all production code from NCSP
1205 internal sources only. No production code, libraries, OS images, etc.
1206 shall be distributed from publically accessible depots.
1207
1208 R-99771 The VNF **MUST** provide all code/configuration files in a
1209 "Locked down" or hardened state or with documented recommendations for
1210 such hardening. All unnecessary services will be disabled. VNF provider
1211 default credentials, community strings and other such artifacts will be
1212 removed or disclosed so that they can be modified or removed during
1213 provisioning.
1214
1215 R-19768 The VNF **SHOULD** support L3 VPNs that enable segregation of
1216 traffic by application (dropping packets not belonging to the VPN) (i.e.,
1217 AVPN, IPSec VPN for Internet routes).
1218
1219 R-33981 The VNF **SHOULD** interoperate with various access control
1220 mechanisms for the Network Cloud execution environment (e.g.,
1221 Hypervisors, containers).
1222
1223 R-40813 The VNF **SHOULD** support the use of virtual trusted platform
1224 module, hypervisor security testing and standards scanning tools.
1225
1226 R-56904 The VNF **MUST** interoperate with the ONAP (SDN) Controller so that
1227 it can dynamically modify the firewall rules, ACL rules, QoS rules, virtual
1228 routing and forwarding rules.
1229
1230 R-26586 The VNF **SHOULD** support the ability to work with aliases
1231 (e.g., gateways, proxies) to protect and encapsulate resources.
1232
1233 R-49956 The VNF **MUST** pass all access to applications (Bearer,
1234 signaling and OA&M) through various security tools and platforms from
1235 ACLs, stateful firewalls and application layer gateways depending on
1236 manner of deployment. The application is expected to function (and in
1237 some cases, interwork) with these security tools.
1238
1239 R-69649 The VNF **MUST** have all vulnerabilities patched as soon
1240 as possible. Patching shall be controlled via change control process
1241 with vulnerabilities disclosed along with mitigation recommendations.
1242
1243 R-78010 The VNF **MUST** use the NCSP’s IDAM API for Identification,
1244 authentication and access control of customer or VNF application users.
1245
1246 R-42681 The VNF **MUST** use the NCSP’s IDAM API or comply with
1247 the requirements if not using the NCSP’s IDAM API, for identification,
1248 authentication and access control of OA&M and other system level
1249 functions.
1250
1251 R-68589 The VNF **MUST**, if not using the NCSP’s IDAM API, support
1252 User-IDs and passwords to uniquely identify the user/application. VNF
1253 needs to have appropriate connectors to the Identity, Authentication
1254 and Authorization systems that enables access at OS, Database and
1255 Application levels as appropriate.
1256
1257 R-52085 The VNF **MUST**, if not using the NCSP’s IDAM API, provide
1258 the ability to support Multi-Factor Authentication (e.g., 1st factor =
1259 Software token on device (RSA SecureID); 2nd factor = User Name+Password,
1260 etc.) for the users.
1261
1262 R-98391 The VNF **MUST**, if not using the NCSP’s IDAM API, support
1263 Role-Based Access Control to permit/limit the user/application to
1264 performing specific activities.
1265
1266 R-63217 The VNF **MUST**, if not using the NCSP’s IDAM API, support
1267 logging via ONAP for a historical view of “who did what and when”.
1268
1269 R-62498 The VNF **MUST**, if not using the NCSP’s IDAM API, encrypt
1270 OA&M access (e.g., SSH, SFTP).
1271
1272 R-79107 The VNF **MUST**, if not using the NCSP’s IDAM API, enforce
1273 a configurable maximum number of Login attempts policy for the users.
1274 VNF provider must comply with "terminate idle sessions" policy.
1275 Interactive sessions must be terminated, or a secure, locking screensaver
1276 must be activated requiring authentication, after a configurable period
1277 of inactivity. The system-based inactivity timeout for the enterprise
1278 identity and access management system must also be configurable.
1279
1280 R-35144 The VNF **MUST**, if not using the NCSP’s IDAM API, comply
1281 with the NCSP’s credential management policy.
1282
1283 R-75041 The VNF **MUST**, if not using the NCSP’s IDAM API, expire
1284 passwords at regular configurable intervals.
1285
1286 R-46908 The VNF **MUST**, if not using the NCSP’s IDAM API, comply
1287 with "password complexity" policy. When passwords are used, they shall
1288 be complex and shall at least meet the following password construction
1289 requirements: (1) be a minimum configurable number of characters in
1290 length, (2) include 3 of the 4 following types of characters:
1291 upper-case alphabetic, lower-case alphabetic, numeric, and special,
1292 (3) not be the same as the UserID with which they are associated or
1293 other common strings as specified by the environment, (4) not contain
1294 repeating or sequential characters or numbers, (5) not to use special
1295 characters that may have command functions, and (6) new passwords must
1296 not contain sequences of three or more characters from the previous
1297 password.
1298
1299 R-39342 The VNF **MUST**, if not using the NCSP’s IDAM API, comply
1300 with "password changes (includes default passwords)" policy. Products
1301 will support password aging, syntax and other credential management
1302 practices on a configurable basis.
1303
1304 R-40521 The VNF **MUST**, if not using the NCSP’s IDAM API, support
1305 use of common third party authentication and authorization tools such
1306 as TACACS+, RADIUS.
1307
1308 R-41994 The VNF **MUST**, if not using the NCSP’s IDAM API, comply
1309 with "No Self-Signed Certificates" policy. Self-signed certificates
1310 must be used for encryption only, using specified and approved
1311 encryption protocols such as TLS 1.2 or higher or equivalent security
1312 protocols such as IPSec, AES.
1313
1314 R-23135 The VNF **MUST**, if not using the NCSP’s IDAM API,
1315 authenticate system to system communications where one system
1316 accesses the resources of another system, and must never conceal
1317 individual accountability.
1318
1319 R-95105 The VNF **MUST** host connectors for access to the application
1320 layer.
1321
1322 R-45496 The VNF **MUST** host connectors for access to the OS
1323 (Operating System) layer.
1324
1325 R-05470 The VNF **MUST** host connectors for access to the database layer.
1326
1327 R-99174 The VNF **MUST** comply with Individual Accountability
1328 (each person must be assigned a unique ID) when persons or non-person
1329 entities access VNFs.
1330
1331 R-42874 The VNF **MUST** comply with Least Privilege (no more
1332 privilege than required to perform job functions) when persons
1333 or non-person entities access VNFs.
1334
1335 R-71787 The VNF **MUST** comply with Segregation of Duties (access to a
1336 single layer and no developer may access production without special
1337 oversight) when persons or non-person entities access VNFs.
1338
1339 R-86261 The VNF **MUST NOT** allow VNF provider access to VNFs remotely.
1340
1341 R-49945 The VNF **MUST** authorize VNF provider access through a
1342 client application API by the client application owner and the resource
1343 owner of the VNF before provisioning authorization through Role Based
1344 Access Control (RBAC), Attribute Based Access Control (ABAC), or other
1345 policy based mechanism.
1346
1347 R-31751 The VNF **MUST** subject VNF provider access to privilege
1348 reconciliation tools to prevent access creep and ensure correct
1349 enforcement of access policies.
1350
1351 R-34552 The VNF **MUST** provide or support the Identity and Access
1352 Management (IDAM) based threat detection data for OWASP Top 10.
1353
1354 R-29301 The VNF **MUST** provide or support the Identity and Access
1355 Management (IDAM) based threat detection data for Password Attacks.
1356
1357 R-72243 The VNF **MUST** provide or support the Identity and Access
1358 Management (IDAM) based threat detection data for Phishing / SMishing.
1359
1360 R-58998 The VNF **MUST** provide or support the Identity and Access
1361 Management (IDAM) based threat detection data for Malware (Key Logger).
1362
1363 R-14025 The VNF **MUST** provide or support the Identity and Access
1364 Management (IDAM) based threat detection data for Session Hijacking.
1365
1366 R-31412 The VNF **MUST** provide or support the Identity and Access
1367 Management (IDAM) based threat detection data for XSS / CSRF.
1368
1369 R-51883 The VNF **MUST** provide or support the Identity and Access
1370 Management (IDAM) based threat detection data for Replay.
1371
1372 R-44032 The VNF **MUST** provide or support the Identity and Access
1373 Management (IDAM) based threat detection data for Man in the Middle (MITM).
1374
1375 R-58977 The VNF **MUST** provide or support the Identity and Access
1376 Management (IDAM) based threat detection data for Eavesdropping.
1377
1378 R-24825 The VNF **MUST** provide Context awareness data (device,
1379 location, time, etc.) and be able to integrate with threat detection system.
1380
1381 R-59391 The VNF provider **MUST**, where a VNF provider requires
1382 the assumption of permissions, such as root or administrator, first
1383 log in under their individual user login ID then switch to the other
1384 higher level account; or where the individual user login is infeasible,
1385 must login with an account with admin privileges in a way that
1386 uniquely identifies the individual performing the function.
1387
1388 R-85028 The VNF **MUST** authenticate system to system access and
1389 do not conceal a VNF provider user’s individual accountability for
1390 transactions.
1391
1392 R-80335 The VNF **MUST** make visible a Warning Notice: A formal
1393 statement of resource intent, i.e., a warning notice, upon initial
1394 access to a VNF provider user who accesses private internal networks
1395 or Company computer resources, e.g., upon initial logon to an internal
1396 web site, system or application which requires authentication.
1397
1398 R-73541 The VNF **MUST** use access controls for VNFs and their
1399 supporting computing systems at all times to restrict access to
1400 authorized personnel only, e.g., least privilege. These controls
1401 could include the use of system configuration or access control
1402 software.
1403
1404 R-64503 The VNF **MUST** provide minimum privileges for initial
1405 and default settings for new user accounts.
1406
1407 R-86835 The VNF **MUST** set the default settings for user access
1408 to sensitive commands and data to deny authorization.
1409
1410 R-77157 The VNF **MUST** conform to approved request, workflow
1411 authorization, and authorization provisioning requirements when
1412 creating privileged users.
1413
1414 R-81147 The VNF **MUST** have greater restrictions for access and
1415 execution, such as up to 3 factors of authentication and restricted
1416 authorization, for commands affecting network services, such as
1417 commands relating to VNFs.
1418
1419 R-49109 The VNF **MUST** encrypt TCP/IP--HTTPS (e.g., TLS v1.2)
1420 transmission of data on internal and external networks.
1421
1422 R-39562 The VNF **MUST** disable unnecessary or vulnerable cgi-bin programs.
1423
1424 R-15671 The VNF **MUST NOT** provide public or unrestricted access
1425 to any data without the permission of the data owner. All data
1426 classification and access controls must be followed.
1427
1428 R-89753 The VNF **MUST NOT** install or use systems, tools or
1429 utilities capable of capturing or logging data that was not created
1430 by them or sent specifically to them in production, without
1431 authorization of the VNF system owner.
1432
1433 R-19082 The VNF **MUST NOT** run security testing tools and
1434 programs, e.g., password cracker, port scanners, hacking tools
1435 in production, without authorization of the VNF system owner.
1436
1437 R-19790 The VNF **MUST NOT** include authentication credentials
1438 in security audit logs, even if encrypted.
1439
1440 R-85419 The VNF **SHOULD** use REST APIs exposed to Client
1441 Applications for the implementation of OAuth 2.0 Authorization
1442 Code Grant and Client Credentials Grant, as the standard interface
1443 for a VNF.
1444
1445 R-86455 The VNF **SHOULD** support hosting connectors for OS
1446 Level and Application Access.
1447
1448 R-48080 The VNF **SHOULD** support SCEP (Simple Certificate
1449 Enrollment Protocol).
1450
1451 R-37608 The VNF **MUST** provide a mechanism to restrict access based
1452 on the attributes of the VNF and the attributes of the subject.
1453
1454 R-43884 The VNF **MUST** integrate with external authentication
1455 and authorization services (e.g., IDAM).
1456
1457 R-25878 The VNF **MUST** use certificates issued from publicly
1458 recognized Certificate Authorities (CA) for the authentication process
1459 where PKI-based authentication is used.
1460
1461 R-19804 The VNF **MUST** validate the CA signature on the certificate,
1462 ensure that the date is within the validity period of the certificate,
1463 check the Certificate Revocation List (CRL), and recognize the identity
1464 represented by the certificate where PKI-based authentication is used.
1465
1466 R-47204 The VNF **MUST** protect the confidentiality and integrity of
1467 data at rest and in transit from unauthorized access and modification.
1468
1469 R-33488 The VNF **MUST** protect against all denial of service
1470 attacks, both volumetric and non-volumetric, or integrate with external
1471 denial of service protection tools.
1472
1473 R-21652 The VNF **MUST** implement the following input validation
1474 control: Check the size (length) of all input. Do not permit an amount
1475 of input so great that it would cause the VNF to fail. Where the input
1476 may be a file, the VNF API must enforce a size limit.
1477
1478 R-54930 The VNF **MUST** implement the following input validation
1479 control: Do not permit input that contains content or characters
1480 inappropriate to the input expected by the design. Inappropriate input,
1481 such as SQL insertions, may cause the system to execute undesirable
1482 and unauthorized transactions against the database or allow other
1483 inappropriate access to the internal network.
1484
1485 R-21210 The VNF **MUST** implement the following input validation
1486 control: Validate that any input file has a correct and valid
1487 Multipurpose Internet Mail Extensions (MIME) type. Input files
1488 should be tested for spoofed MIME types.
1489
1490 R-23772 The VNF **MUST** validate input at all layers implementing VNF APIs.
1491
1492 R-87135 The VNF **MUST** comply with NIST standards and industry
1493 best practices for all implementations of cryptography.
1494
1495 R-02137 The VNF **MUST** implement all monitoring and logging as
1496 described in the Security Analytics section.
1497
1498 R-15659 The VNF **MUST** restrict changing the criticality level of
1499 a system security alarm to administrator(s).
1500
1501 R-19367 The VNF **MUST** monitor API invocation patterns to detect
1502 anomalous access patterns that may represent fraudulent access or
1503 other types of attacks, or integrate with tools that implement anomaly
1504 and abuse detection.
1505
1506 R-78066 The VNF **MUST** support requests for information from law
1507 enforcement and government agencies.
1508
1509 R-48470 The VNF **MUST** support Real-time detection and
1510 notification of security events.
1511
1512 R-22286 The VNF **MUST** support Integration functionality via
1513 API/Syslog/SNMP to other functional modules in the network (e.g.,
1514 PCRF, PCEF) that enable dynamic security control by blocking the
1515 malicious traffic or malicious end users.
1516
1517 R-32636 The VNF **MUST** support API-based monitoring to take care of
1518 the scenarios where the control interfaces are not exposed, or are
1519 optimized and proprietary in nature.
1520
1521 R-61648 The VNF **MUST** support event logging, formats, and delivery
1522 tools to provide the required degree of event data to ONAP.
1523
1524 R-22367 The VNF **MUST** support detection of malformed packets due to
1525 software misconfiguration or software vulnerability.
1526
1527 R-31961 The VNF **MUST** support integrated DPI/monitoring functionality
1528 as part of VNFs (e.g., PGW, MME).
1529
1530 R-20912 The VNF **MUST** support alternative monitoring capabilities
1531 when VNFs do not expose data or control traffic or use proprietary and
1532 optimized protocols for inter VNF communication.
1533
1534 R-73223 The VNF **MUST** support proactive monitoring to detect and
1535 report the attacks on resources so that the VNFs and associated VMs can
1536 be isolated, such as detection techniques for resource exhaustion, namely
1537 OS resource attacks, CPU attacks, consumption of kernel memory, local
1538 storage attacks.
1539
1540 R-58370 The VNF **MUST** coexist and operate normally with commercial
1541 anti-virus software which shall produce alarms every time when there is a
1542 security incident.
1543
1544 R-56920 The VNF **MUST** protect all security audit logs (including
1545 API, OS and application-generated logs), security audit software, data,
1546 and associated documentation from modification, or unauthorized viewing,
1547 by standard OS access control mechanisms, by sending to a remote system,
1548 or by encryption.
1549
1550 R-54520 The VNF **MUST** log successful and unsuccessful login attempts.
1551
1552 R-55478 The VNF **MUST** log logoffs.
1553
1554 R-08598 The VNF **MUST** log successful and unsuccessful changes to
1555 a privilege level.
1556
1557 R-13344 The VNF **MUST** log starting and stopping of security
1558 logging.
1559
1560 R-07617 The VNF **MUST** log creating, removing, or changing the
1561 inherent privilege level of users.
1562
1563 R-94525 The VNF **MUST** log connections to a network listener of the
1564 resource.
1565
1566 R-31614 The VNF **MUST** log the field “event type” in the security
1567 audit logs.
1568
1569 R-97445 The VNF **MUST** log the field “date/time” in the security
1570 audit logs.
1571
1572 R-25547 The VNF **MUST** log the field “protocol” in the security audit logs.
1573
1574 R-06413 The VNF **MUST** log the field “service or program used for
1575 access” in the security audit logs.
1576
1577 R-15325 The VNF **MUST** log the field “success/failure” in the
1578 security audit logs.
1579
1580 R-89474 The VNF **MUST** log the field “Login ID” in the security audit logs.
1581
1582 R-04982 The VNF **MUST NOT** include an authentication credential,
1583 e.g., password, in the security audit logs, even if encrypted.
1584
1585 R-63330 The VNF **MUST** detect when the security audit log storage
1586 medium is approaching capacity (configurable) and issue an alarm via
1587 SMS or equivalent as to allow time for proper actions to be taken to
1588 pre-empt loss of audit data.
1589
1590 R-41252 The VNF **MUST** support the capability of online storage of
1591 security audit logs.
1592
1593 R-41825 The VNF **MUST** activate security alarms automatically when
1594 the following event is detected: configurable number of consecutive
1595 unsuccessful login attempts
1596
1597 R-43332 The VNF **MUST** activate security alarms automatically when
1598 the following event is detected: successful modification of critical
1599 system or application files
1600
1601 R-74958 The VNF **MUST** activate security alarms automatically when
1602 the following event is detected: unsuccessful attempts to gain permissions
1603 or assume the identity of another user
1604
1605 R-15884 The VNF **MUST** include the field “date” in the Security alarms
1606 (where applicable and technically feasible).
1607
1608 R-23957 The VNF **MUST** include the field “time” in the Security alarms
1609 (where applicable and technically feasible).
1610
1611 R-71842 The VNF **MUST** include the field “service or program used for
1612 access” in the Security alarms (where applicable and technically feasible).
1613
1614 R-57617 The VNF **MUST** include the field “success/failure” in the
1615 Security alarms (where applicable and technically feasible).
1616
1617 R-99730 The VNF **MUST** include the field “Login ID” in the Security
1618 alarms (where applicable and technically feasible).
1619
1620 R-29705 The VNF **MUST** restrict changing the criticality level of a
1621 system security alarm to administrator(s).
1622
1623 R-13627 The VNF **MUST** monitor API invocation patterns to detect
1624 anomalous access patterns that may represent fraudulent access or other
1625 types of attacks, or integrate with tools that implement anomaly and
1626 abuse detection.
1627
1628 R-21819 The VNF **MUST** support requests for information from law
1629 enforcement and government agencies.
1630
1631 R-56786 The VNF **MUST** implement “Closed Loop” automatic implementation
1632 (without human intervention) for Known Threats with detection rate in low
1633 false positives.
1634
1635 R-25094 The VNF **MUST** perform data capture for security functions.
1636
1637 R-04492 The VNF **MUST** generate security audit logs that must be sent
1638 to Security Analytics Tools for analysis.
1639
1640 R-19219 The VNF **MUST** provide audit logs that include user ID, dates,
1641 times for log-on and log-off, and terminal location at minimum.
1642
1643 R-30932 The VNF **MUST** provide security audit logs including records
1644 of successful and rejected system access data and other resource access
1645 attempts.
1646
1647 R-54816 The VNF **MUST** support the storage of security audit logs
1648 for agreed period of time for forensic analysis.
1649
1650 R-57271 The VNF **MUST** provide the capability of generating security
1651 audit logs by interacting with the operating system (OS) as appropriate.
1652
1653 R-84160 The VNF **MUST** have security logging for VNFs and their
1654 OSs be active from initialization. Audit logging includes automatic
1655 routines to maintain activity records and cleanup programs to ensure
1656 the integrity of the audit/logging systems.
1657
1658 R-58964 The VNF **MUST** provide the capability to restrict read
1659 and write access to data.
1660
1661 R-99112 The VNF **MUST** provide the capability to restrict access
1662 to data to specific users.
1663
1664 R-83227 The VNF **MUST** Provide the capability to encrypt data in
1665 transit on a physical or virtual network.
1666
1667 R-32641 The VNF **MUST** provide the capability to encrypt data on
1668 non-volatile memory.
1669
1670 R-13151 The VNF **SHOULD** disable the paging of the data requiring
1671 encryption, if possible, where the encryption of non-transient data is
1672 required on a device for which the operating system performs paging to
1673 virtual memory. If not possible to disable the paging of the data
1674 requiring encryption, the virtual memory should be encrypted.
1675
1676 R-93860 The VNF **MUST** provide the capability to integrate with an
1677 external encryption service.
1678
1679 R-73067 The VNF **MUST** use industry standard cryptographic algorithms
1680 and standard modes of operations when implementing cryptography.
1681
1682 R-22645 The VNF **SHOULD** use commercial algorithms only when there
1683 are no applicable governmental standards for specific cryptographic
1684 functions, e.g., public key cryptography, message digests.
1685
1686 R-12467 The VNF **MUST NOT** use the SHA, DSS, MD5, SHA-1 and
1687 Skipjack algorithms or other compromised encryption.
1688
1689 R-02170 The VNF **MUST** use, whenever possible, standard implementations
1690 of security applications, protocols, and format, e.g., S/MIME, TLS, SSH,
1691 IPSec, X.509 digital certificates for cryptographic implementations.
1692 These implementations must be purchased from reputable vendors and must
1693 not be developed in-house.
1694
1695 R-70933 The VNF **MUST** provide the ability to migrate to newer
1696 versions of cryptographic algorithms and protocols with no impact.
1697
1698 R-44723 The VNF **MUST** use symmetric keys of at least 112 bits in length.
1699
1700 R-25401 The VNF **MUST** use asymmetric keys of at least 2048 bits in length.
1701
1702 R-95864 The VNF **MUST** use commercial tools that comply with X.509
1703 standards and produce x.509 compliant keys for public/private key generation.
1704
1705 R-12110 The VNF **MUST NOT** use keys generated or derived from
1706 predictable functions or values, e.g., values considered predictable
1707 include user identity information, time of day, stored/transmitted data.
1708
1709 R-52060 The VNF **MUST** provide the capability to configure encryption
1710 algorithms or devices so that they comply with the laws of the jurisdiction
1711 in which there are plans to use data encryption.
1712
1713 R-69610 The VNF **MUST** provide the capability of using certificates
1714 issued from a Certificate Authority not provided by the VNF provider.
1715
1716 R-83500 The VNF **MUST** provide the capability of allowing certificate
1717 renewal and revocation.
1718
1719 R-29977 The VNF **MUST** provide the capability of testing the validity
1720 of a digital certificate by validating the CA signature on the certificate.
1721
1722 R-24359 The VNF **MUST** provide the capability of testing the validity
1723 of a digital certificate by validating the date the certificate is being
1724 used is within the validity period for the certificate.
1725
1726 R-39604 The VNF **MUST** provide the capability of testing the
1727 validity of a digital certificate by checking the Certificate Revocation
1728 List (CRL) for the certificates of that type to ensure that the
1729 certificate has not been revoked.
1730
1731 R-75343 The VNF **MUST** provide the capability of testing the
1732 validity of a digital certificate by recognizing the identity represented
1733 by the certificate — the "distinguished name".
1734
1735 VNF Modularity
1736 ~~~~~~~~~~~~~~~~~~
1737
1738 R-37028 The VNF **MUST** be composed of one “base” module.
1739
1740 R-41215 The VNF **MAY** have zero to many “incremental” modules.
1741
1742 R-20974 The VNF **MUST** deploy the base module first, prior to
1743 the incremental modules.
1744
1745 R-11200 The VNF **MUST** keep the scope of a Cinder volume module,
1746 when it exists, to be 1:1 with the VNF Base Module or Incremental Module.
1747
1748 R-38474 The VNF **MUST** have a corresponding environment file for
1749 a Base Module.
1750
1751 R-81725 The VNF **MUST** have a corresponding environment file for
1752 an Incremental Module.
1753
1754 R-53433 The VNF **MUST** have a corresponding environment file for
1755 a Cinder Volume Module.
1756
1757 VNF Devops
1758 ~~~~~~~~~~~~~~
1759
1760 R-46960 NCSPs **MAY** operate a limited set of Guest OS and CPU
1761 architectures and families, virtual machines, etc.
1762
1763 R-23475 VNFCs **SHOULD** be agnostic to the details of the Network Cloud
1764 (such as hardware, host OS, Hypervisor or container technology) and must run
1765 on the Network Cloud with acknowledgement to the paradigm that the Network
1766 Cloud will continue to rapidly evolve and the underlying components of
1767 the platform will change regularly.
1768
1769 R-33846 The VNF **MUST** install the NCSP required software on Guest OS
1770 images when not using the NCSP provided Guest OS images. [5]_
1771
1772 R-09467 The VNF **MUST**  utilize only NCSP standard compute flavors. [5]_
1773
1774 R-02997 The VNF **MUST** preserve their persistent data. Running VMs
1775 will not be backed up in the Network Cloud infrastructure.
1776
1777 R-29760 The VNFC **MUST** be installed on non-root file systems,
1778 unless software is specifically included with the operating system
1779 distribution of the guest image.
1780
1781 R-20860 The VNF **MUST** be agnostic to the underlying infrastructure
1782 (such as hardware, host OS, Hypervisor), any requirements should be
1783 provided as specification to be fulfilled by any hardware.
1784
1785 R-89800 The VNF **MUST NOT** require Hypervisor-level customization
1786 from the cloud provider.
1787
1788 R-86758 The VNF **SHOULD** provide an automated test suite to validate
1789 every new version of the software on the target environment(s). The tests
1790 should be of sufficient granularity to independently test various
1791 representative VNF use cases throughout its lifecycle. Operations might
1792 choose to invoke these tests either on a scheduled basis or on demand to
1793 support various operations functions including test, turn-up and
1794 troubleshooting.
1795
1796 R-39650 The VNF **SHOULD** provide the ability to test incremental
1797 growth of the VNF.
1798
1799 R-14853 The VNF **MUST** respond to a "move traffic" [2]_ command
1800 against a specific VNFC, moving all existing session elsewhere with
1801 minimal disruption if a VNF provides a load balancing function across
1802 multiple instances of its VNFCs. Note: Individual VNF performance
1803 aspects (e.g., move duration or disruption scope) may require further
1804 constraints.
1805
1806 R-06327 The VNF **MUST** respond to a "drain VNFC" [2]_ command against
1807 a specific VNFC, preventing new session from reaching the targeted VNFC,
1808 with no disruption to active sessions on the impacted VNFC, if a VNF
1809 provides a load balancing function across multiple instances of its VNFCs.
1810 This is used to support scenarios such as proactive maintenance with no
1811 user impact.
1812
1813 R-64713 The VNF **SHOULD** support a software promotion methodology
1814 from dev/test -> pre-prod -> production in software, development &
1815 testing and operations.
1816
1817 **VNF Modeling Requirements**
1818 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1819
1820 Heat
1821 ~~~~~~
1822
1823 R-43125 The VNF Heat **MUST** indent properties and lists with 1 or
1824 more spaces.
1825
1826 R-67888 The VNF Heat **MUST** contain the following
1827 sections:
1828
1829 - heat\_template\_version:
1830 - description:
1831 - parameters:
1832 - resources:
1833
1834 R-39402 The VNF Heat **MUST** contain the description section.
1835
1836 R-35414 The VNF Heat **MUST** contain the parameter section.
1837
1838 R-90279 The VNF Heat **MUST** use in a resource all parameters declared in
1839 a template except for the parameters for the OS::Nova::Server property
1840 availability\_zone. See Property: availability\_zone. for more details on
1841 availability\_zone.
1842
1843 R-28657 The VNF Heat **MUST** provide the attribute 'type' on
1844 parameters per the OpenStack Heat Orchestration Template standard.
1845
1846 R-44001 The VNF Heat **MUST** provide the attribute 'description'
1847 on parameters. (Note that this attribute is OpenStack optional.)
1848
1849 R-90526 The VNF Heat **MUST NOT** use the attribute 'default'.
1850 If a parameter has a default value, it must be provided in
1851 the environment file. (Note that this attribute is OpenStack
1852 optional.)
1853
1854 R-88863 The VNF Heat **MUST** have a constraint of range or
1855 allowed\_values for a parameter type 'number'.
1856
1857 - range: The range constraint applies to parameters of type number.
1858   It defines a lower and upper limit for the numeric value of the
1859   parameter. The syntax of the range constraint is
1860
1861 R-23664 The VNF Heat **MUST** have a resources: section with the
1862 declaration of at least one resource.
1863
1864 R-16447 The VNF Heat **MUST** have unique resource IDs across all Heat
1865 Orchestration Templates that compose the VNF. This requirement
1866 also applies when a VNF is composed of more than one Heat
1867 Orchestration Template (see ONAP VNF Modularity Overview).
1868
1869 R-97199 The VNF Heat **MUST** use the metadata property for
1870 OS::Nova::Server resource type.
1871
1872 R-03324 The VNF Heat **MUST** contain the following sections in the
1873 environment file:
1874
1875 - parameters:
1876
1877 R-19473 The VNF Heat **MUST** include “base” in the filename for the
1878 base module.
1879
1880 R-81339 The VNF Heat **MUST** match one of the following options for
1881 the base module file name:
1882
1883 - base\_<text>.y[a]ml
1884 - <text>\_base.y[a]ml
1885 - base.y[a]ml
1886 - <text>\_base\_<text>.y[a]ml
1887
1888 R-91342 The VNF Heat **MUST** name the base module’s corresponding
1889 environment file to be identical to the base module with “.y[a]ml”
1890 replaced with “.env”.
1891
1892 R-87247 The VNF Heat **MUST NOT** use any special characters or the
1893 word “base” in the name of the incremental module.
1894
1895 - <text>.y[a]ml
1896
1897 R-94509 The VNF Heat **MUST** name the incremental module’s
1898 corresponding environment file to be identical to the incremental
1899 module with “.y[a]ml” replaced with “.env”.
1900
1901 R-82732 The VNF Heat **MUST** name the Cinder volume module file name
1902 to be the same as the corresponding module it is supporting (base
1903 module or incremental module) with “\_volume” appended.
1904
1905 - <base module name>\_volume.y[a]ml
1906 - <incremental module name>\_volume.y[a]ml
1907
1908 R-31141 The VNF Heat **MUST** name the volume module’s corresponding
1909 environment file to be identical to the volume module with “.y[a]ml”
1910 replaced with “.env”.
1911
1912 R-76057 The VNF Heat **MUST NOT** use special characters
1913 or the word “base” in the file name for the nested template.
1914
1915 R-18224 The VNF Heat **MUST** pass in as properties all parameter values
1916 associated with the nested heat file in the resource definition defined
1917 in the parent heat template.
1918
1919 R-07443 The VNF Heat **MUST** match the Output parameter name and type with
1920 the input parameter name and type unless the Output parameter is of the
1921 type comma\_delimited\_list.
1922
1923 R-23983 The VNF **MUST** pass the external networks into the VNF Heat
1924 Orchestration Templates as parameters.
1925
1926 - Neutron Network-id (UUID)
1927 - Neutron Network subnet ID (UUID)
1928 - Contrail Network Fully Qualified Domain Name (FQDN)
1929
1930 R-63345 The VNF Heat **MUST** pass the appropriate external
1931 network IDs into nested VM templates when nested Heat is used.
1932
1933 R-35666 The VNF Heat **MUST** include the resource(s) to
1934 create the internal network. The internal network must be either a
1935 Neutron Network or a Contrail Network.
1936
1937 R-86972 The VNF Heat **MUST** create internal networks in the Base
1938 Module, in the modular approach, with their resource IDs exposed as outputs
1939 (i.e., ONAP Base Module Output Parameters) for use by all incremental
1940 modules. If the Network resource ID is required in the base template,
1941 then a get\_resource must be used.
1942
1943 R-68936 The VNF Heat **SHOULD** assign a unique
1944 {network-role} in the context of the VNF, when the internal network is
1945 created. ONAP Resource ID and Parameter Naming Convention provides
1946 additional details.
1947
1948 R-01455 The VNF Heat **MUST** assign a VNF unique
1949 {vm-type} for each Virtual Machine type (i.e., OS::Nova::Server)
1950 instantiated in the VNF. While the {vm-type} must be unique to the VNF,
1951 it does not have to be globally unique across all VNFs that ONAP
1952 supports.
1953
1954 R-82481 The VNF Heat **MUST** include {vm-type} as part of the parameter name
1955 for any parameter that is associated with a unique Virtual Machine type.
1956
1957 R-66729 The VNF Heat **MUST** include {vm-type} as part of the resource ID
1958 for any resource ID that is associated with a unique Virtual Machine type in
1959 the VNF.
1960
1961 R-32394 The VNF Heat **MUST** use the same case for {vm-type} for all
1962 parameter names in the VNF.
1963
1964 R-46839 The VNF Heat **MUST** use the same case for {vm-type} for all
1965 Resource IDs in the VNF.
1966
1967 R-05008 The VNF Heat **MUST NOT** be prefixed with a common
1968 {vm-type} identifier for the six ONAP Metadata parameters.
1969 They are *vnf\_name*, *vnf\_id*, *vf\_module\_id*, *vf\_module\_name*,
1970 *vm\_role*. The ONAP Metadata parameters are described in
1971 Resource: OS::Nova::Server – Metadata Parameters.
1972
1973 R-15422 The VNF Heat **MUST NOT** be prefixed with a common {vm-type}
1974 identifier the parameter referring to the OS::Nova::Server property
1975 availability\_zone. availability\_zone is described in
1976 Property: availability_zone.
1977
1978 R-21330 The VNF Heat **MUST** include the {network-role} as part of the
1979 parameter name for any parameter that is associated with an external network.
1980
1981 R-11168 The VNF Heat **MUST** include the {network-role} as part of the
1982 resource ID for any resource ID that is associated with an external network
1983 must.
1984
1985 R-84322 The VNF Heat **MUST** include int\_{network-role} as part of the
1986 parameter name for any parameter that is associated with an internal network.
1987
1988 R-96983 The VNF Heat **MUST** include int\_{network-role} as part of the
1989 resource ID for any resource ID that is associated with an internal network.
1990
1991 R-58424 The VNF Heat **MUST** use the same case for {network-role} for
1992 all parameter names in the VNF.
1993
1994 R-21511 The VNF Heat **MUST** use the same case for {network-role} for
1995 all Resource IDs in the VNF.
1996
1997 R-59629 The VNF Heat **MUST** have unique resource IDs within the
1998 resources section of a Heat Orchestration Template. This is an
1999 OpenStack Requirement.
2000
2001 R-43319 The VNF Heat **MUST** have unique resource IDs
2002 across all modules that compose the VNF,
2003 when a VNF is composed of more than one Heat Orchestration Template
2004 (i.e., modules).
2005
2006 R-54517 The VNF Heat **MUST** include {vm-type} in the resource ID
2007 when a resource is associated with a single {vm-type}.
2008
2009 R-96482 The VNF Heat **MUST** include {network-role} in the resource ID
2010 when a resource is associated with a single external network.
2011
2012 R-98138 The VNF Heat **MUST** include int\_{network-role} in the resource ID
2013 when a resource is associated with a single internal network.
2014
2015 R-82115 The VNF Heat **MUST** include both the {vm-type} and
2016 {network-role} in the resource ID,
2017 when a resource is associated with a single {vm-type} and a single
2018 external network.
2019
2020 - The {vm-type} must appear before the {network-role} and must be
2021   separated by an underscore (i.e., {vm-type}\_{network-role}).
2022 - Note that an {index} value may separate the {vm-type} and the
2023   {network-role}. An underscore will separate the three values (i.e.,
2024   {vm-type}\_{index}\_{network-role}).
2025
2026 R-82551 The VNF Heat **MUST** include both the {vm-type} and
2027 int\_{network-role} in the resource ID,
2028 when a resource is associated with a single {vm-type} and a single
2029 internal network.
2030
2031 - The {vm-type} must appear before the int\_{network-role} and must be
2032   separated by an underscore (i.e., {vm-type}\_int\_{network-role}).
2033 - Note that an {index} value may separate the {vm-type} and the
2034   int\_{network-role}. An underscore will separate the three values
2035   (i.e., {vm-type}\_{index}\_int\_{network-role}).
2036
2037 R-69287 The VNF Heat **MUST** use only alphanumeric characters and “\_”
2038 underscores in the resource ID. Special characters must not be used.
2039
2040 R-71152 The VNF Heat **MUST** declare as type: string the parameter
2041 for property image.
2042
2043 R-91125 The VNF Heat **MUST** enumerate the parameter for property
2044 image in the Heat Orchestration Template environment file.
2045
2046 R-57282 The VNF Heat **MUST** have a separate parameter for image for
2047 Each VM type (i.e., {vm-type}) even if more than one {vm-type} shares
2048 the same image. This provides maximum clarity and flexibility.
2049
2050 R-50436 The VNF Heat **MUST** declare the parameter property for
2051 flavor as type: string.
2052
2053 R-69431 The VNF Heat **MUST** enumerate the parameter for property
2054 flavor in the Heat Orchestration Template environment file.
2055
2056 R-40499 The VNF Heat **MUST** have a separate parameter for flavor for each
2057 VM type (i.e., {vm-type}) even if more than one {vm-type} shares the same
2058 flavor. This provides maximum clarity and flexibility.
2059
2060 R-22838 The VNF Heat **MUST NOT** enumerate the parameter for property name
2061 in the environment file.
2062
2063 R-51430 The VNF Heat **MUST** declare the parameter for property name as
2064 type: string or type: comma\_delimited\_list
2065
2066 R-98450 The VNF Heat **MUST** name the parameter availability\_zone\_{index}
2067 in the Heat Orchestration Template.
2068
2069 R-13561 The VNF Heat **MUST** start the {index} at zero.
2070
2071 R-60204 The VNF Heat **MUST** increment the {index} by one.
2072
2073 R-36887 The VNF Heat **MUST NOT** include the {vm-type} in the parameter name.
2074
2075 R-17020 The VNF Heat **MUST** include the following three mandatory
2076 metadata parameters for an OS::Nova::Server resource:
2077
2078 - vnf\_id
2079 - vf\_module\_id
2080 - vnf\_name
2081
2082 R-55218 The VNF Heat **MUST NOT** have parameter constraints defined
2083 for the OS::Nova::Server metadata parameter vnf\_id.
2084
2085 R-20856 The VNF Heat **MUST NOT** enumerate the OS::Nova::Server
2086 metadata parameter vnf\_id in environment file.
2087
2088 R-98374 The VNF Heat **MUST NOT** have parameter constraints
2089 defined for the OS::Nova::Server metadata parameter vf\_module\_id.
2090
2091 R-72871 The VNF Heat **MUST NOT** enumerate the OS::Nova::Server
2092 metadata parameter vf\_module\_id in environment file.
2093
2094 R-44318 The VNF Heat **MUST NOT** have parameter constraints defined
2095 for the OS::Nova::Server metadata parameter vnf\_name.
2096
2097 R-36542 The VNF Heat **MUST NOT** enumerate the OS::Nova::Server
2098 metadata parameter vnf\_name in the environment file.
2099
2100 R-72050 The VNF Heat **MUST** contain {network-role} in the parameter name
2101
2102 R-57576 The VNF Heat **MUST** contain int\_{network-role}
2103 in the parameter name.
2104
2105 R-93272 The VNF Heat **MUST** adhere to the following parameter naming
2106 convention in the Heat Orchestration Template, when the parameter
2107 associated with the property network is referencing an “external” network:
2108
2109 - {network-role}\_net\_id for the Neutron network ID
2110 - {network-role}\_net\_name for the network name in OpenStack
2111
2112 R-65373 The VNF Heat **MUST**  adhere to the following parameter naming
2113 convention, when the parameter associated with the property network is
2114 referencing an “internal” network:
2115
2116 - int\_{network-role}\_net\_id for the Neutron network ID
2117 - int\_{network-role}\_net\_name for the network name in OpenStack
2118
2119 R-47716 The VNF Heat **MUST** adhere to the following parameter naming
2120 convention for the property fixed\_ips and Map Property subnet\_id
2121 parameter, when the parameter is referencing a subnet of an
2122 “external” network.
2123
2124 - {network-role}\_subnet\_id if the subnet is an IPv4 subnet
2125 - {network-role}\_v6\_subnet\_id if the subnet is an IPv6 subnet
2126
2127 R-20106 The VNF Heat **MUST** adhere to the following naming convention for
2128 the property fixed\_ips and Map Property subnet\_id parameter,
2129 when the parameter is referencing the subnet of an “internal” network:
2130
2131 - int\_{network-role}\_subnet\_id if the subnet is an IPv4 subnet
2132 - int\_{network-role}\_v6\_subnet\_id if the subnet is an IPv6 subnet
2133
2134 R-41177 The VNF Heat **MUST** include {vm-type} and {network-role}
2135 in the parameter name, when a SDN-C IP assignment is made to a
2136 port connected to an external network.
2137
2138 R-84898 The VNF Heat **MUST** adhere to the following naming convention,
2139 when the parameter for property fixed\_ips and Map Property ip\_address
2140 is declared type: comma\_delimited\_list:
2141
2142 - {vm-type}\_{network-role}\_ips for IPv4 address
2143 - {vm-type}\_{network-role}\_v6\_ips for IPv6 address
2144
2145 R-34960 The VNF Heat **MUST** adhere to the following
2146 naming convention,
2147 when the parameter for property fixed\_ips and Map Property ip\_address
2148 is declared type: string:
2149
2150 - {vm-type}\_{network-role}\_ip\_{index} for an IPv4 address
2151 - {vm-type}\_{network-role}\_v6\_ip\_{index} for an IPv6 address
2152
2153 R-62584 The VNF Heat **MUST** adhere to
2154 the following naming convention,
2155 when the parameter for property fixed\_ips and Map Property ip\_address
2156 is declared type: comma\_delimited\_list:
2157
2158 - {vm-type}\_int\_{network-role}\_ips for IPv4 address
2159 - {vm-type}\_int\_{network-role}\_v6\_ips for IPv6 address
2160
2161 R-29256 The VNF Heat **MUST** must adhere to the following
2162 naming convention,
2163 when the parameter for property fixed\_ips and Map Property ip\_address
2164 is declared type: string:
2165
2166 - {vm-type}\_int\_{network-role}\_ip\_{index} for an IPv4 address
2167 - {vm-type}\_int\_{network-role}\_v6\_ip\_{index} for an IPv6 address
2168
2169 R-61282 The VNF Heat **MUST**
2170 adhere to the following naming convention for the property
2171 allowed\_address\_pairs and Map Property ip\_address parameter,
2172 when the parameter is referencing an “external” network:
2173
2174 - {vm-type}\_{network-role}\_floating\_ip for an IPv4 address
2175 - {vm-type}\_{network-role}\_floating\_v6\_ip for an IPv6 address
2176
2177 R-16805 The VNF Heat **MUST** adhere to the following naming convention
2178 for the property allowed\_address\_pairs and Map Property ip\_address
2179 parameter when the parameter is referencing an “internal” network.
2180
2181 - {vm-type}\_int\_{network-role}\_floating\_ip for an IPv4 address
2182 - {vm-type}\_int\_{network-role}\_floating\_v6\_ip for an IPv6 address
2183
2184 R-85734 The VNF Heat **MUST** use the intrinsic function str\_replace
2185 in conjunction with the ONAP supplied metadata parameter
2186 vnf\_name to generate a unique value,
2187 when the property name for a non OS::Nova::Server resources is defined
2188 in a Heat Orchestration Template.
2189
2190 R-47788 The VNF Heat **MUST** have a 1:1 scope of a cinder volume module,
2191 when it exists, with the Base Module or Incremental Module
2192
2193 R-79531 The VNF Heat **MUST** define “outputs” in the volume
2194 template for each Cinder volume resource universally unique
2195 identifier (UUID) (i.e. ONAP Volume Template Output Parameters).
2196
2197 R-86285 The VNF Heat **MUST** have a
2198 corresponding environment file, even if no parameters are required to be
2199 enumerated.
2200
2201 R-67205 The VNF Heat **MUST** have a corresponding
2202 environment file for a Base Module.
2203
2204 R-35727 The VNF Heat **MUST** have a
2205 corresponding environment file for an Incremental module.
2206
2207 R-22656 The VNF Heat **MUST** have a corresponding environment file
2208 for a Cinder Volume Module.
2209
2210 R-89868 The VNF Heat **MUST** have unique file names within the scope
2211 of the VNF for a nested heat yaml file.
2212
2213 R-52530 The VNF Heat **MUST NOT** use a directory hierarchy for
2214 nested templates. All templates must be in a single, flat directory
2215 (per VNF).
2216
2217 R-11041 The VNF Heat **MUST** have the resource calling the
2218 nested yaml file pass in as properties all parameters defined
2219 in nested yaml file.
2220
2221 R-61183 The VNF Heat **MUST NOT** change the parameter names, when
2222 OS::Nova::Server metadata parameters are past into a nested heat template.
2223
2224 R-76718 The VNF Heat **MUST** reference the get\_files targets in
2225 Heat templates by file name, and the corresponding files should be
2226 delivered to ONAP along with the Heat templates.
2227
2228 R-41888 The VNE Heat **MUST NOT** use URL-based file retrieval.
2229
2230 R-62177 The VNF Heat **MUST** have unique file names for the included
2231 files within the scope of the VNF.
2232
2233 R-87848 The VNF Heat **MUST** have all included files in a single, flat
2234 directory per VNF. ONAP does not support a directory hierarchy.
2235
2236 - Included files may be used by all Modules within a given VNF.
2237 - get\_file directives may be used in both non-nested and nested
2238   templates
2239
2240 **ONAP Management Requirements**
2241 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2242
2243
2244 VNF On-boarding and package management
2245 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2246
2247
2248 R-77707 The xNF provider **MUST** include a Manifest File that
2249 contains a list of all the components in the xNF package.
2250
2251 R-66070 The xNF Package **MUST** include xNF Identification Data to
2252 uniquely identify the resource for a given xNF provider. The identification
2253 data must include: an identifier for the xNF, the name of the xNF as was
2254 given by the xNF provider, xNF description, xNF provider, and version.
2255
2256 R-69565 The xNF Package **MUST** include documentation describing xNF
2257 Management APIs, which must include information and tools for ONAP to
2258 deploy and configure (initially and ongoing) the xNF application(s)
2259 (e.g., NETCONF APIs) which includes a description of configurable
2260 parameters for the xNF and whether the parameters can be configured
2261 after xNF instantiation.
2262
2263 R-00156 The xNF Package **MUST** include documentation describing xNF
2264 Management APIs, which must include information and tools for ONAP
2265 to monitor the health of the xNF (conditions that require healing
2266 and/or scaling responses).
2267
2268 R-00068 The xNF Package **MUST** include documentation which includes
2269 a description of parameters that can be monitored for the xNF and
2270 event records (status, fault, flow, session, call, control plane,
2271 etc.) generated by the xNF after instantiation.
2272
2273 R-12678 The xNF Package **MUST** include documentation which includes a
2274 description of runtime lifecycle events and related actions (e.g.,
2275 control responses, tests) which can be performed for the xNF.
2276
2277 R-84366 The xNF Package **MUST** include documentation describing
2278 xNF Functional APIs that are utilized to build network and
2279 application services. This document describes the externally exposed
2280 functional inputs and outputs for the xNF, including interface
2281 format and protocols supported.
2282
2283 R-36280 The xNF provider **MUST** provide documentation describing
2284 xNF Functional Capabilities that are utilized to operationalize the
2285 xNF and compose complex services.
2286
2287 R-98617 The xNF provider **MUST** provide information regarding any
2288 dependency (e.g., affinity, anti-affinity) with other xNFs and resources.
2289
2290 R-89571 The xNF **MUST** support and provide artifacts for configuration
2291 management using at least one of the following technologies;
2292 a) Netconf/YANG, b) Chef, or c) Ansible.
2293
2294 R-30278 The xNF provider **MUST** provide a Resource/Device YANG model
2295 as a foundation for creating the YANG model for configuration. This will
2296 include xNF attributes/parameters and valid values/attributes configurable
2297 by policy.
2298
2299 R-13390 The xNF provider **MUST** provide cookbooks to be loaded
2300 on the appropriate Chef Server.
2301
2302 R-18525 The xNF provider **MUST** provide a JSON file for each
2303 supported action for the xNF.  The JSON file must contain key value
2304 pairs with all relevant values populated with sample data that illustrates
2305 its usage. The fields and their description are defined in Appendix A.
2306
2307 R-75608 The xNF provider **MUST** provide playbooks to be loaded
2308 on the appropriate Ansible Server.
2309
2310 R-16777 The xNF provider **MUST** provide a JSON file for each
2311 supported action for the xNF.  The JSON file must contain key value
2312 pairs with all relevant values populated with sample data that illustrates
2313 its usage. The fields and their description are defined in Appendix B.
2314
2315 R-46567 The xNF Package **MUST** include configuration scripts
2316 for boot sequence and configuration.
2317
2318 R-16065 The xNF provider **MUST** provide configurable parameters
2319 (if unable to conform to YANG model) including xNF attributes/parameters
2320 and valid values, dynamic attributes and cross parameter dependencies
2321 (e.g., customer provisioning data).
2322
2323 R-22888 The xNF provider **MUST** provide documentation for the xNF
2324 Policy Description to manage the xNF runtime lifecycle. The document
2325 must include a description of how the policies (conditions and actions)
2326 are implemented in the xNF.
2327
2328 R-01556 The xNF Package **MUST** include documentation describing the
2329 fault, performance, capacity events/alarms and other event records
2330 that are made available by the xNF.
2331
2332 R-16875 The xNF Package **MUST** include documentation which must include
2333 a unique identification string for the specific xNF, a description of
2334 the problem that caused the error, and steps or procedures to perform
2335 Root Cause Analysis and resolve the issue.
2336
2337 R-35960 The xNF Package **MUST** include documentation which must include
2338 all events, severity level (e.g., informational, warning, error) and
2339 descriptions including causes/fixes if applicable for the event.
2340
2341 R-42018 The xNF Package **MUST** include documentation which must include
2342 all events (fault, measurement for xNF Scaling, Syslogs, State Change
2343 and Mobile Flow), that need to be collected at each VM, VNFC (defined in `VNF Guidelines <http://onap.readthedocs.io/en/latest/submodules/vnfrqts/guidelines.git/docs/vnf_guidelines/vnf_guidelines.html#a-glossary>`__ ) and for the overall xNF.
2344
2345 R-27711 The xNF provider **MUST** provide an XML file that contains a
2346 list of xNF error codes, descriptions of the error, and possible
2347 causes/corrective action.
2348
2349 R-01478 The xNF Package **MUST** include documentation describing all
2350 parameters that are available to monitor the xNF after instantiation
2351 (includes all counters, OIDs, PM data, KPIs, etc.) that must be
2352 collected for reporting purposes.
2353
2354 R-73560 The xNF Package **MUST** include documentation about monitoring
2355 parameters/counters exposed for virtual resource management and xNF
2356 application management.
2357
2358 R-90632 The xNF Package **MUST** include documentation about KPIs and
2359 metrics that need to be collected at each VM for capacity planning
2360 and performance management purposes.
2361
2362 R-86235 The xNF Package **MUST** include documentation about the monitoring
2363 parameters that must include latencies, success rates, retry rates, load
2364 and quality (e.g., DPM) for the key transactions/functions supported by
2365 the xNF and those that must be exercised by the xNF in order to perform
2366 its function.
2367
2368 R-33904 The xNF Package **MUST** include documentation for each KPI, provide
2369 lower and upper limits.
2370
2371 R-53598 The xNF Package **MUST** include documentation to, when relevant,
2372 provide a threshold crossing alert point for each KPI and describe the
2373 significance of the threshold crossing.
2374
2375 R-69877 The xNF Package **MUST** include documentation for each KPI,
2376 identify the suggested actions that need to be performed when a
2377 threshold crossing alert event is recorded.
2378
2379 R-22680 The xNF Package **MUST** include documentation that describes
2380 any requirements for the monitoring component of tools for Network
2381 Cloud automation and management to provide these records to components
2382 of the xNF.
2383
2384 R-33694 The xNF Package **MUST** include documentation to when applicable,
2385 provide calculators needed to convert raw data into appropriate reporting
2386 artifacts.
2387
2388 R-56815 The xNF Package **MUST** include documentation describing
2389 supported xNF scaling capabilities and capacity limits (e.g., number
2390 of users, bandwidth, throughput, concurrent calls).
2391
2392 R-48596 The xNF Package **MUST** include documentation describing
2393 the characteristics for the xNF reliability and high availability.
2394
2395 R-74763 The xNF provider **MUST** provide an artifact per xNF that contains
2396 all of the xNF Event Records supported. The artifact should include reference
2397 to the specific release of the xNF Event Stream Common Event Data Model
2398 document it is based on. (e.g., `VES Event Listener <https://github.com/att/evel-test-collector/tree/master/docs/att_interface_definition>`__)
2399
2400 R-35851 The xNF Package **MUST** include xNF topology that describes
2401 basic network and application connectivity internal and external to the
2402 xNF including Link type, KPIs, Bandwidth, latency, jitter, QoS (if
2403 applicable) for each interface.
2404
2405 R-97102 The VNF Package **MUST** include VM requirements via a Heat
2406 template that provides the necessary data for VM specifications
2407 for all VNF components - for hypervisor, CPU, memory, storage.
2408
2409 R-20204 The VNF Package **MUST** include VM requirements via a Heat
2410 template that provides the necessary data for network connections,
2411 interface connections, internal and external to VNF.
2412
2413 R-44896 The VNF Package **MUST** include VM requirements via a Heat
2414 template that provides the necessary data for high availability
2415 redundancy model.
2416
2417 R-55802 The VNF Package **MUST** include VM requirements via a Heat
2418 template that provides the necessary data for scaling/growth VM
2419 specifications.
2420
2421 R-26881 The xNF provider **MUST** provide the binaries and images
2422 needed to instantiate the xNF (xNF and VNFC images).
2423
2424 R-96634 The xNF provider **MUST** describe scaling capabilities
2425 to manage scaling characteristics of the xNF.
2426
2427 R-43958 The xNF Package **MUST** include documentation describing
2428 the tests that were conducted by the xNF providor and the test results.
2429
2430 R-04298 The xNF provider **MUST** provide their testing scripts to
2431 support testing.
2432
2433 R-58775 The xNF provider **MUST** provide software components that
2434 can be packaged with/near the xNF, if needed, to simulate any functions
2435 or systems that connect to the xNF system under test. This component is
2436 necessary only if the existing testing environment does not have the
2437 necessary simulators.
2438
2439 R-85653 The xNF **MUST** provide metrics (e.g., number of sessions,
2440 number of subscribers, number of seats, etc.) to ONAP for tracking
2441 every license.
2442
2443 R-44125 The xNF provider **MUST** agree to the process that can
2444 be met by Service Provider reporting infrastructure. The Contract
2445 shall define the reporting process and the available reporting tools.
2446
2447 R-40827 The xNF provider **MUST** enumerate all of the open
2448 source licenses their xNF(s) incorporate.
2449
2450 R-97293 The xNF provider **MUST NOT** require audits of
2451 Service Provider’s business.
2452
2453 R-44569 The xNF provider **MUST NOT** require additional
2454 infrastructure such as a xNF provider license server for xNF provider
2455 functions and metrics.
2456
2457 R-13613 The VNF **MUST** provide clear measurements for licensing
2458 purposes to allow automated scale up/down by the management system.
2459
2460 R-27511 The VNF provider **MUST** provide the ability to scale
2461 up a VNF provider supplied product during growth and scale down a
2462 VNF provider supplied product during decline without “real-time”
2463 restrictions based upon VNF provider permissions.
2464
2465 R-85991 The xNF provider **MUST** provide a universal license key
2466 per xNF to be used as needed by services (i.e., not tied to a VM
2467 instance) as the recommended solution. The xNF provider may provide
2468 pools of Unique xNF License Keys, where there is a unique key for
2469 each xNF instance as an alternate solution. Licensing issues should
2470 be resolved without interrupting in-service xNFs.
2471
2472 R-47849 The xNF provider **MUST** support the metadata about
2473 licenses (and their applicable entitlements) as defined in this
2474 document for xNF software, and any license keys required to authorize
2475 use of the xNF software.  This metadata will be used to facilitate
2476 onboarding the xNF into the ONAP environment and automating processes
2477 for putting the licenses into use and managing the full lifecycle of
2478 the licenses. The details of this license model are described in
2479 Appendix C. Note: License metadata support in ONAP is not currently
2480 available and planned for 1Q 2018.
2481
2482 Configuration Management
2483 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2484
2485 R-20741 The xNF **MUST** support ONAP Controller’s **Configure** command.
2486
2487 R-19366 The xNF **MUST** support ONAP Controller’s **ConfigModify** command.
2488
2489 R-32981 The xNF **MUST** support ONAP Controller’s **ConfigBackup** command.
2490
2491 R-48247 The xNF **MUST** support ONAP Controller’s **ConfigRestore** command.
2492
2493 R-94084 The xNF **MUST** support ONAP Controller’s **ConfigScaleOut**
2494 command.
2495
2496 R-56385 The xNF **MUST** support ONAP Controller’s **Audit** command.
2497
2498 R-12706 The xNF **MUST** support ONAP Controller’s **QuiesceTraffic**
2499 command.
2500
2501 R-07251 The xNF **MUST** support ONAP Controller’s **ResumeTraffic**
2502 command.
2503
2504 R-83146 The xNF **MUST** support ONAP Controller’s **StopApplication**
2505 command.
2506
2507 R-82811 The xNF **MUST** support ONAP Controller’s **StartApplication**
2508 command.
2509
2510 R-19922 The xNF **MUST** support ONAP Controller’s **UpgradePrecheck**
2511 command.
2512
2513 R-49466 The xNF **MUST** support ONAP Controller’s **UpgradeSoftware**
2514 command.
2515
2516 R-45856 The xNF **MUST** support ONAP Controller’s **UpgradePostCheck**
2517 command.
2518
2519 R-97343 The xNF **MUST** support ONAP Controller’s **UpgradeBackup**
2520 command.
2521
2522 R-65641 The xNF **MUST** support ONAP Controller’s **UpgradeBackOut**
2523 command.
2524
2525 R-41430 The xNF **MUST** support ONAP Controller’s **HealthCheck**
2526 command.
2527
2528 R-88026 The xNF **MUST** include a NETCONF server enabling
2529 runtime configuration and lifecycle management capabilities.
2530
2531 R-95950 The xNF **MUST** provide a NETCONF interface fully defined
2532 by supplied YANG models for the embedded NETCONF server.
2533
2534 R-73468 The xNF **MUST** allow the NETCONF server connection
2535 parameters to be configurable during virtual machine instantiation
2536 through Heat templates where SSH keys, usernames, passwords, SSH
2537 service and SSH port numbers are Heat template parameters.
2538
2539 R-90007 The xNF **MUST** implement the protocol operation:
2540 **close-session()**- Gracefully close the current session.
2541
2542 R-70496 The xNF **MUST** implement the protocol operation:
2543 **commit(confirmed, confirm-timeout)** - Commit candidate
2544 configuration datastore to the running configuration.
2545
2546 R-18733 The xNF **MUST** implement the protocol operation:
2547 **discard-changes()** - Revert the candidate configuration
2548 datastore to the running configuration.
2549
2550 R-44281 The xNF **MUST** implement the protocol operation:
2551 **edit-config(target, default-operation, test-option, error-option,
2552 config)** - Edit the target configuration datastore by merging,
2553 replacing, creating, or deleting new config elements.
2554
2555 R-60106 The xNF **MUST** implement the protocol operation:
2556 **get(filter)** - Retrieve (a filtered subset of) the running
2557 configuration and device state information. This should include
2558 the list of xNF supported schemas.
2559
2560 R-29488 The xNF **MUST** implement the protocol operation:
2561 **get-config(source, filter)** - Retrieve a (filtered subset of
2562 a) configuration from the configuration datastore source.
2563
2564 R-11235 The xNF **MUST** implement the protocol operation:
2565 **kill-session(session)** - Force the termination of **session**.
2566
2567 R-02597 The xNF **MUST** implement the protocol operation:
2568 **lock(target)** - Lock the configuration datastore target.
2569
2570 R-96554 The xNF **MUST** implement the protocol operation:
2571 **unlock(target)** - Unlock the configuration datastore target.
2572
2573 R-29324 The xNF **SHOULD** implement the protocol operation:
2574 **copy-config(target, source) -** Copy the content of the
2575 configuration datastore source to the configuration datastore target.
2576
2577 R-88031 The xNF **SHOULD** implement the protocol operation:
2578 **delete-config(target) -** Delete the named configuration
2579 datastore target.
2580
2581 R-97529 The xNF **SHOULD** implement the protocol operation:
2582 **get-schema(identifier, version, format) -** Retrieve the YANG schema.
2583
2584 R-62468 The xNF **MUST** allow all configuration data to be
2585 edited through a NETCONF <edit-config> operation. Proprietary
2586 NETCONF RPCs that make configuration changes are not sufficient.
2587
2588 R-01382 The xNF **MUST** allow the entire configuration of the
2589 xNF to be retrieved via NETCONF's <get-config> and <edit-config>,
2590 independently of whether it was configured via NETCONF or other
2591 mechanisms.
2592
2593 R-28756 The xNF **MUST** support **:partial-lock** and
2594 **:partial-unlock** capabilities, defined in RFC 5717. This
2595 allows multiple independent clients to each write to a different
2596 part of the <running> configuration at the same time.
2597
2598 R-83873 The xNF **MUST** support **:rollback-on-error** value for
2599 the <error-option> parameter to the <edit-config> operation. If any
2600 error occurs during the requested edit operation, then the target
2601 database (usually the running configuration) will be left unaffected.
2602 This provides an 'all-or-nothing' edit mode for a single <edit-config>
2603 request.
2604
2605 R-68990 The xNF **MUST** support the **:startup** capability. It
2606 will allow the running configuration to be copied to this special
2607 database. It can also be locked and unlocked.
2608
2609 R-68200 The xNF **MUST** support the **:url** value to specify
2610 protocol operation source and target parameters. The capability URI
2611 for this feature will indicate which schemes (e.g., file, https, sftp)
2612 that the server supports within a particular URL value. The 'file'
2613 scheme allows for editable local configuration databases. The other
2614 schemes allow for remote storage of configuration databases.
2615
2616 R-20353 The xNF **MUST** implement both **:candidate** and
2617 **:writable-running** capabilities. When both **:candidate** and
2618 **:writable-running** are provided then two locks should be supported.
2619
2620 R-11499 The xNF **MUST** fully support the XPath 1.0 specification
2621 for filtered retrieval of configuration and other database contents.
2622 The 'type' attribute within the <filter> parameter for <get> and
2623 <get-config> operations may be set to 'xpath'. The 'select' attribute
2624 (which contains the XPath expression) will also be supported by the
2625 server. A server may support partial XPath retrieval filtering, but
2626 it cannot advertise the **:xpath** capability unless the entire XPath
2627 1.0 specification is supported.
2628
2629 R-83790 The xNF **MUST** implement the **:validate** capability
2630
2631 R-49145 The xNF **MUST** implement **:confirmed-commit** If
2632 **:candidate** is supported.
2633
2634 R-58358 The xNF **MUST** implement the **:with-defaults** capability
2635 [RFC6243].
2636
2637 R-59610 The xNF **MUST** implement the data model discovery and
2638 download as defined in [RFC6022].
2639
2640 R-87662 The xNF **SHOULD** implement the NETCONF Event Notifications
2641 [RFC5277].
2642
2643 R-93443 The xNF **MUST** define all data models in YANG [RFC6020],
2644 and the mapping to NETCONF shall follow the rules defined in this RFC.
2645
2646 R-26115 The xNF **MUST** follow the data model upgrade rules defined
2647 in [RFC6020] section 10. All deviations from section 10 rules shall
2648 be handled by a built-in automatic upgrade mechanism.
2649
2650 R-10716 The xNF **MUST** support parallel and simultaneous
2651 configuration of separate objects within itself.
2652
2653 R-29495 The xNF **MUST** support locking if a common object is
2654 being manipulated by two simultaneous NETCONF configuration operations
2655 on the same xNF within the context of the same writable running data
2656 store (e.g., if an interface parameter is being configured then it
2657 should be locked out for configuration by a simultaneous configuration
2658 operation on that same interface parameter).
2659
2660 R-53015 The xNF **MUST** apply locking based on the sequence of
2661 NETCONF operations, with the first configuration operation locking
2662 out all others until completed.
2663
2664 R-02616 The xNF **MUST** permit locking at the finest granularity
2665 if a xNF needs to lock an object for configuration to avoid blocking
2666 simultaneous configuration operations on unrelated objects (e.g., BGP
2667 configuration should not be locked out if an interface is being
2668 configured or entire Interface configuration should not be locked out
2669 if a non-overlapping parameter on the interface is being configured).
2670
2671 R-41829 The xNF **MUST** be able to specify the granularity of the
2672 lock via a restricted or full XPath expression.
2673
2674 R-66793 The xNF **MUST** guarantee the xNF configuration integrity
2675 for all simultaneous configuration operations (e.g., if a change is
2676 attempted to the BUM filter rate from multiple interfaces on the same
2677 EVC, then they need to be sequenced in the xNF without locking either
2678 configuration method out).
2679
2680 R-54190 The xNF **MUST** release locks to prevent permanent lock-outs
2681 when/if a session applying the lock is terminated (e.g., SSH session
2682 is terminated).
2683
2684 R-03465 The xNF **MUST** release locks to prevent permanent lock-outs
2685 when the corresponding <partial-unlock> operation succeeds.
2686
2687 R-63935 The xNF **MUST** release locks to prevent permanent lock-outs
2688 when a user configured timer has expired forcing the NETCONF SSH Session
2689 termination (i.e., product must expose a configuration knob for a user
2690 setting of a lock expiration timer)
2691
2692 R-10173 The xNF **MUST** allow another NETCONF session to be able to
2693 initiate the release of the lock by killing the session owning the lock,
2694 using the <kill-session> operation to guard against hung NETCONF sessions.
2695
2696 R-88899 The xNF **MUST** support simultaneous <commit> operations
2697 within the context of this locking requirements framework.
2698
2699 R-07545 The xNF **MUST** support all operations, administration and
2700 management (OAM) functions available from the supplier for xNFs using
2701 the supplied YANG code and associated NETCONF servers.
2702
2703 R-60656 The xNF **MUST** support sub tree filtering.
2704
2705 R-80898 The xNF **MUST** support heartbeat via a <get> with null filter.
2706
2707 R-06617 The xNF **MUST** support get-schema (ietf-netconf-monitoring)
2708 to pull YANG model over session.
2709
2710 R-25238 The xNF PACKAGE **MUST** validated YANG code using the open
2711 source pyang [3]_ program using the following commands:
2712
2713 R-63953 The xNF **MUST** have the echo command return a zero value
2714 otherwise the validation has failed
2715
2716 R-26508 The xNF **MUST** support a NETCONF server that can be mounted on
2717 OpenDaylight (client) and perform the operations of: modify, update,
2718 change, rollback configurations using each configuration data element,
2719 query each state (non-configuration) data element, execute each YANG
2720 RPC, and receive data through each notification statement.
2721
2722 R-28545 The xNF **MUST** conform its YANG model to RFC 6060,
2723 “YANG - A Data Modeling Language for the Network Configuration
2724 Protocol (NETCONF)”
2725
2726 R-29967 The xNF **MUST** conform its YANG model to RFC 6022,
2727 “YANG module for NETCONF monitoring”.
2728
2729 R-22700 The xNF **MUST** conform its YANG model to RFC 6470,
2730 “NETCONF Base Notifications”.
2731
2732 R-10353 The xNF **MUST** conform its YANG model to RFC 6244,
2733 “An Architecture for Network Management Using NETCONF and YANG”.
2734
2735 R-53317 The xNF **MUST** conform its YANG model to RFC 6087,
2736 “Guidelines for Authors and Reviewers of YANG Data Model Documents”.
2737
2738 R-33955 The xNF **SHOULD** conform its YANG model to RFC 6991,
2739 “Common YANG Data Types”.
2740
2741 R-22946 The xNF **SHOULD** conform its YANG model to RFC 6536,
2742 “NETCONF Access Control Model”.
2743
2744 R-10129 The xNF **SHOULD** conform its YANG model to RFC 7223,
2745 “A YANG Data Model for Interface Management”.
2746
2747 R-12271 The xNF **SHOULD** conform its YANG model to RFC 7223,
2748 “IANA Interface Type YANG Module”.
2749
2750 R-49036 The xNF **SHOULD** conform its YANG model to RFC 7277,
2751 “A YANG Data Model for IP Management”.
2752
2753 R-87564 The xNF **SHOULD** conform its YANG model to RFC 7317,
2754 “A YANG Data Model for System Management”.
2755
2756 R-24269 The xNF **SHOULD** conform its YANG model to RFC 7407,
2757 “A YANG Data Model for SNMP Configuration”.
2758
2759 R-33946 The xNF **MUST** conform to the NETCONF RFC 4741,
2760 “NETCONF Configuration Protocol”.
2761
2762 R-04158 The xNF **MUST** conform to the NETCONF RFC 4742,
2763 “Using the NETCONF Configuration Protocol over Secure Shell (SSH)”.
2764
2765 R-13800 The xNF **MUST** conform to the NETCONF RFC 5277,
2766 “NETCONF Event Notification”.
2767
2768 R-01334 The xNF **MUST** conform to the NETCONF RFC 5717,
2769 “Partial Lock Remote Procedure Call”.
2770
2771 R-08134 The xNF **MUST** conform to the NETCONF RFC 6241,
2772 “NETCONF Configuration Protocol”.
2773
2774 R-78282 The xNF **MUST** conform to the NETCONF RFC 6242,
2775 “Using the Network Configuration Protocol over Secure Shell”.
2776
2777 R-31809 The xNF **MUST** support the HealthCheck RPC. The HealthCheck
2778 RPC executes a xNF Provider-defined xNF HealthCheck over the scope of
2779 the entire xNF (e.g., if there are multiple VNFCs, then run a health check,
2780 as appropriate, for all VNFCs). It returns a 200 OK if the test completes.
2781 A JSON object is returned indicating state (healthy, unhealthy), scope
2782 identifier, time-stamp and one or more blocks containing info and fault
2783 information. If the xNF is unable to run the HealthCheck, return a
2784 standard http error code and message.
2785
2786 R-79224 The xNF **MUST** have the chef-client be preloaded with
2787 validator keys and configuration to register with the designated
2788 Chef Server as part of the installation process.
2789
2790 R-72184 The xNF **MUST** have routable FQDNs for all the endpoints
2791 (VMs) of a xNF that contain chef-clients which are used to register
2792 with the Chef Server.  As part of invoking xNF actions, ONAP will
2793 trigger push jobs against FQDNs of endpoints for a xNF, if required.
2794
2795 R-47068 The xNF **MAY** expose a single endpoint that is
2796 responsible for all functionality.
2797
2798 R-67114 The xNF **MUST** be installed with Chef-Client >= 12.0 and
2799 Chef push jobs client >= 2.0.
2800
2801 R-27310 The xNF Package **MUST** include all relevant Chef artifacts
2802 (roles/cookbooks/recipes) required to execute xNF actions requested by
2803 ONAP for loading on appropriate Chef Server.
2804
2805 R-26567 The xNF Package **MUST** include a run list of
2806 roles/cookbooks/recipes, for each supported xNF action, that will
2807 perform the desired xNF action in its entirety as specified by ONAP
2808 (see Section 7.c, ONAP Controller APIs and Behavior, for list of xNF
2809 actions and requirements), when triggered by a chef-client run list
2810 in JSON file.
2811
2812 R-98911 The xNF **MUST NOT** use any instance specific parameters
2813 for the xNF in roles/cookbooks/recipes invoked for a xNF action.
2814
2815 R-37929 The xNF **MUST** accept all necessary instance specific
2816 data from the environment or node object attributes for the xNF
2817 in roles/cookbooks/recipes invoked for a xNF action.
2818
2819 R-62170 The xNF **MUST** over-ride any default values for
2820 configurable parameters that can be set by ONAP in the roles,
2821 cookbooks and recipes.
2822
2823 R-78116 The xNF **MUST** update status on the Chef Server
2824 appropriately (e.g., via a fail or raise an exception) if the
2825 chef-client run encounters any critical errors/failures when
2826 executing a xNF action.
2827
2828 R-44013 The xNF **MUST** populate an attribute, defined as node
2829 [‘PushJobOutput’] with the desired output on all nodes in the push job
2830 that execute chef-client run if the xNF action requires the output of a
2831 chef-client run be made available (e.g., get running configuration).
2832
2833 R-30654 The xNF Package **MUST** have appropriate cookbooks that are
2834 designed to automatically ‘rollback’ to the original state in case of
2835 any errors for actions that change state of the xNF (e.g., configure).
2836
2837 R-65755 The xNF **SHOULD** support callback URLs to return information
2838 to ONAP upon completion of the chef-client run for any chef-client run
2839 associated with a xNF action.
2840
2841 R-15885 The xNF **MUST** Upon completion of the chef-client run,
2842 POST back on the callback URL, a JSON object as described in Table
2843 A2 if the chef-client run list includes a cookbook/recipe that is
2844 callback capable. Failure to POST on the Callback Url should not be
2845 considered a critical error. That is, if the chef-client successfully
2846 completes the xNF action, it should reflect this status on the Chef
2847 Server regardless of whether the Callback succeeded or not.
2848
2849 R-32217 The xNF **MUST** have routable FQDNs that are reachable via
2850 the Ansible Server for the endpoints (VMs) of a xNF on which playbooks
2851 will be executed. ONAP will initiate requests to the Ansible Server
2852 for invocation of playbooks against these end points [4]_.
2853
2854 R-54373 The xNF **MUST** have Python >= 2.6 on the endpoint VM(s)
2855 of a xNF on which an Ansible playbook will be executed.
2856
2857 R-35401 The xNF **MUST** support SSH and allow SSH access by the
2858 Ansible server for the endpoint VM(s) and comply with the Network
2859 Cloud Service Provider guidelines for authentication and access.
2860
2861 R-82018 The xNF **MUST** load the Ansible Server SSH public key onto xNF
2862 VM(s) as part of instantiation. This will allow the Ansible Server
2863 to authenticate to perform post-instantiation configuration without
2864 manual intervention and without requiring specific xNF login IDs
2865 and passwords.
2866
2867 R-92866 The xNF **MUST** include as part of post-instantiation configuration
2868 done by Ansible Playbooks the removal/update of the SSH public key from
2869 /root/.ssh/authorized_keys, and  update of SSH keys loaded through
2870 instantiation to support Ansible. This may include download and install of
2871 new SSH keys and new mechanized IDs.
2872
2873 R-91745 The xNF **MUST** update the Ansible Server and other entities
2874 storing and using the SSH keys for authentication when the SSH keys used
2875 by Ansible are regenerated/updated.
2876
2877 R-40293 The xNF **MUST** make available playbooks that conform
2878 to the ONAP requirement.
2879
2880 R-49396 The xNF **MUST** support each ONAP (APPC) xNF action by invocation
2881 of **one** playbook [7]_. The playbook will be responsible
2882 for executing all necessary tasks (as well as calling other playbooks)
2883 to complete the request.
2884
2885 R-33280 The xNF **MUST NOT** use any instance specific parameters
2886 in a playbook.
2887
2888 R-48698 The xNF **MUST** utilize information from key value pairs
2889 that will be provided by the Ansible Server as "extra-vars" during
2890 invocation to execute the desired xNF action. If the playbook requires
2891 files, they must also be supplied using the methodology detailed in
2892 the Ansible Server API, unless they are bundled with playbooks, example,
2893 generic templates.
2894
2895 R-43253 The xNF **MUST** use playbooks designed to allow Ansible
2896 Server to infer failure or success based on the “PLAY_RECAP” capability.
2897 NOTE: There are cases where playbooks need to interpret results of a task
2898 and then determine success or failure and return result accordingly
2899 (failure for failed tasks).
2900
2901 R-50252 The xNF **MUST** write to a specific one text files that
2902 will be retrieved and made available by the Ansible Server if, as part
2903 of a xNF action (e.g., audit), a playbook is required to return any
2904 xNF information. The text files must be written in the same directory as
2905 the one from which the playbook is being executed. A text file must be
2906 created for the xNF playbook run targets/affects, with the name
2907 ‘<VNFname>_results.txt’ into which any desired output from each
2908 respective VM/xNF must be written.
2909
2910 R-51442 The xNF **SHOULD** use playbooks that are designed to
2911 automatically ‘rollback’ to the original state in case of any errors
2912 for actions that change state of the xNF (e.g., configure).
2913
2914 R-58301 The xNF **SHOULD NOT** use playbooks that make requests to
2915 Cloud resources e.g. Openstack (nova, neutron, glance, heat, etc.);
2916 therefore, there is no use for Cloud specific variables like Openstack
2917 UUIDs in Ansible Playbooks.
2918
2919 R-02651 The xNF **SHOULD** use the Ansible backup feature to save a
2920 copy of configuration files before implementing changes to support
2921 operations such as backing out of software upgrades, configuration
2922 changes or other work as this will help backing out of configuration
2923 changes when needed.
2924
2925 R-43353 The xNF **MUST** return control from Ansible Playbooks only
2926 after tasks are fully complete, signaling that the playbook completed
2927 all tasks. When starting services, return control only after all services
2928 are up. This is critical for workflows where the next steps are dependent
2929
2930 R-51910 The xNF **MUST** provide all telemetry (e.g., fault event
2931 records, syslog records, performance records etc.) to ONAP using the
2932 model, format and mechanisms described in this section.
2933
2934 R-19624 The xNF **MUST** encode and serialize content delivered to
2935 ONAP using JSON (RFC 7159) plain text format. High-volume data is to
2936 be encoded and serialized using `Avro <http://avro.apache.org/>`_,
2937 where the Avro [6]_ data format are described using JSON.
2938
2939 Note:
2940
2941 - JSON plain text format is preferred for moderate volume data sets
2942   (option 1), as JSON has the advantage of having well-understood simple
2943   processing and being human-readable without additional decoding. Examples
2944   of moderate volume data sets include the fault alarms and performance
2945   alerts, heartbeat messages, measurements used for xNF scaling and syslogs.
2946 - Binary format using Avro is preferred for high volume data sets
2947   (option 2) such as mobility flow measurements and other high-volume
2948   streaming events (such as mobility signaling events or SIP signaling)
2949   or bulk data, as this will significantly reduce the volume of data
2950   to be transmitted. As of the date of this document, all events are
2951   reported using plain text JSON and REST.
2952 - Avro content is self-documented, using a JSON schema. The JSON schema is
2953   delivered along with the data content
2954   (http://avro.apache.org/docs/current/ ). This means the presence and
2955   position of data fields can be recognized automatically, as well as the
2956   data format, definition and other attributes. Avro content can be
2957   serialized as JSON tagged text or as binary. In binary format, the
2958   JSON schema is included as a separate data block, so the content is
2959   not tagged, further compressing the volume. For streaming data, Avro
2960   will read the schema when the stream is established and apply the
2961   schema to the received content.
2962
2963 R-98191 The xNF **MUST** vary the frequency that asynchronous data is
2964 delivered based on the content and how data may be aggregated or grouped
2965 together.
2966
2967 Note:
2968
2969 - For example, alarms and alerts are expected to be delivered as soon
2970   as they appear. In contrast, other content, such as performance
2971   measurements, KPIs or reported network signaling may have various ways
2972   of packaging and delivering content. Some content should be streamed
2973   immediately; or content may be monitored over a time interval, then packaged
2974   as collection of records and delivered as block; or data may be collected
2975   until a package of a certain size has been collected; or content may be
2976   summarized statistically over a time interval, or computed as a KPI, with
2977   the summary or KPI being delivered.
2978 - We expect the reporting frequency to be configurable depending
2979   on the virtual network function’s needs for management. For example,
2980   Service Provider may choose to vary the frequency of collection between
2981   normal and trouble-shooting scenarios.
2982 - Decisions about the frequency of data reporting will affect the
2983   size of delivered data sets, recommended delivery method, and how the
2984   data will be interpreted by ONAP. These considerations should not
2985   affect deserialization and decoding of the data, which will be guided
2986   by the accompanying JSON schema or GPB definition files.
2987
2988 R-88482 The xNF **SHOULD** use REST using HTTPS delivery of plain
2989 text JSON for moderate sized asynchronous data sets, and for high
2990 volume data sets when feasible.
2991
2992 R-84879 The xNF **MUST** have the capability of maintaining a primary
2993 and backup DNS name (URL) for connecting to ONAP collectors, with the
2994 ability to switch between addresses based on conditions defined by policy
2995 such as time-outs, and buffering to store messages until they can be
2996 delivered. At its discretion, the service provider may choose to populate
2997 only one collector address for a xNF. In this case, the network will
2998 promptly resolve connectivity problems caused by a collector or network
2999 failure transparently to the xNF.
3000
3001 R-81777 The xNF **MUST** be configured with initial address(es) to use
3002 at deployment time. Subsequently, address(es) may be changed through
3003 ONAP-defined policies delivered from ONAP to the xNF using PUTs to a
3004 RESTful API, in the same manner that other controls over data reporting
3005 will be controlled by policy.
3006
3007 R-08312 The xNF **MAY** use another option which is expected to include REST
3008 delivery of binary encoded data sets.
3009
3010 R-79412 The xNF **MAY** use another option which is expected to include TCP
3011 for high volume streaming asynchronous data sets and for other high volume
3012 data sets. TCP delivery can be used for either JSON or binary encoded data
3013 sets.
3014
3015 R-01033 The xNF **MAY** use another option which is expected to include SFTP
3016 for asynchronous bulk files, such as bulk files that contain large volumes of
3017 data collected over a long time interval or data collected across many xNFs.
3018 (Preferred is to reorganize the data into more frequent or more focused data
3019 sets, and deliver these by REST or TCP as appropriate.)
3020
3021 R-63229 The xNF **MAY** use another option which is expected to include REST
3022 for synchronous data, using RESTCONF (e.g., for xNF state polling).
3023
3024 R-03070 The xNF **MUST**, by ONAP Policy, provide the ONAP addresses
3025 as data destinations for each xNF, and may be changed by Policy while
3026 the xNF is in operation. We expect the xNF to be capable of redirecting
3027 traffic to changed destinations with no loss of data, for example from
3028 one REST URL to another, or from one TCP host and port to another.
3029
3030 R-06924 The xNF **MUST** deliver asynchronous data as data becomes
3031 available, or according to the configured frequency.
3032
3033 R-73285 The xNF **MUST** must encode, address and deliver the data
3034 as described in the previous paragraphs.
3035
3036 R-42140 The xNF **MUST** respond to data requests from ONAP as soon
3037 as those requests are received, as a synchronous response.
3038
3039 R-34660 The xNF **MUST** use the RESTCONF/NETCONF framework used by
3040 the ONAP configuration subsystem for synchronous communication.
3041
3042 R-86586 The xNF **MUST** use the YANG configuration models and RESTCONF
3043 [RFC8040] (https://tools.ietf.org/html/rfc8040).
3044
3045 R-11240 The xNF **MUST** respond with content encoded in JSON, as
3046 described in the RESTCONF specification. This way the encoding of a
3047 synchronous communication will be consistent with Avro.
3048
3049 R-70266 The xNF **MUST** respond to an ONAP request to deliver the
3050 current data for any of the record types defined in
3051 Event Records - Data Structure Description by returning the requested
3052 record, populated with the current field values. (Currently the defined
3053 record types include fault fields, mobile flow fields, measurements for
3054 xNF scaling fields, and syslog fields. Other record types will be added
3055 in the future as they become standardized and are made available.)
3056
3057 R-46290 The xNF **MUST** respond to an ONAP request to deliver granular
3058 data on device or subsystem status or performance, referencing the YANG
3059 configuration model for the xNF by returning the requested data elements.
3060
3061 R-43327 The xNF **SHOULD** use `Modeling JSON text with YANG
3062 <https://tools.ietf.org/html/rfc7951>`_, If YANG models need to be
3063 translated to and from JSON[RFC7951]. YANG configuration and content can
3064 be represented via JSON, consistent with Avro, as described in “Encoding
3065 and Serialization” section.
3066
3067 R-42366 The xNF **MUST** support secure connections and transports such as
3068 Transport Layer Security (TLS) protocol
3069 [`RFC5246 <https://tools.ietf.org/html/rfc5246>`_] and should adhere to
3070 the best current practices outlined in
3071 `RFC7525 <https://tools.ietf.org/html/rfc7525>`_.
3072
3073 R-44290 The xNF **MUST** control access to ONAP and to xNFs, and creation
3074 of connections, through secure credentials, log-on and exchange mechanisms.
3075
3076 R-47597 The xNF **MUST** carry data in motion only over secure connections.
3077
3078 R-68165 The xNF **MUST** encrypt any content containing Sensitive Personal
3079 Information (SPI) or certain proprietary data, in addition to applying the
3080 regular procedures for securing access and delivery.
3081
3082
3083 Ansible Playbook Examples
3084 -----------------------------------------------
3085
3086 The following sections contain examples of Ansible playbooks
3087 which follow the guidelines.
3088
3089 Guidelines for Playbooks to properly integrate with APPC
3090 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3091
3092 NOTE: To support concurrent requests to multiple VNF instances of same
3093 or different type, VNF hosts and other files with VNF specific default
3094 values are kept or created in separate directories.
3095
3096 Example of an Ansible command (after pwd) to run playbook again
3097 vfdb9904v VNF instance:
3098
3099 .. code-block:: none
3100
3101  $ pwd
3102  /storage/vfdb/V16.1/ansible/configure
3103  $ ansible-playbook -i ../inventory/vfdb9904vhosts site.yml --extra-vars "vnf_instance=vfdb9904v"
3104
3105  NOTE: To preserve Ansible inventory/group_vars capability, that makes
3106  group_vars contents global variables available to all playbooks, when they
3107  reside in the inventory directory, guidelines are being updated to name the
3108  VNF inventory hosts file as (a flat file) <VNFName>hosts, stored in the
3109  inventory directory, not a subdirectory under inventory. In the above
3110  example: vfdb9904vhosts (removed / VNF name and hosts vfdb9904/vhosts)
3111
3112 Example of corresponding APPC API Call from ONAP – Ansible Server
3113 Specifications:
3114
3115 An example of a curl request simulating a Rest API POST requesting execution
3116 of configure Playbook (using playbook relative path):
3117
3118 .. code-block:: none
3119
3120  curl -u APIUser:APIPassword -H "Content-type:application/json" -X POST
3121  -d '{"Id": "8412", "PlaybookName": "vfdb/V5.x.x/ansible/configure/site.yml",
3122  "Timeout":"600", "EnvParameters": { "vnf_instance": "vfdb9904v" }}'
3123  http://ansible.server.com:5000/Dispatch
3124
3125 Rest API GET request to obtain response/results for prior request
3126 (same Id as POST request above):
3127
3128 .. code-block:: none
3129
3130  curl -u APIUser:APIPassword -H 'Content-type: application/json' -X GET
3131  'http://ansible.server.com:5000/Dispatch/?Id=8412&Type=GetResult'
3132
3133 Comments:
3134
3135 -  An ID number is assigned to each request. This ID number is used to
3136    track request down to completion and provide status to APPC when
3137    requested.
3138
3139 -  Playbook Name relative path provided in the request as PlaybookName
3140
3141 -  Ansible Server Rest API is aware of playbook’s root directory which may
3142    vary from instance to instance or Ansible Server cluster to cluster.
3143
3144 Ansible Playbooks will use the VNF instance name (passed using
3145 --extra-vars "vnf\_instance=vfdb9904v") to identify other default values
3146 to run the playbook(s) against the target VNF instance. Same example as
3147 above:
3148
3149 .. code-block:: none
3150
3151  $ ansible-playbook -i ../inventory/vfdb9904vhosts site.yml --extra-vars "vnf_instance=vfdb9904v"
3152
3153 Each Ansible Server or cluster is assigned its own identification to be used
3154 to authenticate to VNF VMs using Ansible Server or cluster specific set of
3155 SSH keys that may be rotated regularly. Here hosts file, no longer referencing
3156 file with SSH key credentials, to run ansible-playbook listed in this example
3157 above (IP addresses were scrubbed):
3158
3159 .. code-block:: none
3160
3161  $ more ../inventory/vfdb9904v/hosts
3162  [host]
3163  localhost ansible_connection=local
3164
3165  [oam]
3166  1xx.2yy.zzz.109
3167  1xx.2yy.zzz.110
3168
3169  [rdb]
3170  1xx.2yy.zzz.105
3171  1xx.2yy.zzz.106
3172
3173 NOTE: APPC requests to run Playbooks/Cookbooks are specific to a VNF,
3174 but could be more limited to one VM or one type of VM by the request
3175 parameters. Actions that may impact a site (LCP), a service, or an
3176 entire platform must be orchestrated by MSO in order to execute requests
3177 via APPC which then invoke VNF level playbooks. Playbooks that impact
3178 more than a single VNF are not the current focus of these guidelines.
3179
3180 Since last release of these guidelines, based on recent learnings,
3181 moving VNF Type global variables under inventory/group_vars files, this
3182 way variables and respective values are available to all playbooks without
3183 being explicitly referenced though an include statement. Also creating
3184 templates that are VNF Type specific, but moving away from static files
3185 that are VNF instance specific, working to obtain VNF instance specific
3186 from other sources, inventory database, etc.
3187
3188 And here the scrubbed default arguments for this VNF instance(originated
3189 from previously re-factored playbooks now being phased out):
3190
3191 .. code-block:: none
3192
3193  vnf_instance=vfdb9904v
3194
3195  $ more ../vars/vfdb9904v/default_args.yml
3196  vm_config_oam_vnfc_name: vfdb9904vm001oam001
3197  vm_config_oam_hostname: vfdb9904vm001
3198  vm_config_oam_provider_ip_address: 1xx.2yy.zzz.109
3199  …
3200
3201 IMPORTANT: The APPC and default file attribute name for
3202 vm\_config\_oam\_vnfc\_name, as an example, is derived from vm\_config
3203 array structure (list) in the CSAR package ENV file, with dots replaced
3204 by underscore:
3205
3206 .. code-block:: none
3207
3208  vm_config:
3209
3210  oam: {vnfc_name: {{ vm_config_oam_vnfc_name }}, hostname: {{
3211  vm_config_oam_hostname }}, provider_ip_address: {{
3212  vm_config_oam_provider_ip_address }
3213  },
3214  …
3215
3216 Parameters like VNF names, VNFC names, OA&M IP addresses, after
3217 February, 2018 ONAP release, will be extracted from A&AI by APPC and
3218 then passed down to Ansible Server, as part of APPC request through REST
3219 API. In the meantime, VNF instance specific required values, will
3220 be stored on VNF instance directory, default arguments file and will be
3221 used as defaults. For parameterized playbooks attribute-value pairs
3222 passed down by APPC to Ansible Server always take precedence over
3223 template or VNF instance specific defaults stored in defaults file(s).
3224
3225 .. code-block:: none
3226
3227  $ pwd
3228  /storage/vfdb/latest/ansible
3229  Again, originated from previously re-factored playbooks now being phased out:
3230
3231  $ more vars/vfdb9904v/default_args.yml
3232
3233  vm_config_oam1_vnfc_name: vfdb9904vm001oam001
3234  vm_config_oam1_hostname: vfdb9904vm001
3235  vm_config_oam1_provider_ip_address: 1xx.2yy.zzz.109
3236
3237  vm_config_oam2_vnfc_name: vfdb9904vm002oam001
3238  vm_config_oam2_hostname: vfdb9904vm002
3239  vm_config_oam2_provider_ip_address: 1xx.2yy.zzz.110
3240
3241  vm_config_rdb1_vnfc_name: vfdb9904vm003rdb001
3242  vm_config_rdb1_hostname: vfdb9904vm003
3243  vm_config_rdb1_provider_ip_address: 1xx.2yy.zzz.105
3244
3245  vm_config_rdb2_vnfc_name: vfdb9904vm004rdb001
3246  vm_config_rdb2_hostname: vfdb9904vm004
3247  vm_config_rdb2_provider_ip_address: 1xx.2yy.zzz.106
3248
3249  vm_config_rdb3_vnfc_name: vfdb9904vm005rdb001
3250  vm_config_rdb3_hostname: vfdb9904vm005
3251  vm_config_rdb3_provider_ip_address: 1xx.2yy.zzz.xxx
3252
3253  vm_config_rdb4_vnfc_name: vfdb9904vm006rdb001
3254  vm_config_rdb4_hostname: vfdb9904vm006
3255  vm_config_rdb4_provider_ip_address: 1xx.2yy.zzz.yyy
3256
3257 One of the first tasks on the Ansible Playbooks is to combine the VNF
3258 type generic template, derived from ENV files in CSAR or other files,
3259 with these default values stored on the Ansible Server, together with
3260 the overriding parameters passed down from APPC, to create the VNF
3261 instance specific set of attribute-value pairs to be used for the run, in
3262 INI format. Here is an excerpt from such a file that should look
3263 somewhat similar to ENV files:
3264
3265 .. code-block:: none
3266
3267  $ more tmp/vfdb9904v/all.yml
3268
3269  deployment_prefix: vfdb9904v
3270  …
3271  timezone: Etc/UTC
3272  …
3273  template_version: '2014-10-16'
3274  stack_name: vfdb9904v
3275  c3dbtype: OAM
3276  stackName: vfdb9904v
3277  juno_base: true
3278  …
3279
3280 # logins list contain 'login name', 'login group', 'login password'
3281
3282 .. code-block:: none
3283
3284  logins:
3285  - { name: 'm99999', group: 'm99999', password: 'abcdefgha' }
3286  - { name: 'gsuser', group: 'gsuser', password: ' abcdefgha' }
3287  - { name: 'peruser', group: 'peruser', password: ' abcdefgha' }
3288  - { name: 'dbuser', group: 'dbuser', password: ' abcdefgha' }
3289
3290 NOTE: Arguments passed by APPC to Ansible Server to run a playbook take
3291 precedence over any defaults stored in Ansible Server.
3292
3293 Ansible Playbooks – Notes On Artifacts Required to Run Playbooks
3294 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3295
3296 Inventory hosts file: should be VNF instance specific.
3297
3298 Default variables: should be VNF instance specific.
3299
3300 NOTE: Some playbooks may rely on inventory directory contents to target
3301 the collection of VNFs in the Services Platform supported through
3302 Ansible.
3303
3304 Playbooks and paths to referenced files: Playbooks shall not use
3305 absolute paths in include or import entries (variables or playbooks) or
3306 other types of references.
3307
3308 For this to work properly, when running playbooks, the directory where
3309 the main playbook resides shall be the current directory.
3310
3311 Playbook imports, when used, shall use paths relative to the main
3312 playbook directory.
3313
3314 Root directory named ansible - Any files provided with playbooks,
3315 included, imported, or referenced by playbooks, shall reside under the ansible
3316 playbooks (root) directory, containing all playbook subdirectories, or
3317 below that ansible root directory, in other subdirectories to support
3318 on-boarding and portability of VNF collection of playbooks and related
3319 artifacts.
3320
3321 Designing for a shared environment, concurrently running playbooks,
3322 targeting multiple VNF instances – inventory hosts file:
3323
3324 To avoid inventory hosts file overwrites or collisions between multiple
3325 concurrently running VNF instance requests, chosen approach is for each
3326 VNF instance hosts file, to be stored under the Ansible Server Playbooks
3327 root directory, under the inventory subdirectory, and under a directory
3328 for each VNF instance, named after the VNF instance, as follows:
3329
3330 ansible/inventory/<VNF\_instance\_name>/hosts
3331
3332 Example of inventory hosts file path, relative to ansible playbooks root
3333 directory (playbooks\_dir): ansible/inventory/vnfx0001v/hosts
3334
3335 **Designing for a shared environment, concurrently running multiple playbooks,
3336 targeting multiple VNF instances – default argument variables for
3337 specific VNF instances:**
3338
3339 Files containing attribute name value pairs (variable name and default
3340 values), referenced/included by playbooks – Files containing VNF
3341 instance specific default values – in a later APPC release, some or all
3342 the default attribute value pairs contained in the defaults file, may be
3343 passed down by APPC, to the Ansible Server, overriding these defaults:
3344
3345 VNF instance specific files
3346 referenced/included by playbooks, containing default values, example,
3347 default\_args.yml, shall be stored under a directory with VNF instance
3348 name on the path.
3349
3350 Example:
3351
3352 ansible/vars/<VNF\_instance\_name>/default\_args.yml
3353
3354 Example of include statement:
3355
3356 - include_vars: ../vars/{{ vnf_instance }}/default_args.yml
3357
3358 Again, this was originated from previously re-factored playbooks, now being
3359 phased out, to move away from having to create VNF instance specific files
3360 with VNF instance default variables. Moving to extract these values from
3361 inventory databases and provide them to Ansible Server as part of the APPC
3362 request, but may be used in a transition from having everything stored in the
3363 Ansible Server to APPC extracting and providing VNF instance specific
3364 attribute-value pairs to the Ansible Server as part of the request.
3365
3366 Files containing attribute name value pairs (variable name and default
3367 values), referenced/included by playbooks – created dynamically by
3368 playbooks:
3369
3370 To avoid
3371 overwrites or collisions of multiple concurrently running VNF instance
3372 requests, files created dynamically by playbooks, based on VNF generic
3373 templates, combined with default values and arguments passed down by
3374 APPC (as part of the request), shall be stored under a directory with
3375 VNF instance name on the path.
3376
3377 Example:
3378
3379 tmp/<VNF\_instance\_name>/all.yml
3380
3381 Files containing site specific (Openstack location non-instance
3382 specific) attribute name value pairs, like NTP server and DNS server’s
3383 IP addresses and other parameters, referenced/included by playbooks, not
3384 VNF specific – Could/should be stored under inventory/group_vars directory,
3385 in a subdirectory named after the string used to identify the site (nyc1,
3386 lax2,…).
3387
3388 Examples:
3389
3390 ansible/inventory/group_vars/<Site>
3391
3392 ansible/inventory/group_vars/nyc1
3393
3394 ansible/inventory/group_vars/lax2
3395
3396
3397 \ **Ansible Server Design - Directory Structure**
3398
3399 To help understanding the contents of this section, here are few basic
3400 definitions:
3401
3402 **VNF type a.k.a VNF Function Code** - Based on current Services
3403 Platform naming convention, each Virtual Network Function is assigned a
3404 4 character string (example vfdb), these are 4 characters in
3405 the VNF instance name, followed by (4) numbers, ending in a "v", but the
3406 naming convention is evolving. VNF instance name in
3407 some cases corresponds to the stack name for the VNF when VNF instance
3408 is built based on a single module, single stack. Example of VNF instance
3409 name: vfdb9904v. All VNF performing this function, running the same
3410 software, coming from the same VNF provider will have the same 4
3411 characters in the VNF instance name, in this example, vfdb.
3412
3413 NOTE: New naming convention includes a prefix indicating geographical
3414 location where VNF is instantiated.
3415
3416 VNF type, determined through these 4 characters, is also known as VNF
3417 Function Code and is assigned by inventory team. All Services Platform
3418 VNF Function Codes can be found in inventory database and/or A&AI as
3419 well as Services Platform Network Design Documents.
3420
3421 Version – As in VNF software version is the release of the software
3422 running on the VNF for which the playbooks were developed. VNF
3423 configuration steps may change from release to release and this
3424 <Version> in the path will allow the Ansible Server to host playbooks
3425 associated with each software release. And run the playbooks that match
3426 the software release running on each VNF instance. APPC initially will
3427 not support playbook versioning only latest playbook is supported or a hard
3428 coded version that later should become a variable to allow multiple
3429 actively in use playbook versions according to VNF release.
3430
3431 Playbook Function - Is a name associated with a life cycle management
3432 task(s) performed by the playbook(s) stored in this directory. It should
3433 clearly identify the type of action(s) performed by the main playbook
3434 and possibly other playbooks stored in this same directory. Ideally,
3435 playbook function would match APPC corresponding command or function that
3436 is performed by the main playbook in this directory. Following Ansible naming
3437 standards main playbook is usually named site.yml. There can be other
3438 playbooks on the same directory that use a subset of the roles used by the
3439 main playbook site.yml. Examples of Playbook Function directory names:
3440
3441 -  configure – Contains post-instantiation (bulk) configuration
3442    playbooks, roles,…
3443
3444 -  healthcheck – Contains VNF health check playbook(s), roles,…
3445
3446 -  stop – Contains VNF application stop  (stopApplication) playbook(s),
3447    roles,…
3448
3449 -  start – Contains VNF application start (startApplication) playbook(s),
3450    roles,…
3451
3452 Directory structure to allow hosting multiple version sets of playbooks,
3453 for the same VNF type, to be hosted in the runtime environment on the
3454 Ansible Servers. Generic directory structure:
3455
3456 Ansible Playbooks – Function directory and main playbook:
3457
3458 .. code-block:: none
3459
3460  <VNF type>/<Version>/ansible/<Playbook Function>/site.yml
3461
3462 Example – Post-instantiation (bulk) configuration –APPC Function -
3463 Configure:
3464
3465 .. code-block:: none
3466
3467  <VNF type>/<Version>/ansible/configure/site.yml
3468
3469 Example – Post-instantiation (bulk) configuration –APPC Function
3470 – Configure – VNF software version 16.1:
3471
3472 .. code-block:: none
3473
3474  vfdb/V16.1/ansible/configure/site.yml
3475
3476 Example – Health-check –APPC Function - HealthCheck:
3477
3478 .. code-block:: none
3479
3480  <VNF type>/<Version>/ansible/healthcheck/site.yml
3481
3482 OR (Function directory name does not need to match APPC function name)
3483
3484 .. code-block:: none
3485
3486  <VNF type>/<Version>/ansible/check/site.yml
3487
3488 Ansible Directories for other artifacts – VNF inventory hosts file -
3489 Required:
3490
3491 .. code-block:: none
3492
3493  <VNF type>/<Version>/ansible/inventory/<VNF instance name>hosts
3494
3495 Ansible Directories for other artifacts – VNF instance specific default
3496 arguments – Optional:
3497
3498 .. code-block:: none
3499
3500  <VNF type>/<Version>/ansible/group_vars/<VNF instance name>
3501
3502 NOTE: This requirement is expected to be deprecated all or in part in the
3503 future, for automated actions, once APPC can pass down all VNF specific
3504 arguments for each action. Requirement remains while manual actions are
3505 to be supported. Other automated inventory management mechanisms may be
3506 considered in the future, Ansible supports many automated inventory
3507 management mechanisms/tools/solutions.
3508
3509 Ansible Directories for other artifacts – VNF (special) groups –
3510 Optional:
3511
3512 .. code-block:: none
3513
3514  <VNF type>/<Version>/ansible/inventory/group_vars/<VNF instance name>
3515
3516 NOTE: Default groups will be created based on VNFC type, 3 characters,
3517 on VNFC name. Example: “oam”, “rdb”, “dbs”, “man”, “iox”, “app”,…
3518
3519 Ansible Directories for other artifacts – VNF (special) other files –
3520 Optional – Example – License file:
3521
3522 .. code-block:: none
3523
3524  <VNF type>/<Version>/ansible/<Other directory(s)>
3525
3526 CAUTION: On referenced files used/required by playbooks.
3527
3528 -  To avoid missing files, during on-boarding or uploading of Ansible
3529    Playbooks and related artifacts, all permanent files (not generated
3530    by playbooks as part of execution), required to run any playbook,
3531    shall reside under the ansible root directory or below on other
3532    subdirectories.
3533
3534 -  Any references to files, on includes or other playbook entries, shall
3535    use relative paths.
3536
3537 -  This is the ansible (root) directory referenced on this
3538    note (Ansible Server mount point not included):
3539
3540 .. code-block:: none
3541
3542      <VNF type>/<Version>/ansible/
3543
3544 There will be a soft link to the latest set of Ansible Playbooks for
3545 each VNF type.
3546
3547 VNF type directories use A&AI inventory VNF function code. Ansible
3548 Playbooks will be stored on a Cinder Volume mounted on the Ansible
3549 Servers as /storage. Example:
3550
3551 /storage/vfdb/latest/ansible – This soft link point to the latest set of
3552 playbooks (or the only set)
3553
3554 /storage/vfdb/V16.1/ansible – Root directory for database VNF Ansible
3555 Playbooks for release 16.1
3556
3557 CAUTION: To support this directory structure as the repository to store
3558 Ansible Playbooks run by APPC, APPC API in the Ansible Server side needs
3559 to be configured to run playbooks from directory, not MySQL database.
3560
3561 Ansible Server HTTP will be configured to support APPC REST API requests
3562 to run playbooks as needed, against specific VNF instances, or specific
3563 VM(s) as specified in the request.
3564
3565 ONAP APPC REST API to Ansible Server is documented separately and can be
3566 found under ONAP (onap.org).
3567
3568 **Ansible Server – On-boarding Ansible Playbooks**
3569
3570 Once playbooks are developed following the guidelines listed in prior
3571 section(s), playbooks need to be on-boarded onto Ansible Server(s). In
3572 the future, they’ll be on-boarded and distributed through ONAP, at least
3573 that is the proposed plan, but for now they need to be uploaded
3574 manually. There is work in progress to use a Git as the playbook
3575 repository to store and track playbooks by version, version control.
3576
3577 These are the basic steps to on-board playbooks manually onto the
3578 Ansible Server.
3579
3580 1. Upload CSAR, zip, or tar file containing VNF playbooks and related
3581    artifacts.
3582
3583 2. Create full directory (using –p option below) to store Ansible
3584    Playbooks and other artifacts under /storage (or other configured)
3585    file system.
3586
3587    a. Includes VNF type using VNF function code 4 characters under
3588       /storage.
3589
3590    b. Includes VNF “Version” directory as part of the path to store
3591       playbooks for this VNF version.
3592
3593    c. Include generic ansible root directory. Creating full directory
3594       path as an example:
3595
3596 .. code-block:: none
3597
3598      $ mkdir –p /storage/vfdb/V16.1/ansible**/**
3599
3600 3. Make this directory (VNF ansible root directory) current directory
3601    for next few steps:
3602
3603 .. code-block:: none
3604
3605      cd /storage/vfdb/V16.1/ansible/
3606
3607 4. Extract Ansible Playbooks and other Ansible artifacts associated with
3608    the playbooks onto the ansible directory. Command depends on the type
3609    of file uploaded, examples would be:
3610
3611 .. code-block:: none
3612
3613      tar xvf ..
3614      unzip …
3615      bunzip ..
3616
3617 5. Create VNF inventory hosts file with all VMs and
3618    OA&M IP addresses for all VNF instances with known OA&M IP addresses
3619    for respective VMs, example:
3620
3621 .. code-block:: none
3622
3623     $ mkdir inventory
3624
3625     $ touch inventory/vfdb9904vhosts
3626
3627     $ cat inventory/vfdb9904vhosts
3628
3629     [host]
3630     localhost ansible\_connection=local
3631
3632     [oam]
3633     1xx.2yy.zzz.109
3634     1xx.2yy.zzz.110
3635
3636     [rdb]
3637     1xx.2yy.zzz.105
3638     1xx.2yy.zzz.106
3639
3640 6. (Optional, being deprecated) Create directory to hold default
3641 arguments for each VNF instance,
3642 example:
3643
3644 .. code-block:: none
3645
3646    $ mkdir –p vars/vfdb9904v
3647    $ touch vars/vfdb9904v/default\_args.yml
3648    $ cat vars/vfdb9904v/default\_args.yml
3649    vm\_config\_oam1\_vnfc\_name: vfdb9904vm001oam001
3650    vm\_config\_oam1\_hostname: vfdb9904vm001
3651    vm\_config\_oam1\_provider\_ip\_address: 1xx.2yy.zzz.109
3652
3653    vm\_config\_oam2\_vnfc\_name: vfdb9904vm002oam001
3654    vm\_config\_oam2\_hostname: vfdb9904vm002
3655    vm\_config\_oam2\_provider\_ip\_address: 1xx.2yy.zzz.110
3656
3657    vm\_config\_rdb1\_vnfc\_name: vfdb9904vm003rdb001
3658    vm\_config\_rdb1\_hostname: vfdb9904vm003
3659    vm\_config\_rdb1\_provider\_ip\_address: 1xx.2yy.zzz.105
3660
3661    vm\_config\_rdb2\_vnfc\_name: vfdb9904vm004rdb001
3662    vm\_config\_rdb2\_hostname: vfdb9904vm004
3663    vm\_config\_rdb2\_provider\_ip\_address: 1xx.2yy.zzz.106
3664
3665    vm\_config\_rdb3\_vnfc\_name: vfdb9904vm005rdb001
3666    vm\_config\_rdb3\_hostname: vfdb9904vm005
3667    vm\_config\_rdb3\_provider\_ip\_address: 1xx.2yy.zzz.xxx
3668
3669    vm\_config\_rdb4\_vnfc\_name: vfdb9904vm006rdb001
3670    vm\_config\_rdb4\_hostname: vfdb9904vm006
3671    vm\_config\_rdb4\_provider\_ip\_address: 1xx.2yy.zzz.yyy
3672
3673 NOTE: Please note names in this file shall use underscore “\_” not dots
3674 “.” or dashes “-“.
3675
3676 7. Perform some basic playbook validation running with “--check” option,
3677    running dummy playbooks or other.
3678
3679 NOTE: Each Ansible Server or cluster of Ansible Server will have its own
3680 credentials to authenticate to VNF VMs. Ansible Server SSH public key(s)
3681 have to be loaded onto VNF VMs during instantiation or other way before
3682 Ansible Server can access VNF VMs and run playbooks. HOT templates used
3683 by heat to instantiate VNFs to be configured by these Ansible Servers running
3684 playbooks shall include the same SSH public key and load them onto VNF VM(s)
3685 as part of instantiation.
3686
3687 Other non-vendor specific playbook tasks need to be incorporated in overall
3688 post-instantiation configuration playbook. Alternative is for company
3689 developed playbooks to be uploaded and executed, after VNF vendor provided
3690 playbooks are run.
3691
3692 **A couple of playbooks used for proof-of-concept testing as examples:**
3693
3694 UpgradePreCheck:
3695
3696 .. code-block:: none
3697
3698  $ pwd
3699  /storage/comx/V5.3.1.3/ansible/upgradeprecheck
3700
3701  $ more site.yml
3702  ---
3703
3704  - import_playbook: ../common/create_vars.yml
3705  - import_playbook: ../common/create_hosts.yml
3706
3707  - name: upgrade software pre check
3708    hosts: oam,dbs,cpm
3709    gather_facts: no
3710    become: true
3711    become_method: sudo
3712    become_user: root
3713    max_fail_percentage: 0
3714    any_errors_fatal: True
3715    roles:
3716      - precheck
3717    tags: precheck
3718
3719  $ more roles/precheck/tasks/main.yml
3720  ---
3721
3722  - include_vars: /tmp/{{ vnf_instance }}/all.yml
3723
3724  - name: get software version installed on vnf
3725    shell: grep "^SW_VERSION =" /vendor/software/config/param_common.cfg | grep -c "{{ existing_software_version }}"
3726    register: version_line
3727    ignore_errors: yes
3728
3729  - name: send msg when matches expected version
3730    debug:  msg="*** OK *** VNF software release matches (old) release to be upgraded."
3731     verbosity=1
3732    when: version_line.stdout.find('1') != -1
3733
3734  # send warning message and failure when release is not a match
3735  - fail:
3736      msg="*** WARNING *** VNF software release does not match expected (pre-upgrade) release."
3737    when: (version_line | failed) or version_line.stdout.find('1') == -1
3738
3739
3740 UpgradePostCheck:
3741
3742 .. code-block:: none
3743
3744  $ pwd
3745  /storage/comx/V5.3.1.3/ansible/upgradepostcheck
3746
3747  $ more site.yml
3748  ---
3749
3750  - import_playbook: ../common/create_vars.yml
3751  - import_playbook: ../common/create_hosts.yml
3752
3753  - name: upgrade software post check
3754    hosts: oam,dbs,cpm
3755    gather_facts: no
3756    become: true
3757    become_method: sudo
3758    become_user: root
3759    max_fail_percentage: 0
3760    any_errors_fatal: True
3761    roles:
3762      - postcheck
3763    tags: postcheck
3764
3765  $ more roles/postcheck/tasks/main.yml
3766  ---
3767
3768  - include_vars: /tmp/{{ vnf_instance }}/all.yml
3769
3770  - name: get post upgrade software version installed on vnf
3771    shell: grep "^SW_VERSION =" /vendor/software/config/param_common.cfg | grep -c "{{ new_software_version }}"
3772    register: version_line
3773    ignore_errors: yes
3774
3775  - name: send msg when matches expected version
3776    debug:  msg="*** OK *** VNF software release matches new release."
3777      verbosity=1
3778    when: version_line.stdout.find('1') != -1
3779
3780  # send warning message and failure when release is not a match
3781  - fail:
3782      msg="*** WARNING *** VNF software release does not match expected new (post-upgrade) release."
3783    when: (version_line | failed) or version_line.stdout.find('1') == -1
3784
3785
3786 .. [1]
3787    The “name” field is a mandatory field in a valid Chef Node Object
3788    JSON dictionary.
3789
3790 .. [2]
3791    Not currently supported in ONAP release 1
3792
3793 .. [3]
3794    https://github.com/mbj4668/pyang
3795
3796 .. [4]
3797    Upstream elements must provide the appropriate FQDN in the request to
3798    ONAP for the desired action.
3799
3800 .. [5]
3801    Refer to NCSP’s Network Cloud specification
3802
3803 .. [6]
3804    This option is not currently supported in ONAP and it is currently
3805    under consideration.
3806
3807 .. [7]
3808    Multiple ONAP actions may map to one playbook.
3809