|
1 | | -Protect the modern API application with F5XC - static protection |
2 | | -================================================================ |
| 1 | +Start Protecting the modern API application with F5XC |
| 2 | +===================================================== |
3 | 3 |
|
4 | 4 | Assign OpenAPI spec file to the LB |
5 | 5 | ---------------------------------- |
@@ -55,68 +55,3 @@ Assign the API definition to the LB |
55 | 55 | .. image:: ../pictures/api-protection.png |
56 | 56 | :align: center |
57 | 57 | :scale: 70% |
58 | | - |
59 | | -| |
60 | | -
|
61 | | -Apply API Protection rules |
62 | | --------------------------- |
63 | | - |
64 | | -Understand the difference between API Protection and API Validation |
65 | | -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
66 | | - |
67 | | -Before enforcing any policy, it is important to understand the differences between ``API Protection`` and ``API Validation`` (+API Discovery) |
68 | | - |
69 | | -In the slide below, you can understand the difference: |
70 | | - |
71 | | -* API Protection only allow ``known API endpoints and methods`` and does not enforce responses. |
72 | | - * API Protection is ``Failed-Close`` by design |
73 | | - |
74 | | -* API Validation ``validates`` the OpenAPI Spec (OAS) file with methods, endpoints and parameters. It validates also the responses. |
75 | | - * API Validation is ``Failed-Open`` by design |
76 | | - |
77 | | -* API Discovery is on top of ``API Validation`` and provides discovery of unknown specifications (methods, endpoints and parameters) |
78 | | - * API Discovery can be used alone without API Validation if API Dev can't deliver the OAS file. |
79 | | - |
80 | | -.. image:: ../pictures/slide-api-protection.png |
81 | | - :align: center |
82 | | - :scale: 40% |
83 | | - |
84 | | - |
85 | | -Create the default API Protection rule |
86 | | -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
87 | | - |
88 | | -In this lab, we will create an ``API Protection rule`` to enforce and allow only ``known specifications``. The endpoints defined in the OAS files are: |
89 | | - |
90 | | -* /adjectives |
91 | | -* /animals |
92 | | -* /locations |
93 | | - |
94 | | -.. note:: As a reminder, the endpoint ``/colors`` is not defined in the OAS file, and the base path is ``/api/`` |
95 | | - |
96 | | -#. Edit your "sentence-re-lb" application LB |
97 | | -#. Go to ``API Protection`` - ``API Protection Rules`` and click ``configure`` |
98 | | - |
99 | | - .. image:: ../pictures/api-protection-rules.png |
100 | | - :align: center |
101 | | - |
102 | | -#. Click on ``Configure in Server URLs and API Groups`` and create the following two rules. Don't forget to click on ``Apply`` |
103 | | - |
104 | | - #. Rule 1: allows the methods and endpoints defined in the OAS file. |
105 | | - |
106 | | - .. image:: ../pictures/allow-all-rule.png |
107 | | - :align: left |
108 | | - |
109 | | - #. Rule 2: deny the rest |
110 | | - |
111 | | - .. image:: ../pictures/deny-unknown.png |
112 | | - :align: left |
113 | | - |
114 | | -#. You should now have 2 rules. Save all your configurations. |
115 | | - |
116 | | - .. image:: ../pictures/all-rules.png |
117 | | - :align: center |
118 | | - :scale: 50% |
119 | | - |
120 | | -#. Save and Exit. |
121 | | - |
122 | | -.. note:: You are good to test your first API Protection Load Balancer in F5 Distributes Cloud |
0 commit comments