Extract Mircrosoft Active Directory GPO report via PowerShell

Extract Mircrosoft Active Directory GPO report via PowerShell

Greetings! Domain policy management is one of critical task. We divide polices into multiple GPO depending upon our requirement. PowerShell is one of the powerful tool we have now. In this article we will see how we can create reports for our GPO using PowerShell. First step you need GroupPolicy available on your machine. It is part of Group Policy Management tools which is available as feature on our Windows Server. Once you have installed this feature you have all cmdlets available which are required to manage GPO using PowerShell. You can check…Read more …
Get AWS IAM custom policies and action assigned to it using AWS lambda

Get AWS IAM custom policies and action assigned to it using AWS lambda

Greetings! When it comes to public cloud, access control is very important part in it. It is recommended to use roles for services then using crentials when using AWS lambda. Custom plocies are then very important and there mangement ver critical. You should be in control of what roles has what kind of access. This sctipt lists all your custom policies and actions assigned to it. You can find script here. Please note you will not get inline policies with this. Happy Coding!Read more …
Get all snapshots in your AWS environment using AWS lambda

Get all snapshots in your AWS environment using AWS lambda

Greetings! Managing snapshots is very critical and complex topic in any environment. You should keep a track of snapshots with their creation date. You should be aware when one snapshot should be deleted, as it would be consuming space. In this lambda script you can get consolidated report for all snapshots in your environment. I have excluded the snapshots which are copied from same or different zone. Those snapshots have volume id as vol-ffffffff. I think those should be managed separately but if you want to track those also you can simply remove…Read more …
Search for particular tag name for all instances using AWS lambda

Search for particular tag name for all instances using AWS lambda

Greetings! Tags are very helpful feature in AWS. You can store information related to your business or resource configuration using tags. It helps us to query for resources based on particular condition. This lambda function queries for name tag for all instances in particular region in a particular account and returns its value. You can find script here. Happy coding!  Read more …
Get public IP addresses of all EC2 instances in single AWS account

Get public IP addresses of all EC2 instances in single AWS account

Greetings! When you are working in big organization and server count is very high it is very tedious to manage networks. Public IP address management is very critical, you should be aware what machines are exposed to Internet. This python lambda scripts gets list of all public IP addresses availble in your account. You can find script here. Happy Coding!Read more …
Filter data in AWS DynamoDB using AWS Lambda

Filter data in AWS DynamoDB using AWS Lambda

Greetings! Working with data in dynamodb is different from SQL databases. We are use to use select queries to search data. In dynamodb it is different. I am using dynamodb scan function to search for particular values in my database. Here I am displaying values of ColumnA by filtering particular value from ColumnB. You can find the code here. Happy Coding!Read more …
Get all EC2 instances from all regions and store it in dynamodb

Get all EC2 instances from all regions and store it in dynamodb

Greetings! In AWS we have multiple regions, if you want to check resources or services of particular region you need to switch to that region first. This script will fetch EC2 instance name, ID and type from all regions. The script has two parts which I have divided into two functions. One functions collects all the information and second adds that to dynamodb. you can skip second part and save it in csv in S3 bucket. You can find script here. Happy Coding!Read more …
AWS Connect and Lambda integration to get caller ID

AWS Connect and Lambda integration to get caller ID

Greetings! IT Service Desk is backbone for support for any company to function. It’s the face of IT operations. what if you can take few tasks service desk performs and automate them. I am going dig into this. Last year Amazon announced service called connect, with this you can be up and running within minutes. In this article we will connect AWS Connect with lambda. We will capture the called ID of user and if user exists in database we will greet user. To start with, we will first create IAM role and…Read more …
Get all AWS IAM user information

Get all AWS IAM user information

Greetings! Access rights is very critical for any project. You need to be certain who should have access to which resources and then manage that. You should regularly audit users and access rights they have. In this article I tried to get all AWS IAM users, policies they have attached, is multi factor authentication enabled and groups they are member of. For code I have used python and boto3 to fetch data from AWS. I have used lambda function to execute this code. Script will fetch the data and export it to file…Read more …
Use AWS Lex chatbot to start and stop the AWS instance

Use AWS Lex chatbot to start and stop the AWS instance

Greetings!! Technology is changing very rapidly now.  You can design, develop and make your application up and available within minutes(depends how quick you are at designing and coding). I came across LEX recently. It is very easy to create your chatbot within minutes. You can teach your chatbot and then integrate with other services to deliver the desired result. I have created a chatbot which helps you to start and stop AWS instance just by using chat. I have integrated this with Facebook chat, slack and twilio also. It is very easy. Let's…Read more …