2

I am using the AWS CLI to update the secrets but I am having some issues updating multi-string secrets with a Private SSH Key.

{
    "Name": "multi-value-secret-string-with-ssh-key",
    "VersionId": "red321ds-d3eb-4964-9a8f-7f4ecb375a35",
    "SecretString": {"public": "some-public-key-here", "private": "need-to-insert-the-private-key-here"},
    "VersionStages": [
        "AWSCURRENT"
    ],
    "CreatedDate": 125125123124124312412432,
    "ARN": "arn:aws:secretsmanager:us-east-2:432414312412342141243124:secret:multi-key-XQuwafs"
}

The private key is stored in private.ppk and I want to put the content of that private key file to the private attribute of the secretstring, is this possible via CLI?

John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
Alex
  • 105
  • 1
  • 8
  • What CLI command are you using and what exactly is the issue? Any errors? – Marcin May 18 '21 at 03:01
  • @Marcin I am using this command `aws secretsmanager update-secret --secret-id TestKeyPairs --description "Mytest with multiples values" --secret-string file://test.json` - I store the content of the key to json file and I am not sure if this correct or will this work? https://imgur.com/0s9eJBv – Alex May 18 '21 at 03:04
  • json file https://imgur.com/a/nJRgJtt – Alex May 18 '21 at 03:05
  • Were you able to solve this problem? I found this from your other question about it and face the same issue. – dmitrybelyakov Sep 07 '21 at 10:09

0 Answers0