Helping you here

Share This Post

How to Compile /C++ Programs




How to compile C programs

In a large number of my past posts, I have utilized C as the programming dialect for composing the projects. In case you're new to C programming and think that its hard to incorporate the C/C++ source codes then this post is for you. 

Here is a well ordered method to introduce Borland C++ compiler 5.5 on your PC and gather the C/C++ programs.

How to Install Borland C++ compiler?

Follow the below steps to install Borland C++ compiler 5.5 on your PC:
  1. Download Borland C++ compiler 5.5 (for Windows platform) from the following link:
  2. After you download, run the file C++5.51.exe. The default installation path would be:
    C:\Borland\BCC55

How to configure Borland C++ compiler?

Here is a step-by-step instruction on how to configure the compiler:
  1. After you install Borland C++ compier, create two new Text Documents.
  2. Open the first New Text Document.txt file and add the following two lines into it:
    -I”c:\Borland\Bcc55\include”
    -L”c:\Borland\Bcc55\lib”
    Save changes and close the file. Now rename the file from New Text Document.txt to bcc32.cfg.
  3. Open the second New Text Document (2).txt file and add the following line into it:
    -L”c:\Borland\Bcc55\lib”
    Save changes and close the file. Rename the file from New Text Document (2).txt to ilink32.cfg.
  4. Now copy the two files bcc32.cfg and ilink32.cfg, navigate toC:\Borland\BCC55\Bin and paste them.

How to Compile the C/C++ Source Code (.C/.cpp files)?

Here is a detailed instruction on how to compile C source codes:
  1. You need to place the .C/.cpp (example.c) file to be compiled in the following location:
  2. C:\Borland\BCC55\Bin
  3. Now go to the command prompt (Start->Run->type cmd->Enter)
  4. Make the following path as the present working directory (use the CDcommand):
  5. C:\Borland\BCC55\Bin
  6. To compile the file (example.c/.cpp) use the following command:
  7. bcc32 example.c
  8. Now if there exists no error in the source code, you’ll get a compiled executable module (example.exe) in the same location (C:\Borland\BCC55\Bin).
  9. Now you have successfully compiled the source code into an executable file(.exe file).
NOTE: The above tutorial assumes that you’ve installed the compiler onto the C: drive (by default).
[Read More...]


Block or Redirect Unwanted Websites Using HOSTS File




Block Websites Using Hosts File

The hosts document is one of the fascinating and valuable component of both Windows and Linux working systems that gives numerous convenient choices in tending to network hubs. For example, you can utilize the hosts document to square irritating promotions, pop-ups, pennants, porn locales, or even divert one site to another. 

In this post I will demonstrate to you best practices to play around with the hosts document to accomplish a portion of the previously mentioned employments. 

What is a hosts File? 

The hosts record is much the same as whatever other computer document that is utilized by the working system to outline and domain names on to their relating IP addresses. 

As it were, the point at which you write "google.com" on your program's address bar, your computer will search for the hosts document to check whether it contains the comparing IP address for the domain name you wrote (google.com). On the off chance that if no passage is available in the hosts document, the demand is then passed on to the DNS (Domain Name System) server to get the IP address. 

hosts File versus DNS 

With regards to settling the hostnames, the hosts record is given the principal need over the Domain Name System. Much of the time, the hosts document remains unconfigured on the working system and thus the DNS is utilized by the computer to determine the domain names to their relating IP addresses. 

In any case, if the hosts document is found to contain a legitimate section for a given hostname or domain name, then this is grabbed and utilized by the working system.

Where is the hosts File Located?

Windows: In case of the Windows operating system, the hosts file is located at:
%systemroot%\system32\drivers\etc\hosts
NOTE: In most cases this should be: C:\Windows\System32\drivers\etc\hosts
Unix/Linux: In case of Linux it is located at:
/etc/hosts

How to Block a Website?

To Block a particular site, you should simply include another section for that site in the hosts document. I would like to reinforcement the first record and make another one as opposed to adjusting it. Along these lines, if something turns out badly, you can simply erase it and reestablish the first one! All things considered, here is a well ordered system on the most proficient method to make another hosts document on Windows:
  1. Go to “My Computer” and you should see the “Menu bar” on top. In case ofVista and Win 7, just click “Alt” to unhide the “Menu bar”.
  2. Now in the menu bar, click on “Tools -> Folder Options”. In the “View” tabuncheck the option that says: “Hide extensions for known file types” and click on “OK”.
