Saturday, 3 August 2019

Concepts of AWS part-1

Nowadays we have so many cloud services hosted on the internet by various providers like Apple iCloud, Google Cloud Platform, Microsoft Azure, Amazon Web Services , IBM Cloud, Salesforce and many others.
Everybody has there own perception of how things are uploaded/downloaded/accessed from a cloud. But people are not keen to learn about how things actually work in this process.
Because of the versatility and vastness of Amazon Web Services I have chosen this to understand and clear my concept of cloud architecture.

Lets start with understanding what is AWS and its services first. In the end we would be able to create a cloud architecture ourself by connecting all the dots together.

What is AWS?

AWS stands for Amazon Web Services.

Amazon's Cloud services provide great flexibility in provisioning, duplicating and scaling resources to balance the requirements of users, hosted applications and solutions.
Cloud services are built, operated and managed by a cloud service provider, which works to ensure end-to-end availability, reliability and security of the cloud.

AWS ensures the three aspects of security, i.e., Confidentiality, integrity, and availability of user's data.

There are three basic types of cloud services:

  • Software as a service (SaaS)
  • Infrastructure as a service (IaaS)
  • Platform as a service (PaaS)

In addition to these services above, AWS also offers Function as a Service (FaaS), which is the concept on which Serverless computing is build.
These services are the building blocks that can be used to create and deploy any type of application in the cloud.
Currently there are around 165 services that are being offered by AWS.
If you want to know more about the services offered by AWS. Please feel free to follow this link.

History of AWS

  • In 2003, Chris Pinkham and Benjamin Black presented a paper on how Amazon's own internal infrastructure should look like. They suggested to sell it as a service and prepared a business case on it. They prepared a six-page document and had a look over it to proceed with it or not. They decided to proceed with the documentation.
  • In 2004, the first web service SQS which stands for "Simple Queue Service" was officially launched. 
  • In 2006, AWS (Amazon Web Services) was officially re-launched, combining the three initial service offerings of Amazon S3 cloud storage, SQS and EC2.
  • In 2007, over 180,000 developers had signed up for the AWS.
  • In 2014, AWS claimed its aim was to achieve 100% renewable energy usage in the future.
  • In 2015, AWS breaks its revenue and reaches to $6 Billion USD per annum. The revenue was growing 90% every year.
  • By 2016, revenue doubled and reached $13 Billion USD per annum.
  • In 2018, AWS launched a Machine Learning Speciality Certs. It heavily focused on automating Artificial Intelligence and Machine learning.

Advantages of AWS

  1. High Availability and durability (99.9999999%)
  2. High Scalability/Elasticity (expand/shrink on demand)
  3. Fault tolerance (Reliable/Resilient)
  4. Based on the concept of Pay-As-You-Go - Pay for the resources when you need them.
  5. Cost-effectiveness - No long term commitments/huge investments in physical infrastructure.
  6. Loosely coupled architecture - Best fit for adopting microservice architecture.

