Tuesday, May 18, 2010

How to install HUAWEI E1550 on ubuntu

Steps:
Execute the following commands:
 $ sudo -s
 $ sudo apt-get install udev-extras
 $ sudo lsusb

Add a udev rule:
  $ gksu gedit /etc/udev/rules.d/15-huawei-e1550.rules

Paste this and save:

SUBSYSTEM=="usb",
SYSFS{idProduct}=="1446",
SYSFS{idVendor}=="12d1",
RUN+="/lib/udev/modem-modeswitch --vendor 0x12d1 --product 0x1446 --type option-zerocd"

Right click on NetworkManager Icon, select Edit connections -> Mobile BroadBand

Click on add button, Select "Airtel" service provider and Connection name save as Airtel.

Once the above settings done, please remove the device and Insert it again.

It works.

The latest auto launches and test drives Drag n' drop

Thursday, May 6, 2010

How to reset the Root Password

*My boot loader is GRUB

)Following is the procedure to reset root password if you are using GRUB as a boot loader:
  1. Select the kernel
  2. Press the e key to edit the entry
  3. Select second line (the line starting with the word kernel)
  4. Press the e key to edit kernel entry so that you can append single user mode
  5. Append the letter S (or word Single) to the end of the (kernel) line
  6. Press ENTER key
  7. Now press the b key to boot the Linux kernel into single user mode
  8. At prompt type passwd command to reset password:
You need to mount at least / and other partitions:
# mount -t proc proc /proc
# mount -o remount,rw /

Change the root password, enter:
# passwd
Finally reboot system:
# sync
# reboot


*My boot loader is LILO
At LILO boot loader type linux single and press [ENTER] key:
Boot: linux single
When you get the # prompt you will need to type passwd root to reset password:
# passwd
Reboot system:
# sync
# reboot


Catch the changing security environment Get it now.

Tuesday, May 4, 2010

How to Install Ftp server vsftpd / services on Linux

Ubuntu Linux comes with various ftp servers to setup FTP service such as:
=> proftpd - Versatile, virtual-hosting FTP daemon
=> vsftpd - The Very Secure FTP Daemon
=> ftpd - FTP server
=> wu-ftpd - powerful and widely used FTP server
=> wzdftpd - A portable, modular, small and efficient ftp server
=> pure-ftpd - Pure-FTPd FTP server
I recommend using vsftpd. It is simple and quite secure FTP server. According to vsftpd man page:
vsftpd is the Very Secure File Transfer Protocol Daemon. The server can be launched via a super-server such as inetd or xinetd. Alternatively, vsftpd can be launched in standalone mode, in which case vsftpd itself will listen on the network.
=> Default ftp port : 21
=> Default configuration file : /etc/vsftpd.conf

How do I set up the vsftpd daemon to accept connections from another computer?

The configuration of the vsftpd FTP service (read as daemon ) simply requires three steps.

Step # 1: Install vsftpd