Windows Folder Options
  1. Open a new text pad (New Text Document.txt) and rename it to: hosts. You will get a pop-up message with a warning. Just click on “Yes”.
    Please note that the renamed file hosts should not have any extensionsuch as
    hosts.txt.
  2. Open the hosts file using the notepad. Now let us assume that you want to block the sites Facebook and Youtube on your computer. For this all you have to do is add the following lines to your hosts file:
    127.0.0.1       facebook.com
    127.0.0.1       www.facebook.com
    127.0.0.1       youtube.com
    127.0.0.1       www.youtube.com
    Each entry should be placed on an individual line. The IP address and the hostname should be separated by a space or a tab. In this way, you can block any given website by just pointing it to the IP address 127.0.0.1.
  3. Navigate to %systemroot%\system32\drivers\etc. Here you should see the original hosts file, rename it to hosts_bak. Just copy and paste the newhosts file that you have created. That’s it. You’ve now successfully blocked those websites from loading on your computer.
    If you are using Vista/Win 7 you may have to take ownership of the originalhosts file before renaming it.

How to Redirect a Website?

Suppose you want to redirect Friendster.com to Google.com, all you have to do is just add the following lines to your hosts file:
74.125.236.72       friendster.com
74.125.236.72       www.friendster.com
Here 74.125.236.72 is the IP address of Google.com. To find out the IP address of any given website, just go to command prompt and ping it. For example: ping google.com. You should get a ping response that displays the IP address as shown below:
Ping Test
From now on, whenever you type “friendster.com” on your browser, you will be redirected to “google.com”.

How does a hosts File work?

Whenever you block a website using the hosts file, you point it to the IP address127.0.0.1 which in fact is the IP address of your own computer. In other words, the IP 127.0.0.1 points to your own computer and doesn’t exist outside.
So, whenever you type the URL of a website for which an entry is present in thehosts file, your computer will load the IP as 127.0.0.1 instead of the actual one and tries to establish a connection with this IP address (127.0.0.1) but fails. As a result the website doesn’t load at all.
The redirection of the website works by pointing the domain name of one website to the IP address of another website (as configured by the hosts file) instead of its original IP address. So, whenever you type friendster.com, it is pointed to Google.com’s IP address and thus, the Google page loads up instead of the actual page from friendster.com.

How to Block the Annoying Ads?

I have found a great solution to keep all the annoying ads, banners, pop-ups and other parasites at bay by using a pre-configured hosts called MVPS hosts file. This hosts file contains a long list of entries to block all those annoying ads and pop-ups that usually load while you are surfing the Internet. You can also receive regular updates on this to stay up-to-date. You can download MVPS hosts file from the link below:
If you are playing around with the hosts file and something goes wrong, just delete the hosts file itself and rename the original file from hosts_bak to hosts. This should bring back everything to normal. I hope this post on hosts file will help you block unwanted websites on your computer. Waiting for your comments. :)
[Read More...]


How to Create a Virus to Block Websites



A Virus to Block WebsitesMost of us are familiar with the virus that used to block Orkut and Youtube websites. If you are curious about creating such a virus on your own, here is how it can be done.
As usual I am using my favorite programming language ‘C’ to create this website blocking virus. I will give a brief introduction about this virus before I jump into the technical jargon.
This virus has been exclusively created in ‘C’. So, anyone with a basic knowledge of ‘C’ will be able to understand the working of this virus program. When this program is executed, it will block all those websites that are listed in the source code. In the following example, the sites that are listed in the source code are Google, Yahoo and Youtube. When you download the source code of this program, you have a choice to include your own list of sites that you want this virus to block.
I have just removed the source code of this program from this post as it is lengthy and makes the post look messy. You can still download the source code of this virus program from the following link:

How Virus Program Works?

The Windows operating system maintains a special file called HOSTS which can be used to block any given hostname or domain name (website) by adding new entries onto it. This program works by modifying the HOSTS file by adding new entries of those sites that are intended to be blocked. The HOSTS file is located at:
%windir%\system32\drivers\etc (Usually: C:\windows\system32\drivers\etc)
So, when you execute this program, all it does is add the entries of the list of those sites (mentioned in the source code) to this HOSTS file. Once this is done, the site will be blocked from your computer. So, none of the browsers would be able to load those sites on your computer.
For more information on HOSTS file, I recommend reading my other post on How to use HOSTS file to block websites.
Now, as far as the technical part of this program is concerned, people who have a working knowledge of ‘C’ should be easily able to understand the working of this virus program. However, for those who are new to ‘C’ programming, here is the algorithm of this program:
  • Determine the Root drive. ie: Find the drive (C:, D:, E: or F:) on which the Windows is installed.
  • Navigate to: %windir%\system32\drivers\etc
  • Open/Load the HOSTS file.
  • Copy a list of those websites that are mentioned in the ARRAY to the END of the file.
  • Save the file and Exit.

