Running Security Operations
This section describes how you can use the Sample Application instances running on the Kubernetes cluster to protect the data that is sent by a REST API client.
To run security operations:
- Send the following CURL request from the Linux instance.
curl --location --request POST 'http://<DNS name or IP address of the Load Balancer>:8080/protect' --header 'Content-Type: application/json' --header 'X-Correlation-ID: k81d1fae-7dec-41g0-a765-90a0c31e6wf5' --data-raw '{ "dataElement": "Alphanum", "policyUser": "user1", "input": [ "protegrity1234","helloworld" ] }' -v
The Application Protector Java Container instance returns the following protected output.
{"output":["pLAvXYIAbp5234","hCkp7o0rld"],"errorMsg":"None"}
If you want to unprotect the data, then you can run the following command.
curl --location --request POST 'http://<DNS name or IP address of the Load Balancer>:8080/unprotect' --header 'Content-Type: application/json' --header 'X-Correlation-ID: k81d1fae-7dec-41g0-a765-90a0c31e6wf5' --data-raw '{ "dataElement": "TE_A_N_S13_L0R0_Y_ST", "policyUser": "user1", "input": [ "pLAvXYIAbp5234","hCkp7o0rld" ] }' -v
The Application Protector Java Container instance returns the following protected output.
{"output":["protegrity1234","helloworld"],"errorMsg":"None"}
If you want to reprotect the data, then you can run the following command.
curl --location --request POST 'http://<DNS name or IP address of the Load Balancer>:8080/reprotect' --header 'Content-Type: application/json' --header 'X-Correlation-ID: k81d1fae-7dec-41g0-a765-90a0c31e6wf5' --data-raw '{ "dataElement": "TE_A_N_S13_L0R0_Y_ST", "newDataElement": "TE_A_N_S13_L1R3_N", "policyUser": "user1", "input": [ "iaDDNBdH6EI8U","9jB7cRSuk98B" ] }' -v
{"output":["pXvJPSIPAbp5689","hDl83ns2d"],"errorMsg":"None"}
For more information about the AP Java APIs, refer to the following section Application Protector Java APIs.
For more information about the AP Java API return codes, refer to the section Application Protector API Return Codes.
Access the audit logs from the Insights Dashboard.
For more information about accessing the audit logs, refer to the section Working with Discover.
Feedback
Was this page helpful?