Monday, January 10, 2011

Wireless in Window.

Hi here is some info to share with you regarding Wireless connection in Window.



*Show Wireless profile in Window

C:\>netsh wlan show profiles

*Export collected Wireless profile and save in to Computer

C:\>netsh wlan export profile folder=C:\temp

*Use wireless profile 

C:\>netsh wlan add profile filename="<filename.xml>"



Easy to go rite...

Security Tips - Sharehosting / Sharedserver Environment

SolutionSecurity Tips
========

These tips are basically for the websites which are hosted on shared servers/environment.

(1) Always use latest updated software
-------------------------------------------
Avoid using older versions of software as they are insecure. Use the latest release which includes few security fixes and functionality as well.

(2) 3rd Party Scripts and Code
----------------------------------
Plugins, widgets or any other code you usually install on WordPress or Joomla are written by other people under unknown circumstances. Some may be great, some may have security holes. Make sure you research any code you wish to use but you haven't written yourself. Do a few Google searches before using such code to verify how secure the code actually is.

(3) Secure Your Own Computers
-------------------------------------
One of the biggest reasons of Identity theft and an easy way for someone to fetch confidential details to your site(s). Your personal computer could well turn out to be a weak link in this. It could be anything, from an infected Powerpoint file or someone phishing your account details, the vulnerabilities are too many to consider. No matter how secure your actual website is, if the machine you use to access, log in and edit your web pages is infected you stand a grave risk of being compromised and its outcome may be more than just the effect on your site.

Use anti-virus scans, clear logs, secure your passwords and be aware of general security issues. Public WIFI spots are also a security risk.

(4) Secure Passwords
-------------------------
A secure password goes a long way in making it difficult for a potential infiltrator to intrude into. Your passwords should always be a combination of letters, numbers and special characters. The longer the password, the better. You can also generate a random password which is even more secure.

(5) Checking Your Logs Regularly
-------------------------------------
If you spot any unusual traffic spike in your website stats (ranking for gambling, pharmaceuticals and sex terms is a common one) try working out where it is coming from and going to. From there if you can make sure whether it is a hack.

(6) Backups
-------------
Taking the backups regularly alone won't protect your website from being hacked. In case of hack you will need to take care of the following:-
* Records of IP's accessing your website
* Pre hack backup of your website including the latest updates.

With Shinjiru backup plans you can make backups for your website daily, weekly as per your requirements. You would be able to use latest backup you had on backup space.

(7) Host on a Virtual Private Server
-----------------------------------------
Host your websites on a VPS server that immediately isolates yourself from the shared hosting environment and being affected by the issues that are invited by other users in the same server.

Wednesday, January 5, 2011

What is People’s Favorite Passwords?

Have you ever wondered what is people’s favorite password? You might be one of them. Thus, better think twice before choosing a password for e-mail, online bank accounts and airline tickets. Passwords that show no imagination or distinctiveness are easy prey for information pirates, a new US study says. A statistically analysis of 28000 passwords recently stolen from a popular US website and posted on the internet reveals that people often do the easy thing.
It found that 16% took a first name as a password, often their own or one of their children, according to the study published by Information Week. Another 14% relied on the easiest keyboard combination to remember such as “1234” or “12345678”. For those using English keyboard, “Qwerty” was popular. Likewise, “Azerty” scored with people with European keyboards.
5% of the stolen passwords were names of television shows or stars popular with young people like “Hannah”, inspired by singer Hannah Montana. “Pokemon”, “Matrix” and “Ironman” were others. The word “password” or easy to guess variations like “password1”, accounted for 4%. 3% of the passwords expressed attitudes like “I don’t care”, “whatever”, “yes” or “no”.
There were sentimental choices, “Iloveyou” and their opposite, “Ihateyou”. Robert Graham, of the company Errata Security, which did the analysis and published the conclusions, advices that to better protect against cyber intrusions: “choose a password that is longer than eight characters with one capital letter and one symbol.” – AFP

Hidden commands in windows …

Without mysteries, life would be very dull indeed. What would be left to strive for if everything were known?
Just like the commands of Windows, The true mystery of the world is the visible, not the invisible. If you turn the pages and insert your head in the basic of Windows then there are some thing to explore, here are few examples of some hidden secret commands in Windows:

1. ‘systeminfo’

It boasts how long it can stay up. Whereas previous versions of Windows were coy about how long they went between boots, XP is positively proud of its stamina.
Go to the Command Prompt in the Accessories menu from the All Programs start button option, and then type ‘systeminfo’. The computer will produce a lot of useful info, including the uptime. If you want to keep
these, type ‘systeminfo > info.txt‘. This creates a file called info.txt you can look at later with Notepad. (Professional Edition only).

2. gpedit