How to Compile the Source Code?

For a step-by-step compilation guide, refer my post: How to compile C Programs?

Testing the Virus:

  1. To test, run the compiled module. It will block the sites that are listed in the source code.
  2. Once you run the file block_Site.exe, restart your browser program. Then, type the URL of the blocked site and you’ll see the browser showing error “Page cannot displayed“.
  3. To remove the virus type the following command in the Run.
    %windir%\system32\drivers\etc
  4. There, open the file named “hosts” using the notepad. At the bottom of the opened file you’ll see something like this:
    127.0.0.1 google.com
  5. Delete all such entries which contain the names of blocked sites.
NOTE: You can also change the ICON of the virus to make it look like a legitimate program.
[Read More...]


Protect Your Email and Other Online Accounts from Hackers




Protect your Email Account from HackersIn this post, I will teach you how to protect your email account from getting hacked in a very simple and easy to understand manner. The tips provided in this post not only applies to your email account, but can also be used to protect any other online account such as your bank logins, Paypal or your social networking account. Nowadays, I get a lot of emails from people where most of them ask me for help on getting back their email accounts. This is because, they have simply fallen victims and have got their email accounts hacked!

Today, it is a common problem for many Internet users to have their email accounts compromised by hackers. But this arises one BIG question in my mind!
“Is it so easy to hack an email account? OR Is it so difficult for people to protect their email account from getting hacked?”.
The single answer to these two questions is “Absolutely NOT!“. It is neither easy to hack an email nor difficult to protect an email account from being hacked.
If this is the case, then what is the reason for many people to lose their accounts?
The answer is very simple. They do not know how to protect themselves from getting hacked! In fact, most of the people who lose their online accounts to hackers are not the victims of hacking but the victims of trapping. They get hacked not because they are hacked by some expert hackers, but because they are fooled to such an extent that they themselves give away their password.
Are you confused? If so continue reading and you’ll come to know…
Now I will mention some of the most common pitfalls by which people often fall victims and get their accounts compromised. In addition to this, I will also give information on how to avoid these pitfalls and stay protected.

1. Website Spoofing (Phishing Scam)

Website spoofing, also known as phishing is the act of creating a fake website with the intention of misleading the visitors. The website will be created by a different person or organization (other than the original) especially for the purpose of cheating. Normally, the website will adopt the design of the target website and sometimes has a similar URL.
For example a spoofed website of Yahoo.com appears exactly same as Yahoo Website. So, most people would believe this as the original site and lose their passwords. The main intention of spoofed websites is to fool users and take away their login details. For this, the spoofed sites offer fake login pages. These fake login pages resemble the original login pages of sites like Yahoo, Gmail or Facebook. Since they resemble the original login page, people believe that it is true and give away their login details to the hackers by trying to login to their accounts.

Solution:

  • Never try to login/access your online account from the sites other than the original site.
  • Always type the URL of the site in the address bar to get into the site. Do not click on a hyperlink to enter the site.

2. By using Keylogger (Spyware)

The other commonly used method to steal password is by using a Keylogger. A Keylogger is nothing but a spyware. The detailed description of keylogger and its usage is discussed in the post What Is Keylogger And How To Be Safe From Keyloggers?. If you read this post you’ll come to know that it is too easy to steal the password using a keylogger program. If you just access your account from a computer installed with keylogger, you definitely lose your password. This is because the keylogger records each and every keystroke that you type on the computer’s keyboard.

Solution:

Protecting yourselves from a keylogger scam is very easy. Just install a good anti-spyware program and update it regularly. This keeps your PC secure from a keylogger. For more information.

3. Accessing your Email from a Public Place

Do you access your email from public places like cyber cafes? If so, you are definitely under the risk of losing your password. In fact, many people lose their email account in cyber cafes. For the owner of the cyber cafe, it is just a cakewalk to steal your password. For this, all he need to do is install a keylogger program on his computers. So, when you login to your email account from this PC, you give away your password to the cafe owner. Also, there are many Remote Administration Tools (RATs) which can be used to monitor your browsing activities in real time.
This doesn’t mean that you should never use cyber cafes for surfing the Internet. I know, not all the cyber cafe owners will be so wicked. However, it is recommended not to use public places for accessing confidential information. If it comes to the matter of security never trust anyone, not even your friend. I always use my own computer to login to my accounts so as to ensure the safety.
So with this I conclude my post and assume that I have helped my readers to protect their online accounts from being hacked. Please pass your comments. :)
[Read More...]