Type apt-get command to install vsftpd
$ sudo apt-get install vsftpd
Output:
Password:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
vsftpd
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 121kB of archives.
After unpacking 438kB of additional disk space will be used.
Get:1 http://us.archive.ubuntu.com edgy/main vsftpd 2.0.4-0ubuntu5 [121kB]
Fetched 121kB in 0s (246kB/s)
Selecting previously deselected package vsftpd.
(Reading database ... 31396 files and directories currently installed.)
Unpacking vsftpd (from .../vsftpd_2.0.4-0ubuntu5_amd64.deb) ...
Setting up vsftpd (2.0.4-0ubuntu5) ...
Adding system user `ftp' with uid 106...
Adding new user `ftp' (106) with group `nogroup'.
Not creating home directory `/home/ftp'.
* Starting FTP server: vsftpd

Step # 2: Configure /etc/vsftpd.conf

The default vsftpd configuration file is /etc/vsftpd.conf. You need to edit this file using text editor such as vi:
$ sudo vi /etc/vsftpd.conf
Add the following line (uncomment line) to the vsftpd configuration file:
local_enable=YES
Above config directive will allow local users to log in via ftp
If you would like to allow users to upload file, add the following to the file:
write_enable=YES
For security you may restrict local users to their home directories. Add the following to the file:
chroot_local_user=YES
Save and close the file.

Step # 3: Restart vsftpd

To restart vsftpd type the command :
$ sudo /etc/init.d/vsftpd restart
Output:
* Stopping FTP server: vsftpd                                                                                       [ ok ]
* Starting FTP server: vsftpd                                                                                       [ ok ]

How do I use ftp command line utility?

Now you should be able to FTP to this server with any account that exists on the system except for the root user. From Windows or other Linux system use ftp client, type the command:
$ ftp ftp.roviksolutions.in
Output:
Connected to ftp.roviksolutions.in.
220 (vsFTPd 2.0.4)
Name (ftp.roviksolutions.in:vasanth): vasanth
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> pwd
257 "/"
ftp> ls
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
-rw-r--r--    1 1000     1000        91798 Aug 16 08:26 apf-current.tar.gz
-rwxr-xr-x    1 1000     1000          156 Nov 10 07:05 iptables.stop
drwxr-xr-x    3 0        0            4096 Dec 23 11:11 postfix
-rw-r--r--    1 0        0        10481942 Nov 29 23:35 webmin_1.310_all.deb
226 Directory send OK.
ftp> quit
221 Goodbye.

Open FTP port using iptables (optional)

Add following rules to your iptables script. Assuming that default incoming policy is drop. If protocol is TCP and destination port is 21 (ftp):
iptables -A INPUT -p tcp -m tcp --dport 21 -j ACCEPT


There are a large number of other configuration options available for vsftpd that can be used to fine tune ftp server. Read vsftpd.conf man page by typing following command:
$ man vsftpd.conf


The latest auto launches and test drives Drag n' drop

Top 10 Windows Vista Speed Tweaks

10 Speed Tweaks that can make a huge difference in Vista performance

 
1. Turn off Windows Search Indexing
Windows Vista search indexing is constantly reviewing files on your system to make their contents available for quick searching. This is handy, but can severely impact system performance.
To disable constant indexing:
  • Click Start then Computer
  • Right Click the C: Drive
  • On General Tab, Uncheck Index this drive for faster searching
  • On the subsequent dialog box, Select Include subfolders and files
2. Turn off Remote Differential Compression Remote Differential Compression measures the changes in files over a network to transfer them with minimal bandwidth rather than transferring an entire file that has previously been moved. By constantly checking for file changes, this service can hinder system performance.
To disable this service:
  • Open Control Panel
  • Switch to Classic View
  • Select Program Features
  • Choose Turn Windows features on and off
  • Scroll down and uncheck Remote Differential Compression
3. Turn off Automatic Windows Defender Operation Windows Defender real-time protection against malware continues to run despite having Automatic operation disabled.
To disable this feature:
  • Open Control Panel
  • Select Windows Defender
  • Choose Tools from the top menu
  • Select Options
  • Uncheck Auto Start at the bottom of the window
4. Turn off Automatic Disk Defragmentation Windows Vista and its always-on defragment feature isn't really that necessary and can cause system slow down. Just remember to run a defrag manually every week or so.
To disable this:
  • Click Start then Computer
  • Right Click the C: Drive
  • Click on Properties
  • Select the Tools Tab
  • Click on Defragment Now
  • Uncheck Run on a schedule
5. Add a 2GB or higher USB Flash drive to take advantage of Windows Ready Boost (Additional Memory Cache) Ready Boost is Microsoft's name for using a USB thumb/flash drive to provide some quick access memory the operating system can use as extra RAM. The Ready Boost system can significantly improve system performance.
To set this up:
  • Insert a USB Flash Drive
  • Click Start then Computer
  • Right Click the USB Drive in My Computer
  • Select the Ready Boost Tab
  • Choose Use this device
  • Select as much space as you can free up for RAM usage vs. Storage
6. Turn off Windows Hibernation Windows hibernation background services can use a large amount of system resources. If you don't use the Hibernate feature on a regular basis you may want to disable it to give Vista a performance boost.
To disable Hibernation:
  • Select the Control Panel then Power Options
  • Click Change Plan Settings
  • Click on Change Advanced Power Settings
  • Expand the Sleep selection
  • Expand the Hibernate After selection
  • Crank the selector down to zero
  • Click Apply
7. Turn off System Restore Analysis and restore point creation by Windows Vista can eat a fair amount of system resources. Disabling this service will obviously mean the system restore feature in Vista will not be available in the event of a system crash. Change this at your own risk.
To disable this service:
  • Control Panel > System
  • Click System Protection on the left panel
  • Uncheck the main system drive
  • Agree to the confirmation
8. Disable User Access Control (UAC) This much-loathed new Vista feature attempts to protect your system from malware infection by making you manually confirm a whole host of everyday user operations. While it doesn't directly impact performance, it can be annoying and might be more hassle than good.
To disable User Access Control:
  • Click Start then Control Panel
  • Select User Accounts
  • Select Turn User Account Control on or off
  • Uncheck User Account Control Box
  • Restart as recommended
9. Disable excess Windows Services that Auto-Launch at Startup Just like Windows XP, Vista ships with all kinds of services enabled that load at startup and may never be used by most users.
To see what loads at startup and disable the ones you likely won't be needing (they can always be started manually later):
  • Click Start then Control Panel
  • Select Administrative Tools
  • Choose System Configuration
  • Click the Services Tab
  • You can safely deselect:
    • Offline Files (unless you're using Offline File Sync)
    • Tablet PC Input Service (unless you have a tablet PC)
    • Terminal Services
    • Windows Search (If you have already disabled indexing)
    • Fax (unless you're using a fax modem)
10. Disable Excess Windows Features Windows ships with other features that are listed separately in the Vista operating system from the startup services.
You can view and disable these features by:
  • Clicking Start then Control Panel
  • Select Program Features
  • On the left panel, select Turn Windows Features on or off
  • You can safely deselect:
    • Indexing Service
    • Remote Differential Compression
    • Tablet PC Optional Components
    • Windows DFS Replication Service
    • Windows Fax & Scan (unless you use a modem for faxing)
    • Windows Meeting Space (unless you use the Live Meeting Service)


The battle for the FIH Hockey World Cup Drag n' drop

How to Delete Undeletable Files in Windows

Many times when trying to remove an unwanted program, especially a piece of adware or spyware, you may run across a file that is undeletable by any normal method. When you try to remove it you'll receive the error message shown below telling you "access denied" and explaining the file may be in use.  You may also receive one of the following messages.

Cannot delete file: Access is denied
There has been a sharing violation.
The source or destination file may be in use.
The file is in use by another program or user.
Make sure the disk is not full or write-protected and that the file is not currently in use.



So if the file is in use, how do you delete it?

I'll show you several ways of removing these types of files and even some freeware programs that help you remove these pesky undeletable files.
Windows 95/98/ME
If you are using Windows 95, 98, or Windows ME , the easiest way to remove an undeleteable file is to boot to a DOS prompt and manually delete the file. Before you do this, you'll want to make a note of the location of the file including the entire path to it. Follow the steps below to delete these types of files.
If you already know the path to the file, please skip to Step 7

  1. Click on Start, Find, Files and Folders
  2. Type the name of the undeletable file in the Named or Search For box
  3. Make sure the Look In box shows the correct drive letter
  4. Click on Find Now or Search Now and let the computer find the file
  5. Once the file is located, right-click on it and choose properties, make a note of the file location. Usually this is something similar to

    c:\windows\system32\undeleteablefilesname.exe
  6. Close the search box 
  7. Locate a boot disk for your version of Windows, if you do not have a boot disk, follow the steps on the link below to create an emergency boot disk.

  8. Shut down and restart your computer with the boot disk in your floppy drive.
  9. The computer will boot to a DOS prompt that will look similar to

    c:\

  10.  Type the following command and press Enter to delete the filer, substituting the phrase <path to file> with the actual path and file name you discovered in Step 5 above.

    del <path to file>

    Example:

    del c:\windows\undeleteablefile.exe
  11. Remove the boot disk in the floppy drive and restart your computer
  12. The file should now be deleted.
Windows XP
In Windows XP, there are a couple ways to remove an undeleteable file, a manual way, and a couple automated ways using some freeware programs. First, I'll show you the manual way.

Manual Method


If you already know the path to the file, please skip to Step 7

  1. Click on Start, Search, All Files and Folders
  2. Type the name of the undeletable file in the box shown
  3. Make sure the Look In box shows the correct drive letter
  4. Click Search and let the computer find the file
  5. Once the file is located, right-click on it and choose properties, make a note of the file location. Usually this is something similar to

    c:\windows\system32\undeleteablefilesname.exe

  6. Close the search box 
  7. Click on Start, Run, and type CMD and Press Enter to open a command Prompt window
  8. Leave the Command Prompt window open, but proceed to close all other open programs
  9. Click on Start, Run and type TASKMGR.EXE and press Enter to start Task Manager
  10. Click on the Processes tab, click on the process named Explorer.exe and click on End Process.
  11.  Minimize Task Manager but leave it open
  12. Go back to the Command Prompt window and change to the directory where the file is located. To do this, use the CD command. You can follow the example below.

    Example: to change to the Windows\System32 directory you would enter the following command and Press Enter

    cd \windows\system32

  13. Now use the DEL command to delete the offending file. Type DEL <filename> where <filename> is the file you wish to delete.

    Example: del undeletable.exe
  14. Use ALT-TAB to go back to Task Manager
  15. In Task Manager, click File, New Task and enter EXPLORER.EXE to restart the Windows shell.
  16. Close Task Manager


Catch the changing security environment Get it now.

How to make SSH2 work with OpenSSH

The commercial version of SSH2 uses a different key format than the OpenSSH. This guide shows how to make them inter-operate with each other with public key authentication.
 a. OpenSSH server and SSH2 client
Suppose you already generated an RSA2 key pair on your SSH2 client machine, and the public key is stored at ~/.ssh2/id_rsa_1024_a.pub. The following procedure applies to DSA key pairs too.
  1. Copy your SSH2 public key from your SSH2 client machine to your OpenSSH server like:
    scp ~/.ssh2/id_rsa_1024_a.pub server:.ssh/rsa_ssh2.pub
    If you can't copy the public key because the password authentication is disabled, you can email it to the system administrator and ask him/her to do the following for you (~/ is your home directory).
  2. Run the OpenSSH version of ssh-keygen on the server to convert the SSH2 public key to into the format needed by OpenSSH:
    ssh-keygen -i -f ~/.ssh/rsa_ssh2.pub > ~/.ssh/rsa_openssh.pub
  3. Append this newly generated OpenSSH public key to your authorization file on the server:
    cat ~/.ssh/rsa_openssh.pub >> ~/.ssh/authorized_keys2
  4. Once this is done, the .pub files you created are no longer needed so you can remove them if you like.
Now your SHH2 client should be able to connect to the OpenSSH server with the public key authentication.
 b. SSH2 server and OpenSSH client
By default, the public key is stored at ~/.ssh/id_dsa.pub.
  1. Run the OpenSSH version of ssh-keygen on the OpenSSH client machine to convert the OpenSSH public key into the format needed by SSH2:
    ssh-keygen -e -f ~/.ssh/id_dsa.pub > ~/.ssh/dsa_ssh2.pub
  2. Copy this SSH2 public key to your .ssh2 directory on the SSH2 server:
    scp ~/.ssh/dsa_ssh2.pub server:.ssh2/dsa_ssh2.pub
    If you can't copy the public key because the password authentication is disabled, you can email it to the system administrator and ask him/her to do the following for you (~/ is your home directory).
  3. Add this new pub key to the authorization on the server:
    echo Key dsa_ssh2.pub >> ~/.ssh2/authorization
  4. Once this is done, the temporary .pub file you created on the OpenSSH client is no longer needed so you can remove it. DO NOT remove the .pub file you just copied to the SSH2 server.
Now your OpenSSH client should be able to connect to the SSH2 server with the DSA public key authentication.


The latest auto launches and test drives Drag n' drop

How To Remove Windows Genuine Authentication

Have you updated your copy of Windows and received the "This copy of Windows is not genuine" notification. Have you ever wondered how to get rid of it?
The Windows Genuine Advantage notification checks if you have a genuine copy of Windows registered to that computer. It allows you to update your computer with the Windows updates. If you have installed it, and you do not have a genuine copy of Windows XP installed, then you may notice an icon at the bottom of your window before you Login. It will make you wait three seconds before allowing you to login.
WGA on the Login Screen
In your tray, you will also notice a WGA icon telling you that you may be a victim of software counterfeiting.
Here's how to get rid of it.
The Long Way:
  • The longer way is to restart your computer and go into Safe Mode. If you do not know how to boot into safe mode, please refer this Page. Once in safe mode, non-essential programs will not run, including WgaTray.exe (the Windows Genuine Advantage program). Once in Safe Mode go to C:\Windows\System32\ and locate and delete WgaTray.exe
Tongue outCheat notes for computer savy users:
  1. Restart your computer and boot into safe mode (press F8 while you restart your computer)
  2. In Safe mode browse to C:\Windows\System32\
  3. Search for WgaTray.exe and Delete it.
  4. Reboot your computer and you are done. 
The Quick but more difficult way (requires speed):
  • If you do not want to restart your computer and get into Safe Mode, you can do it in the following way. This requires a bit of speed with both the mouse and keyboard because every time you close the WgaTray.exe process, it will restart itself in less than a second.
  • Go to C:\Windows\System32\ and locate WgaTray.exe and highlight it. Trying to delete this right now will not work since WgaTray.exe is currently running. Next press ctrl+alt+del and select the process tab. Find WgaTray.exe in the list. To make it easier to find it, you can sort the list in alphabetical order by clicking the Process title at the top. Highlight WgaTray.exe.
  • Here's where your speed comes in. You have to end the WgaTray.exe process and then quickly go to the other window and delete WgaTray.exe.

  • Tip: Press end process then enter, then alt+tab, then delete, then enter. This is the sequence you should go through.
  • Note: If you do not delete WgaTray.exe before the program restarts itself, you will not be able to delete it. You will have to try again.
In both cases, continue with the following steps.
Next go to C:\Windows\System32\dllcache\ and delete WgaTray.exe here also.
Next you have to modify your registry.
  • Press the Start Button > Run and type regedit and then press enter.
  • Go to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\Notify and delete the WGALOGON folder.
That's all you have to do, now you are WGA free. Just make sure you don't automatically install the WGA update again. Restart your computer to see if you did it correctly. The WGA logo should not appear on your login screen.
DISCLAIMER: We do not condone having pirated copies of Windows on your computer. You should have one CAL per computer. This is for educational purposes only.


The latest auto launches and test drives Drag n' drop

How to Start Windows in Safe Mode

Many times in order to remove a piece of spyware or troubleshooting and diagnostic purposes, you'll have to start Windows in Safe Mode. While in Safe Mode, only specific programs and files needed to run the operating system are loaded. Some functions, such as connecting to the Internet, will not be active in Safe Mode and a standard video driver will be loaded causing a washed out look and a possible change in resolution. 
However, because just the essential programs and files are loaded in Safe Mode, this allows us to remove some spyware, adware, viruses and such that cannot be removed in Normal Mode. Follow the instructions below to Start Safe Mode for your specific version of Windows.

Windows 7

  • Turn the computer on or Restart the computer
  • Start tapping the F8 key. The Windows Advanced Boot Options Menu appears. If you begin tapping the F8 key too soon, some computers display a "keyboard error" message. To resolve this, restart the computer and try again.
  • Ensure that the Safe mode option is selected, not Repair Your Computer
  • Press Enter. The computer then begins to start in Safe mode.
  • When you are finished with troubleshooting, close all programs and restart the computer as you normally would
Windows Vista

Windows Vista is similar to Windows XP for starting in Safe Mode.


  • Turn the computer on or Restart the computer
  • Start tapping the F8 key. The Windows Advanced Boot Options Menu appears. If you begin tapping the F8 key too soon, some computers display a "keyboard error" message. To resolve this, restart the computer and try again.
  • Ensure that the Safe mode option is selected (the top option)
  • Press Enter. The computer then begins to start in Safe mode.
  • When you are finished with troubleshooting, close all programs and restart the computer as you normally would.
Windows XP
If Windows XP is the only operating system installed on your computer, booting into Safe Mode with these instructions.
  • If the computer is running, shut down Windows, and then turn off the power
  • Wait 30 seconds, and then turn the computer on.
  • Start tapping the F8 key. The Windows Advanced Options Menu appears. If you begin tapping the F8 key too soon, some computers display a "keyboard error" message. To resolve this, restart the computer and try again.
  • Ensure that the Safe mode option is selected.
  • Press Enter. The computer then begins to start in Safe mode.
  • When you are finished with all troubleshooting, close all programs and restart the computer as you normally would.
To use the System Configuration Utility method
  • Close all open programs.
  • Click Start, Run and type MSCONFIG in the box and click OK
  • The System Configuration Utility appears, On the BOOT.INI tab, Check the "/SAFEBOOT" option, and then click OK and Restart your computer when prompted.
  • The computer restarts in Safe mode.
  • Perform the troubleshooting steps for which you are using Safe Mode.
    When you are finished with troubleshooting in Safe mode, open MSCONFIG again, on the BOOT.INI tab,  uncheck "/SAFEBOOT" and click OK to restart your computer



All the post budget analysis and implications Sign up now.

How to make Windows XP Genuine

Here is the easy way to make you Windows XP Genuine.
  1. Start
  2. run
  3. regedit
  4. HKEY_LOCAL_MACHINE
  5. SOFTWARE
  6. Microsoft
  7. Windows NT
  8. Current Version
  9. WPAEvents
  10. Double click OOBETimer
  11. Select all and delete
  12. FF D5 71 D6 8B 6A 8D 6F D5 33 93 FD
  13. Right click on WPAEvents
  14. Permissions
  15. System
  16. Deny Full Control
  17. Apply
  18. Yes
  19. OK
  20. Done!
Alternate Solution torrent download : http://thepiratebay.org/torrent/3550335/Make_Windows_XP_Genuine_in_5_seconds._No_more_WGA_Cracks


The latest auto launches and test drives Drag n' drop

SSH/SSH2 Password-less Authentication

A great little guide to setting up two accounts so that you don't have to type in your password when sshing between them. btw, OS X uses OpenSSH. I don't know what it is for other platforms.

Basic Idea

No-password authentication works because of public key crypto. Let's say you have a local machine Ooga and a remote machine Booga. You want to be able to ssh from Ooga to Booga without having to enter your password. First you generate a public/private RSA key pair on Ooga. Then you send your public key to Booga, so that Booga knows that Ooga's key belongs to a list of authorized keys. Then when you try to ssh fromOoga to Booga, RSA authentication is performed automagically.
Here are detailed steps on how to do this.
NOTE: The following examples and scenarios assume you are creating only a single key, e.g. one RSA key or one DSA key. If it turns out that you've created both keys on your (client) system, then you will need to send both of them to the SSH/SSH2 server; otherwise, you may still be asked to enter a passphrase.

ssh1

If you're using ssh1, then do this:
ooga% ssh-keygen -f ~/.ssh/identity
This will generate a public/private rsa1 key pair. When it asks you to enter your passphrase, just hit return (i.e. leave it empty). Now you need to send your public key to the remote server.
ooga% cd .ssh
ooga% scp identity.pub user@booga:~/.ssh
Now you need to log into Booga and add Ooga's public key to Booga's list of authorized keys.
ooga% ssh user@booga
booga% cd .ssh
booga% cat identity.pub >> authorized_keys
booga% chmod 640 authorized_keys
booga% rm -f identity.pub
That's it! You can now ssh from Ooga to Booga without entering your password.

ssh2

It's harder for ssh2. There are two common implementations of ssh2: OpenSSH and SSH2. Let's say we want to ssh from Ooga to Booga. If Ooga and Booga both run the same implementation then it's easy. Otherwise, we need to do some extra work to make them talk to each other properly.
My particular situation is that my local machine is running Windows 2000 with the Cygwin tools and OpenSSH 3.2.x. The remote machines may either have OpenSSH or SSH2. I'll cover these two cases below.

ssh2: Ooga = OpenSSH, Booga = OpenSSH

First, generate a public/private DSA key pair on Ooga.
ooga% ssh-keygen -t dsa -f ~/.ssh/id_dsa
When you are asked for a passphrase, leave it empty. Now send the public key to Booga.
ooga% cd .ssh
ooga% scp id_dsa.pub user@booga:~/.ssh
Next, log in to Booga and add the public key to the list of authorized keys.
ooga% ssh user@booga
booga% cd .ssh
booga% cat id_dsa.pub >> authorized_keys2
booga% chmod 640 authorized_keys2
booga% rm -f id_dsa.pub
Note that the filename is authorized_keys2, not authorized_keys. That's it; you're ready to ssh from Ooga to Booga without having to enter a password.

ssh2: Ooga = OpenSSH, Booga = SSH2

First, generate a public/private DSA key pair on Ooga.
ooga% ssh-keygen -t dsa -f ~/.ssh/id_dsa
When you are asked for a passphrase, leave it empty. This key is stored in a format that OpenSSH can use, but SSH2 cannot. You need to export the key to a format that SSH2 understands.
ooga% ssh-keygen -e -f .ssh/id_dsa.pub > id_dsa_ssh2_ooga.pub
Note: the exact flags you need to specify may differ in your case. Check the man pages if the line above doesn't work. Now send the exported public key to Booga.
ooga% scp id_dsa_ssh2_ooga.pub user@booga:~/.ssh2/
Note: the target directory is .ssh2, not .ssh. Next, log in to Booga and add the public key to the list of authorized keys.
ooga% ssh user@booga
booga% cd .ssh2
booga% cat >> authorization key id_dsa_ssh2_ooga.pub
booga% chmod 640 authorization
For SSH2, there is an authorization file in which you list the file names of the authorized public keys. Note that this step is different than the case in which Booga is running OpenSSH.
Now you are ready to ssh from Ooga to Booga without having to enter a password.


Catch the changing security environment Get it now.

Sunday, May 2, 2010

Desktop Blogging Clients for Free



If you feel bored by going to a website by logging in by username and password everytime you like to post something, here there are some solutions.
Inside Firefox
Scribefire
 
Inside Windows

  1. Windows live Writer
  2. Thingamablog
  3. zoundryraven
Inside Linux
  1. Bleezer(Supports MAC, Linux and Windows)
  2. BlogTK
  3. Drivel Blog Editor
  4. Gnome Blog


The battle for the FIH Hockey World Cup Drag n' drop

User Creation using PHP/MySQL

Username/password Creation in PHP and MySQL. a Simple form is designed to get the username and two passwords the objectives are
1. Both the username and password should contain atleast 6 characters
2. both the passwords should be same
3. upon submitting to the database, the existence of username is checked with the database, if the username already exists, then the user is allowed to select some other, else user is created.
//html file is given below, file name is
<h2>User Registration Form</h2>
<pre>
<form action="userregis.php" method="post">
Enter the username: <input name="username" type="text" /> Enter the password: <input name="password1″ type="password" />
Confirm the password: <input name="password2″ type="password" />
<input type="submit" value="create" />
</form>
</pre>
//userregis.php
<?php
include("dbconnect.php");
$u=$_POST['username'];
$p1=$_POST['password1'];
$p2=$_POST['password2'];
$query1="Select * from usertable where user='$u'";
$query2="Insert into usertable values ('$u',password('$p1′))";
if(strlen($u)<6 or strlen($p1)<6)
{
echo "The username and password should contain atleast 6 characters";
}
else if($p1!=$p2)
{
echo "The Passwords should be same";
}
else
{
$r1=mysql_query($query1) or die("Database Selection Failed");
$num=mysql_num_rows($r1);
if($num==1)
{
echo "The username <h3> $u </h3> is already exists";
}
else
{
$r2=mysql_query($query2) or die("Database Insertion Failed");
if($r2)
echo "Username <h3> $u </h3> is successfully created";
else
echo "Database Insertion Failed";
}
}
?>
<?php
include("dbconnect.php");
$u=$_POST['username'];
$p1=$_POST['password1'];
$p2=$_POST['password2'];
$query1="Select * from usertable where user='$u'";
$query2="Insert into usertable values ('$u',password('$p1′))";
if(strlen($u)<6 or strlen($p1)<6)
{
echo "The username and password should contain atleast 6 characters";
}
else if($p1!=$p2)
{
echo "The Passwords should be same";
}
else
{
$r1=mysql_query($query1) or die("Database Selection Failed");
$num=mysql_num_rows($r1);
if($num==1)
{
echo "The username <h3> $u </h3> is already exists";
}
else
{
$r2=mysql_query($query2) or die("Database Insertion Failed");
if($r2)
echo "Username <h3> $u </h3> is successfully created";
else
echo "Database Insertion Failed";
}
}
?>
//dbconnect.php
<?php
$con=mysql_connect("localhost","root","abc123″) or die(mysql_error());
$db=mysql_select_db("dummy",$con) or die (mysql_error());
?>

All the post budget analysis and implications Sign up now.

How to install OMNET++ on Ubuntu

OMNeT++ is a discrete event simulation environment. Its primary application area is the simulation of communication networks, but because of its generic and flexible architecture, is successfully used in other areas like the simulation of complex IT systems, queueing networks or hardware architectures as well.

Follow the simple steps given below and get your OMNET++ up:

1. Download the OMNET++ simulator from here.

2. sudo -s (become root user)
    sudo tar zxf omnetpp-4.0p1-src.tgz -C /usr/local/ ; cd /usr/local ; sudo ln -s omnetpp-4.0p1 omnetpp

3. sudo apt-get install bison byacc flex blt lmodern giftrans doxygen libxml2-dev graphviz imagemagick (or use synaptic package manager for installing these)

4. sudo apt-get install tcl8.4 tk8.4 tcl8.4-dev tk8.4-dev (Or use synaptic package manager for installing these)

5. The following environment variables may be added into ~/.bashrc for future convenience. Remember to remove the word export!)
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/omnetpp/lib
export TCL_LIBRARY=/usr/share/tcltk/tcl8.4
export PATH=$PATH:/usr/local/omnetpp/bin

6. cd /usr/local/omnetpp; sudo ./configure;

7. sudo make

8. export PATH=$PATH:/usr/local/omnetpp/bin

9. sudo make

This will complete your installation. Try running the program given in samples directory by:

10. cd /usr/local/omnetpp-3.3/samples/dyna

11. run ./dyna

Its so simple!! Have fun !!


Mobility Framework for OMNeT++

1. Download Mobility Framework (MF) from Omnetapp

2. Unzip the tar file using tar command

3. goto MF directory

4. run ./mkmk

5. Add in ~/.bashrc file
export LD_LIBRARY_PATH=/mobility-fw directory/core/lib
export LD_LIBRARY_PATH=/mobility-fw directory/contrib/lib

4. make all

5. goto networks directory->802.11

6. ./802.11

Try other examples also given with MF.

Oops !! Still getting shared library error, then follow this step->

a. Create symbolic link from /../core/lib/*.so to /usr/local/lib/*.so

and /../contrib/lin/*.so to /usr/local/lib/*.so

How to create Symbolic link ? Here we go->

ln -s /../MF Directory/core/lib/filename.so /usr/local/lib/filename.so


And I am sure this will surely solve your problem :)



Catch the changing security environment Get it now.

Friday, March 5, 2010

How to Lock the Folder/Files in Linux

How to Lock the Folder/Files in Linux?

Here is the Simple method to lock your files,

#Step 1:
first we change permissions for the folder which we want to protect
Code:

$ sudo chmod a-r /path/to/folder

u have to enter your root password, when prompted ,to run this command
also change the /path/to/folder according to your folder location u wish to lock

#Step 2:
now to create the key!
create an empty file ,and name it as u wish but for this HOW-TO i'm using "protector"
Code:

$ touch .PROTECTOR

the file is created in your home/user/ folder
if u cannot see the file, select "show hidden files" from the View menu or press Ctrl+H , now the file should be visible

#Step 3:
open the file using the text editor and enter the following command>
Code:
$ nano ~/.PROTECTOR

And Paste the following 5 lines in the file.
#!/bin/bash
gksu chmod +r /path/to/folder;
nautilus /path/to/folder;
sleep 1;
sudo chmod a-r /path/to/folder

now save and exit.

#Step 4:
now right click the file > select "properties"> select "permissions" tab> check "Allow executing the file as program"
Or you can set execute permission through Terminal

$ chmod +x ~/.PROTECTOR

#Step 5:
*  To create a Launcher in Main Menu, Goto System > Preferences > Main Menu
Click on New Item
Input the correct detail's on dialogue box:
 
Type          : Application
Name         : <Name of the Launcher>
Command    : /home/username/.PROTECTOR
Comment    : Comment to Launcher

And also you can create a launcher on the panel/or Desktop...

The best dressed and the most admired Drag n' drop

Oracle Password Reset

From Oracle FAQ

ORAPWD is a utility used to create a password file for an Oracle Database.

Run orapwd utility before:

    * setting REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE|SHARED
    * Grant OSDBA/OSOPER to users

Check V$PWFILE_USERS to see who was granted OSDBA/OSOPER access.
[edit] Examples

Create a new password file:

orapwd file=orapwSID password=oracle entries=5

If the password file already exists:

orapwd file=orapwSID password=oracle entries=5 FORCE=Y

The FORCE parameter is available starting from Oracle 10g.



All the latest on four wheels and more Get it now.