You can delete files immediately, without having them move to the Recycle Bin first. Go to the start menu, select Run… and type ‘ gpedit.msc‘; then select User Configuration, Administrative Templates, Windows Components, Windows Explorer and find the Do not move deleted files to the Recycle Bin setting. Set it.
Poking around in gpedit will reveal a great many interface and system options, but take care — some may stop your computer behaving as you wish.
(Professional Edition only).

3. rundll32.exe

You can lock your XP workstation with two clicks of the mouse. Create a new shortcut on your desktop using a right mouse click, and enter ‘rundll32.exe
user32.dll,LockWorkStation
‘ in the location field. Give the shortcut a name you like. That’s it — just double click on it and your computer will be locked. And if that’s not easy enough, Windows key + L will do the same.

4. sysoc.inf

XP hides some system software you might want to remove, such as Windows Messenger, but you can tickle it and make it disgorge everything. Using Notepad or Edit, edit the text file /windows/inf/sysoc.inf, search for the word ‘hide‘ and remove it. You can then go to the Add or Remove Programs in the Control Panel, select Add/Remove Windows Components and there will be your prey, exposed and vulnerable.

5. schtasks

For those skilled in the art of DOS batch files, XP has a number of interesting new commands. These include ‘eventcreate‘ and ‘eventtriggers‘ for creating and watching system events, ‘typeperf’ for monitoring performance of various subsystems, and ‘schtasks’ for handling scheduled tasks. As usual, typing the command name followed by /? will give a list of options — they’re all far too baroque to go into here.

6. ipv6

XP has IP version 6 support (the next generation of IP). Unfortunately this is more than your ISP has, so you can only experiment with this on your LAN. Type ‘ipv6 install‘ into Run… (it’s OK, it won’t ruin your existing network setup) and then ‘ipv6 /?‘ at the command line to find out more. If you don’t know what IPv6 is, don’t worry and don’t bother.

7. taskkill

You can at last get rid of tasks on the computer from the command line by using ‘taskkill /pid‘ and the task number, or just ‘tskill’ and the process number.
Find that out by typing ‘tasklist’, which will also tell you a lot about what’s going on in your system.

8. zipfldr.dll

XP will treat Zip files like folders, which is nice if you’ve got a fast machine. On slower machines, you
can make XP leave zip files well alone by typing ‘regsvr32 /u zipfldr.dll‘ at the command line. If you change your mind later, you can put things back as they were by typing ‘regsvr32 zipfldr.dll‘.

Tuesday, January 4, 2011

List of the keyboard shortcuts that are available in Windows

General keyboard shortcuts

    * CTRL+C (Copy)
    * CTRL+X (Cut)
    * CTRL+V (Paste)
    * CTRL+Z (Undo)
    * DELETE (Delete)
    * SHIFT+DELETE (Delete the selected item permanently without placing the item in the Recycle Bin)
    * CTRL while dragging an item (Copy the selected item)
    * CTRL+SHIFT while dragging an item (Create a shortcut to the selected item)
    * F2 key (Rename the selected item)
    * CTRL+RIGHT ARROW (Move the insertion point to the beginning of the next word)
    * CTRL+LEFT ARROW (Move the insertion point to the beginning of the previous word)
    * CTRL+DOWN ARROW (Move the insertion point to the beginning of the next paragraph)
    * CTRL+UP ARROW (Move the insertion point to the beginning of the previous paragraph)
    * CTRL+SHIFT with any of the arrow keys (Highlight a block of text)
    * SHIFT with any of the arrow keys (Select more than one item in a window or on the desktop, or select text in a document)
    * CTRL+A (Select all)
    * F3 key (Search for a file or a folder)
    * ALT+ENTER (View the properties for the selected item)
    * ALT+F4 (Close the active item, or quit the active program)
    * ALT+ENTER (Display the properties of the selected object)
    * ALT+SPACEBAR (Open the shortcut menu for the active window)
    * CTRL+F4 (Close the active document in programs that enable you to have multiple documents open simultaneously)
    * ALT+TAB (Switch between the open items)
    * ALT+ESC (Cycle through items in the order that they had been opened)
    * F6 key (Cycle through the screen elements in a window or on the desktop)
    * F4 key (Display the Address bar list in My Computer or Windows Explorer)
    * SHIFT+F10 (Display the shortcut menu for the selected item)
    * ALT+SPACEBAR (Display the System menu for the active window)
    * CTRL+ESC (Display the Start menu)
    * ALT+Underlined letter in a menu name (Display the corresponding menu)
    * Underlined letter in a command name on an open menu (Perform the corresponding command)
    * F10 key (Activate the menu bar in the active program)
    * RIGHT ARROW (Open the next menu to the right, or open a submenu)
    * LEFT ARROW (Open the next menu to the left, or close a submenu)
    * F5 key (Update the active window)
    * BACKSPACE (View the folder one level up in My Computer or Windows Explorer)
    * ESC (Cancel the current task)
    * SHIFT when you insert a CD-ROM into the CD-ROM drive (Prevent the CD-ROM from automatically playing)
    * CTRL+SHIFT+ESC (Open Task Manager)


