1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245
|
<pre>Internet Engineering Task Force (IETF) A. Bierman
Request for Comments: 8341 YumaWorks
STD: 91 M. Bjorklund
Obsoletes: <a href="./rfc6536">6536</a> Tail-f Systems
Category: Standards Track March 2018
ISSN: 2070-1721
<span class="h1">Network Configuration Access Control Model</span>
Abstract
The standardization of network configuration interfaces for use with
the Network Configuration Protocol (NETCONF) or the RESTCONF protocol
requires a structured and secure operating environment that promotes
human usability and multi-vendor interoperability. There is a need
for standard mechanisms to restrict NETCONF or RESTCONF protocol
access for particular users to a preconfigured subset of all
available NETCONF or RESTCONF protocol operations and content. This
document defines such an access control model.
This document obsoletes <a href="./rfc6536">RFC 6536</a>.
Status of This Memo
This is an Internet Standards Track document.
This document is a product of the Internet Engineering Task Force
(IETF). It represents the consensus of the IETF community. It has
received public review and has been approved for publication by the
Internet Engineering Steering Group (IESG). Further information on
Internet Standards is available in <a href="./rfc7841#section-2">Section 2 of RFC 7841</a>.
Information about the current status of this document, any errata,
and how to provide feedback on it may be obtained at
<a href="https://www.rfc-editor.org/info/rfc8341">https://www.rfc-editor.org/info/rfc8341</a>.
<span class="grey">Bierman & Bjorklund Standards Track [Page 1]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-2" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
Copyright Notice
Copyright (c) 2018 IETF Trust and the persons identified as the
document authors. All rights reserved.
This document is subject to <a href="https://www.rfc-editor.org/bcp/bcp78">BCP 78</a> and the IETF Trust's Legal
Provisions Relating to IETF Documents
(<a href="https://trustee.ietf.org/license-info">https://trustee.ietf.org/license-info</a>) in effect on the date of
publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License.
Table of Contents
<a href="#section-1">1</a>. Introduction ....................................................<a href="#page-4">4</a>
<a href="#section-1.1">1.1</a>. Terminology ................................................<a href="#page-4">4</a>
<a href="#section-1.2">1.2</a>. Changes since <a href="./rfc6536">RFC 6536</a> .....................................<a href="#page-6">6</a>
<a href="#section-2">2</a>. Access Control Design Objectives ................................<a href="#page-7">7</a>
<a href="#section-2.1">2.1</a>. Access Control Points ......................................<a href="#page-7">7</a>
<a href="#section-2.2">2.2</a>. Simplicity .................................................<a href="#page-8">8</a>
<a href="#section-2.3">2.3</a>. Procedural Interface .......................................<a href="#page-8">8</a>
<a href="#section-2.4">2.4</a>. Datastore Access ...........................................<a href="#page-8">8</a>
<a href="#section-2.5">2.5</a>. Users and Groups ...........................................<a href="#page-8">8</a>
<a href="#section-2.6">2.6</a>. Maintenance ................................................<a href="#page-9">9</a>
<a href="#section-2.7">2.7</a>. Configuration Capabilities .................................<a href="#page-9">9</a>
<a href="#section-2.8">2.8</a>. Identifying Security-Sensitive Content .....................<a href="#page-9">9</a>
<a href="#section-3">3</a>. NETCONF Access Control Model (NACM) ............................<a href="#page-10">10</a>
<a href="#section-3.1">3.1</a>. Overview ..................................................<a href="#page-10">10</a>
<a href="#section-3.1.1">3.1.1</a>. Features ...........................................<a href="#page-10">10</a>
<a href="#section-3.1.2">3.1.2</a>. External Dependencies ..............................<a href="#page-11">11</a>
<a href="#section-3.1.3">3.1.3</a>. Message Processing Model ...........................<a href="#page-11">11</a>
<a href="#section-3.2">3.2</a>. Datastore Access ..........................................<a href="#page-14">14</a>
<a href="#section-3.2.1">3.2.1</a>. Mapping New Datastores to NACM .....................<a href="#page-14">14</a>
<a href="#section-3.2.2">3.2.2</a>. Access Rights ......................................<a href="#page-14">14</a>
<a href="#section-3.2.3">3.2.3</a>. RESTCONF Methods ...................................<a href="#page-15">15</a>
<a href="#section-3.2.4">3.2.4</a>. <get> and <get-config> Operations ..................<a href="#page-16">16</a>
<a href="#section-3.2.5">3.2.5</a>. <edit-config> Operation ............................<a href="#page-16">16</a>
<a href="#section-3.2.6">3.2.6</a>. <copy-config> Operation ............................<a href="#page-18">18</a>
<a href="#section-3.2.7">3.2.7</a>. <delete-config> Operation ..........................<a href="#page-18">18</a>
<a href="#section-3.2.8">3.2.8</a>. <commit> Operation .................................<a href="#page-19">19</a>
<a href="#section-3.2.9">3.2.9</a>. <discard-changes> Operation ........................<a href="#page-19">19</a>
<a href="#section-3.2.10">3.2.10</a>. <kill-session> Operation ..........................<a href="#page-19">19</a>
<span class="grey">Bierman & Bjorklund Standards Track [Page 2]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-3" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<a href="#section-3.3">3.3</a>. Model Components ..........................................<a href="#page-19">19</a>
<a href="#section-3.3.1">3.3.1</a>. Users ..............................................<a href="#page-19">19</a>
<a href="#section-3.3.2">3.3.2</a>. Groups .............................................<a href="#page-20">20</a>
<a href="#section-3.3.3">3.3.3</a>. Emergency Recovery Session .........................<a href="#page-20">20</a>
<a href="#section-3.3.4">3.3.4</a>. Global Enforcement Controls ........................<a href="#page-20">20</a>
<a href="#section-3.3.4.1">3.3.4.1</a>. enable-nacm Switch ........................<a href="#page-20">20</a>
<a href="#section-3.3.4.2">3.3.4.2</a>. read-default Switch .......................<a href="#page-20">20</a>
<a href="#section-3.3.4.3">3.3.4.3</a>. write-default Switch ......................<a href="#page-21">21</a>
<a href="#section-3.3.4.4">3.3.4.4</a>. exec-default Switch .......................<a href="#page-21">21</a>
<a href="#section-3.3.4.5">3.3.4.5</a>. enable-external-groups Switch .............<a href="#page-22">22</a>
<a href="#section-3.3.5">3.3.5</a>. Access Control Rules ...............................<a href="#page-22">22</a>
<a href="#section-3.4">3.4</a>. Access Control Enforcement Procedures .....................<a href="#page-22">22</a>
<a href="#section-3.4.1">3.4.1</a>. Initial Operation ..................................<a href="#page-23">23</a>
<a href="#section-3.4.2">3.4.2</a>. Session Establishment ..............................<a href="#page-23">23</a>
<a href="#section-3.4.3">3.4.3</a>. "access-denied" Error Handling .....................<a href="#page-23">23</a>
<a href="#section-3.4.4">3.4.4</a>. Incoming RPC Message Validation ....................<a href="#page-24">24</a>
<a href="#section-3.4.5">3.4.5</a>. Data Node Access Validation ........................<a href="#page-26">26</a>
<a href="#section-3.4.6">3.4.6</a>. Outgoing <notification> Authorization ..............<a href="#page-29">29</a>
<a href="#section-3.5">3.5</a>. Data Model Definitions ....................................<a href="#page-31">31</a>
<a href="#section-3.5.1">3.5.1</a>. Data Organization ..................................<a href="#page-31">31</a>
<a href="#section-3.5.2">3.5.2</a>. YANG Module ........................................<a href="#page-32">32</a>
<a href="#section-4">4</a>. IANA Considerations ............................................<a href="#page-42">42</a>
<a href="#section-5">5</a>. Security Considerations ........................................<a href="#page-42">42</a>
<a href="#section-5.1">5.1</a>. NACM Configuration and Monitoring Considerations ..........<a href="#page-43">43</a>
<a href="#section-5.2">5.2</a>. General Configuration Issues ..............................<a href="#page-45">45</a>
<a href="#section-5.3">5.3</a>. Data Model Design Considerations ..........................<a href="#page-47">47</a>
<a href="#section-6">6</a>. References .....................................................<a href="#page-47">47</a>
<a href="#section-6.1">6.1</a>. Normative References ......................................<a href="#page-47">47</a>
<a href="#section-6.2">6.2</a>. Informative References ....................................<a href="#page-49">49</a>
<a href="#appendix-A">Appendix A</a>. Usage Examples ........................................<a href="#page-50">50</a>
<a href="#appendix-A.1">A.1</a>. <groups> Example ...........................................<a href="#page-50">50</a>
<a href="#appendix-A.2">A.2</a>. Module Rule Example ........................................<a href="#page-51">51</a>
<a href="#appendix-A.3">A.3</a>. Protocol Operation Rule Example ............................<a href="#page-53">53</a>
<a href="#appendix-A.4">A.4</a>. Data Node Rule Example .....................................<a href="#page-55">55</a>
<a href="#appendix-A.5">A.5</a>. Notification Rule Example ..................................<a href="#page-57">57</a>
Authors' Addresses ................................................<a href="#page-58">58</a>
<span class="grey">Bierman & Bjorklund Standards Track [Page 3]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-4" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h2"><a class="selflink" id="section-1" href="#section-1">1</a>. Introduction</span>
The Network Configuration Protocol (NETCONF) and the RESTCONF
protocol do not provide any standard mechanisms to restrict the
protocol operations and content that each user is authorized to
access.
There is a need for interoperable management of the controlled access
to administrator-selected portions of the available NETCONF or
RESTCONF content within a particular server.
This document addresses access control mechanisms for the Operations
and Content layers of NETCONF, as defined in [<a href="./rfc6241" title=""Network Configuration Protocol (NETCONF)"">RFC6241</a>]; and RESTCONF,
as defined in [<a href="./rfc8040" title=""RESTCONF Protocol"">RFC8040</a>]. It contains three main sections:
1. Access Control Design Objectives
2. NETCONF Access Control Model (NACM)
3. YANG Data Model (ietf-netconf-acm.yang)
YANG version 1.1 [<a href="./rfc7950" title=""The YANG 1.1 Data Modeling Language"">RFC7950</a>] adds two new constructs that need special
access control handling. The "action" statement is similar to the
"rpc" statement, except that it is located within a data node. The
"notification" statement can also be located within a data node.
<span class="h3"><a class="selflink" id="section-1.1" href="#section-1.1">1.1</a>. Terminology</span>
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" in this document are to be interpreted as described in
<a href="https://www.rfc-editor.org/bcp/bcp14">BCP 14</a> [<a href="./rfc2119" title=""Key words for use in RFCs to Indicate Requirement Levels"">RFC2119</a>] [<a href="./rfc8174" title=""Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words"">RFC8174</a>] when, and only when, they appear in all
capitals, as shown here.
The following terms are defined in [<a href="./rfc8342" title=""Network Management Datastore Architecture (NMDA)"">RFC8342</a>] and are not redefined
here:
o datastore
o configuration datastore
o conventional configuration datastore
o candidate configuration datastore
o running configuration datastore
o startup configuration datastore
<span class="grey">Bierman & Bjorklund Standards Track [Page 4]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-5" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
o operational state datastore
o client
o server
The following terms are defined in [<a href="./rfc6241" title=""Network Configuration Protocol (NETCONF)"">RFC6241</a>] and are not redefined
here:
o protocol operation
o session
o user
The following terms are defined in [<a href="./rfc7950" title=""The YANG 1.1 Data Modeling Language"">RFC7950</a>] and are not redefined
here:
o action
o data node
o data definition statement
The following terms are defined in [<a href="./rfc8040" title=""RESTCONF Protocol"">RFC8040</a>] and are not redefined
here:
o data resource
o datastore resource
o operation resource
o target resource
The following term is defined in [<a href="./rfc7230" title=""Hypertext Transfer Protocol (HTTP/1.1): Message Syntax and Routing"">RFC7230</a>] and is not redefined here:
o request URI
The following terms are used throughout this document:
access control: A security feature provided by the server that
allows an administrator to restrict access to a subset of all
protocol operations and data, based on various criteria.
access control model (ACM): A conceptual model used to configure and
monitor the access control procedures desired by the administrator
to enforce a particular access control policy.
<span class="grey">Bierman & Bjorklund Standards Track [Page 5]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-6" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
access control rule: The criterion used to determine if a particular
access operation will be permitted or denied.
access operation: How a request attempts to access a conceptual
object. One of "none", "read", "create", "delete", "update", or
"execute".
data node hierarchy: The hierarchy of data nodes that identifies the
specific "action" or "notification" node in the datastore.
recovery session: A special administrative session that is given
unlimited NETCONF access and is exempt from all access control
enforcement. The mechanism or mechanisms used by a server to
control and identify whether or not a session is a recovery
session are implementation specific and are outside the scope of
this document.
write access: A shorthand for the "create", "delete", and "update"
access operations.
<span class="h3"><a class="selflink" id="section-1.2" href="#section-1.2">1.2</a>. Changes since <a href="./rfc6536">RFC 6536</a></span>
The NACM procedures and data model have been updated to support new
data modeling capabilities in version 1.1 of the YANG data modeling
language. The "action" and "notification" statements can be used
within data nodes to define data-model-specific operations and
notifications.
An important use case for these new YANG statements is the increased
access control granularity that can be achieved over top-level "rpc"
and "notification" statements. The new "action" and "notification"
statements are used within data nodes, and access to the action or
notification can be restricted to specific instances of these data
nodes.
Support for the RESTCONF protocol has been added. The RESTCONF
operations are similar to the NETCONF operations, so a simple mapping
to the existing NACM procedures and data model is possible.
The data node access behavior for path matches has been clarified to
also include matching descendant nodes of the specified path.
The <edit-config> operation access rights behavior has been clarified
to indicate that write access is not required for data nodes that are
implicitly modified through side effects (such as the evaluation of
YANG when-stmts, or data nodes implicitly deleted when creating a
data node under a different branch under a YANG choice-stmt).
<span class="grey">Bierman & Bjorklund Standards Track [Page 6]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-7" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
The Security Considerations section has been updated to comply with
the "YANG module security guidelines" [<a href="#ref-YANG-SEC" title=""YANG Security Guidelines"">YANG-SEC</a>]. Note that the YANG
module in this document does not define any RPC operations.
<span class="h2"><a class="selflink" id="section-2" href="#section-2">2</a>. Access Control Design Objectives</span>
This section documents the design objectives for the NETCONF access
control model presented in <a href="#section-3">Section 3</a>.
<span class="h3"><a class="selflink" id="section-2.1" href="#section-2.1">2.1</a>. Access Control Points</span>
NETCONF allows server implementers to add new custom protocol
operations, and the YANG data modeling language supports this
feature. These operations can be defined in standard or proprietary
YANG modules.
It is not possible to design an ACM for NETCONF that only focuses on
a static set of standard protocol operations defined by NETCONF
itself, like some other protocols. Since few assumptions can be made
about an arbitrary protocol operation, the NETCONF architectural
server components need to be protected at three conceptual control
points.
These access control points, described in Figure 1, are as follows:
protocol operation: Permission to invoke specific protocol
operations.
datastore: Permission to read and/or alter specific data nodes
within any datastore.
notification: Permission to receive specific notification event
types.
+-------------+ +-------------+
client | protocol | | data node |
request --> | operation | -------------> | access |
| allowed? | datastore | allowed? |
+-------------+ or state +-------------+
data access
+----------------+
| notification |
event --> | allowed? |
+----------------+
Figure 1
<span class="grey">Bierman & Bjorklund Standards Track [Page 7]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-8" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="section-2.2" href="#section-2.2">2.2</a>. Simplicity</span>
There is concern that a complicated ACM will not be widely deployed
because it is too hard to use. Configuration of the access control
system needs to be as simple as possible. Simple and common tasks
need to be easy to configure and require little expertise or
domain-specific knowledge. Complex tasks are possible using
additional mechanisms that may require additional expertise.
A single set of access control rules ought to be able to control all
types of NETCONF protocol operation invocation, all datastore access,
and all notification events.
Access control ought to be defined with a small and familiar set of
permissions, while still allowing full control of datastore access.
<span class="h3"><a class="selflink" id="section-2.3" href="#section-2.3">2.3</a>. Procedural Interface</span>
NETCONF uses a Remote Procedure Call (RPC) model and an extensible
set of protocol operations. Access control for any possible protocol
operation is necessary.
<span class="h3"><a class="selflink" id="section-2.4" href="#section-2.4">2.4</a>. Datastore Access</span>
It is necessary to control access to specific nodes and subtrees
within the datastore, regardless of which protocol operation --
standard or proprietary -- was used to access the datastore.
<span class="h3"><a class="selflink" id="section-2.5" href="#section-2.5">2.5</a>. Users and Groups</span>
It is necessary that access control rules for a single user or a
configurable group of users can be configured.
The ACM needs to support the concept of administrative groups, to
support the well-established distinction between a root account and
other types of less-privileged conceptual user accounts. These
groups need to be configurable by the administrator.
It is necessary that the user-to-group mapping can be delegated to a
central server, such as a RADIUS server [<a href="./rfc2865" title=""Remote Authentication Dial In User Service (RADIUS)"">RFC2865</a>] [<a href="./rfc5607" title=""Remote Authentication Dial-In User Service (RADIUS) Authorization for Network Access Server (NAS) Management"">RFC5607</a>]. Since
authentication is performed by the transport layer and RADIUS
performs authentication and service authorization at the same time,
the underlying transport protocol needs to be able to report a set of
group names associated with the user to the server. It is necessary
that the administrator can disable the usage of these group names
within the ACM.
<span class="grey">Bierman & Bjorklund Standards Track [Page 8]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-9" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="section-2.6" href="#section-2.6">2.6</a>. Maintenance</span>
It ought to be possible to disable part or all of the access control
model enforcement procedures without deleting any access control
rules.
<span class="h3"><a class="selflink" id="section-2.7" href="#section-2.7">2.7</a>. Configuration Capabilities</span>
Suitable configuration and monitoring mechanisms are needed to allow
an administrator to easily manage all aspects of the ACM's behavior.
A standard data model, suitable for use with the <edit-config>
protocol operation, needs to be available for this purpose.
Access control rules to restrict access operations on specific
subtrees within the configuration datastore need to be supported.
<span class="h3"><a class="selflink" id="section-2.8" href="#section-2.8">2.8</a>. Identifying Security-Sensitive Content</span>
One of the most important aspects of the data model documentation,
and one of the biggest concerns during deployment, is the
identification of security-sensitive content. This applies to
protocol operations in NETCONF, not just data and notifications.
It is mandatory for security-sensitive objects to be documented in
the Security Considerations section of an RFC. This is nice, but it
is not good enough, for the following reasons:
o This documentation-only approach forces administrators to study
the RFC and determine if there are any potential security risks
introduced by a new data model.
o If any security risks are identified, then the administrator must
study some more RFC text and determine how to mitigate the
security risk(s).
o The ACM on each server must be configured to mitigate the security
risks, e.g., require privileged access to read or write the
specific data identified in the Security Considerations section.
o If the ACM is not preconfigured, then there will be a time window
of vulnerability after the new data model is loaded and before the
new access control rules for that data model are configured,
enabled, and debugged.
Often, the administrator just wants to disable default access to the
secure content so that no inadvertent or malicious changes can be
made to the server. This allows the default rules to be more
lenient, without significantly increasing the security risk.
<span class="grey">Bierman & Bjorklund Standards Track [Page 9]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-10" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
A data model designer needs to be able to use machine-readable
statements to identify content that needs to be protected by default.
This will allow client and server tools to automatically identify
data-model-specific security risks, by denying access to sensitive
data unless the user is explicitly authorized to perform the
requested access operation.
<span class="h2"><a class="selflink" id="section-3" href="#section-3">3</a>. NETCONF Access Control Model (NACM)</span>
<span class="h3"><a class="selflink" id="section-3.1" href="#section-3.1">3.1</a>. Overview</span>
This section provides a high-level overview of the access control
model structure. It describes the NETCONF protocol message
processing model and the conceptual access control requirements
within that model.
<span class="h4"><a class="selflink" id="section-3.1.1" href="#section-3.1.1">3.1.1</a>. Features</span>
The NACM data model provides the following features:
o Independent control of RPC, action, data, and notification access
is provided.
o The concept of an emergency recovery session is supported, but
configuration of the server for this purpose is beyond the scope
of this document. An emergency recovery session will bypass all
access control enforcement, in order to allow it to initialize or
repair the NACM configuration.
o A simple and familiar set of datastore permissions is used.
o Support for YANG security tagging (e.g., a
"nacm:default-deny-write" statement) allows default security modes
to automatically exclude sensitive data.
o Separate default access modes for read, write, and execute
permissions are provided.
o Access control rules are applied to configurable groups of users.
o The access control enforcement procedures can be disabled during
operation, without deleting any access control rules, in order to
debug operational problems.
<span class="grey">Bierman & Bjorklund Standards Track [Page 10]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-11" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
o The number of denied protocol operation requests and denied
datastore write requests can be monitored by the client.
o Simple unconstrained YANG instance-identifiers are used to
configure access control rules for specific data nodes.
<span class="h4"><a class="selflink" id="section-3.1.2" href="#section-3.1.2">3.1.2</a>. External Dependencies</span>
NETCONF [<a href="./rfc6241" title=""Network Configuration Protocol (NETCONF)"">RFC6241</a>] and RESTCONF [<a href="./rfc8040" title=""RESTCONF Protocol"">RFC8040</a>] are used for network
management purposes within this document.
The YANG data modeling language [<a href="./rfc7950" title=""The YANG 1.1 Data Modeling Language"">RFC7950</a>] is used to define the data
models for use with NETCONF or RESTCONF. YANG is also used to define
the data model in this document.
<span class="h4"><a class="selflink" id="section-3.1.3" href="#section-3.1.3">3.1.3</a>. Message Processing Model</span>
The following diagram shows the conceptual message flow model,
including the points at which access control is applied during
NETCONF message processing.
RESTCONF operations are mapped to the access control model based on
the HTTP method and resource class used in the operation. For
example, a POST method on a data resource is considered "write data
node" access, but a POST method on an operation resource is
considered "operation" access.
The new "pre-read data node acc. ctl" boxes in the diagram below
refer to group read access as it relates to data node ancestors of an
action or notification. As an example, if an action is defined as
/interfaces/interface/reset-interface, the group must be authorized
to (1) read /interfaces and /interfaces/interface and (2) execute on
/interfaces/interface/reset-interface.
<span class="grey">Bierman & Bjorklund Standards Track [Page 11]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-12" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
+-------------------------+
| session |
| (username) |
+-------------------------+
| ^
V |
+--------------+ +---------------+
| message | | message |
| dispatcher | | generator |
+--------------+ +---------------+
| | ^ ^
| V | |
| +=============+ | |
| | pre-read | | |
| | data node | | |
| | acc. ctl | | |
| +=============+ | |
| | | |
V V | |
+===========+ +-------------+ +----------------+
| operation |---> | reply | | <notification> |
| acc. ctl | | generator | | generator |
+===========+ +-------------+ +----------------+
| ^ ^ ^
V +------+ | |
+-----------+ | +=============+ +================+
| operation | | | read | | <notification> |
| processor |-+ | data node | | access ctl |
| | | acc. ctl | | |
+-----------+ +=============+ +================+
| | ^ ^ ^
V +----------------+ | | |
+===========+ | | | +============+
| write | | | | | pre-read |
| data node | | | | | data node |
| acc. ctl | -----------+ | | | | acc. ctl |
+===========+ | | | | +============+
| | | | | ^
V V V | | |
+---------------+ +-------------------+
| configuration | ---> | server |
| datastore | | instrumentation |
| | <--- | |
+---------------+ +-------------------+
Figure 2
<span class="grey">Bierman & Bjorklund Standards Track [Page 12]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-13" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
The following high-level sequence of conceptual processing steps is
executed for each received <rpc> message, if access control
enforcement is enabled:
o For each active session, access control is applied individually to
all <rpc> messages (except <close-session>) received by the
server, unless the session is identified as a recovery session.
o If the <action> operation defined in [<a href="./rfc7950" title=""The YANG 1.1 Data Modeling Language"">RFC7950</a>] is invoked, then
read access is required for all instances in the hierarchy of data
nodes that identifies the specific action in the datastore, and
execute access is required for the action node. If the user is
not authorized to read all the specified data nodes and execute
the action, then the request is rejected with an "access-denied"
error.
o Otherwise, if the user is not authorized to execute the specified
protocol operation, then the request is rejected with an
"access-denied" error.
o If a datastore is accessed by the protocol operation, then the
server checks to see if the client is authorized to access the
nodes in the datastore. If the user is not authorized to perform
the requested access operation on the requested data, then the
request is rejected with an "access-denied" error.
The following sequence of conceptual processing steps is executed for
each generated notification event, if access control enforcement is
enabled:
o Server instrumentation generates a notification for a particular
subscription.
o If the "notification" statement is specified within a data
subtree, as specified in [<a href="./rfc7950" title=""The YANG 1.1 Data Modeling Language"">RFC7950</a>], then read access is required
for all instances in the hierarchy of data nodes that identifies
the specific notification in the datastore, and read access is
required for the notification node. If the user is not authorized
to read all the specified data nodes and the notification node,
then the notification is dropped for that subscription.
o If the "notification" statement is a top-level statement, the
notification access control enforcer checks the notification event
type, and if it is one that the user is not authorized to read,
then the notification is dropped for that subscription.
<span class="grey">Bierman & Bjorklund Standards Track [Page 13]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-14" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="section-3.2" href="#section-3.2">3.2</a>. Datastore Access</span>
The same access control rules apply to all datastores that support
the NACM -- for example, the candidate configuration datastore or the
running configuration datastore.
All conventional configuration datastores and the operational state
datastore are controlled by the NACM. Local files, remote files, or
datastores accessed via the <url> parameter are not controlled by
the NACM.
<span class="h4"><a class="selflink" id="section-3.2.1" href="#section-3.2.1">3.2.1</a>. Mapping New Datastores to NACM</span>
It is possible that new datastores will be defined over time for use
with NETCONF. The NACM MAY be applied to other datastores that have
similar access rights as defined in the NACM. To apply the NACM to a
new datastore, the new datastore specification needs to define how it
maps to the NACM CRUDX (Create, Read, Update, Delete, eXec) access
rights. It is possible that only a subset of the NACM access rights
would be applicable. For example, only retrieval access control
would be needed for a read-only datastore. Operations and access
rights not supported by the NACM CRUDX model are outside the scope of
this document. A datastore does not need to use the NACM, e.g., the
datastore specification defines something else or does not use access
control.
<span class="h4"><a class="selflink" id="section-3.2.2" href="#section-3.2.2">3.2.2</a>. Access Rights</span>
A small set of hard-wired datastore access rights is needed to
control access to all possible protocol operations, including vendor
extensions to the standard protocol operation set.
The CRUDX model can support all protocol operations:
o Create: allows the client to add a new data node instance to a
datastore.
o Read: allows the client to read a data node instance from a
datastore or receive the notification event type.
o Update: allows the client to update an existing data node instance
in a datastore.
o Delete: allows the client to delete a data node instance from a
datastore.
o eXec: allows the client to execute the operation.
<span class="grey">Bierman & Bjorklund Standards Track [Page 14]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-15" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h4"><a class="selflink" id="section-3.2.3" href="#section-3.2.3">3.2.3</a>. RESTCONF Methods</span>
The RESTCONF protocol utilizes HTTP methods to perform datastore
operations, similar to NETCONF. The NACM procedures were originally
written for NETCONF protocol operations, so the RESTCONF methods are
mapped to NETCONF operations for the purpose of access control
processing. The enforcement procedures described within this
document apply to both protocols unless explicitly stated otherwise.
The request URI needs to be considered when processing RESTCONF
requests on data resources:
o For HEAD and GET requests, any data nodes that are ancestor nodes
of the target resource are considered to be part of the retrieval
request for access control purposes.
o For PUT, PATCH, and DELETE requests, any data nodes that are
ancestor nodes of the target resource are not considered to be
part of the edit request for access control purposes. The access
operation for these nodes is considered to be "none". The edit
begins at the target resource.
o For POST requests on data resources, any data nodes that are
specified in the request URI, including the target resource, are
not considered to be part of the edit request for access control
purposes. The access operation for these nodes is considered to
be "none". The edit begins at a child node of the target
resource, specified in the message body.
<span class="grey">Bierman & Bjorklund Standards Track [Page 15]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-16" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
Not all RESTCONF methods are subject to access control. The
following table specifies how each method is mapped to NETCONF
protocol operations. The value "none" indicates that the NACM is not
applied at all to the specific RESTCONF method.
+---------+-----------------+---------------------+-----------------+
| Method | Resource class | NETCONF operation | Access |
| | | | operation |
+---------+-----------------+---------------------+-----------------+
| OPTIONS | all | none | none |
| HEAD | all | <get>, <get-config> | read |
| GET | all | <get>, <get-config> | read |
| POST | datastore, data | <edit-config> | create |
| POST | operation | specified operation | execute |
| PUT | data | <edit-config> | create, update |
| PUT | datastore | <copy-config> | update |
| PATCH | data, datastore | <edit-config> | update |
| DELETE | data | <edit-config> | delete |
+---------+-----------------+---------------------+-----------------+
Table 1: Mapping RESTCONF Methods to NETCONF
<span class="h4"><a class="selflink" id="section-3.2.4" href="#section-3.2.4">3.2.4</a>. <get> and <get-config> Operations</span>
The NACM access rights are not directly coupled to the <get> and
<get-config> protocol operations but apply to all <rpc> operations
that would result in a "read" access operation to the target
datastore. This section describes how these access rights apply to
the specific access operations supported by the <get> and
<get-config> protocol operations.
Data nodes to which the client does not have read access are silently
omitted, along with any descendants, from the <rpc-reply> message.
This is done to allow NETCONF filters for <get> and <get-config> to
function properly, instead of causing an "access-denied" error
because the filter criteria would otherwise include unauthorized read
access to some data nodes. For NETCONF filtering purposes, the
selection criteria are applied to the subset of nodes that the user
is authorized to read, not the entire datastore.
<span class="h4"><a class="selflink" id="section-3.2.5" href="#section-3.2.5">3.2.5</a>. <edit-config> Operation</span>
The NACM access rights are not directly coupled to the <edit-config>
"operation" attribute, although they are similar. Instead, a NACM
access right applies to all protocol operations that would result in
a particular access operation to the target datastore. This section
describes how these access rights apply to the specific access
operations supported by the <edit-config> protocol operation.
<span class="grey">Bierman & Bjorklund Standards Track [Page 16]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-17" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
If the effective access operation is "none" (i.e.,
default-operation="none") for a particular data node, then no access
control is applied to that data node. This is required to allow
access to a subtree within a larger data structure. For example, a
user may be authorized to create a new "/interfaces/interface" list
entry but not be authorized to create or delete its parent container
("/interfaces"). If the "/interfaces" container already exists in
the target datastore, then the effective operation will be "none" for
the "/interfaces" node if an "/interfaces/interface" list entry is
edited.
If the protocol operation would result in the creation of a datastore
node and the user does not have "create" access permission for that
node, the protocol operation is rejected with an "access-denied"
error.
If the protocol operation would result in the deletion of a datastore
node and the user does not have "delete" access permission for that
node, the protocol operation is rejected with an "access-denied"
error.
If the protocol operation would result in the modification of a
datastore node and the user does not have "update" access permission
for that node, the protocol operation is rejected with an
"access-denied" error.
A "merge" or "replace" <edit-config> operation may include data nodes
that do not alter portions of the existing datastore. For example, a
container or list node may be present for naming purposes but does
not actually alter the corresponding datastore node. These unaltered
data nodes are ignored by the server and do not require any access
rights by the client.
A "merge" <edit-config> operation may include data nodes but not
include particular child data nodes that are present in the
datastore. These missing data nodes within the scope of a "merge"
<edit-config> operation are ignored by the server and do not require
any access rights by the client.
The contents of specific restricted datastore nodes MUST NOT be
exposed in any <rpc-error> elements within the reply.
An <edit-config> operation may cause data nodes to be implicitly
created or deleted as an implicit side effect of a requested
operation. For example, a YANG when-stmt expression may evaluate to
a different result, causing data nodes to be deleted, or created with
default values; or if a data node is created under one branch of a
YANG choice-stmt, then all data nodes under the other branches are
<span class="grey">Bierman & Bjorklund Standards Track [Page 17]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-18" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
implicitly removed. No NACM access rights are required on any data
nodes that are implicitly changed as a side effect of another allowed
operation.
<span class="h4"><a class="selflink" id="section-3.2.6" href="#section-3.2.6">3.2.6</a>. <copy-config> Operation</span>
Access control for the <copy-config> protocol operation requires
special consideration because the administrator may be replacing the
entire target datastore.
If the source of the <copy-config> protocol operation is the running
configuration datastore and the target is the startup configuration
datastore, the client is only required to have permission to execute
the <copy-config> protocol operation.
Otherwise:
o If the source of the <copy-config> operation is a datastore, then
data nodes to which the client does not have read access are
silently omitted.
o If the target of the <copy-config> operation is a datastore, the
client needs access to the modified nodes. Specifically:
* If the protocol operation would result in the creation of a
datastore node and the user does not have "create" access
permission for that node, the protocol operation is rejected
with an "access-denied" error.
* If the protocol operation would result in the deletion of a
datastore node and the user does not have "delete" access
permission for that node, the protocol operation is rejected
with an "access-denied" error.
* If the protocol operation would result in the modification of a
datastore node and the user does not have "update" access
permission for that node, the protocol operation is rejected
with an "access-denied" error.
<span class="h4"><a class="selflink" id="section-3.2.7" href="#section-3.2.7">3.2.7</a>. <delete-config> Operation</span>
Access to the <delete-config> protocol operation is denied by
default. The "exec-default" leaf does not apply to this protocol
operation. Access control rules must be explicitly configured to
allow invocation by a non-recovery session.
<span class="grey">Bierman & Bjorklund Standards Track [Page 18]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-19" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h4"><a class="selflink" id="section-3.2.8" href="#section-3.2.8">3.2.8</a>. <commit> Operation</span>
The server MUST determine the exact nodes in the running
configuration datastore that are actually different and only check
"create", "update", and "delete" access permissions for this set of
nodes, which could be empty.
For example, if a session can read the entire datastore but only
change one leaf, that session needs to be able to edit and commit
that one leaf.
<span class="h4"><a class="selflink" id="section-3.2.9" href="#section-3.2.9">3.2.9</a>. <discard-changes> Operation</span>
The client is only required to have permission to execute the
<discard-changes> protocol operation. No datastore permissions are
needed.
<span class="h4"><a class="selflink" id="section-3.2.10" href="#section-3.2.10">3.2.10</a>. <kill-session> Operation</span>
The <kill-session> operation does not directly alter a datastore.
However, it allows one session to disrupt another session that is
editing a datastore.
Access to the <kill-session> protocol operation is denied by default.
The "exec-default" leaf does not apply to this protocol operation.
Access control rules must be explicitly configured to allow
invocation by a non-recovery session.
<span class="h3"><a class="selflink" id="section-3.3" href="#section-3.3">3.3</a>. Model Components</span>
This section defines the conceptual components related to the access
control model.
<span class="h4"><a class="selflink" id="section-3.3.1" href="#section-3.3.1">3.3.1</a>. Users</span>
A "user" is the conceptual entity that is associated with the access
permissions granted to a particular session. A user is identified by
a string that is unique within the server.
As described in [<a href="./rfc6241" title=""Network Configuration Protocol (NETCONF)"">RFC6241</a>], the username string is derived from the
transport layer during session establishment. If the transport layer
cannot authenticate the user, the session is terminated.
<span class="grey">Bierman & Bjorklund Standards Track [Page 19]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-20" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h4"><a class="selflink" id="section-3.3.2" href="#section-3.3.2">3.3.2</a>. Groups</span>
Access to a specific NETCONF protocol operation is granted to a
session. The session is associated with a group (i.e., not with
a user).
A group is identified by its name. All group names are unique within
the server.
Access control is applied at the level of groups. A group contains
zero or more group members.
A group member is identified by a username string.
The same user can be a member of multiple groups.
<span class="h4"><a class="selflink" id="section-3.3.3" href="#section-3.3.3">3.3.3</a>. Emergency Recovery Session</span>
The server MAY support a recovery session mechanism, which will
bypass all access control enforcement. This is useful for
restricting initial access and repairing a broken access control
configuration.
<span class="h4"><a class="selflink" id="section-3.3.4" href="#section-3.3.4">3.3.4</a>. Global Enforcement Controls</span>
There are five global controls that are used to help control how
access control is enforced.
<span class="h5"><a class="selflink" id="section-3.3.4.1" href="#section-3.3.4.1">3.3.4.1</a>. enable-nacm Switch</span>
A global "enable-nacm" on/off switch is provided to enable or disable
all access control enforcement. When this global switch is set to
"true", all requests are checked against the access control rules and
only permitted if configured to allow the specific access request.
When this global switch is set to "false", all access requests are
permitted.
<span class="h5"><a class="selflink" id="section-3.3.4.2" href="#section-3.3.4.2">3.3.4.2</a>. read-default Switch</span>
An on/off "read-default" switch is provided to enable or disable
default access to receive data in replies and notifications. When
the "enable-nacm" global switch is set to "true", this global switch
is relevant if no matching access control rule is found to explicitly
permit or deny read access to the requested datastore data or
notification event type.
<span class="grey">Bierman & Bjorklund Standards Track [Page 20]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-21" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
When this global switch is set to "permit" and no matching access
control rule is found for the datastore read or notification event
requested, access is permitted.
When this global switch is set to "deny" and no matching access
control rule is found for the datastore read or notification event
requested, access is denied. This means that the requested data is
not sent to the client. See step 11 in <a href="#section-3.4.5">Section 3.4.5</a> for details.
<span class="h5"><a class="selflink" id="section-3.3.4.3" href="#section-3.3.4.3">3.3.4.3</a>. write-default Switch</span>
An on/off "write-default" switch is provided to enable or disable
default access to alter configuration data. When the "enable-nacm"
global switch is set to "true", this global switch is relevant if no
matching access control rule is found to explicitly permit or deny
write access to the requested datastore data.
When this global switch is set to "permit" and no matching access
control rule is found for the datastore write requested, access is
permitted.
When this global switch is set to "deny" and no matching access
control rule is found for the datastore write requested, access is
denied. See step 12 in <a href="#section-3.4.5">Section 3.4.5</a> for details.
<span class="h5"><a class="selflink" id="section-3.3.4.4" href="#section-3.3.4.4">3.3.4.4</a>. exec-default Switch</span>
An on/off "exec-default" switch is provided to enable or disable
default access to execute protocol operations. When the
"enable-nacm" global switch is set to "true", this global switch is
relevant if no matching access control rule is found to explicitly
permit or deny access to the requested NETCONF protocol operation.
When this global switch is set to "permit" and no matching access
control rule is found for the NETCONF protocol operation requested,
access is permitted.
When this global switch is set to "deny" and no matching access
control rule is found for the NETCONF protocol operation requested,
access is denied. See step 12 in <a href="#section-3.4.4">Section 3.4.4</a> and step 13 in
<a href="#section-3.4.5">Section 3.4.5</a> for details.
<span class="grey">Bierman & Bjorklund Standards Track [Page 21]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-22" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h5"><a class="selflink" id="section-3.3.4.5" href="#section-3.3.4.5">3.3.4.5</a>. enable-external-groups Switch</span>
When this global switch is set to "true", the group names reported by
the transport layer for a session are used together with the locally
configured group names to determine the access control rules for the
session.
When this switch is set to "false", the group names reported by the
transport layer are ignored by the NACM.
<span class="h4"><a class="selflink" id="section-3.3.5" href="#section-3.3.5">3.3.5</a>. Access Control Rules</span>
There are four types of rules available in the NACM:
module rule: controls access for definitions in a specific YANG
module, identified by its name.
protocol operation rule: controls access for a specific protocol
operation, identified by its YANG module and name.
data node rule: controls access for a specific data node and its
descendants, identified by its path location within the conceptual
XML document for the data node.
notification rule: controls access for a specific notification event
type, identified by its YANG module and name.
<span class="h3"><a class="selflink" id="section-3.4" href="#section-3.4">3.4</a>. Access Control Enforcement Procedures</span>
There are six separate phases that need to be addressed, four of
which are related to the NETCONF message processing model
(<a href="#section-3.1.3">Section 3.1.3</a>):
1. Initial operation
2. Session establishment
3. "access-denied" error handling
4. Incoming RPC message validation
5. Data node access validation
6. Outgoing <notification> authorization
In addition, the initial startup mode for a NETCONF server, session
establishment, and "access-denied" error-handling procedures also
need to be considered.
<span class="grey">Bierman & Bjorklund Standards Track [Page 22]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-23" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
The server MUST use the access control rules in effect at the time it
starts processing the message. The same access control rules MUST
stay in effect for the processing of the entire message.
<span class="h4"><a class="selflink" id="section-3.4.1" href="#section-3.4.1">3.4.1</a>. Initial Operation</span>
Upon the very first startup of the NETCONF server, the access control
configuration will probably not be present. If it isn't, a server
MUST NOT allow any write access to any session role except a recovery
session.
Access rules are enforced any time a request is initiated from a user
session. Access control is not enforced for server-initiated access
requests, such as the initial load of the running configuration
datastore, during bootup.
<span class="h4"><a class="selflink" id="section-3.4.2" href="#section-3.4.2">3.4.2</a>. Session Establishment</span>
The access control model applies specifically to the well-formed XML
content transferred between a client and a server after session
establishment has been completed and after the <hello> exchange has
been successfully completed.
Once session establishment is completed and a user has been
authenticated, the transport layer reports the username and a
possibly empty set of group names associated with the user to the
NETCONF server. The NETCONF server will enforce the access control
rules, based on the supplied username, group names, and the
configuration data stored on the server.
<span class="h4"><a class="selflink" id="section-3.4.3" href="#section-3.4.3">3.4.3</a>. "access-denied" Error Handling</span>
The "access-denied" error-tag is generated when the access control
system denies access to either a request to invoke a protocol
operation or a request to perform a particular access operation on
the configuration datastore.
A server MUST NOT include any information the client is not allowed
to read in any <error-info> elements within the <rpc-error> response.
<span class="grey">Bierman & Bjorklund Standards Track [Page 23]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-24" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h4"><a class="selflink" id="section-3.4.4" href="#section-3.4.4">3.4.4</a>. Incoming RPC Message Validation</span>
The diagram below shows the basic conceptual structure of the access
control processing model for incoming NETCONF <rpc> messages within a
server.
NETCONF server
+------------+
| XML |
| message |
| dispatcher |
+------------+
|
|
V
+---------------+
| <rpc> message |
+---------------+
| | |
| | +--------------------------------+
| +---------------+ |
V V V
+------------------+ +--------------------+ +--------------------+
| vendor operation | | standard operation | | standard operation |
| <my-edit> | | <edit-config> | | <unlock> |
+------------------+ +--------------------+ +--------------------+
| |
| |
V V
+----------------------+
| configuration |
| datastore |
+----------------------+
Figure 3
Access control begins with the message dispatcher.
After the server validates the <rpc> element and determines the
namespace URI and the element name of the protocol operation being
requested, the server verifies that the user is authorized to invoke
the protocol operation.
<span class="grey">Bierman & Bjorklund Standards Track [Page 24]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-25" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
The server MUST separately authorize every protocol operation by
following these steps:
1. If the "enable-nacm" leaf is set to "false", then the protocol
operation is permitted.
2. If the requesting session is identified as a recovery session,
then the protocol operation is permitted.
3. If the requested operation is the NETCONF <close-session>
protocol operation, then the protocol operation is permitted.
4. Check all the "group" entries to see if any of them contain a
"user-name" entry that equals the username for the session
making the request. If the "enable-external-groups" leaf is
"true", add to these groups the set of groups provided by the
transport layer.
5. If no groups are found, continue with step 10.
6. Process all rule-list entries, in the order they appear in the
configuration. If a rule-list's "group" leaf-list does not
match any of the user's groups, proceed to the next rule-list
entry.
7. For each rule-list entry found, process all rules, in order,
until a rule that matches the requested access operation is
found. A rule matches if all of the following criteria are met:
* The rule's "module-name" leaf is "*" or equals the name of
the YANG module where the protocol operation is defined.
* Either (1) the rule does not have a "rule-type" defined or
(2) the "rule-type" is "protocol-operation" and the
"rpc-name" is "*" or equals the name of the requested
protocol operation.
* The rule's "access-operations" leaf has the "exec" bit set or
has the special value "*".
8. If a matching rule is found, then the "action" leaf is checked.
If it is equal to "permit", then the protocol operation is
permitted; otherwise, it is denied.
9. At this point, no matching rule was found in any rule-list
entry.
<span class="grey">Bierman & Bjorklund Standards Track [Page 25]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-26" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
10. If the requested protocol operation is defined in a YANG module
advertised in the server capabilities and the "rpc" statement
contains a "nacm:default-deny-all" statement, then the protocol
operation is denied.
11. If the requested protocol operation is the NETCONF
<kill-session> or <delete-config>, then the protocol operation
is denied.
12. If the "exec-default" leaf is set to "permit", then permit the
protocol operation; otherwise, deny the request.
If the user is not authorized to invoke the protocol operation, then
an <rpc-error> is generated with the following information:
error-tag: access-denied
error-path: Identifies the requested protocol operation. The
following example represents the <edit-config> protocol operation
in the NETCONF base namespace:
<error-path
xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0">
/nc:rpc/nc:edit-config
</error-path>
If a datastore is accessed, either directly or as a side effect of
the protocol operation, then the server MUST intercept the access
operation and make sure that the user is authorized to perform the
requested access operation on the specified data, as defined in
<a href="#section-3.4.5">Section 3.4.5</a>.
<span class="h4"><a class="selflink" id="section-3.4.5" href="#section-3.4.5">3.4.5</a>. Data Node Access Validation</span>
If (1) a data node within a datastore is accessed or (2) an action or
notification is tied to a data node, then the server MUST ensure that
the user is authorized to perform the requested "read", "create",
"update", "delete", or "execute" access operation on the specified
data node.
If an action is requested to be executed, the server MUST ensure that
the user is authorized to perform the "execute" access operation on
the requested action.
If a notification tied to a data node is generated, the server MUST
ensure that the user is authorized to perform the "read" access
operation on the requested notification.
<span class="grey">Bierman & Bjorklund Standards Track [Page 26]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-27" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
The data node access request is authorized by following these steps:
1. If the "enable-nacm" leaf is set to "false", then the access
operation is permitted.
2. If the requesting session is identified as a recovery session,
then the access operation is permitted.
3. Check all the "group" entries to see if any of them contain a
"user-name" entry that equals the username for the session
making the request. If the "enable-external-groups" leaf is
"true", add to these groups the set of groups provided by the
transport layer.
4. If no groups are found, continue with step 9.
5. Process all rule-list entries, in the order they appear in the
configuration. If a rule-list's "group" leaf-list does not
match any of the user's groups, proceed to the next rule-list
entry.
6. For each rule-list entry found, process all rules, in order,
until a rule that matches the requested access operation is
found. A rule matches if all of the following criteria are met:
* The rule's "module-name" leaf is "*" or equals the name of
the YANG module where the requested data node is defined.
* Either (1) the rule does not have a "rule-type" defined or
(2) the "rule-type" is "data-node" and the "path" matches the
requested data node, action node, or notification node. A
path is considered to match if the requested node is the node
specified by the path or is a descendant node of the path.
* For a "read" access operation, the rule's "access-operations"
leaf has the "read" bit set or has the special value "*".
* For a "create" access operation, the rule's
"access-operations" leaf has the "create" bit set or has the
special value "*".
* For a "delete" access operation, the rule's
"access-operations" leaf has the "delete" bit set or has the
special value "*".
<span class="grey">Bierman & Bjorklund Standards Track [Page 27]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-28" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
* For an "update" access operation, the rule's
"access-operations" leaf has the "update" bit set or has the
special value "*".
* For an "execute" access operation, the rule's
"access-operations" leaf has the "exec" bit set or has the
special value "*".
7. If a matching rule is found, then the "action" leaf is checked.
If it is equal to "permit", then the data node access is
permitted; otherwise, it is denied. For a "read" access
operation, "denied" means that the requested data is not
returned in the reply.
8. At this point, no matching rule was found in any rule-list
entry.
9. For a "read" access operation, if the requested data node is
defined in a YANG module advertised in the server capabilities
and the data definition statement contains a
"nacm:default-deny-all" statement, then the requested data node
and all its descendants are not included in the reply.
10. For a "write" access operation, if the requested data node is
defined in a YANG module advertised in the server capabilities
and the data definition statement contains a
"nacm:default-deny-write" or a "nacm:default-deny-all"
statement, then the access request is denied for the data node
and all its descendants.
11. For a "read" access operation, if the "read-default" leaf is set
to "permit", then include the requested data node in the reply;
otherwise, do not include the requested data node or any of its
descendants in the reply.
12. For a "write" access operation, if the "write-default" leaf is
set to "permit", then permit the data node access request;
otherwise, deny the request.
13. For an "execute" access operation, if the "exec-default" leaf is
set to "permit", then permit the request; otherwise, deny the
request.
<span class="grey">Bierman & Bjorklund Standards Track [Page 28]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-29" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h4"><a class="selflink" id="section-3.4.6" href="#section-3.4.6">3.4.6</a>. Outgoing <notification> Authorization</span>
Configuration of access control rules specifically for descendant
nodes of the notification event type are outside the scope of this
document. If the user is authorized to receive the notification
event type, then it is also authorized to receive any data it
contains.
If the notification is specified within a data subtree, as specified
in [<a href="./rfc7950" title=""The YANG 1.1 Data Modeling Language"">RFC7950</a>], then read access to the notification is required.
Processing continues as described in <a href="#section-3.4.5">Section 3.4.5</a>.
The following figure shows the conceptual message processing model
for outgoing <notification> messages.
NETCONF server
+------------+
| XML |
| message |
| generator |
+------------+
^
|
+----------------+
| <notification> |
| generator |
+----------------+
^
|
+=================+
| <notification> |
| access control |
| <eventType> |
+=================+
^
|
+------------------------+
| server instrumentation |
+------------------------+
| ^
V |
+----------------------+
| configuration |
| datastore |
+----------------------+
Figure 4
<span class="grey">Bierman & Bjorklund Standards Track [Page 29]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-30" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
The generation of a notification for a specific subscription
[<a href="./rfc5277" title=""NETCONF Event Notifications"">RFC5277</a>] is authorized by following these steps:
1. If the "enable-nacm" leaf is set to "false", then the
notification is permitted.
2. If the session is identified as a recovery session, then the
notification is permitted.
3. If the notification is the NETCONF <replayComplete> or
<notificationComplete> event type [<a href="./rfc5277" title=""NETCONF Event Notifications"">RFC5277</a>], then the
notification is permitted.
4. Check all the "group" entries to see if any of them contain a
"user-name" entry that equals the username for the session
making the request. If the "enable-external-groups" leaf is
"true", add to these groups the set of groups provided by the
transport layer.
5. If no groups are found, continue with step 10.
6. Process all rule-list entries, in the order they appear in the
configuration. If a rule-list's "group" leaf-list does not
match any of the user's groups, proceed to the next rule-list
entry.
7. For each rule-list entry found, process all rules, in order,
until a rule that matches the requested access operation is
found. A rule matches if all of the following criteria are met:
* The rule's "module-name" leaf is "*" or equals the name of
the YANG module where the notification is defined.
* Either (1) the rule does not have a "rule-type" defined or
(2) the "rule-type" is "notification" and the
"notification-name" is "*" or equals the name of the
notification.
* The rule's "access-operations" leaf has the "read" bit set or
has the special value "*".
8. If a matching rule is found, then the "action" leaf is checked.
If it is equal to "permit", then permit the notification;
otherwise, drop the notification for the associated
subscription.
9. Otherwise, no matching rule was found in any rule-list entry.
<span class="grey">Bierman & Bjorklund Standards Track [Page 30]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-31" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
10. If the requested notification is defined in a YANG module
advertised in the server capabilities and the "notification"
statement contains a "nacm:default-deny-all" statement, then the
notification is dropped for the associated subscription.
11. If the "read-default" leaf is set to "permit", then permit the
notification; otherwise, drop the notification for the
associated subscription.
<span class="h3"><a class="selflink" id="section-3.5" href="#section-3.5">3.5</a>. Data Model Definitions</span>
<span class="h4"><a class="selflink" id="section-3.5.1" href="#section-3.5.1">3.5.1</a>. Data Organization</span>
The following diagram highlights the contents and structure of the
NACM YANG module.
module: ietf-netconf-acm
+--rw nacm
+--rw enable-nacm? boolean
+--rw read-default? action-type
+--rw write-default? action-type
+--rw exec-default? action-type
+--rw enable-external-groups? boolean
+--ro denied-operations yang:zero-based-counter32
+--ro denied-data-writes yang:zero-based-counter32
+--ro denied-notifications yang:zero-based-counter32
+--rw groups
| +--rw group* [name]
| +--rw name group-name-type
| +--rw user-name* user-name-type
+--rw rule-list* [name]
+--rw name string
+--rw group* union
+--rw rule* [name]
+--rw name string
+--rw module-name? union
+--rw (rule-type)?
| +--:(protocol-operation)
| | +--rw rpc-name? union
| +--:(notification)
| | +--rw notification-name? union
| +--:(data-node)
| +--rw path node-instance-identifier
+--rw access-operations? union
+--rw action action-type
+--rw comment? string
<span class="grey">Bierman & Bjorklund Standards Track [Page 31]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-32" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h4"><a class="selflink" id="section-3.5.2" href="#section-3.5.2">3.5.2</a>. YANG Module</span>
The following YANG module specifies the normative NETCONF content
that MUST be supported by the server.
The "ietf-netconf-acm" YANG module imports typedefs from [<a href="./rfc6991" title=""Common YANG Data Types"">RFC6991</a>].
<CODE BEGINS> file "ietf-netconf-acm@2018-02-14.yang"
module ietf-netconf-acm {
namespace "urn:ietf:params:xml:ns:yang:ietf-netconf-acm";
prefix nacm;
import ietf-yang-types {
prefix yang;
}
organization
"IETF NETCONF (Network Configuration) Working Group";
contact
"WG Web: <<a href="https://datatracker.ietf.org/wg/netconf/">https://datatracker.ietf.org/wg/netconf/</a>>
WG List: <mailto:netconf@ietf.org>
Author: Andy Bierman
<mailto:andy@yumaworks.com>
Author: Martin Bjorklund
<mailto:mbj@tail-f.com>";
description
"Network Configuration Access Control Model.
Copyright (c) 2012 - 2018 IETF Trust and the persons
identified as authors of the code. All rights reserved.
Redistribution and use in source and binary forms, with or
without modification, is permitted pursuant to, and subject
to the license terms contained in, the Simplified BSD
License set forth in <a href="#section-4">Section 4</a>.c of the IETF Trust's
Legal Provisions Relating to IETF Documents
(<a href="https://trustee.ietf.org/license-info">https://trustee.ietf.org/license-info</a>).
This version of this YANG module is part of <a href="./rfc8341">RFC 8341</a>; see
the RFC itself for full legal notices.";
<span class="grey">Bierman & Bjorklund Standards Track [Page 32]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-33" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
revision "2018-02-14" {
description
"Added support for YANG 1.1 actions and notifications tied to
data nodes. Clarified how NACM extensions can be used by
other data models.";
reference
"<a href="./rfc8341">RFC 8341</a>: Network Configuration Access Control Model";
}
revision "2012-02-22" {
description
"Initial version.";
reference
"<a href="./rfc6536">RFC 6536</a>: Network Configuration Protocol (NETCONF)
Access Control Model";
}
/*
* Extension statements
*/
extension default-deny-write {
description
"Used to indicate that the data model node
represents a sensitive security system parameter.
If present, the NETCONF server will only allow the designated
'recovery session' to have write access to the node. An
explicit access control rule is required for all other users.
If the NACM module is used, then it must be enabled (i.e.,
/nacm/enable-nacm object equals 'true'), or this extension
is ignored.
The 'default-deny-write' extension MAY appear within a data
definition statement. It is ignored otherwise.";
}
extension default-deny-all {
description
"Used to indicate that the data model node
controls a very sensitive security system parameter.
If present, the NETCONF server will only allow the designated
'recovery session' to have read, write, or execute access to
the node. An explicit access control rule is required for all
other users.
<span class="grey">Bierman & Bjorklund Standards Track [Page 33]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-34" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
If the NACM module is used, then it must be enabled (i.e.,
/nacm/enable-nacm object equals 'true'), or this extension
is ignored.
The 'default-deny-all' extension MAY appear within a data
definition statement, 'rpc' statement, or 'notification'
statement. It is ignored otherwise.";
}
/*
* Derived types
*/
typedef user-name-type {
type string {
length "1..max";
}
description
"General-purpose username string.";
}
typedef matchall-string-type {
type string {
pattern '\*';
}
description
"The string containing a single asterisk '*' is used
to conceptually represent all possible values
for the particular leaf using this data type.";
}
typedef access-operations-type {
type bits {
bit create {
description
"Any protocol operation that creates a
new data node.";
}
bit read {
description
"Any protocol operation or notification that
returns the value of a data node.";
}
bit update {
description
"Any protocol operation that alters an existing
data node.";
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 34]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-35" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
bit delete {
description
"Any protocol operation that removes a data node.";
}
bit exec {
description
"Execution access to the specified protocol operation.";
}
}
description
"Access operation.";
}
typedef group-name-type {
type string {
length "1..max";
pattern '[^\*].*';
}
description
"Name of administrative group to which
users can be assigned.";
}
typedef action-type {
type enumeration {
enum permit {
description
"Requested action is permitted.";
}
enum deny {
description
"Requested action is denied.";
}
}
description
"Action taken by the server when a particular
rule matches.";
}
typedef node-instance-identifier {
type yang:xpath1.0;
description
"Path expression used to represent a special
data node, action, or notification instance-identifier
string.
A node-instance-identifier value is an
unrestricted YANG instance-identifier expression.
<span class="grey">Bierman & Bjorklund Standards Track [Page 35]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-36" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
All the same rules as an instance-identifier apply,
except that predicates for keys are optional. If a key
predicate is missing, then the node-instance-identifier
represents all possible server instances for that key.
This XML Path Language (XPath) expression is evaluated in the
following context:
o The set of namespace declarations are those in scope on
the leaf element where this type is used.
o The set of variable bindings contains one variable,
'USER', which contains the name of the user of the
current session.
o The function library is the core function library, but
note that due to the syntax restrictions of an
instance-identifier, no functions are allowed.
o The context node is the root node in the data tree.
The accessible tree includes actions and notifications tied
to data nodes.";
}
/*
* Data definition statements
*/
container nacm {
nacm:default-deny-all;
description
"Parameters for NETCONF access control model.";
leaf enable-nacm {
type boolean;
default "true";
description
"Enables or disables all NETCONF access control
enforcement. If 'true', then enforcement
is enabled. If 'false', then enforcement
is disabled.";
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 36]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-37" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
leaf read-default {
type action-type;
default "permit";
description
"Controls whether read access is granted if
no appropriate rule is found for a
particular read request.";
}
leaf write-default {
type action-type;
default "deny";
description
"Controls whether create, update, or delete access
is granted if no appropriate rule is found for a
particular write request.";
}
leaf exec-default {
type action-type;
default "permit";
description
"Controls whether exec access is granted if no appropriate
rule is found for a particular protocol operation request.";
}
leaf enable-external-groups {
type boolean;
default "true";
description
"Controls whether the server uses the groups reported by the
NETCONF transport layer when it assigns the user to a set of
NACM groups. If this leaf has the value 'false', any group
names reported by the transport layer are ignored by the
server.";
}
leaf denied-operations {
type yang:zero-based-counter32;
config false;
mandatory true;
description
"Number of times since the server last restarted that a
protocol operation request was denied.";
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 37]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-38" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
leaf denied-data-writes {
type yang:zero-based-counter32;
config false;
mandatory true;
description
"Number of times since the server last restarted that a
protocol operation request to alter
a configuration datastore was denied.";
}
leaf denied-notifications {
type yang:zero-based-counter32;
config false;
mandatory true;
description
"Number of times since the server last restarted that
a notification was dropped for a subscription because
access to the event type was denied.";
}
container groups {
description
"NETCONF access control groups.";
list group {
key name;
description
"One NACM group entry. This list will only contain
configured entries, not any entries learned from
any transport protocols.";
leaf name {
type group-name-type;
description
"Group name associated with this entry.";
}
leaf-list user-name {
type user-name-type;
description
"Each entry identifies the username of
a member of the group associated with
this entry.";
}
}
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 38]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-39" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
list rule-list {
key name;
ordered-by user;
description
"An ordered collection of access control rules.";
leaf name {
type string {
length "1..max";
}
description
"Arbitrary name assigned to the rule-list.";
}
leaf-list group {
type union {
type matchall-string-type;
type group-name-type;
}
description
"List of administrative groups that will be
assigned the associated access rights
defined by the 'rule' list.
The string '*' indicates that all groups apply to the
entry.";
}
list rule {
key name;
ordered-by user;
description
"One access control rule.
Rules are processed in user-defined order until a match is
found. A rule matches if 'module-name', 'rule-type', and
'access-operations' match the request. If a rule
matches, the 'action' leaf determines whether or not
access is granted.";
leaf name {
type string {
length "1..max";
}
description
"Arbitrary name assigned to the rule.";
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 39]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-40" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
leaf module-name {
type union {
type matchall-string-type;
type string;
}
default "*";
description
"Name of the module associated with this rule.
This leaf matches if it has the value '*' or if the
object being accessed is defined in the module with the
specified module name.";
}
choice rule-type {
description
"This choice matches if all leafs present in the rule
match the request. If no leafs are present, the
choice matches all requests.";
case protocol-operation {
leaf rpc-name {
type union {
type matchall-string-type;
type string;
}
description
"This leaf matches if it has the value '*' or if
its value equals the requested protocol operation
name.";
}
}
case notification {
leaf notification-name {
type union {
type matchall-string-type;
type string;
}
description
"This leaf matches if it has the value '*' or if its
value equals the requested notification name.";
}
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 40]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-41" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
case data-node {
leaf path {
type node-instance-identifier;
mandatory true;
description
"Data node instance-identifier associated with the
data node, action, or notification controlled by
this rule.
Configuration data or state data
instance-identifiers start with a top-level
data node. A complete instance-identifier is
required for this type of path value.
The special value '/' refers to all possible
datastore contents.";
}
}
}
leaf access-operations {
type union {
type matchall-string-type;
type access-operations-type;
}
default "*";
description
"Access operations associated with this rule.
This leaf matches if it has the value '*' or if the
bit corresponding to the requested operation is set.";
}
leaf action {
type action-type;
mandatory true;
description
"The access control action associated with the
rule. If a rule has been determined to match a
particular request, then this object is used
to determine whether to permit or deny the
request.";
}
<span class="grey">Bierman & Bjorklund Standards Track [Page 41]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-42" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
leaf comment {
type string;
description
"A textual description of the access rule.";
}
}
}
}
}
<CODE ENDS>
<span class="h2"><a class="selflink" id="section-4" href="#section-4">4</a>. IANA Considerations</span>
This document reuses the URI for "ietf-netconf-acm" in the "IETF XML
Registry".
This document updates the module registration in the "YANG Module
Names" registry to reference this RFC instead of <a href="./rfc6536">RFC 6536</a> for
"ietf-netconf-acm". Following the format in [<a href="./rfc6020" title=""YANG - A Data Modeling Language for the Network Configuration Protocol (NETCONF)"">RFC6020</a>], the following
has been registered.
Name: ietf-netconf-acm
Namespace: urn:ietf:params:xml:ns:yang:ietf-netconf-acm
Prefix: nacm
Reference: <a href="./rfc8341">RFC 8341</a>
<span class="h2"><a class="selflink" id="section-5" href="#section-5">5</a>. Security Considerations</span>
The YANG module specified in this document defines a schema for data
that is designed to be accessed via network management protocols such
as NETCONF [<a href="./rfc6241" title=""Network Configuration Protocol (NETCONF)"">RFC6241</a>] or RESTCONF [<a href="./rfc8040" title=""RESTCONF Protocol"">RFC8040</a>]. The lowest NETCONF layer
is the secure transport layer, and the mandatory-to-implement secure
transport is Secure Shell (SSH) [<a href="./rfc6242" title=""Using the NETCONF Protocol over Secure Shell (SSH)"">RFC6242</a>]. The lowest RESTCONF layer
is HTTPS, and the mandatory-to-implement secure transport is TLS
[<a href="./rfc5246" title=""The Transport Layer Security (TLS) Protocol Version 1.2"">RFC5246</a>].
The NETCONF access control model [<a href="./rfc8341">RFC8341</a>] provides the means to
restrict access for particular NETCONF or RESTCONF users to a
preconfigured subset of all available NETCONF or RESTCONF protocol
operations and content.
There is a risk related to the lack of access control enforcement for
the RESTCONF OPTIONS and PATCH methods. The risk here is that the
response to OPTIONS and PATCH may vary based on the presence or
absence of a resource corresponding to the URL's path. If this is
the case, then it can be used to trivially probe for the presence or
absence of values within a tree. Therefore, a server MUST NOT vary
<span class="grey">Bierman & Bjorklund Standards Track [Page 42]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-43" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
its responses based on the existence of the underlying resource,
which would indicate the presence or absence of resource instances.
In particular, servers should not expose any instance information
before ensuring that the client has the necessary access permissions
to obtain that information. In such cases, servers are expected to
always return the "access-denied" error response.
There are a number of data nodes defined in this YANG module that are
writable/creatable/deletable (i.e., config true, which is the
default). These data nodes may be considered sensitive or vulnerable
in some network environments. Write operations (e.g., edit-config)
to these data nodes without proper protection can have a negative
effect on network operations. These are the subtrees and data nodes
and their sensitivity/vulnerability:
o /nacm: The entire /nacm subtree is related to security. Refer to
the following sections for more details.
This section highlights the issues for an administrator to consider
when configuring a NETCONF server with the NACM.
<span class="h3"><a class="selflink" id="section-5.1" href="#section-5.1">5.1</a>. NACM Configuration and Monitoring Considerations</span>
Configuration of the access control system is highly sensitive to
system security. A server may choose not to allow any user
configuration to some portions of it, such as the global security
level or the groups that allowed access to system resources.
By default, NACM enforcement is enabled. By default, "read" access
to all datastore contents is enabled (unless "nacm:default-deny-all"
is specified for the data definition), and "exec" access is enabled
for safe protocol operations. An administrator needs to ensure that
the NACM is enabled and also decide if the default access parameters
are set appropriately. Make sure that the following data nodes are
properly configured:
o /nacm/enable-nacm (default "true")
o /nacm/read-default (default "permit")
o /nacm/write-default (default "deny")
o /nacm/exec-default (default "permit")
An administrator needs to restrict write access to all configurable
objects within this data model.
<span class="grey">Bierman & Bjorklund Standards Track [Page 43]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-44" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
If write access is allowed for configuration of access control rules,
then care needs to be taken not to disrupt the access control
enforcement. For example, if the NACM access control rules are
edited directly within the running configuration datastore (i.e.,
:writable-running capability is supported and used), then care needs
to be taken not to allow unintended access while the edits are being
done.
An administrator needs to make sure that the translation from a
transport- or implementation-dependent user identity to a NACM
username is unique and correct. This requirement is specified in
detail in <a href="./rfc6241#section-2.2">Section 2.2 of [RFC6241]</a>.
An administrator needs to be aware that the YANG data structures
representing access control rules (/nacm/rule-list and
/nacm/rule-list/rule) are ordered by the client. The server will
evaluate the access control rules according to their relative
conceptual order within the running configuration datastore.
Note that the /nacm/groups data structure contains the administrative
group names used by the server. These group names may be configured
locally and/or provided through an external protocol, such as RADIUS
[<a href="./rfc2865" title=""Remote Authentication Dial In User Service (RADIUS)"">RFC2865</a>] [<a href="./rfc5607" title=""Remote Authentication Dial-In User Service (RADIUS) Authorization for Network Access Server (NAS) Management"">RFC5607</a>].
An administrator needs to be aware of the security properties of any
external protocol used by the transport layer to determine group
names. For example, if this protocol does not protect against
man-in-the-middle attacks, an attacker might be able to inject group
names that are configured in the NACM so that a user gets more
permissions than it should. In such cases, the administrator may
wish to disable the usage of such group names by setting
/nacm/enable-external-groups to "false".
Some of the readable data nodes in this YANG module may be considered
sensitive or vulnerable in some network environments. It is thus
important to control read access (e.g., via get, get-config, or
notification) to these data nodes. These are the subtrees and data
nodes and their sensitivity/vulnerability:
o /nacm/enable-nacm
o /nacm/read-default
o /nacm/write-default
o /nacm/exec-default
o /nacm/enable-external-groups
<span class="grey">Bierman & Bjorklund Standards Track [Page 44]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-45" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
o /nacm/groups
o /nacm/rule-list
An administrator needs to restrict read access to the above-listed
objects within this data model, as they reveal access control
configuration that could be considered sensitive.
<span class="h3"><a class="selflink" id="section-5.2" href="#section-5.2">5.2</a>. General Configuration Issues</span>
There is a risk that invocation of non-standard protocol operations
will have undocumented side effects. An administrator needs to
construct access control rules such that the configuration datastore
is protected from such side effects.
It is possible for a session with some write access (e.g., allowed to
invoke <edit-config>), but without any access to a particular
datastore subtree containing sensitive data, to determine the
presence or non-presence of that data. This can be done by
repeatedly issuing some sort of edit request (create, update, or
delete) and possibly receiving "access-denied" errors in response.
These "fishing" attacks can identify the presence or non-presence of
specific sensitive data even without the "error-path" field being
present within the <rpc-error> response.
It may be possible for the set of NETCONF capabilities on the server
to change over time. If so, then there is a risk that new protocol
operations, notifications, and/or datastore content have been added
to the device. An administrator needs to be sure that the access
control rules are correct for the new content in this case.
Mechanisms to detect NETCONF capability changes on a specific device
are outside the scope of this document.
It is possible that the data model definition itself (e.g., a YANG
when-stmt) will help an unauthorized session determine the presence
or even value of sensitive data nodes by examining the presence and
values of different data nodes.
It is possible that the data model definition itself (e.g., a YANG
when-stmt or choice-stmt) will allow a session to implicitly create
or delete nodes that the session does not have write access to as an
implicit side effect from the processing of an allowed <edit-config>
operation.
<span class="grey">Bierman & Bjorklund Standards Track [Page 45]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-46" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
There is a risk that non-standard protocol operations, or even the
standard <get> protocol operation, may return data that "aliases" or
"copies" sensitive data from a different data object. There may
simply be multiple data model definitions that expose or even
configure the same underlying system instrumentation.
A data model may contain external keys (e.g., YANG leafref), which
expose values from a different data structure. An administrator
needs to be aware of sensitive data models that contain leafref
nodes. This entails finding all the leafref objects that "point" at
the sensitive data (i.e., "path-stmt" values) that implicitly or
explicitly includes the sensitive data node.
It is beyond the scope of this document to define access control
enforcement procedures for underlying device instrumentation that may
exist to support the NETCONF server operation. An administrator can
identify each protocol operation that the server provides and decide
if it needs any access control applied to it.
This document incorporates the optional use of a recovery session
mechanism, which can be used to bypass access control enforcement in
emergencies such as NACM configuration errors that disable all access
to the server. The configuration and identification of such a
recovery session mechanism are implementation specific and are
outside the scope of this document. An administrator needs to be
aware of any recovery session mechanisms available on the device and
make sure that they are used appropriately.
It is possible for a session to disrupt configuration management,
even without any write access to the configuration, by locking the
datastore. This may be done to ensure that all or part of the
configuration remains stable while it is being retrieved, or it may
be done as a "denial-of-service" attack. There is no way for the
server to know the difference. An administrator may wish to restrict
"exec" access to the following protocol operations:
o <lock>
o <unlock>
o <partial-lock>
o <partial-unlock>
<span class="grey">Bierman & Bjorklund Standards Track [Page 46]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-47" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="section-5.3" href="#section-5.3">5.3</a>. Data Model Design Considerations</span>
Designers need to clearly identify any sensitive data, notifications,
or protocol operations defined within a YANG module. For such
definitions, a "nacm:default-deny-write" or "nacm:default-deny-all"
statement ought to be present, in addition to a clear description of
the security risks.
Protocol operations need to be properly documented by the data model
designer so that it is clear to administrators what data nodes (if
any) are affected by the protocol operation and what information (if
any) is returned in the <rpc-reply> message.
Data models ought to be designed so that different access levels for
input parameters to protocol operations are not required. The use of
generic protocol operations should be avoided, and if different
access levels are needed, separate protocol operations should be
defined instead.
<span class="h2"><a class="selflink" id="section-6" href="#section-6">6</a>. References</span>
<span class="h3"><a class="selflink" id="section-6.1" href="#section-6.1">6.1</a>. Normative References</span>
[<a id="ref-RFC2119">RFC2119</a>] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", <a href="https://www.rfc-editor.org/bcp/bcp14">BCP 14</a>, <a href="./rfc2119">RFC 2119</a>,
DOI 10.17487/RFC2119, March 1997,
<<a href="https://www.rfc-editor.org/info/rfc2119">https://www.rfc-editor.org/info/rfc2119</a>>.
[<a id="ref-RFC5246">RFC5246</a>] Dierks, T. and E. Rescorla, "The Transport Layer Security
(TLS) Protocol Version 1.2", <a href="./rfc5246">RFC 5246</a>,
DOI 10.17487/RFC5246, August 2008,
<<a href="https://www.rfc-editor.org/info/rfc5246">https://www.rfc-editor.org/info/rfc5246</a>>.
[<a id="ref-RFC5277">RFC5277</a>] Chisholm, S. and H. Trevino, "NETCONF Event
Notifications", <a href="./rfc5277">RFC 5277</a>, DOI 10.17487/RFC5277, July 2008,
<<a href="https://www.rfc-editor.org/info/rfc5277">https://www.rfc-editor.org/info/rfc5277</a>>.
[<a id="ref-RFC6020">RFC6020</a>] Bjorklund, M., Ed., "YANG - A Data Modeling Language for
the Network Configuration Protocol (NETCONF)", <a href="./rfc6020">RFC 6020</a>,
DOI 10.17487/RFC6020, October 2010,
<<a href="https://www.rfc-editor.org/info/rfc6020">https://www.rfc-editor.org/info/rfc6020</a>>.
[<a id="ref-RFC6241">RFC6241</a>] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed.,
and A. Bierman, Ed., "Network Configuration Protocol
(NETCONF)", <a href="./rfc6241">RFC 6241</a>, DOI 10.17487/RFC6241, June 2011,
<<a href="https://www.rfc-editor.org/info/rfc6241">https://www.rfc-editor.org/info/rfc6241</a>>.
<span class="grey">Bierman & Bjorklund Standards Track [Page 47]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-48" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
[<a id="ref-RFC6242">RFC6242</a>] Wasserman, M., "Using the NETCONF Protocol over Secure
Shell (SSH)", <a href="./rfc6242">RFC 6242</a>, DOI 10.17487/RFC6242, June 2011,
<<a href="https://www.rfc-editor.org/info/rfc6242">https://www.rfc-editor.org/info/rfc6242</a>>.
[<a id="ref-RFC6991">RFC6991</a>] Schoenwaelder, J., Ed., "Common YANG Data Types",
<a href="./rfc6991">RFC 6991</a>, DOI 10.17487/RFC6991, July 2013,
<<a href="https://www.rfc-editor.org/info/rfc6991">https://www.rfc-editor.org/info/rfc6991</a>>.
[<a id="ref-RFC7230">RFC7230</a>] Fielding, R., Ed., and J. Reschke, Ed., "Hypertext
Transfer Protocol (HTTP/1.1): Message Syntax and Routing",
<a href="./rfc7230">RFC 7230</a>, DOI 10.17487/RFC7230, June 2014,
<<a href="https://www.rfc-editor.org/info/rfc7230">https://www.rfc-editor.org/info/rfc7230</a>>.
[<a id="ref-RFC7950">RFC7950</a>] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language",
<a href="./rfc7950">RFC 7950</a>, DOI 10.17487/RFC7950, August 2016,
<<a href="https://www.rfc-editor.org/info/rfc7950">https://www.rfc-editor.org/info/rfc7950</a>>.
[<a id="ref-RFC8040">RFC8040</a>] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF
Protocol", <a href="./rfc8040">RFC 8040</a>, DOI 10.17487/RFC8040, January 2017,
<<a href="https://www.rfc-editor.org/info/rfc8040">https://www.rfc-editor.org/info/rfc8040</a>>.
[<a id="ref-RFC8174">RFC8174</a>] Leiba, B., "Ambiguity of Uppercase vs Lowercase in
<a href="./rfc2119">RFC 2119</a> Key Words", <a href="https://www.rfc-editor.org/bcp/bcp14">BCP 14</a>, <a href="./rfc8174">RFC 8174</a>,
DOI 10.17487/RFC8174, May 2017,
<<a href="https://www.rfc-editor.org/info/rfc8174">https://www.rfc-editor.org/info/rfc8174</a>>.
[<a id="ref-RFC8342">RFC8342</a>] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K.,
and R. Wilton, "Network Management Datastore Architecture
(NMDA)", <a href="./rfc8342">RFC 8342</a>, DOI 10.17487/RFC8342, March 2018,
<<a href="https://www.rfc-editor.org/info/rfc8342">https://www.rfc-editor.org/info/rfc8342</a>>.
[<a id="ref-W3C.REC-xml-20081126">W3C.REC-xml-20081126</a>]
Bray, T., Paoli, J., Sperberg-McQueen, M., Maler, E., and
F. Yergeau, "Extensible Markup Language (XML) 1.0
(Fifth Edition)", World Wide Web Consortium Recommendation
REC-xml-20081126, November 2008,
<<a href="https://www.w3.org/TR/2008/REC-xml-20081126">https://www.w3.org/TR/2008/REC-xml-20081126</a>>.
<span class="grey">Bierman & Bjorklund Standards Track [Page 48]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-49" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="section-6.2" href="#section-6.2">6.2</a>. Informative References</span>
[<a id="ref-RFC2865">RFC2865</a>] Rigney, C., Willens, S., Rubens, A., and W. Simpson,
"Remote Authentication Dial In User Service (RADIUS)",
<a href="./rfc2865">RFC 2865</a>, DOI 10.17487/RFC2865, June 2000,
<<a href="https://www.rfc-editor.org/info/rfc2865">https://www.rfc-editor.org/info/rfc2865</a>>.
[<a id="ref-RFC5607">RFC5607</a>] Nelson, D. and G. Weber, "Remote Authentication Dial-In
User Service (RADIUS) Authorization for Network Access
Server (NAS) Management", <a href="./rfc5607">RFC 5607</a>, DOI 10.17487/RFC5607,
July 2009, <<a href="https://www.rfc-editor.org/info/rfc5607">https://www.rfc-editor.org/info/rfc5607</a>>.
[<a id="ref-YANG-SEC">YANG-SEC</a>] IETF, "YANG Security Guidelines", <<a href="https://trac.ietf.org/trac/ops/wiki/yang-security-guidelines">https://trac.ietf.org/</a>
<a href="https://trac.ietf.org/trac/ops/wiki/yang-security-guidelines">trac/ops/wiki/yang-security-guidelines</a>>.
<span class="grey">Bierman & Bjorklund Standards Track [Page 49]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-50" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h2"><a class="selflink" id="appendix-A" href="#appendix-A">Appendix A</a>. Usage Examples</span>
The following XML [<a href="#ref-W3C.REC-xml-20081126">W3C.REC-xml-20081126</a>] snippets are provided as
examples only, to demonstrate how the NACM can be configured to
perform some access control tasks.
<span class="h3"><a class="selflink" id="appendix-A.1" href="#appendix-A.1">A.1</a>. <groups> Example</span>
There needs to be at least one <group> entry in order for any of the
access control rules to be useful.
The following XML shows arbitrary groups and is not intended to
represent any particular use case.
<nacm xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-acm">
<groups>
<group>
<name>admin</name>
<user-name>admin</user-name>
<user-name>andy</user-name>
</group>
<group>
<name>limited</name>
<user-name>wilma</user-name>
<user-name>bam-bam</user-name>
</group>
<group>
<name>guest</name>
<user-name>guest</user-name>
<user-name>guest@example.com</user-name>
</group>
</groups>
</nacm>
This example shows three groups:
admin: The "admin" group contains two users named "admin" and
"andy".
limited: The "limited" group contains two users named "wilma" and
"bam-bam".
guest: The "guest" group contains two users named "guest" and
"guest@example.com".
<span class="grey">Bierman & Bjorklund Standards Track [Page 50]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-51" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="appendix-A.2" href="#appendix-A.2">A.2</a>. Module Rule Example</span>
Module rules are used to control access to all the content defined in
a specific module. A module rule has the "module-name" leaf set but
no nodes from the "rule-type" choice set.
<nacm xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-acm">
<rule-list>
<name>guest-acl</name>
<group>guest</group>
<rule>
<name>deny-ncm</name>
<module-name>ietf-netconf-monitoring</module-name>
<access-operations>*</access-operations>
<action>deny</action>
<comment>
Do not allow guests any access to the NETCONF
monitoring information.
</comment>
</rule>
</rule-list>
<rule-list>
<name>limited-acl</name>
<group>limited</group>
<rule>
<name>permit-ncm</name>
<module-name>ietf-netconf-monitoring</module-name>
<access-operations>read</access-operations>
<action>permit</action>
<comment>
Allow read access to the NETCONF
monitoring information.
</comment>
</rule>
<rule>
<name>permit-exec</name>
<module-name>*</module-name>
<access-operations>exec</access-operations>
<action>permit</action>
<comment>
Allow invocation of the
supported server operations.
</comment>
</rule>
</rule-list>
<span class="grey">Bierman & Bjorklund Standards Track [Page 51]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-52" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<rule-list>
<name>admin-acl</name>
<group>admin</group>
<rule>
<name>permit-all</name>
<module-name>*</module-name>
<access-operations>*</access-operations>
<action>permit</action>
<comment>
Allow the 'admin' group complete access to all
operations and data.
</comment>
</rule>
</rule-list>
</nacm>
This example shows four module rules:
deny-ncm: This rule prevents the "guest" group from reading any
monitoring information in the "ietf-netconf-monitoring" YANG
module.
permit-ncm: This rule allows the "limited" group to read the
"ietf-netconf-monitoring" YANG module.
permit-exec: This rule allows the "limited" group to invoke any
protocol operation supported by the server.
permit-all: This rule allows the "admin" group complete access to
all content in the server. No subsequent rule will match for the
"admin" group because of this module rule.
<span class="grey">Bierman & Bjorklund Standards Track [Page 52]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-53" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="appendix-A.3" href="#appendix-A.3">A.3</a>. Protocol Operation Rule Example</span>
Protocol operation rules are used to control access to a specific
protocol operation.
<nacm xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-acm">
<rule-list>
<name>guest-limited-acl</name>
<group>limited</group>
<group>guest</group>
<rule>
<name>deny-kill-session</name>
<module-name>ietf-netconf</module-name>
<rpc-name>kill-session</rpc-name>
<access-operations>exec</access-operations>
<action>deny</action>
<comment>
Do not allow the 'limited' group or the 'guest' group
to kill another session.
</comment>
</rule>
<rule>
<name>deny-delete-config</name>
<module-name>ietf-netconf</module-name>
<rpc-name>delete-config</rpc-name>
<access-operations>exec</access-operations>
<action>deny</action>
<comment>
Do not allow the 'limited' group or the 'guest' group
to delete any configurations.
</comment>
</rule>
</rule-list>
<span class="grey">Bierman & Bjorklund Standards Track [Page 53]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-54" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<rule-list>
<name>limited-acl</name>
<group>limited</group>
<rule>
<name>permit-edit-config</name>
<module-name>ietf-netconf</module-name>
<rpc-name>edit-config</rpc-name>
<access-operations>exec</access-operations>
<action>permit</action>
<comment>
Allow the 'limited' group to edit the configuration.
</comment>
</rule>
</rule-list>
</nacm>
This example shows three protocol operation rules:
deny-kill-session: This rule prevents the "limited" group or the
"guest" group from invoking the NETCONF <kill-session> protocol
operation.
deny-delete-config: This rule prevents the "limited" group or the
"guest" group from invoking the NETCONF <delete-config> protocol
operation.
permit-edit-config: This rule allows the "limited" group to invoke
the NETCONF <edit-config> protocol operation. This rule will have
no real effect unless the "exec-default" leaf is set to "deny".
<span class="grey">Bierman & Bjorklund Standards Track [Page 54]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-55" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<span class="h3"><a class="selflink" id="appendix-A.4" href="#appendix-A.4">A.4</a>. Data Node Rule Example</span>
Data node rules are used to control access to specific (config and
non-config) data nodes within the NETCONF content provided by the
server.
<nacm xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-acm">
<rule-list>
<name>guest-acl</name>
<group>guest</group>
<rule>
<name>deny-nacm</name>
<path xmlns:n="urn:ietf:params:xml:ns:yang:ietf-netconf-acm">
/n:nacm
</path>
<access-operations>*</access-operations>
<action>deny</action>
<comment>
Deny the 'guest' group any access to the /nacm data.
</comment>
</rule>
</rule-list>
<rule-list>
<name>limited-acl</name>
<group>limited</group>
<rule>
<name>permit-acme-config</name>
<path xmlns:acme="http://example.com/ns/netconf">
/acme:acme-netconf/acme:config-parameters
</path>
<access-operations>
read create update delete
</access-operations>
<action>permit</action>
<comment>
Allow the 'limited' group complete access to the acme
NETCONF configuration parameters. Showing long form
of 'access-operations' instead of shorthand.
</comment>
</rule>
</rule-list>
<span class="grey">Bierman & Bjorklund Standards Track [Page 55]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-56" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
<rule-list>
<name>guest-limited-acl</name>
<group>guest</group>
<group>limited</group>
<rule>
<name>permit-dummy-interface</name>
<path xmlns:acme="http://example.com/ns/itf">
/acme:interfaces/acme:interface[acme:name='dummy']
</path>
<access-operations>read update</access-operations>
<action>permit</action>
<comment>
Allow the 'limited' and 'guest' groups read
and update access to the dummy interface.
</comment>
</rule>
</rule-list>
<rule-list>
<name>admin-acl</name>
<group>admin</group>
<rule>
<name>permit-interface</name>
<path xmlns:acme="http://example.com/ns/itf">
/acme:interfaces/acme:interface
</path>
<access-operations>*</access-operations>
<action>permit</action>
<comment>
Allow the 'admin' group full access to all acme interfaces.
</comment>
</rule>
</rule-list>
</nacm>
<span class="grey">Bierman & Bjorklund Standards Track [Page 56]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-57" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
This example shows four data node rules:
deny-nacm: This rule denies the "guest" group any access to the
/nacm subtree.
permit-acme-config: This rule gives the "limited" group read-write
access to the acme <config-parameters>.
permit-dummy-interface: This rule gives the "limited" and "guest"
groups read-update access to the acme <interface> entry named
"dummy". This entry cannot be created or deleted by these groups;
it can only be altered.
permit-interface: This rule gives the "admin" group read-write
access to all acme <interface> entries.
<span class="h3"><a class="selflink" id="appendix-A.5" href="#appendix-A.5">A.5</a>. Notification Rule Example</span>
Notification rules are used to control access to a specific
notification event type.
<nacm xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-acm">
<rule-list>
<name>sys-acl</name>
<group>limited</group>
<group>guest</group>
<rule>
<name>deny-config-change</name>
<module-name>acme-system</module-name>
<notification-name>sys-config-change</notification-name>
<access-operations>read</access-operations>
<action>deny</action>
<comment>
Do not allow the 'guest' group or the 'limited' group
to receive config change events.
</comment>
</rule>
</rule-list>
</nacm>
This example shows one notification rule:
deny-config-change: This rule prevents the "limited" group or the
"guest" group from receiving the acme <sys-config-change>
event type.
<span class="grey">Bierman & Bjorklund Standards Track [Page 57]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-58" ></span>
<span class="grey"><a href="./rfc8341">RFC 8341</a> NACM March 2018</span>
Authors' Addresses
Andy Bierman
YumaWorks
685 Cochran St.
Suite #160
Simi Valley, CA 93065
United States of America
Email: andy@yumaworks.com
Martin Bjorklund
Tail-f Systems
Email: mbj@tail-f.com
Bierman & Bjorklund Standards Track [Page 58]
</pre>
|