API Discovery Setup ¶
This article describes how to enable, configure and debug the API Discovery module.
Enable¶
API Discovery is included in all forms of the Wallarm node installation. During node deployment, it installs the API Discovery module but keeps it disabled by default.
To enable and run API Discovery correctly:
-
Make sure your subscription plan includes API Discovery. To change the subscription plan, please send a request to sales@wallarm.com.
-
In Wallarm Console → API Discovery → Configure API Discovery, enable traffic analysis with API Discovery.
Once the API Discovery module is enabled, it will start the traffic analysis and API inventory building. The API inventory will be displayed in the API Discovery section of Wallarm Console.
Configure¶
By clicking the Configure API Discovery button in the API Discovery section, you proceed to the API discovery fine-tuning options, such as choosing applications for API discovery and customizing the risk score calculation.
Choosing applications for API Discovery¶
You may enable/disable API Discovery for all applications or only the selected ones:
-
Ensure that the applications are added as described in the Setting up applications article.
If the applications are not configured, structures of all APIs are grouped in one tree.
-
Enable API Discovery for the required applications in Wallarm Console → API Discovery → Configure API Discovery.
When you add a new application in Settings → Applications, it is automatically added to the list of applications for API discovery in the disabled state.
Customizing risk score calculation¶
You can configure the weight of each factor in risk score calculation and calculation method.
Customizing sensitive data detection¶
API Discovery detects and highlights sensitive data consumed and carried by your APIs. You can fine-tune the existing detection process and extend it with your own data types to detect.
To view the current configuration and perform changes, in Wallarm Console, go to API Discovery → Configure API Discovery → Sensitive data. Here, you can overview and modify the existing sensitive data patterns and add your own.
Debug¶
To get and analyze the API Discovery logs, you can use the following methods:
-
Read the log file
/opt/wallarm/var/log/wallarm/appstructure-out.log
on the machine where the node is running. -
If the Wallarm node is deployed as the Kubernetes Ingress controller: check the status of the pod running the Tarantool and
wallarm-appstructure
containers. The pod status must be Running.Read the logs of the
wallarm-appstructure
container: