Showing posts with label 5. Show all posts
Showing posts with label 5. Show all posts

Friday, 6 May 2016

5 Best Ways To Get Paid To Write Online 2016

If you are good at writing or if you can express your ideas well then you can definitely get paid to write online. It is not necessary that you should be professional writer or experienced columnist. Even you do not require writing lengthy and extensive story writing when you are writing for online websites. You can make money writing articles, blogs, product reviews etc.get-paid-writing-online
Now let us see in detail how to get paid to write online:
On World Wide Web, there are several websites who want to hire you as a writer depending on their business needs. The most popular 5 methods that you can get paid to write online are as follows:

1) Make money writing articles online

Lot of websites requires news articles to enrich the content of their website to attract more and more users to get updated with the industry specific updates. Such websites owners prefer to hire freelance writers instead of full time writers who are paid on number of articles contributed by the freelance writers. This way you can make money writing part time or full time for either single or multiple websites.

2) Make money writing advertisement

Affiliate program is another important ways to get paid for writing advertisement for product that you have affiliated. You need to advertise on free advertising directory that reside on web. You can even use pay per click advertising network like Google AdWord. This will increase traffic to your affiliated product website and help to increase purchase and thus make you earn commission for advertising.

3) Make money blogging

Blogging is again different style of writing where you can post your ideas on daily basis. Blogging helps you to make money in lot of ways. You can sign up account with Google AdSense and be the part of advertising network and make money every time sightseer read your blog or click the advertisement. You can even use free blog platform like Blogger.com or create your own blog website with WordPress.

4) Make money writing articles to promote website

As said before, lot of website owners would like to promote their website with rich articles and contents for which they prefer to hire freelance writers. They publish the need of freelance writers on various free job directories. You can register with such free job directory and write on lot of writing projects. Each time you write an article you will get paid for it.

5) Make money writing reviews

Get paid to write reviews are again good way to make money. You can earn up to $300 per review if your website is having high traffic. You need to create your own blog platform where you can write product reviews.

Monday, 25 April 2016

Wireless Hacking Basics WPA Dictionary Attack, Handshake, Data Capture, Part 5 - Backtrack

Getting a Handshake and a Data Capture, WPA Dictionary Attack

Introduction To Kali and WiFi Pen Testing
How to Install Kali Linux
WEP Hacking
Kali Linux and Reaver
Getting a Handshake and a Data Capture, WPA Dictionary Attack
Using Aircrack and a Dictionary to Crack a WPA Data Capture
Cracking a WPA Capture with the GPU using HashCat
Creating a Dictionary / Wordlist with Crunch Part 8

WPA Dictionary Attack
WPA and WPA 2 is the newest encryption for wireless devices, as far as cracking them, they are the same so I will use WPA from here on.

A dictionary attack is one of the easiest to understand, but the least likely to find a password. This is often the last resort because while it does work it depends on the dictionary used and the computing power.

Basically a data capture of the router is captured wirelessly when someone logs into the router. Then a dictionary file with a bunch of names and combination of names/numbers is used to throw at the data capture until the password is found.

If someone knows the person then they may be able to guess the password but otherwise this can take a long time and never find anything. If you are stuck using this method, thinking about how the password might be structured will be crucial along with computing power. The data capture could be copied between multiple computers to split the things up. A to F on one G to Z on another. Cloud computing might be a option to harness someone else computing power and so on.

There are other ways such as Rainbow Tables, or the video card attack but the simplest or easiest way to understand a WPA dictionary attack is to use aircrack-ng. The way this works basically is that there is a large dictionary that you use to throw as many combinations of words as possible at the WPA encryption until it cracks. If the password is easy then it will find it quick, if it is a long paraphrase with many different number letter combinations then it will be much harder.

If you are unable to crack a WPA handshake capture there are online services that will do it for you for a price.

Getting a Handshake and a Data Capture

Commands used
airmon-ng
airmon-ng start wlan0
airodump-ng mon0

A data capture or handshake is a captured password when two devices talk wirelessly. The data capture will be stored in a file in a computer. It still will be encrypted and need to be cracked which is when a dictionary will be used to guess the password. This is a two step process capturing the data file being first.

Setup a test environment. 
Setup a test environment with a WPA or WPA2 encrypted router and set a password on it, and connect to it with a laptop, smartphone, or computer wirelessly.

Kali Linux should be up and running.

Open a terminal window.
Getting a Handshake and a Data Capture

Run the command “airmon-ng” to see if your USB adapter shows up, if it doesn’t, then some troubleshooting as to why it is not will have to be done. For this example I am using a Alfa AWUS036NH which uses the Ralink Rt2070/3070 chipset
Getting a Handshake and a Data Capture, WPA Dictionary Attack

Once you know the adapter is connected and operating run this command to get the adapter into monitor mode.

“airmon-ng start wlan0”
Wireless Hacking Basics WPA Dictionary Attack, Handshake, Data Capture,  Part 5

If all goes well the screen will scroll by with some information then say enabled on mon0. (Sometimes it will enable on mon1 or mon2 if it does use this.)  

Now we want to see what router or access point (AP) are out there so we run this command.
“airodump-ng mon0”
Kali linux WPA Dictionary Attack how to
Kali Linux Handshake and a Data Capture

A picture like the above should come up and show all the routers out there. Here we want to target the router we want and copy the BSSID. Use CTRL+C to stop the terminal window and copy the BSSID.

Next we want to leave the original terminal alone and open a second terminal window. Here we are going to setup the adapter to do a data capture on the router we selected. After we do this we will have to wait for a wireless device to connect to the router and it will do a data capture. To do this we do the following command.

airodump-ng -c (channel) -w (Our file name) –bssid (bssid of AP) mon0
So for me it would be.
airodump-ng -c 6 -w dlink –bssid 00:26:5A:F2:57:2B mon0
Kali linux and hacking wifi

The “-w” syntax is telling airodump-ng to write a file to the drive it can be given any name.

Then it should go into monitoring the AP for a data capture.
monitoring the AP for a data capture

At this point we could simply wait for someone to connect wirelessly to the router. It can be any device their laptop, desktop or smart phone. When they connect the password will be transmitted back and forth to the device. If we wait then we stay in passive mode and no one can detect we are there. The top right of the terminal window will display WPA Handshake in the upper right when this happens.
WPA wpa 2 Handshake

Once it says “WPA handshake” on the top right the file it is done and the file is captured and written to the drive.

There is a way to speed this up if you know someone has a wireless device connected to the router by de-authenticating them or kicking them forcing them to reconnect. This will most likely be recorded by the router so this is not a passive method. To do this open another terminal window and type the following.

“aireplay-ng -0 5 -a (Target BSSID) mon0”

For me this would be.
aireplay-ng -0 5 -a 00:26:5A:F2:57:2B mon0





Friday, 22 April 2016

5 Ways To Reverse A String In Java With Example

In this tutorial we will discuss  how to reverse a string in java . Although there are many ways to get the solution but we are sharing 5 different ways to  reverse a string. This question is frequently asked in the technical interview of java.This question is easy , but please mark this question in your to do list before attending any technical interview in java. First we will understand the question by writing example.

Input :   malayalam
Output: malayalam

Input : akbar
Output : rabka

Points to Keep in Mind Before attempting the Solution:

1. String class in java do not have reverse() method , StringBuilder class does have built in reverse() method.
2. StringBuilder class do not have toCharArray() method , while String class does have toCharArray() method.

Pseudo Code for Reverse String Method 1:

1. The user will input the string to be reversed.
2. First we will convert String to character array by using the built in java String class method toCharArray().

3. Then , we will scan the string from end  to start,  and print the character one by one.


import java.io.*;
import java.util.*;

