Giter Site home page Giter Site logo

awsdocs / aws-secrets-manager-docs Goto Github PK

View Code? Open in Web Editor NEW
32.0 29.0 55.0 955 KB

The open source version of the AWS Secrets Manager documentation. You can submit feedback and requests for changes by submitting issues in this repo or by making proposed changes and submitting a pull request.

License: Other

aws-secrets-manager-docs's People

Contributors

agileraymond avatar akshaybiradar-ab avatar angrytoast avatar belialboy avatar bisdavid avatar blange avatar daminich24 avatar dominik-gubrynowicz avatar dulac avatar ecraw-amzn avatar ermiyaeskandary avatar hamadsuniverse avatar huanjani avatar jackcasey-visier avatar johanneshartmantr avatar joshbean avatar jpeddicord avatar jshwright avatar kevindenotariis avatar lucy-writer avatar mgalioto avatar n6rayan avatar ozaditya avatar paulerickson avatar pi-bansal avatar pluc avatar randalld-aws avatar scoates avatar sdoyle88 avatar wjordan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aws-secrets-manager-docs's Issues

Bad link to "What is ABAC in AWS ?" in Userguide

Make secret rotation lambda templates available on GitHub

It's a bit of a pain to have to create a cloudformation stack just to see the sample code for creating custom lambdas. Would someone be able to put these onto GitHub and reference the source in the serverlessrepo and the docs?

I'm referring to this doc:
https://docs.aws.amazon.com/secretsmanager/latest/userguide/rotating-secrets-create-generic-template.html

And one of the stacks in the serverless repo is linked below:

https://serverlessrepo.aws.amazon.com/applications/arn:aws:serverlessrepo:us-east-1:297356227824:applications~SecretsManagerRotationTemplate

Thanks in advance. Happy to raise a PR to contribute to the docs, but it's not my code to publish...

Help Wanted - Troubleshooting Tips, Tricks, and Strategies

As you know, troubleshooting an asynchronous process like a rotation Lambda with its many moving parts can be a challenge. What issues have you run into getting your rotation Lambdas to work? Can you share your solutions with your colleagues? Please share only problems for which you've found a solution. If you're still struggling with a problem please contact Customer Support or post your issue on the Forums.

Share the following information with me as a response to this issue, and I'll consider adding it to the troubleshooting section of the AWS Secrets Manager documentation.

  1. What were the symptoms of the problem?
  2. Were the exception/error messages helpful or less than helpful? Did they help lead you to the solution, confuse you, or were they just white noise that didn't help or hurt? What specific message(s) did you get and how did they help or not help?
  3. What did you do to troubleshoot? What did you try that didn't help? What finally did lead you to the correct root cause?
  4. What did you finally do to correct the problem?

I'll use this information to improve the documentation - specifically the troubleshooting sections and descriptions of the exception messages. I'll also pass it relevant details on to the engineering team to possibly improve the error messages or the product itself. The more detail you can add, the better I can use it to improve things! Thank you very much, especially on behalf of all of your colleagues who run into the same problems!

Dave Bishop
Senior Technical Writer
AWS Secrets Manager
https://docs.aws.amazon.com/secretsmanager/latest/userguide/

AWS secret retrieval issue nodeJs

Hello everyone,
I am using the below nodejs code to retrieve the secret. but i am not getting the response. i am not sure if i have to use await here if yes then how and where. Also if i am making some other mistake in this code then please guide me. i have also attached trackers using console.log to see where the compiler is going. I am also attaching the output. Please provide me your guidance. I am new with both nodejs and AWS.
Thank you.
code:

exports.handler = async(event)=>{
// Use this code snippet in your app.
// If you need more information about configurations or implementing the sample code, visit the AWS docs:
// https://aws.amazon.com/developers/getting-started/nodejs/

// Load the AWS SDK
var AWS = require('aws-sdk'),
region = "us-east-1",
secretName = "MySecret",
secret,
decodedBinarySecret;
console.log(region);
// Create a Secrets Manager client
var client = new AWS.SecretsManager({
region: region
});

// In this sample we only handle the specific exceptions for the 'GetSecretValue' API.
// See https://docs.aws.amazon.com/secretsmanager/latest/apireference/API_GetSecretValue.html
// We rethrow the exception by default.

console.log("start");
client.getSecretValue({SecretId: secretName}, function(err, data) {
console.log("1");
if (err) {
if (err.code === 'DecryptionFailureException')
// Secrets Manager can't decrypt the protected secret text using the provided KMS key.
// Deal with the exception here, and/or rethrow at your discretion.
throw err;
else if (err.code === 'InternalServiceErrorException')
// An error occurred on the server side.
// Deal with the exception here, and/or rethrow at your discretion.
throw err;
else if (err.code === 'InvalidParameterException')
// You provided an invalid value for a parameter.
// Deal with the exception here, and/or rethrow at your discretion.
throw err;
else if (err.code === 'InvalidRequestException')
// You provided a parameter value that is not valid for the current state of the resource.
// Deal with the exception here, and/or rethrow at your discretion.
throw err;
else if (err.code === 'ResourceNotFoundException')
// We can't find the resource that you asked for.
// Deal with the exception here, and/or rethrow at your discretion.
throw err;
}
else {
// Decrypts secret using the associated KMS CMK.
// Depending on whether the secret is a string or binary, one of these fields will be populated.
console.log("secret found");
if ('SecretString' in data) {
secret = data.SecretString;
console.log("storing secret");

    } else {
        console.log(4);
        let buff = new Buffer(data.SecretBinary, 'base64');
        decodedBinarySecret = buff.toString('ascii');
    }
}


// Your code goes here.

});
console.log("end");
const response ={
body: JSON.stringify(secret),
};
return response;
};

Output:
image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.