How to SignUp to the AWS platform

  • First visit this website https://aws.amazon.com/, then click on the Complete Sign Up to create an account and fill the required details.
  • Now, fill your contact information.
  • After providing the contact information, fill your payment information.(Don't worry nothing will be deducted from your account)
  • After providing your payment information, confirm your identity by entering your phone number and security check code, and then click on the "Contact me" button.
  • AWS will contact you to verify whether the provided contact number is correct or not via a phone call.
  • The final step is the confirmation step. Click on the link to log in again; it redirects you to the "Management Console".
AWS provides 4 plans, you can choose as per your usage/features: 
  • Basic - Free
  • Developer - Starting at $29 per month
  • Business - Starting at $100 per month
  • Enterprise - Starting at $15,000 per month

Wondering how much percentage of internet is comprised of AWS??

AWS hosts about 5% of all websites and accounts for about 40% of all Internet traffic.
You can check by blocking all the traffic coming from IP address ranges of AWS hosted servers, which is shared by AWS here
There is a simple script called AWS Blocker created by a developer which retrieve the official list of AWS IPv4 and IPv6 ranges, then block them all using iptables.
After running the above script on your linux machine, you won’t be able to listen to Spotify, book a flight on Expedia, or look at rooms on Airbnb & moreover not able to watch your favorite seasons on Netflix :'(
This is what the internet would look if Amazon Web Services suddenly ceased to exist.


In the next blog, we will deeply discuss about the components that make AWS such an amazing cloud platform in the coming future. Components of AWS part-2


Thursday, 15 December 2016

Riders paradise - 5 B's of Bikerism

Becoming a rider is not an easy task, you have to be an engineer, a manager, a mechanic, a cook, a guide and many others qualities.
Its not just by riding a bike and having a destination in your mind will make you a rider. Somethings only comes with passion. So you don't require any degree just require that passion with few qualities and respect for other riders.

The basic requirements for becoming a rider are 5 B's, else you will be called a traveler.


5 B's of Bikerism and their significance


Bullet - All other bikes will serve the purpose of taking you from your start point to destination but if you are riding a Royal Enfield then whole route will become more travel worthy. That sturdy look of the bike itself will say that anything comes into my way I am gonna get through it. That thudding sound will make you feel like a roaring beast on the highway. When a rider controls the massiveness of a bullet while making turns, that feeling is something out of this world.

Beard - It's easier to grow but difficult to maintain. A normal man can grow a beard ranging from an inch to 2-3 feets depending upon his genes and surely on his strengthened thoughts. The beard lover likes the things raw, they don't like artificial make-ups. In ancient times, Beard was a symbol of royalness, strength and position in society.
It projects one's traits like Patience, Perseverance and exudes his wisdom.
Beard will not only completes a rider look but it will also protects him from cold chilly winds.
Trust me while riding in colder areas the snowflakes that are stuck in your beard will look like a diamond studded in some finest jewelry.

Boots - Boots can be of many types and brands, but a rider will always choose a pair of boots that are old school and rugged in looks at the same time can sustain the roughness of the route. You'll feel heavy initially but later when you'll ride, they will go best with the biker attire.
Boots make people look at you from bottom to top, instead of looking from top to bottom. Choose very wisely as this is an essential part of your biker attire.

Biker Jacket - Like in the war between 2 countries how soldiers distinguish the soldiers from other country, just by looking at their uniform.
Similarly for rider to be in a perfect attire, he needs to wear a jacket that must be different from his regular jackets, to distinguish him from the crowd.
It will not only provide you safety with the padded armour but will also gives a rider a sense of mission accomplishment. That pride ahhaa!!!

Biker Tattoo - Tattoo is an art, who doesn't loves art can not be a nature lover. It's a symbol of commitment to anything, whether it can be your loved ones, role model or your passion.
Don't rush in choosing one, even the tattoo artist matters a lot.
Good luck in finding that perfect tattoo design that you can wear for the rest of your life!


Information regarding my Leh-Ladakh expedition and route yet to be shared in next blog, stay tuned RIDERS!!

Monday, 29 August 2016

Configuring Raspberry Pi as NAS,VNC,Samba,Apache server

The Raspberry Pi is a small, credit card sized computer that doesn’t require a lot of power to use.
It can be used for solving many purposes in day to day technical life and building many IOT (Internet Of Things) systems.

Here we are going to discuss about the configurations to be done after you have bought the RPi. It comes without any OS to boot and test the device. First we need a 16 GB Class 10 micro SD card. (Preferably Sandisk Ultra UHS-I)


Creating bootable Raspbian OS image

Download the Raspbian Jessie OS image:
https://www.raspberrypi.org/downloads/raspbian/

For Linux: DD command is use for bit-by-bit copying the image on the memory card
umount /dev/sdx (For unmounting the SD card)
dd bs=10M if=~/2015-02-16-raspbian-jessie.img of=/dev/sdx

For Windows:
Install this software - Win32DiskImager

First thing First!

After installation of Jessie Raspbian first thing should be connecting to RPi via SSH and upgrading Package & Firmware
Default Username/Password : pi / raspberry

sudo apt-get update
sudo raspi-update
sudo raspi-config -> Expand File System (requires reboot)


Configuring Static IP Address on RPi

sudo nano /etc/network/interfaces
Replace iface eth0 inet dhcp with static
auto eth0
iface eth0 inet static
address 192.168.0.2
netmask 255.255.255.0
network 192.168.0.0
gateway 192.168.0.1

(Reboot again)  This will assign the RPi 192.168.0.2 IP everytime it boots.

Automatically connecting to a WiFi network

sudo nano /etc/network/interfaces
on wlan0
# allow-hotplug wlan0
         iface wlan0 inet manual
         wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
         iface default inet dhcp

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf

Add this in the end of file
network={
ssid="WiFi_name"
proto=RSN
key_mgmt=WPA-PSK
pairwise=CCMP TKIP
group=CCMP TKIP
psk="wifi_password"
}

(Reboot again)  This is very useful configuration when you don't have access to UI and you have to connect the RPi to a Wireless network everytime it boots. No need to connect it through LAN.



Now the networking part is over, we are ready to install the services on RPI now.

Services you can run on your RPi

Wireless printer using Rpi
Samba share drive on Rpi
VNC server on Rpi
Apache server with PHP & mysql
NAS server
Running boot scripts & commands at startup (Editing /etc/rc.local)

Installing Samba server

sudo apt-get install samba samba-common-bin
sudo vi /etc/samba/smb.conf
Paste in the end of Share Definitions :-

[pihome]
   comment= Pi Home
   path=/home/pi
   browseable=Yes
   writeable=Yes
   only guest=no
   create mask=0777
   directory mask=0777
   public=no

sudo smbpasswd -a pi (Adding a pi share user)
service samba restart

Installing VNC server (Remote Desktop)

sudo apt-get install xrdp

On Windows Run > mstsc (for Remote Desktop connection)

This service is very useful when you don't have a external keyboard/mouse to operate the UI of Raspbian OS, so we utilize laptop's keyboard via RDP connection.

Installing Apache MySql Server

sudo apt-get install apache2
sudo apt-get install mysql-server

verify the verison when installation is done
mysql –version
mysql -u root –p
mysql> show databases;

Install PHP & MySql driver for PHP

sudo apt-get install php5 php5-mysql
Testing PHP : 
sudo nano /var/www/hello.php

Converting Raspberry Pi into a NAS device


Add support to Raspbian for NTFS-formatted disks. To do so type the following command:
sudo apt-get install ntfs-3g (This is present on OS but still to upgrade the package)

Look for the unmounted partitions of the attached external hard drives.
sudo fdisk –l
umount /dev/sda1 (Suppose you external hard disk is sda1)
sudo mkdir /media/USBHDD

sudo mount -t auto /dev/sda1 /media/USBHDD

sudo nano /etc/samba/smb.conf


[NAS HDD]
comment = NAS Drive
path = /media/USBHDD
valid users = @users
force group = users
create mask = 0660
directory mask = 0771
read only = no

Creating a Pi share user

sudo useradd nas -m -G users (Adding a user “nas”)
sudo passwd nas

sudo smbpasswd -a nas (Adding “nas” user to smb)

When Rpi restarts it will automatically mount the external hard drives:

sudo nano /etc/fstab

/dev/sda1 /media/USBHDD auto noatime 0 0

Saturday, 19 September 2015

How to extend the range of WiFi adapter

Hi friends, I feel enormously happy to explain this hack to all of you. Do you know how much is the range of a normal WiFi adapter (Internal / External), it's just a few meters 10-15 mts or for some dongles it may varies between 15-20 mts if nothing comes in between the router and the wireless adapter.

So I have decided to write this blog so that everyone should know how they can increase their WiFi adapter range but unfortunately this hack can't increase the internal WiFi adapter range, this is only for External WiFi adapter. For this hacks you require certain things like:

  • Parabolic Dish (Unused Reliance Dish Antennae)
  • External USB WiFi Adapter (TP Link TL-WN721N)
  • USB extension cable Male to Female (1 to 5 mts)

The basic principle behind this hack is the principle of convergence of waves over a focal point of parabolic dish. You can learn about this in detail from the wiki link. (https://en.wikipedia.org/wiki/Parabolic_reflector)

To calculate the focal point of  the parabolic dish there is a formula, which gives a relationship between the diameter D, the depth d and the focal distance f of the dish.

f = D^2 / 16d

The above formula helps in positioning the feed of the parabolic antennas as it gives the focal distance f.


The focus of this hack is to find the focus of the parabola dish that you have and install your WiFi adapter on that spot. Please see these images how I made it.







You can install it on a camera tripod if u have one or adjust it between AC and the upper wall like me :P



So basically it's an uni directional or Line of Sight Communication system. And you can capture or hack wifi that are very far away from your range just by pointing the setup on the victim site. I can't disclose how many networks I own now :D

Proof Of Concept Screenshots:

Capturing packets through Airodump with WiFi dongle only


Capturing packets through Airodump with WiFi dongle installed in dish antenna, able to find so many distant Wireless signals



If you like my setup please do share it or comment over here.
Happy Hunting !!

Monday, 13 July 2015

Find saved wifi password on Android device

Hi Friends.. I am back with a new hack on Android devices. Few of my friends were asking how to find saved wifi password on Android device. So I decided to tell all of you via my blog. This trick will work on any android device with any version.

Whenever we connect to a wireless network and punch in the password. After successful connection we cant find the field where we have typed in the password because it has been stored on a configuration file. But the best part is that it get saved in a non-encrypted plaintext format.

Prerequisite to extract password : You got to have a rooted android device, as we have to search for a file in Root file system. And a good file explorer like ES Explorer.

Open the file explorer and grant the file explorer root privileges. Navigate back to the root directory "/".
Navigate to --> data > misc > wifi.

Open the file wpa_supplicant.conf in any text editor. And voila you can see all of the passwords of your previously connected networks.

network={
ssid="example wpa-psk network"
key_mgmt=WPA-PSK
proto=WPA
pairwise=TKIP
group=TKIP
psk="secret passphrase"
}

Or you can also download an app from the link below if you don't want to search manually for it. For running this app you must have root privileges.
http://www.mediafire.com/download/8lm66g3w1dbt3cw/wifi.passwords.apk

Do leave comments and likes for this post if it worked!!

Sunday, 10 August 2014

How to get serial number of laptop from Command Prompt

Hi friends, recently one of my friend was asking about how to know the serial number of his laptop as his sticker pasted on the back of laptop has been ruined and was not visible from there.

So there is a remedy for that a small command you can run over your command prompt to know the serial number whether its a Dell, Compaq ,Hp or Acer laptop. (Brand doesn't matter only platform matters that it should be Windows)

In the Run windows (Windows + R) type "cmd" and press enter to open the command prompt window.
On cmd window write the following command :
>wmic bios get serialnumber (Press enter)

Voila you will get the serial number of your laptop.
Its a simple way to know your laptop's serial number instead of turning it around while you are working.

WMIC stands for Windows Management Instrumentation Command-line.


Tuesday, 8 April 2014

Distance Finder and Temperature meter using Arduino microcontroller

Hello friends!! Its been a long long time since I visited my blog now I have decided to write a post on Arduino technology.
So my techie friends who wish to work with electronic components here's a golden chance to understand and start your field of interest from here only.
To learn more about Arduino, please go through Wikipedia's link. http://en.wikipedia.org/wiki/Arduino

Click on the image to get a bigger view of what I have made.




Things you would be requiring before starting off the project:

1. Firstly installing the Arduino IDE for compiling and uploading the code on Arduino chip. Here is the link: http://arduino.cc/en/main/software

2. Arduino UNO R3 - Rs.1395 (http://fabtolab.com/UNO-R3?search=arduino%20uno)

3. 16x2 Character LCD Module - Rs.230 (http://fabtolab.com/16x2-LCD-Module-Green)

4. TMP 36 IC - Rs.85 (http://fabtolab.com/sensors/temperature-sensors/TMP36GT9Z-temperature-sensor)

5. HC-SR04 - Rs.135 (http://fabtolab.com/sensors/distance-proximity-sensors/HC-SR04-ultrasonic)

6. Buzzer - Rs.14 (http://fabtolab.com/5V-piezo-buzzer)

7. Male Headers(used for soldering on LCD) - Rs.6 (http://fabtolab.com/components/miscellaneous-components/male-headers)

8. Breadboard - Rs.125 (http://fabtolab.com/breadboard-850-pts)

9. Rest you require are few male to male cables to connect the components.- Rs.100 (Various sizes available on FabtoLab.com)

Plus Shipping - Rs.55

This project has costed me around 2100 bucks. But seriously spending this much amount on it is worthy.

Interfacing diagram of HC_SR04 which is the ultrasonic sensor used to find distance by sending and receiving ultrasonic waves and calculating their time. This is a high precision device with the precision of 0.3 cm and its range is: 2cm – 450 cm
Personally I have tested this device till 350 cms. If anybody has tested with more range ,please drop me a mail.



Interfacing diagram of LCD with Arduino. It can display 16 characters per line and there are 2 such lines.


Below is the LCD pinout for deep understanding the interfacing.


Interfacing diagram of TMP36 module

1st pin : 5V
2nd pin : A0 on arduino
3rd pin : GND on arduino

Interfacing diagram of Buzzer: It is optional for producing beep sound if distance becomes less than 20 cms.

+ve of buzzer - 9 Digital pin which is PWM pin
-ve of buzzer - GND of arduino

NOTE: This device can only work as temperature monitor or distance finder at once.
Here is the arduino code available for download.

Temperature Monitor: http://www.mediafire.com/view/1uo3x9gr7ge7huz/LCD_Thermometer.ino

Distance Finder: http://www.mediafire.com/view/93wmy47pkr5pkbc/LCD_distance_finder.ino

Likes and Shares are always appreciated. Keep reading for more Arduino projects.

Thursday, 5 September 2013

Unlimited Energy hack for Candy Crush Saga for Free

Prerequisite:
An Android phone with Candy crush game installed.
ROOT is required

1. Download GMD speed lite from this link
Download
2. Install it and run it, you will get a UI like the image below.

3. Select your multiplier and click on start. (10X is max in Lite version but u can increase it to infinity if u can spend Rs.150 by buying Full version app)
Download Full Version
4. Keep this application running in background while you are playing Candy crush.
Each life is revived in 30 mins after this it will be revived in 3 minutes, meanwhile we can play a game in that 3 minutes means we can have inexhaustible stack of energy.
5. This hack increases time speed in time based games. It does so by increasing device clock speed.

Note: It will also increase the speed of ur android phone clock so don't worry ,it will get back to normal if u stop this application.

Monday, 2 September 2013

Steganography tool in JAVA: Hide your message in image files

History behind Steganography


It is the art and science of writing hidden messages in such a way that no one, apart from the sender and intended recipient, suspects the existence of the message, a form of security through obscurity. It was first used in 440 BC.

The motive behind this project was to merge a text file to an image file, so that the message can be sent in a hidden way. Although this will increase the size of the image file but it will not decrease its quality or distort it in any manner.

Steganography achieves its goal if the message text is inserted in such a way that the file size does not increase, when the message occupies the empty spaces in between the image file.

Prerequisites to run this file:

1. Java 1.6 or higher must be installed on machine.
2. System variable "Path" should be set to the path of Java bin directory. (C:\Program Files\Java\jdk1.7.0_02\bin)

Steps to hide message:

1. Download file from the link below and run the steganography_tool.jar file.
    Open Command prompt and type "java -jar steganography_tool.jar" to run it.
2. Click on "Image file" button and browse it to Open any image (jpg,bmp,png)
3. Click on "Text file" button and browse it to Open any txt file whcih has some text you want to hide in the specified image.
4. Click on "Hide it!!" button to hide the text in the selected image
5. A new file is generated in the same folder of image with prefix "_new" appended to the image filename.
6. Now open the new generated file with notepad and scroll it till the end to see the hidden text.




Eager to know the code of this tool, get it from my git repo.


git clone https://github.com/saurabh221089/steganography_tool.git


Tuesday, 6 August 2013

Making your own Deface page using Javascript

Cy4n0g3n H4ck3r