AWS Identity and Access Management
CLI Reference (API Version 2010-05-08)
« PreviousNext »
View the PDF for this guide.Go to the AWS Discussion Forum for this product.Did this page help you?  Yes | No |  Tell us about it...

iam-servercertupload

Description

Uploads a server certificate entity for the AWS account. The server certificate entity includes a public key certificate, a private key, and an optional certificate chain, which should all be PEM-encoded.

For information about the number of server certificates you can upload, see Appendix A: Limitations on IAM Entities.

Syntax

iam-servercertupload -b CERTBODYFILE -k PRIVATEKEYFILE -s SERVERCERTNAME [-p PATH] [-c CERTCHAINFILE] [-v]

Options

Name Description Required

-b CERTBODYFILE

The contents of the public key certificate in PEM-encoded format.

Type: String

Default: None

Yes

-k PRIVATEKEYFILE

The contents of the private key in PEM-encoded format.

Type: String

Default: None

Yes

-s SERVERCERTNAME

A name that you assign to the server certificate. For information about limitations on server certificate names, see Limitations on IAM Entities.

Type: String

Default: None

Yes

-p PATH

The path for the server certificate. For more information about paths, go to Identifiers for IAM Entities in Using AWS Identity and Access Management. This option is optional. If it is not included, the path defaults to a slash (/).

Type: String

Default: None

No

-c CERTCHAINFILE

The contents of the certificate chain. This is typically a concatenation of the chain's PEM-encoded public key certificates.

Type: String

Default: None

No

Output

If the command is successful, the output is empty. In verbose mode, IAM returns the server certificate Amazon Resource Name (ARN) and GUID.

Example

The following example uploads a server certificate and its associated private key, and names the server certificate ProductionCert in verbose mode.

PROMPT> iam-servercertupload -b C:\certs\ProductionCert.pem -k C:\keys\pri-key.pem -s ProductionCert -v
arn:aws:iam::123456789012:server-certificate/ProductionCert
ASCACexampleKEZUQ4K