# US 2024/0179182 A1 · Authorization policy validation

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

- Number: US 2024/0179182 A1
- Document ID: US20240179182A1
- Status: Published application
- Kind: A1
- Application number: 18/070,349
- Filed: 2022-11-28
- Published: 2024-05-30
- Earliest claimed: 2022-11-28
- Assignees: Amazon Technologies, Inc.
- Applicants: Amazon Technologies, Inc.
- Inventors: Michael W. HICKS; John Holman KASTNER; Emina TORLAK; Richard Matthew MCCUTCHEN; Darin MCADAMS; Neha RUNGTA; Aaron Joseph ELINE; Joseph Wallace CUTLER; Eleftherios IOANNIDIS
- Web page: https://patentgrep.com/patent/US20240179182A1

## CPC

- H04L 63/20: {for managing network security; network security policies in general (filtering policies H04L63/0227)}
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

A system and method for authorization policy validation. A validator takes as input an authorization policy to be analyzed and a schema that specifies entity types and their attributes, types of entity parents in an entity hierarchy, and which entity types can be used with which actions. The validator checks that the policy conforms to the schema. If the check passes, then the policy is guaranteed to be free of both type errors and attribute access errors for any input that conforms to the schema.

## Claims

### Claim 1

A method performed by one or more electronic devices in a provider network, the method comprising:
obtaining an authorization policy schema;
determining whether there are any inconsistencies between an authorization policy in an authorization policy language and the authorization policy schema;
wherein the authorization policy comprises:
(a) an effect;
(b) an authorization policy head that selects one or more principals, one or more actions, or one or more resources to which the authorization policy applies; and
(c) one or more optional conditional clauses that further refine the circumstances under which the authorization policy applies;
determining there are no inconsistencies between the authorization policy and the authorization policy schema such that the authorization policy is guaranteed to be free of runtime type errors and free of runtime attribute access errors for any input that conforms to the authorization policy schema.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
storing a set of entities arranged in an entity hierarchy; and
wherein the authorization policy further comprises at least one expression in terms of one or more entities in the entity hierarchy.

### Claim 3 (depends on 1)

The method of claim 1, wherein the authorization policy language is a dynamically typed language.

### Claim 4

A method performed by one or more electronic devices, the method comprising:
obtaining an authorization policy schema;
determining whether there are any inconsistencies between an authorization policy in an authorization policy language and the authorization policy schema;
wherein the authorization policy comprises:
(a) an effect;
(b) an authorization policy head that selects one or more principals, one or more actions, or one or more resources to which the authorization policy applies; and
(c) one or more optional conditional clauses that further refine the circumstances under which the authorization policy applies;
if there are one or more determined inconsistencies between the authorization policy and the authorization policy schema, then causing display of information indicating that the authorization policy is invalid with respect to the authorization policy schema; and
wherein if there are no determined inconsistencies between the authorization policy and the authorization policy schema, then the authorization policy is guaranteed to be free of runtime type errors and free of runtime attribute access errors for any input that conforms to the authorization policy schema.

### Claim 5 (depends on 4)

The method of claim 4, further comprising:
storing a set of entities arranged in an entity hierarchy; and
wherein the authorization policy further comprises at least one expression in terms of one or more entities in the entity hierarchy.

### Claim 6 (depends on 4)

The method of claim 4, further comprising:
detecting a Boolean expression in the authorization policy that dereferences an optional attribute of an entity without checking for existence of the optional attribute of the entity as a condition precedent; and
wherein the information displayed indicates that the Boolean expression lacks a check for existence of the optional attribute of the entity as a condition precedent.

### Claim 7 (depends on 4)

The method of claim 4, further comprising:
detecting an entity type in the authorization policy that is not an entity type listed in the entity types specification; and
wherein the information displayed indicates the entity type of in the authorization policy.

### Claim 8 (depends on 4)

