1 Answers
1
Accepted Answer
It is not a must to use Node.js as backend to store credentials. When setting credentials in a browser, make sure not to hard code credentials (e.g., access/secret keys for IAM users). Also, always grant the least privilege required for your task.
We do not recommend hard coding your AWS credentials in your scripts. Hard coding credentials poses a risk of exposing your access key ID and secret access key.
The recommended way to obtain AWS credentials for your browser scripts is to use the Amazon Cognito Identity credentials object, AWS.CognitoIdentityCredentials. Amazon Cognito enables authentication of users through third-party identity providers.
answered 22 days ago
Relevant questions
How to use AWS Tranlsation if I only have plain text, not CSV, not Memory files?
asked 3 months agoJavascript as a Game client for a Gamelift Server
asked 3 years agoIs it really supported to use alerting on "AWS Elasticsearch"?
asked 3 years agoIs it safe to share Signed Url of s3 content specifically for images which has AWSAccessKeyId and signature on it ?
asked 5 months agoAmazon Workspaces (Windows) : Is it possibile to use Google G Suite IdP for SSO ?
Accepted Answerasked 3 years agoNodeJs server SDK
asked 5 years agoUsing AWS Textract with Javascript SDK in a browser
asked 10 days agoIs it possible to use AWS RDS SQL Server as an AAG target from on premise primary?
asked 10 months agoIs it safe to use plain Javascript for aws-sdk?
Accepted Answerasked 23 days agoMy Website is Down and I Don't Know How to Get it Back Up
asked 7 months ago
Like I saw documentation of AWS Webpack can we use that and store all the credentials in .env file is it safe or not?, and with webpack we build bundle.js that way is secure?
You can store credentials that way and the instruction is provided here. But it's for Node.js. For front end code, again don't hard code credentials. Also, I am assuming you would use IAM user credentials there. Make sure to rotate credentials on a regular basis and secure access to the application server. If you are running that on an EC2 instance, you can simply attach an instance profile so there is no need to use long term (IAM user) credentials. It auto rotates credentials for an IAM role (short-term credentials).