Dialog box keyboard shortcuts

If you press SHIFT+F8 in extended selection list boxes, you enable extended selection mode. In this mode, you can use an arrow key to move a cursor without changing the selection. You can press CTRL+SPACEBAR or SHIFT+SPACEBAR to adjust the selection. To cancel extended selection mode, press SHIFT+F8 again. Extended selection mode cancels itself when you move the focus to another control.

    * CTRL+TAB (Move forward through the tabs)
    * CTRL+SHIFT+TAB (Move backward through the tabs)
    * TAB (Move forward through the options)
    * SHIFT+TAB (Move backward through the options)
    * ALT+Underlined letter (Perform the corresponding command or select the corresponding option)
    * ENTER (Perform the command for the active option or button)
    * SPACEBAR (Select or clear the check box if the active option is a check box)
    * Arrow keys (Select a button if the active option is a group of option buttons)
    * F1 key (Display Help)
    * F4 key (Display the items in the active list)
    * BACKSPACE (Open a folder one level up if a folder is selected in the Save As or Open dialog box)


Microsoft natural keyboard shortcuts

    * Windows Logo (Display or hide the Start menu)
    * Windows Logo+BREAK (Display the System Properties dialog box)
    * Windows Logo+D (Display the desktop)
    * Windows Logo+M (Minimize all of the windows)
    * Windows Logo+SHIFT+M (Restore the minimized windows)
    * Windows Logo+E (Open My Computer)
    * Windows Logo+F (Search for a file or a folder)
    * CTRL+Windows Logo+F (Search for computers)
    * Windows Logo+F1 (Display Windows Help)
    * Windows Logo+ L (Lock the keyboard)
    * Windows Logo+R (Open the Run dialog box)
    * Windows Logo+U (Open Utility Manager)


Accessibility keyboard shortcuts

    * Right SHIFT for eight seconds (Switch FilterKeys either on or off)
    * Left ALT+left SHIFT+PRINT SCREEN (Switch High Contrast either on or off)
    * Left ALT+left SHIFT+NUM LOCK (Switch the MouseKeys either on or off)
    * SHIFT five times (Switch the StickyKeys either on or off)
    * NUM LOCK for five seconds (Switch the ToggleKeys either on or off)
    * Windows Logo +U (Open Utility Manager)


Windows Explorer keyboard shortcuts

    * END (Display the bottom of the active window)
    * HOME (Display the top of the active window)
    * NUM LOCK+Asterisk sign (*) (Display all of the subfolders that are under the selected folder)
    * NUM LOCK+Plus sign (+) (Display the contents of the selected folder)
    * NUM LOCK+Minus sign (-) (Collapse the selected folder)
    * LEFT ARROW (Collapse the current selection if it is expanded, or select the parent folder)
    * RIGHT ARROW (Display the current selection if it is collapsed, or select the first subfolder)


Shortcut keys for Character Map

After you double-click a character on the grid of characters, you can move through the grid by using the keyboard shortcuts:

    * RIGHT ARROW (Move to the right or to the beginning of the next line)
    * LEFT ARROW (Move to the left or to the end of the previous line)
    * UP ARROW (Move up one row)
    * DOWN ARROW (Move down one row)
    * PAGE UP (Move up one screen at a time)
    * PAGE DOWN (Move down one screen at a time)
    * HOME (Move to the beginning of the line)
    * END (Move to the end of the line)
    * CTRL+HOME (Move to the first character)
    * CTRL+END (Move to the last character)
    * SPACEBAR (Switch between Enlarged and Normal mode when a character is selected)


Microsoft Management Console (MMC) main window keyboard shortcuts

    * CTRL+O (Open a saved console)
    * CTRL+N (Open a new console)
    * CTRL+S (Save the open console)
    * CTRL+M (Add or remove a console item)
    * CTRL+W (Open a new window)
    * F5 key (Update the content of all console windows)
    * ALT+SPACEBAR (Display the MMC window menu)
    * ALT+F4 (Close the console)
    * ALT+A (Display the Action menu)
    * ALT+V (Display the View menu)
    * ALT+F (Display the File menu)
    * ALT+O (Display the Favorites menu)


