Documentation ¶
Overview ¶
Package policy provides a custom function to unmarshal AWS policies.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Policy ¶
type Policy struct { Version string `json:"Version"` ID string `json:"ID,omitempty"` Statements []Statement `json:"Statement"` }
Policy represents an AWS iam policy document
func (*Policy) UnmarshalJSON ¶
UnmarshalJSON decodifies input JSON info to awsPolicy type
type Statement ¶
type Statement struct { StatementID string `json:"StatementID,omitempty"` // Statement ID, service specific Effect string `json:"Effect"` // Allow or Deny Principal map[string][]string `json:"Principal,omitempty"` // principal that is allowed or denied NotPrincipal map[string][]string `json:"NotPrincipal,omitempty"` // exception to a list of principals Action []string `json:"Action"` // allowed or denied action NotAction []string `json:"NotAction,omitempty"` // matches everything except Resource []string `json:"Resource,omitempty"` // object or objects that the statement covers NotResource []string `json:"NotResource,omitempty"` // matches everything except Condition []string `json:"Condition,omitempty"` // conditions for when a policy is in effect }
Statement represents body of AWS iam policy document
Click to show internal directories.
Click to hide internal directories.