The method of claim 4, further comprising:
detecting an action in the authorization policy that is not an action listed in the actions specification; and
wherein the information displayed indicates the action in the authorization policy.

### Claim 9 (depends on 4)

The method of claim 4, further comprising:
detecting an action in the authorization policy that is applied to an unsupported principal or resource in the authorization policy; and
wherein the information displayed indicates the action in the authorization policy and indicates the unsupported principal or resource in the authorization policy to which the action is applied.

### Claim 10 (depends on 4)

The method of claim 4, further comprising:
detecting an improper use of a hierarchy containment operator in the authorization policy; and
wherein the information displayed comprises a hint about proper use of the hierarchy containment operator in an authorization policy.

### Claim 11 (depends on 4)

The method of claim 4, further comprising:
detecting an improper use of an equality operator in the authorization policy; and
wherein the information displayed comprises a hint about proper use of the hierarchy containment operator.

### Claim 12 (depends on 4)

The method of claim 4, further comprising:
detecting an unrecognized attribute of an entity in the authorization policy that is not specified as an attribute of the entity in the authorization policy schema; and
wherein the information displayed indicates the unrecognized attribute.

### Claim 13 (depends on 4)

The method of claim 4, further comprising:
detecting a type mismatch in an operator expression in the authorization policy, the operator expression comprising an operator having valid semantics on only certain data types, the operator expression applying the operator to a value of a data type for which the operator does not have valid semantics; and
wherein the information displayed indicates the type mismatch.

### Claim 14 (depends on 4)

The method of claim 4, further comprising:
detecting that the authorization policy always evaluates to false; and
wherein the information displayed indicates that the authorization policy always evaluates to false.

### Claim 15 (depends on 4)

The method of claim 4, wherein the authorization policy schema and the authorization policy are identified to a policy validator by parameters in a command line invocation of the policy validator.

### Claim 16 (depends on 4)

The method of claim 4, wherein the authorization policy language is a dynamically typed language.

### Claim 17

A system comprising:
a first set of one or more electronic devices to implement an authorization policy validation service in a provider network, the authorization policy validation service comprising instructions which when executed cause the authorization policy validation service to perform:
obtaining an authorization policy schema;
determining whether there are any inconsistencies between an authorization policy in an authorization policy language and the authorization policy schema;
wherein the authorization policy comprises:
(a) an effect;
(b) an authorization policy head that selects one or more principals, one or more actions, or one or more resources to which the authorization policy applies; and
(c) one or more optional conditional clauses that further refine the circumstances under which the authorization policy applies;
if there are one or more determined inconsistencies between the authorization policy and the authorization policy schema, then causing display of information indicating that the authorization policy is invalid with respect to the authorization policy schema; and
wherein if there are no determined inconsistencies between the authorization policy and the authorization policy schema, then the authorization policy is guaranteed to be free of runtime type errors and free of runtime attribute access errors for any input that conforms to the authorization policy schema.

### Claim 18 (depends on 17)

The system of claim 17, the authorization policy validation service further comprising instructions which when executed cause the authorization policy validation service to further perform:
storing a set of entities arranged in an entity hierarchy; and
wherein the authorization policy further comprises at least one expression in terms of one or more entities in the entity hierarchy.

### Claim 19 (depends on 17)

The system of claim 17, the authorization policy validation service further comprising instructions which when executed cause the authorization policy validation service to further perform:
detecting a Boolean expression in the authorization policy that dereferences an optional attribute of an entity without checking for existence of the optional attribute of the entity as a condition precedent; and
wherein the information displayed indicates that the Boolean expression lacks a check for existence of the optional attribute of the entity as a condition precedent.

### Claim 20 (depends on 17)

The system of claim 17, the authorization policy validation service further comprising instructions which when executed cause the authorization policy validation service to further perform:
detecting an entity type in the authorization policy that is not an entity type listed in the entity types specification; and
wherein the information displayed indicates the entity type of in the authorization policy.
