SAGARFIVE

AWS Programmatic Access – Login using AWS CLI 

Access keys are used to make programmatic calls to AWS from the AWS CLI, Tools for PowerShell, AWS SDKs, or direct AWS API calls. You can have a maximum of two access keys (active or inactive) at a time.

In Simplified way :  

We can Access the AWS Services using CLI(Command Line Interface) in Different platforms with these AWS Programmatic Access, it gives Access ID , Secrete Key. 

By Installing AWS CLI in different platforms with Logging in , we can use AWS Services using CLI in that Machine.


Enabling Programmatic Access : 
(GUI MID – 2022 varies with respect to time)


(i) Open IAM Dashboard, click on Create user

(ii) Give username, Tick Provide Management console, Add Password, Untick reset password on login, click on Next

(iii) Add Permissions based on your need

(iv) Verify and click on Create user

(v) Save or Remember your logins, and click on Return to users list

(v) Click on user

(vi) Go to Security Credentials, Go to Access key and click on Create access key

(vii) Select CLI, Tick the confirmation

(vii) Add tags, click on create access key, then after you can see the completion page, download or save the cli keys

(viii) When you again check the access key section, you  can see one access key is added

(xi) You can only one get the secret key, so copy or download and save at secure place



Logging in using Access key : 
(AWS Interface(GUI) on MID – 2022, it varies with respect to time)


You can login AWS from the AWS CLI, Tools for PowerShell, AWS SDKs, or direct AWS API calls. You can have a maximum of two access keys (active or inactive) at a time.

+ Logging in Windows :

1. Download AWS CLI and Install it : you can find the software and documentation here

https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html

2. Installation done ! using MSI Package Installer

3. Open Terminal/CMD (Search For Terminal/CMD in window 11), check version

commandaws configure

4. Run commands :

Commandaws configure

Enter Your details :

AWS Access Key IDYour Access KeyEx: AKIATVHXUFY2M5LI4ODP
AWS Secret Access KeyYour Secret Access KeyEx: s97vKqBqG//VSXsZrCl+lfEpNZcCxcHT4SwrwhI0
Default region nameHere you will get Link Ex: ap-south-1
Default output formatCLI Output data formatEx: json

 Command Prompt Visual :

5. Lets access aws service:
Task : Retrieving the VPC List in the Region

Commandaws ec2 describe-vpcs

 Command Prompt Visual :

6. Delete Access Keys , if you don’t need that anymore.

Deleting Access key : (AWS Interface(GUI) on MID – 2022, it varies with respect to time)


(i)  Go to IAM > Users > Select user > Security Credentials tab > access keys > Choose Access key > Action > Delete

(ii) Deactivate the access key , and copy paste the Access key then after click on Delete

(iii) Now you can see Access Key is deleted

Share

Facebook
LinkedIn
WhatsApp
Pinterest
Telegram
Email

Share