# US 2021/0334384 A1 · Detecting a potential security leak by a microservice

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2021/0334384 A1
- Document ID: US20210334384A1
- Status: Published application
- Kind: A1
- Application number: 16/856,702
- Filed: 2020-04-23
- Published: 2021-10-28
- Earliest claimed: 2020-04-23
- Assignees: Hewlett Packard Enterprise Development LP
- Applicants: Hewlett Packard Enterprise Development LP
- Inventors: Jyoti Ranjan; Prabhu Murthy; Ajay Kumar Bajaj
- Web page: https://patentgrep.com/patent/US20210334384A1

## CPC

- G06F 21/577: {Assessing vulnerabilities and evaluating computer system security}
- G06F 9/547: {Remote procedure calls [RPC]; Web services}
- G06F 11/0766: {Error or fault reporting or storing}
- G06F 11/3636: {by tracing the execution of the program}
- G06F 11/3688: {for test execution, e.g. scheduling of test suites}
- G06F 11/3698: Environments for analysis, debugging or testing of software
- G06F 21/6227: {where protection concerns the structure of data, e.g. records, types, queries}
- G06F 11/3684: {for test design, e.g. generating new test cases}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Embodiments described herein are generally directed to testing a microservice to determine whether the microservice leaks sensitive information. According to an example, prior to deployment of a microservice within a production environment, a test suite for the microservice is generated based at least in part on a specification of an application programming interface (API) of the microservice defining operations supported by the API and information regarding parameters of each of the operations. The microservice is subjected to the test suite. A potential security leak by the microservice is then detected by analyzing a dataset to which the microservice outputs information, including applying security rules to the dataset.

## Claims

### Claim 1

A computer-implemented method comprising:
prior to deployment of a microservice within a production environment, generating a test suite for the microservice based at least in part on a specification of an application programming interface (API) of the microservice defining a plurality of operations supported by the API and information regarding parameters of each of the plurality of operations;
subjecting the microservice to the test suite; and
detecting a potential security leak by the microservice by analyzing a dataset to which the microservice outputs information, including applying a plurality of security rules to the dataset.

### Claim 2 (depends on 1)

The method of claim 1, wherein the dataset includes error log files of a service instance of which the microservice is a part.

### Claim 3 (depends on 1)

The method of claim 1, wherein the dataset includes a stack trace of a service instance of which the microservice is a part.

### Claim 4 (depends on 1)

The method of claim 1, wherein the dataset includes output to a user interface associated with a service instance of which the microservice is a part.

### Claim 5 (depends on 1)

The method of claim 1, wherein the dataset includes responses generated by the plurality of operations.

### Claim 6 (depends on 1)

The method of claim 1, wherein the plurality of security rules test for a plurality of security leak patterns.

### Claim 7

A non-transitory machine readable medium storing instructions executable by a processing resource of a computer system, the non-transitory machine readable medium comprising instructions to:
prior to deployment of a microservice within a production environment, generate a test suite for the microservice based at least in part on a specification of an application programming interface (API) of the microservice defining a plurality of operations supported by the API and information regarding parameters of each of the plurality of operations;
subject the microservice to the test suite; and
detect a potential security leak by the microservice by analyzing a dataset to which the microservice outputs information, including applying a plurality of security rules to the dataset.

### Claim 8 (depends on 7)

The non-transitory machine readable medium of claim 7, wherein the dataset includes error log files of a service instance of which the microservice is a part.

### Claim 9 (depends on 7)

The non-transitory machine readable medium of claim 7, wherein the dataset includes a stack trace of a service instance of which the microservice is a part.

### Claim 10 (depends on 7)

The non-transitory machine readable medium of claim 7, wherein the dataset includes output to a user interface associated with a service instance of which the microservice is a part.

### Claim 11 (depends on 7)

The non-transitory machine readable medium of claim 7, wherein the dataset includes responses generated by the plurality of operations.

### Claim 12 (depends on 7)

The non-transitory machine readable medium of claim 7, wherein the plurality of security rules test for a plurality of security leak patterns.

### Claim 13 (depends on 12)

The non-transitory machine readable medium of claim 12, wherein the plurality of security leak patterns include leakage of credentials, authorization tokens, or session tokens.

### Claim 14 (depends on 12)

The non-transitory machine readable medium of claim 12, wherein the plurality of security leak patterns include leakage of information relating to a service component of a service instance of which the microservice is a part.

### Claim 15 (depends on 14)

The non-transitory machine readable medium of claim 14, wherein the service component includes a message broker endpoint, an Identity and Access Management (IAM) endpoint, or a database table.

### Claim 16 (depends on 12)

The non-transitory machine readable medium of claim 12, wherein the plurality of security leak patterns include leakage of information relating to internal system design or functioning of a service instance of which the microservice is a part.

### Claim 17 (depends on 16)

The non-transitory machine readable medium of claim 16, wherein the information relating to internal system design or functioning of the service instance includes a name of a peer microservice of the microservice or data associated with the peer microservice.

### Claim 18 (depends on 12)

The non-transitory machine readable medium of claim 12, wherein the plurality of security leak patterns include leakage of information relating to internals of the microservice.

### Claim 19 (depends on 7)

The non-transitory machine readable medium of claim 7, wherein the information regarding the parameters of each of the plurality of operations includes types of the parameters, formats of the parameters, valid ranges of values of the parameters, and whether the parameters are required or optional.

### Claim 20

A system comprising:
a processing resource; and
a non-transitory computer-readable medium, coupled to the processing resource, having stored therein instructions that when executed by the processing resource cause the processing resource to:
prior to deployment of a microservice within a production environment, generate a test suite for the microservice based at least in part on a specification of an application programming interface (API) of the microservice defining a plurality of operations supported by the API and information regarding parameters of each of the plurality of operations;
subject the microservice to the test suite; and
detect a potential security leak by the microservice by analyzing a dataset to which the microservice outputs information, including applying a plurality of security rules to the dataset.