public class reverseString {
    public static void main(String[] args) {
        String input="";
        System.out.println("Enter the input string");
        try
        {
            BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
            input = br.readLine();
            char[] try1= input.toCharArray();
            for (int i=try1.length-1;i>=0;i--)
            System.out.print(try1[i]);
        }
        catch (IOException e) {
            e.printStackTrace();
        }
}}

Pseudo Code for Reverse String Method 2:

1.  In the second method , we will use the built in reverse() method of the StringBuilder class ,.
Note :  String class does not have reverse() method . So we need to convert the input string to StringBuilder , which is achieved by using the append method of the StringBuilder.

2.  After that print out the characters of the reversed string  by scanning from the first till the last index.


import java.io.*;
import java.util.*;

public class reverseString {
 public static void main(String[] args) {
  String input="AliveisAwesome";
  StringBuilder input1 = new StringBuilder();
  input1.append(input);
  input1=input1.reverse(); 
  for (int i=0;i<input1.length();i++)
  System.out.print(input1.charAt(i));  
 }}
  



Pseudo Code for Reverse String Method 3:

1. Convert the input string into character array by using the toCharArray() built in method of the String Class .
2. In this method we will scan the character array from both sides , that is from the start index (left) as well as from last index(right) simultaneously.
3. Set the left index equal to 0 and right index equal to the length of the string -1.
4. Swap the characters of the start index scanning with the last index scanning  one by one .After that  increase the left index by 1 (left++) and decrease the right by 1 i.e (right--) to move on to the next characters in the character array .
5. Continue till left is less than or equal to the right .


import java.io.*;
import java.util.*;

public class reverseString {
 public static void main(String[] args) {
    String input = "Be in present";
    char[] temparray= input.toCharArray();
    int left,right=0;
    right=temparray.length-1;
    for (left=0; left < right ; left++ ,right--)
    {
     // Swap values of left and right 
     char temp = temparray[left];
     temparray[left] = temparray[right];
     temparray[right]=temp;
    }
    for (char c : temparray)
     System.out.print(c);
    System.out.println();
   }}
  

Pseudo Code for Reverse String Method  4:

1. Convert the input string into the character array by using toCharArray() built in method.
reverse a string in java with example
2. Then add the characters of the array into the LinkedList object . We used LinkedList because it maintains the insertion order of the input values.
3. Java also has  built  in reverse() method for the Collections class . Since Collections class reverse() method takes a  list object , to reverse the list , we will pass the LinkedList object which is a type of list of characters.
4. We will create the ListIterator object by using the listIterator() method on the LinkedList object.
ListIterator object is used to iterate over the list.
5. ListIterator object will help us to iterate over the reversed list and print it one by one to the output screen.


import java.io.*;
import java.util.*;

public class reverseString {
 public static void main(String[] args) {
     String input = "Be in present";
     char[] hello=input.toCharArray();
     List<Character> trial1= new LinkedList<>();
     for(char c: hello)
     trial1.add(c);
     Collections.reverse(trial1);
     ListIterator li = trial1.listIterator();  
     while(li.hasNext())
    {System.out.print(li.next());}  
   }}
  

Pseudo Code for Reverse String Method 5 :

1. The last method is converting string into bytes .  getBytes()  method  is used to convert the input string into bytes[].
2. Then we will create a temporary byte[]  of length equal to the length of the input string.
3. We will store the bytes(which we get by using getBytes() method) in reverse order   into the temporary byte[] .


package ctci;
import java.io.*;
import java.util.*;

public class reverseString {
 public static void main(String[] args) {
  String input = "Be in present";
  byte [] strAsByteArray = input.getBytes();
  byte [] result = new byte [strAsByteArray.length];
   
  for(int i = 0; i<strAsByteArray.length; i++){
  result[i] = strAsByteArray[strAsByteArray.length-i-1];
  }
  System.out.println( new String(result));
   }}