How a Domain Name is Hijacked and How to Protect it




How Domain Names are HijackedIn this post I will tell you about how the domain names are hacked and how they can be protected. The act of hacking domain names is commonly known as Domain Hijacking. For most of you, the term “domain hijacking” may seem to be like an alien. So, let me first tell you what domain hijacking is all about.

Domain hijacking is a process by which Internet Domain Names are stolen from its legitimate owners. It is also known as domain theft. Before we can proceed to know how to hijack domain names, it is necessary to understand how the domain names operate and how they get associated with a particular web server (website).

The Operation of a Domain Name is as Follows:

Any website say for example gohacking.com consists of two parts. The domain name (gohacking.com) and the web hosting server where the files of the website are actually hosted. In reality, the domain name and the web hosting server (web server) are two different parts and hence they must be integrated before a website can operate successfully. The integration of domain name with the web hosting server is done as follows:
  1. After registering a new domain name, we get a control panel where in we can have a full control of the domain.
  2. From this domain control panel, we point our domain name to the web server where the website’s data (web pages, scripts etc.) are actually hosted.
For a clear understanding let me take up a small example:
John registers a new domain called “abc.com” from an X domain registration company. He also purchases a hosting plan from Y hosting company. He uploads all of his files (.html, .php, javascripts etc.) to his web server (at Y). From the domain control panel (of X) he configures his domain name “abc.com” to point to his web server (of Y).
Now, whenever an Internet user types “abc.com”, the domain name “abc.com” is resolved to the target web server and the web page is displayed. This is how a website actually works.

What Happens When a Domain Name is Hijacked?

Now, let us see what happens when a domain name is hijacked. To hijack a domain name, you just need to gain access to the domain control panel and point the domain name to some other web server other than the original one. So, to hijack a domain you need not gain access to the target web server.
For example, a hacker gets access to the domain control panel of  “abc.com”. From here the hacker re-configures the domain name to point it to some other web server (Z). Now whenever an Internet user tries to access “abc.com” he is taken to the hacker’s website (Z) and not to John’s original site (Y).
In this case the John’s domain name (abc.com) is said to be hijacked.

How the Domain Names are Hijacked?

To hijack a domain name, it is necessary to gain access to the domain control panel of the target domain. For this you need the following ingredients:
  1. The domain registrar name for the target domain.
  2. The administrative email address associated with the target domain.
These information can be obtained by accessing the WHOIS data of the target domain. To get access to the WHOIS data, go to whois.domaintools.com, enter the target domain name and click on Lookup. Once the whois data is loaded, scroll down and you’ll see Whois Record. Under this, you’ll get the “Administrative contact email address”.
To get the domain registrar name, look for the words something like: “Registered through:: XYZ Company”. Here XYZ Company is the domain registrar. In case if you do not find this, scroll up and you’ll see ICANN Registrar under the “Registry Data”. In this case, the ICANN registrar is the actual domain registrar.
The administrative email address associated with the domain is the backdoor to hijack the domain name. It is the key to unlock the domain control panel. So, to take full control of the domain, the hacker will have to hack the administrative email associated with it. 
Once the hacker takes full control of this email account, he will visit the domain registrar’s website and click on forgot password in the login page. There, he will be asked to enter either the domain name or the administrative email address to initiate the password reset process. Once this is done, all the details to reset the password will be sent to the administrative email address.
Since the hacker has the access to this email account, he can easily reset the password of domain control panel. After resetting the password, he logs into the control panel with the new password and from there he can hijack the domain within minutes.

How to Protect the Domain Name from Getting Hijacked?

The best way to protect the domain name is to protect the administrative email account associated with the domain. If you loose this email account, you loose your domain. You can read my earlier post on how to protect your email account from being hacked. Another best way to protect your domain is to go for a private domain registration.
When you register a domain name using the private registration option, all your personal details such as your name, address, phone and administrative email address are hidden from the public.
whenever a hacker performs a WHOIS lookup for your domain name, he will not be able to find your name, phone or the administrative email address. Thus, the private registration provides an extra security and protects your privacy. Even though it costs a few extra bucks, is really is worth for its advantages.
I hope that this article has helped you. You can express your feedback through comments.
[Read More...]


Related Posts Plugin for WordPress, Blogger...
 

Pages

For watching Movies

Contact Form

Name

Email *

Message *

Popular Posts

Return to top of page Copyright © 2014 / 2015 | Pro Theme Design By Mr Kilari