MMC console window keyboard shortcuts

    * CTRL+P (Print the current page or active pane)
    * ALT+Minus sign (-) (Display the window menu for the active console window)
    * SHIFT+F10 (Display the Action shortcut menu for the selected item)
    * F1 key (Open the Help topic, if any, for the selected item)
    * F5 key (Update the content of all console windows)
    * CTRL+F10 (Maximize the active console window)
    * CTRL+F5 (Restore the active console window)
    * ALT+ENTER (Display the Properties dialog box, if any, for the selected item)
    * F2 key (Rename the selected item)
    * CTRL+F4 (Close the active console window. When a console has only one console window, this shortcut closes the console)


Remote desktop connection navigation

    * CTRL+ALT+END (Open the Microsoft Windows NT Security dialog box)
    * ALT+PAGE UP (Switch between programs from left to right)
    * ALT+PAGE DOWN (Switch between programs from right to left)
    * ALT+INSERT (Cycle through the programs in most recently used order)
    * ALT+HOME (Display the Start menu)
    * CTRL+ALT+BREAK (Switch the client computer between a window and a full screen)
    * ALT+DELETE (Display the Windows menu)
    * CTRL+ALT+Minus sign (-) (Place a snapshot of the entire client window area on the Terminal server clipboard and provide the same functionality as pressing ALT+PRINT SCREEN on a local computer.)
    * CTRL+ALT+Plus sign (+) (Place a snapshot of the active window in the client on the Terminal server clipboard and provide the same functionality as pressing PRINT SCREEN on a local computer.)


Microsoft Internet Explorer navigation

    * CTRL+B (Open the Organize Favorites dialog box)
    * CTRL+E (Open the Search bar)
    * CTRL+F (Start the Find utility)
    * CTRL+H (Open the History bar)
    * CTRL+I (Open the Favorites bar)
    * CTRL+L (Open the Open dialog box)
    * CTRL+N (Start another instance of the browser with the same Web address)
    * CTRL+O (Open the Open dialog box, the same as CTRL+L)
    * CTRL+P (Open the Print dialog box)
    * CTRL+R (Update the current Web page)
    * CTRL+W (Close the current window)


