@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class PutResourcePolicyRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
NOOP
Constructor and Description |
---|
PutResourcePolicyRequest() |
Modifier and Type | Method and Description |
---|---|
PutResourcePolicyRequest |
clone()
Creates a shallow clone of this object for all fields except the handler context.
|
boolean |
equals(Object obj) |
Boolean |
getBlockPublicPolicy()
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that
use a wildcard for the principal.
|
String |
getResourcePolicy()
A JSON-formatted string for an Amazon Web Services resource-based policy.
|
String |
getSecretId()
The ARN or name of the secret to attach the resource-based policy.
|
int |
hashCode() |
Boolean |
isBlockPublicPolicy()
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that
use a wildcard for the principal.
|
void |
setBlockPublicPolicy(Boolean blockPublicPolicy)
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that
use a wildcard for the principal.
|
void |
setResourcePolicy(String resourcePolicy)
A JSON-formatted string for an Amazon Web Services resource-based policy.
|
void |
setSecretId(String secretId)
The ARN or name of the secret to attach the resource-based policy.
|
String |
toString()
Returns a string representation of this object.
|
PutResourcePolicyRequest |
withBlockPublicPolicy(Boolean blockPublicPolicy)
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that
use a wildcard for the principal.
|
PutResourcePolicyRequest |
withResourcePolicy(String resourcePolicy)
A JSON-formatted string for an Amazon Web Services resource-based policy.
|
PutResourcePolicyRequest |
withSecretId(String secretId)
The ARN or name of the secret to attach the resource-based policy.
|
addHandlerContext, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getHandlerContext, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestCredentialsProvider, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
public void setSecretId(String secretId)
The ARN or name of the secret to attach the resource-based policy.
For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN.
secretId
- The ARN or name of the secret to attach the resource-based policy.
For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN.
public String getSecretId()
The ARN or name of the secret to attach the resource-based policy.
For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN.
For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN.
public PutResourcePolicyRequest withSecretId(String secretId)
The ARN or name of the secret to attach the resource-based policy.
For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN.
secretId
- The ARN or name of the secret to attach the resource-based policy.
For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN.
public void setResourcePolicy(String resourcePolicy)
A JSON-formatted string for an Amazon Web Services resource-based policy. For example policies, see Permissions policy examples.
resourcePolicy
- A JSON-formatted string for an Amazon Web Services resource-based policy. For example policies, see Permissions
policy examples.public String getResourcePolicy()
A JSON-formatted string for an Amazon Web Services resource-based policy. For example policies, see Permissions policy examples.
public PutResourcePolicyRequest withResourcePolicy(String resourcePolicy)
A JSON-formatted string for an Amazon Web Services resource-based policy. For example policies, see Permissions policy examples.
resourcePolicy
- A JSON-formatted string for an Amazon Web Services resource-based policy. For example policies, see Permissions
policy examples.public void setBlockPublicPolicy(Boolean blockPublicPolicy)
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that use a wildcard for the principal. By default, public policies aren't blocked.
Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
blockPublicPolicy
- Specifies whether to block resource-based policies that allow broad access to the secret, for example
those that use a wildcard for the principal. By default, public policies aren't blocked. Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
public Boolean getBlockPublicPolicy()
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that use a wildcard for the principal. By default, public policies aren't blocked.
Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
public PutResourcePolicyRequest withBlockPublicPolicy(Boolean blockPublicPolicy)
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that use a wildcard for the principal. By default, public policies aren't blocked.
Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
blockPublicPolicy
- Specifies whether to block resource-based policies that allow broad access to the secret, for example
those that use a wildcard for the principal. By default, public policies aren't blocked. Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
public Boolean isBlockPublicPolicy()
Specifies whether to block resource-based policies that allow broad access to the secret, for example those that use a wildcard for the principal. By default, public policies aren't blocked.
Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
Resource policy validation and the BlockPublicPolicy parameter help protect your resources by preventing public access from being granted through the resource policies that are directly attached to your secrets. In addition to using these features, carefully inspect the following policies to confirm that they do not grant public access:
Identity-based policies attached to associated Amazon Web Services principals (for example, IAM roles)
Resource-based policies attached to associated Amazon Web Services resources (for example, Key Management Service (KMS) keys)
To review permissions to your secrets, see Determine who has permissions to your secrets.
public String toString()
toString
in class Object
Object.toString()
public PutResourcePolicyRequest clone()
AmazonWebServiceRequest
clone
in class AmazonWebServiceRequest
Object.clone()