Other information

    * Some keyboard shortcuts may not work if StickyKeys is turned on in Accessibility Options.
    * Some of the Terminal Services client shortcuts that are similar to the shortcuts in Remote Desktop Sharing are not available when you use Remote Assistance in Windows XP Home Edition.
    * Some of the other Microsoft Knowledge Base articles that have similar information as this article are:

      126449  (http://support.microsoft.com/kb/126449/ ) Keyboard shortcuts for Windows
      255090  (http://support.microsoft.com/kb/255090/ ) Keystroke navigation in Windows 2000 Help

    * Refer to Help for the most current information regarding keyboard navigation and visit the following Microsoft Accessibility Web site for additional information that relates to keyboard shortcuts and keyboard navigation in Windows and other Microsoft products:

      http://www.microsoft.com/enable (http://www.microsoft.com/enable)

Monday, January 3, 2011

How to Setup a Dedicated Web Server for Free ...

All great websites have a great server behind them. In this tutorial, I’ll show you how to set up a dedicated web server (with Apache, MySQL, and PHP) using that old computer you have lying around the house and some free software.


1. A Quick Overview

In this tutorial, we are aiming to accomplish several things:
  • We’re going to install the Ubuntu Server operating system. I commonly use Ubuntu because of its ease of use and
    simple administration. It also has a rather large and extremely active community behind it, which makes getting
    support a breeze.
  • We’re going to install an OpenSSH server. This allows you to administer your server from remote computers.
  • A LAMP (Linux, Apache, MySQL, and PHP) stack is going to be installed. This provides the backbone that will run
    your web site. Apache is the industry standard web server on Unix-based operating systems; it’s what most web hosts
    use (NETTUTS is using it right now!) and it’s what we’re going to use.
  • We’re going to install a firewall to protect your server from unauthorized access.
In order to follow this tutorial, you’re going to need a few items:
  • A computer to use as your server. It doesn’t need to be powerful; as long as it’s not ancient, it’ll work fine. Please
    don’t do this on your desktop PC; Ubuntu will completely wipe your computer.
  • A CD burner and a blank CD. These are so that you can burn Ubuntu to a disk in order to install it.
  • Time. Seriously, this process is time-consuming, especially if you run into problems. Try to set aside an afternoon
    to follow this tutorial.
You may be asking why you’d want to have your own web server. There are several reasons, a few of them being: you can have your own testing
ground for your websites; with a little modification, you could host your own site; and, you will learn a lot about Linux/Unix as you go.
With that said, let’s get started!

2. Download Ubuntu Server

First and foremost, we’re going to need a CD with Ubuntu on it. Point your web browser to http://www.ubuntu.com/,
and click download from the menu to the left. You will now be presented with a box with two tabs: “Desktop Edition” and
“Server Edition”. Click the “Server Edition” tab, and select “Ubuntu 8.04 LTS”. Next, select a download location from the
drop-down box. Finally, hit the “Begin Download” button.
Now you need to burn the ISO (the file that you downloaded) to a blank CD. If you don’t know how to do this, there is an
excellent guide at https://help.ubuntu.com/community/BurningIsoHowto

3. Install Ubuntu Server

Now that you’ve downloaded and burned the ISO, let’s get Ubuntu installed on your server. Put the disk in the drive, and boot from the CD. In most modern computers, this will happen by default if a disk is in the drive when you turn it on. If it doesn’t, then you need to press a key on your keyboard right when you turn it on. For my laptop, it’s F12, and for my server, it’s F2. It just depends on your computer. You can find it by looking at the text on your screen right when you turn the computer on, during the BIOS. You’ll see something like “Press [KEY] to change boot order”. Press that key, and select your CD drive.
Still with me? Good. Now that you’ve booted up Ubuntu, you should see the following screen:
Select your language, and hit enter. Now you’ll see this screen:
Select “Install Ubuntu Server”, and away we go!
The installer will now ask you if you want it to detect your keyboard layout. Personally, I always choose no, because
it’s faster to select a standard american keyboard from the list than to have the installer detect it. Either option is fine,
just follow the on-screen instructions.
After you’ve done that, you’ll now see a bunch of loading screens saying things like “Detecting CD-ROM drives” and such.
These should pass quickly and without problems. However, during these screens, the installer will try to auto-configure your
network settings. For most cases, this will work without complaint. However, if it doesn’t work for you, just follow the
on-screen instructions to get it working.
After it’s done with all of that, it will ask you for a host name. You can usually set this to anything; I always set
mine to “web-server”.
The system will now want you to set the time zone for your clock. For me, it’s Pacific. Choose the one that applies to
you.
Now, the system will detect more hardware, and you’ll be prompted to “partion the disk(s)”. Select “Guided – use entire
disk”.
You will now need to select the disk you wish to partition. For most setups, only one disk will be available; however,
for more specialized systems, more options will be available here. Choose the one that applies to you.
It will ask you if you want to write the changes to the disk. Select “Yes” and hit enter. The installer will now proceed
to format the drive and set up the partitions.
Now the magic happens. The system will begin to install. While this happens, go get a cup of coffee. This can take anywhere
from 10 minutes to an hour. It just depends on your system. There might be times that it seems like it’s frozen; don’t worry,
it isn’t. Just let it do it’s thing. However, if it’s stuck on one thing for upwards of an hour, then yes, it is frozen.
Now that the system is installed, it needs to set up the account you are going to login with. First, give it your full
name and hit “Continue”.
Now give it your username. It will normally just set it as your first name,
but you can change it. One name you may not use is “root”.
You will now be asked to provide a password. It is ESSENTIAL that you choose a strong password, or your server will not
be secure at all. I recommend at LEAST a mixture of numbers, lowercase letters, and uppercase letters. However, for my servers
I use symbols, as well as a mixture of the above. DO NOT use a password shorter than 7 characters.
Then, re-enter your password to verify that you typed it correctly.
The system will now attempt to configure the “Package Manager” (we’ll get to what that is shortly). Provide it with your
proxy information, or leave it blank if you don’t use a proxy, and select “Continue”.
The system will now scan several servers looking for updates and configuration settings.
After that has completed, you will be presented with several options to install server software. Now, listen VERY carefully.
Select OpenSSH server, and press SPACE, NOT ENTER. If you hit enter, the install will proceed without installing the OpenSSH server.
You could install “LAMP server” as well, but I have no experience with this option, so we’re going to install it all with a different
command later on.
The system will now install your selected software, as well as other system components.
Finally, the install will finish. Remove the CD, and hit enter. The computer will reboot. If all goes well, you will be
presented with a screen that looks similar to the following:
Congratulations! You’ve just finished the hardest part. Ubuntu is now installed, and it is time to turn this computer into
a web server.

4. Update Your New Server

Before we go any further, we need to make sure your server is up-to-date. To do this, you need to login. First, type your username
(the one you chose earlier), press enter, and then type your password. As you’re typing your password, you’ll notice that nothing
seems to be happening. Don’t worry, that’s the way it was designed to work. After you’ve finished typing your password, hit enter,
and your screen should look similar to the one below if all went well:
Now, type:
sudo aptitude update && sudo aptitude dist-upgrade
It will ask you for you password, and again, you won’t see anything as you’re typing it. After you’ve done that, it will ask you if
you want to continue. Type “y” and press enter. Your screen will look similar to the following:
Your system will now download and install all the latest updates. This will take a while depending on your internet connection. After
it has finished, your computer will need to be rebooted. To do this, type:
sudo shutdown -r now
And let it reboot. Your server is now completely updated.

A Quick Note About “Sudo”

By now, you may have noticed that all of the commands you have typed have started with “sudo”. This is because they require
administrator privileges, and that’s what “sudo” does. It runs the command (i.e. “shutdown”) as an administrator, allowing it to work
properly. This is also why it asks you for your password. However, after you have typed “sudo” once and entered your password,
you do not have to enter your password again for five minutes. Not all commands require sudo, only ones that modify parts of the system.
Got all of that? Good.

5. Install Apache, MySQL, and PHP
It is now time to install some programs. In order to access your sites from the internet, we’re going to need to install a web server (Apache). In additon to the web server, we’ll
also want a database server (MySQL) and a server-side language (PHP) so that we can run popular applications such as WordPress. So,
let’s get to it!
Installing programs on Ubuntu is a lot different than installing programs on Windows or
OS X, in that Ubuntu will download and install the programs for you with a simple command. This is because Ubuntu has something called
a Package Manager, which manages nearly all the programs on your system. All we have to do is tell the package manager
(called “aptitude”) that we want it to install Apache, MySQL, and PHP. To do this, type the following command:
sudo aptitude install apache2 php5-mysql libapache2-mod-php5 mysql-server
And press enter. Aptitude will download and install of the programs you specified. It will also download and install any
dependencies.
During the install process, MySQL will ask you for a root password. You can set this to anything, just be sure you make it long and secure.
Whatever you do, DO NOT leave this blank.
After that has all finished, you now have a fully working web server. To test it out, first find your server’s IP by typing:
ifconfig | grep inet
It’s usually the first IP returned. In my case, it’s 192.168.177.129. Now that you know the IP, open your web browser and point it
to your server IP. If you see the “It works!” message, then congratulations, it works.
However, we’re not done yet. We don’t want Apache or PHP to disclose any information about themselves, as this information is not needed
by your users and could pose a security risk. First, back up the original Apache configuration file:
sudo cp /etc/apache2/apache2.conf /etc/apache2/apache2.conf.bak
Now open the configuration file:
sudo nano /etc/apache2/apache2.conf
Scroll down (down arrow) to where it says “ServerTokens Full” and change it to read “ServerTokens Prod”
Now, scroll down a little further and change “ServerSignature On” to “ServerSignature Off”
Finally, press Control-O followed by Control-X. That will save the file and exit the text editor.
Now, we need to do the same thing for PHP. First, back up the original PHP configuration file:
sudo cp /etc/php5/apache2/php.ini /etc/php5/apache2/php.ini.bak
Open the configuration file:
sudo nano /etc/php5/apache2/php.ini
Change “expose_php = On” to “expose_php = Off”
Again, press Control-O followed by Control-X. Now that the configuration files are updated, restart Apache:
sudo /etc/init.d/apache2 restart
You are done setting up Apache, MySQL, and PHP.

6. Install a Firewall

We now are going to lock down our server a bit more by installing Shorewall, a command-line firewall. To install it:
sudo aptitude install shorewall
By default, Shorewall is installed with no rules, allowing complete access. However, this is not the behavior we want.
Instead, we’re going to block all connections to anything other than port 80 (HTTP) and port 22 (SSH). First, copy the configuration
files to the Shorewall directory:
sudo cp /usr/share/doc/shorewall-common/examples/one-interface/* /etc/shorewall/
Now, open the “rules” file:
sudo nano /etc/shorewall/rules
Add these lines above where it says “#LAST LINE”
HTTP/ACCEPT net  $FW
SSH/ACCEPT net  $FW
Then press Control-O and Control-X. Your firewall is now configured to only accept HTTP and SSH traffic. The last thing we need to
do is tell Shorewall to start on boot. So, open up the main Shorewall configuration file:
sudo nano /etc/shorewall/shorewall.conf
Scroll down to “STARTUP_ENABLED=No” and set it to “STARTUP_ENABLED=Yes”
Press Control-O and Control-X. Now, open the Shorewall default configuration file:
sudo nano /etc/default/shorewall
And change “startup=0″ to “startup=1″. Press Control-O and Control-X. Finally, start your firewall:
sudo /etc/init.d/shorewall start
Congratulations! Your firewall is now set up and protecting your server.

7. Add Your Website to Your Web Server

Now that you’ve got everything all set up, you’d probably like to add a website to it. By default, all of the files Apache serves
up to the internet are located at “/var/www/”. However, you cannot write to this folder. Let’s make it so you can:
sudo usermod -g www-data [YOUR USERNAME]
sudo chown -R www-data:www-data /var/www
sudo chmod -R 775 /var/www
What happened there was you added yourself to the “www-data” group, and made the website folder writable to the members of the “www-data”
group.
Now, you’re going to log into your server using SFTP (not to be confused with FTPS). Some clients that support SFTP are:
WinSCP (Windows, Free), FileZilla (Windows, Linux, OS X, Free),
Cyberduck (OS X, Free), and, my personal favorite, Transmit
(OS X, $30)
Connect to your server using your username and password, and, if your client supports it, a default path of “/var/www” (if it doesn’t,
simply browse to /var/www once you have logged in): (Transmit pictured)
You may now add your files to this folder (/var/www) and they will show up on your server when you browse to it with your
web browser.
Now, you may wonder why we’re using SFTP instead of FTP. Mainly, because SFTP is already built into OpenSSH (which you installed
earlier). However, it is also a lot more secure than FTP, and makes it difficult (if not impossible) for malicious users to gain access
to your login credentials.

8. Make Your Server Accesible to the Internet

Most modern home networks are behind a router these days. Because of this, your web server will not be visible to the internet without
a little work. As I don’t have every router available to test with, I can only give you general directions in this area.
There are two ways to open your server up to the internet: a DMZ or Port Forwarding. The main difference you’ll notice is that with a DMZ, your server uses the
firewall we installed earlier to protect itself. However, with Port Forwarding, your server will be protected by your router’s firewall.
However, before we go on, you’re going to want to give your server a static LAN address. To do that, login to your router, and look for something
along the lines of “Static IPs” or “Static Routing”. After you have given your server a static LAN address, you can do these next parts. Remember,
Google is your friend.
To port foward, there is an excellent website, PortForward.com, that, while ugly, can
help you get the job done for almost any router. The ports that you want to forward are 22 and 80.
To create a DMZ, you need to login to your router and look for something like “DMZ settings”. Once you find it, add your server to
the DMZ, and you’ll be set. Again, Google is helpful in situations like this.
Now, find your public IP, and voila! You can access your server from anywhere as long
as your IP doesn’t change.

9. Managing Your Server Remotely

Beside allowing you to upload files, OpenSSH allows you to login to your server from anywhere as long as you know it’s IP. For Windows, you’ll
need an SSH client. I recommend Putty. For OS X, SSH is
already installed. Simply open up Terminal, and type “ssh you@yourip“. For Putty, choose SSH, and put in your IP, username, and password
when it asks for it. You’ll notice that, once you login, it looks exactly the same as the screen on the server:
You can do anything from here that you would do actually sitting at the server. To logout from the server, simply type “exit” and hit enter.

10. That’s It!

You now have a completely functioning web server. It makes for a great testing ground, and would even be suitable to host websites with fairly
low traffic. There is obviously a lot left to be learned, but hopefully you have gained a little insight into how web servers work.

Thursday, December 30, 2010

How to Stay Secure Online

How to Stay Secure OnlineThere really isn't any assurance your technology won't get stolen someday. As previously mentioned, it happened to me in less than a minute. Fortunately there are a number of tools to keep your laptops and mobile phones secure from tampering, or at least initiate a remote data wipe in the event of a breach.
How to Stay Secure OnlineIf you shop online, your credit card number has been entered into at least one web site. While this is unavoidable, and just about as safe as using your credit card out in the real world, the fact still remains that your number could be intercepted and used to make unauthorized purchases. One easy way around that problem isusing temporary credit card numbers. While not every bank offers this service, if yours does you might want to take advantage of it. If you're making a purchase online—especially at a site you don't trust—you just generate a unique credit card number that will expire after its first use. This is also extremely helpful if you sign up for a trial and want to prevent automatic re-billing.
How to Stay Secure OnlineDoing this gives you all the characteristics of a good, strong password: lowercase and capital letters, at least one number, special characters, and a combination of those things that basically makes no sense when you look at it and turns out to be longer than eight total characters.
How to Stay Secure OnlineWhen it comes to our own, individual online security we put a lot of trust in our password managers. Password managers keep track of your passwords on multiple sites so you never need to remember your password when it's time to log in. This way you can memorize your one master password and never have to worry about remembering any of the others. This is enormously convenient, but what's more important is the added security benefits. A good password manager can help generate incomprehensible passwords, store them in its database, and decode them locally, only one your machine, when it needs to enter them into the web site. You can use a password manager to generate a unique, complex password for every site you visit. Each site will have a different password, you'll have no idea what any of them are, and all you'll have to do is remember the one master password you set for it.
How to Stay Secure OnlineDuring the Summer of my freshman year in high school, I worked at a grocery store as a bag boy and saved up for a laptop. At the end of the Summer I was finally able to buy one. Nowadays laptops are commonplace, but this was back when they were pretty rare. I loved it, and I put my life into that computer. A year later I set it up to print in the computer lab and ran into the other room for 30 seconds. When I returned, the laptop was gone. I was amongst people I trusted and gone for under a minute but, still, it didn't matter: the laptop was gone. I thought I'd somehow get it back, but it didn't take long to realize that wasn't going to happen. But, ultimately, it wasn't the laptop I wanted back. I quickly realized all my personal information—all my secrets—were in the hands of someone I'll never find. Someone gained the potential to know the darkest parts of my life and I'll never know who they are. This experience taught me two things:


How to Stay Secure OnlineIn light of recent events, security has been a serious priority for all of us. Although there is no 100% full-proof plan, there are ways to greatly improve your online security and plan for the worst. Here are our recommendations.

The Bad News: Nobody's Safe

  1. No matter how safe you think you might be, something bad can always happen.
  2. The only way to ensure your private information always remains private and in your control is if it never leaves your own head.
The internet and reality aren't much different, in that sense. There is plenty of, if not more, risk in the real world than there is on the web, but we're just more accustomed to dealing with it. The online world is still very young and so we're learning to protect ourselves as we go along. Nonetheless, like with anything, there is no surefire protection. The web is imperfect. We are imperfect. Ultimately, no site is un-hackable. A person or group with enough knowledge and determination can bring nearly any site down. That said, we can certainly try our best to protect ourselves and be prepared for worst-case scenarios.

Create Strong, Resilient Passwords

How to Stay Secure Online
There are several ways to keep remarkably strong passwords, but every strategy has a point of weakness and a level of inconvenience that you're going to have to accept. We're going to go over a method that we feel is all-around the best way to go, but include a few variations along the way so you can decide what suits you best.

Create Strong, Secure Passwords that Even You Don't Know

How to Stay Secure OnlineWhile there are a number of good password managers out there, like KeePass and 1Password, our favorite isLastPass. LastPass offers incredibly wide support for several operating systems, web browsers, and mobile phones. It's also completely free, remarkably secure, and comes with many features to help you stay as protected as possible. Since you're likely not without a few passwords at this point in your life online, LastPass can help you audit and update your passwords to make them more secure.
But what about creating a secure master password?
While all the passwords LastPass (or your other password manager) will generate will be about as strong as they can be, you want to have a strong master password as well. While your password manager can generate one for you, often times it's going to be too hard to remember and too inconvenient to type (especially on a mobile phone). If you don't mind the extra work for the extra security, your best bet is to have the most secure password you can have. If you want something you're sure you won't forget, Mozilla offers an easy way to create a strong password you'll be able to remember:
If you're not in the mood for a cute strong password public service announcement, the concept goes something like this:
  • Pick a phrase you can remember with a number in it, like "A bird in the hand is worth two in the bush."
  • Change that number (in this case, "two") to its numerical equivalent: A bird in the hand is worth 2 in the bush
  • Condense the phrase by only using the first letter of each word: Abithiw2itb
  • Add some special characters you can remember: #Abithiw2itb!
While we recommend generating complex passwords with your password manager, you can use this same technique to create unique passwords for individual sites. You can take the password and add a suffix specific to each web site. Sticking with out example, let's say you wanted to use this password for Lifehacker. Just add :L1feh@cker, :Lh, or whatever you'll be able to remember to the end of the password: #Abithiw2itb!:Lh. This way you can type your complex password as you normally would and just append your abbreviation for the site you're logging into. This method is a little easier, but it's not impossible for someone to figure out. Ideally you'll want to let your password manager handle your password generation for you, but if that's just not for you then this method is a reasonable alternative.
How to Stay Secure OnlineIf at any point you're not sure about your password's security, head on over to How Secure Is My Password? to get an approximation of how long it would take to crack using an average desktop computer. Our example (#Abithiw2itb!) would take about seven billion years, which seems pretty good. If you're satisfied with the password you've derived, you've got your new master password. If you're not, keep trying and checking.

Keep Your Other Information Protected

Your passwords are not the only kind of important information you don't want floating around the internet, and chances are you have a few gadgets you wouldn't want to fall into the wrong hands. Fortunately there are quite a few ways you can

Protecting Your Credit Cards

Keeping Your Mobile Technology Secure

One of our favorite tools is Prey, which is a free tool (for up to three devices) that can help you track and (potentially) recover your stolen laptop or Android smartphone. If you're looking for a solution for your iOS device, Apple now offers find my iPhone for free. If you're not using an iPhone 4, it is still possible to enable the free Find My iPhone, but it'll take a little bit of extra work. Once you get it up and running, you'll be able to remotely locate your iPhone, send it a message, and wipe your personal data. To get started, you can download Find My iPhone in the iTunes App Store. Despite the name, it'll work with any iOS device (but GPS and 3G service certainly help).

That just about wraps it up for guide to online security. With so many options out there, it's hard to cover the entire spectrum. If you feel we've missed something or have some good tips, please share them in the comments. Thanks for reading, and stay safe!

ShoutMix chat widget