SOHO : Small Office Home Office
Freeware - Opensource software tips, tricks, tweaks & fixes for managing, securing, improving the performance of SOHO Desktop, Laptop, Networks

Wednesday, December 30, 2009

Add Administrator Account to Log In Screen

When Windows XP is first installed it requires you to enter at least one name of a user who will access the computer. Once you create this name the default Administrator account vanishes. To access it, press Ctrl-Alt-Delete twice at the Welcome screen to retrieve the standard Windows 2000 logon dialog. Log on as Administrator from this point. To log the Administrator off, click [Start] [Log Off] and [Log Off] when the [Log Off Windows] selection box appears. The Log On screen with the available users will be displayed.

To Make the Administrator Account Always Visible on the Login Screen

[Start] [Run] [Regedit]
Registry Key: HKEY_LOCALMACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\SpecialAccounts\UserList
Modify/Create the Value Data Type(s) and Value Name(s) as detailed below.
Data Type: DWORD// Value Name: Administrator
Setting for Value Data: [0 = Disabled / 1 = Enabled]
Exit Registry and Reboot
Continue Reading...

Monday, December 28, 2009

How to add readmore in blogger?

Follow this instructions

http://www.google.com/support/blogger/bin/answer.py?answer=154172
Continue Reading...

Embed Photos from Picasa Web Albums

Picasa Web Albums is probably the best way to view a photo album online, but did you know you can embed those photos into a site? Next to each photo, Google shows a link that reads "Embed in Blog/MySpace". Check "Hide album link" and copy the HTML code.

You'll notice a link similar to this one:
http://lh6.google.com/image/[username]/[id1]/[id2]/[id3]/s288/name.jpg

Google resizes your photo to 288 pixels width. But that's pretty small, I hear you saying. The nice thing is that you can change the width, but only to fixed values. Here's a list of numbers you can use to replace 288:
72, 144, 200, 320, 400, 512, 576, 640, 720, 800, 912, 1024, 1152, 1280, 1440, 1600.

If you want to place a direct link to a photo, you can use 1600, as this seems to be the biggest value.
Continue Reading...

how to change the blogger favicon?

This needs editing your template file.

1. Design the icon and save it as png (ico is preferred, but it's harder to upload). The preferred resolution is 16x16, but i saved mine at 22x22 for greater quality, and it seems it works :) (i think 36x36 is the limit)
2. Upload the icon somewhere (photobucket, pages.google.com), and copy the link
3. Go to Edit HTML under the Template tab in your blog's dashboard
4. Find the follwowing line (Ctrl+f) : data:blog.pagetitle
5. Insert this code below it: link href='URL of your icon file' rel='shortcut icon' type='image/vnd.microsoft.icon' (replace "URL of your icon file" with the link you've copied at step 2)
6. Save the template
In order to see the change, close your page, delete the temporary internet files from your browser and reopen your page
Continue Reading...

how to hide blogger navbar?

'm using the blogger tmeplates " rounders 2" and this is the hack to remove the navbar

Copy and paste the code provided below and insert it into the template, the code can be inserted anywhere in the template.

#navbar {
height: 0px;
visibility: hidden;
display: none;
}
Continue Reading...

Saturday, December 26, 2009

install clamTK on ubuntu

clamTK is used for cleaning windows virus on file servers, mail servers and restoring windows partitions.

To install :
sudo apt-get install calmav-freshclam

To update :
sudo freshclam (to update the definations)
Continue Reading...

How To Set up a repository cache with apt-cacher

When running multiple machine with the same distribution, it is interesting to set up a repository cache on your network so that once a package is downloaded from an official repository, all other machines will download it from your local area network.

Having different machines running the same linux distribution, it becomes interesting to set up a repository cache somewhere on your network. This way, you won't download common packages more than 1 time from official repositories.

Here is the situation, we have one machine called repository-cache, this machine is going to act as the repository cache, basically, any other machines in your network is going to use it as a repository.

1. Getting started

As usual, you need to install the required packages in the first place. So type in a terminal:

$sudo apt-get install apt-cacher apache2

Once this is done, it is time to get into the configuration files in /etc/apt-cacher/apt-cacher.conf

2. Configuring Apt-Cacher

2.1. apt-cacher.conf

So now, open apt-cacher's main configuration file: /etc/apt-cacher/apt-cacher.conf and start editing it according to your settings.

The default port apt-cacher is running on is port 3142. You might want to change this value accordingly to your needs.

allowed_hosts: by default, all host are allowed to use the repository cache. You can change this value if you want to only allow certain host. In my case, I want to allow my LAN 192.168.1.0/24 and localhost (both 127.0.0.1 and 127.0.1.1 on ubuntu boxes), so I changed the value to:

allowed_hosts=192.168.1.0/24, 127.0.1.1

as 127.0.0.1 is always allowed, it was not necessary to add 127.0.0.1

generate_reports: This directive makes apt-cacher create a report on how efficient your cache was on a daily basis. Default is 1, if you want to disable this, set it to 0

path_map: This is an interesting directive. Here you can define different aliases for different repository host. For my ubuntu edgy box, my path_map looks like this:

path_map = debuntu repository.debuntu.org ; ubuntu archive.ubuntu.com/ubuntu; ubuntu-updates archive.ubuntu.com/ubuntu ; ubuntu-security security.ubuntu.com/ubuntu

Let me explain that bit. Here I created mappings from names:

* debuntu to host repository.debuntu.org
* ubuntuand ubuntu-updates to host archive.ubuntu.com/ubuntu
* and ubuntu-security to security.ubuntu.com

Now, in order to access a specific repository, we simply need to append the mapping name to our cache repository server, like: repository_cache_machine:port/mapping_name

So, for instance, we can access debuntu repository through http://repository-cache:3142/debuntu and ubuntu secutiry repository through http://repository-cache:3142/ubuntu-security.

2.2. Activating apt-cacher to start

In order to start, apt-cacher needs to be activated from /etc/default/apt-cacher. So open /etc/default/apt-cacher and set AUTOSTART to 1:

AUTOSTART=1

Now restart apt-cacher:

$sudo /etc/init.d/apt-cacher restart

Now that apt-cacher runs, it is time to update all our clients /etc/apt/sources.list files so every host on the network will use our repository-cache machine.

3. Setting up the Clients and Server sources.list

Now it is time to set up the client hosts apt source list files: /etc/apt/sources.list. It make sense to use the repository cache on the server too, as that way, any updates made by the server will fill up the cache.

Here is the original /etc/apt/sources.list:

#debuntu repository
deb http://repository.debuntu.org edgy multiverse
deb-src http://repository.debuntu.org edgy multiverse

#ubuntu main repository
deb http://archive.ubuntu.com/ubuntu/ edgy main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ edgy main restricted universe multiverse

#ubuntu updates repository
deb http://archive.ubuntu.com/ubuntu/ edgy-updates main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ edgy-updates main restricted universe multiverse

#ubuntu security updates repository
deb http://security.ubuntu.com/ubuntu edgy-security main restricted universe multiverse
deb-src http://security.ubuntu.com/ubuntu edgy-security main restricted universe multiverse

In order to use our cache repository, those entries need to be changed to:

#debuntu repository
deb http://repository-cache:3142/debuntu edgy multiverse
deb-src http://repository-cache:3142/debuntu edgy multiverse

#ubuntu main repository
deb http://repository-cache:3142/ubuntu edgy main restricted universe multiverse
deb-src http://repository-cache:3142/ubuntu edgy main restricted universe multiverse

#ubuntu updates repository
deb http://repository-cache:3142/ubuntu-updates edgy-updates main restricted universe multiverse
deb-src http://repository-cache:3142/ubuntu-updates edgy-updates main restricted universe multiverse

#ubuntu security updates repository
deb http://repository-cache:3142/ubuntu-security edgy-security main restricted universe multiverse
deb-src http://repository-cache:3142/ubuntu-security edgy-security main restricted universe multiverse

Cool, now, every host should be able to retrieve the .deb packages from our repository cache once:

$sudo apt-get update

has been ran on every host.

4.Use as a proxy to APT
Static configuration

In a terminal, type:

sudo nano /etc/apt/apt.conf.d/01proxy

Inside your new file, add a line that says:

Acquire::http::Proxy "http://:3142";

"Roaming" mode

This method is useful if you are alternating between office and home with a laptop for example. It involves using the ping command to determine if the apt-cacher server is available at boot-time and then configure the APT proxy or not.

* Open /etc/rc.local (alt-F2, "gksu gedit /etc/rc.local")
* Change the top from "#!/bin/sh -e" to "#!/bin/bash"
* put this near the end (before "exit 0" if present) replacing "SERVER_NAME_HERE" with your server's resolvable name or it's IP:

. /lib/lsb/init-functions
log_daemon_msg "Configuring APT cache proxy" "(based on SERVER_NAME_HERE's presence...)"
ping -c 1 SERVER_NAME_HERE &> /dev/null
if [ $? = "0" ]; then
echo "Acquire::http::Proxy \"http://SERVER_NAME_HERE:3142\";" > /etc/apt/apt.conf.d/01SERVER_NAME_HEREproxy
else
rm /etc/apt/apt.conf.d/01SERVER_NAME_HEREproxy &> /dev/null
fi
log_end_msg 0

5. Importing existing package from /var/cache/apt/archives/ to apt-cacher repository

It might happen that your server already got a whole lot of packages cached in its local repository: /var/cache/apt/archives/. apt-cacher offers a tool to import those files to apt-cacher repository.

There is a whole lot of usefull script that can be found in /usr/share/apt-cacher/. The one we are interested in here is apt-cacher-import.pl. To import deb files from /var/cache/apt/archives to apt-cacher repository run:

$sudo /usr/share/apt-cacher/apt-cacher-import.pl /var/cache/apt/archives

This must be run as user root or .deb files might not be copied to the cache repository

Now, the directory /var/cache/apt-cacher/packages/ should be filled up with a whole bunch of packages.

6. Getting report usage of your repository cache

If you left the directive generate_reports set to 1, apt-cacher will generate report on the usage of the cache every day.

You will be able to access it at the address: http://repository-cache:3142/report

.

If you need to regenerate the report, run: $sudo /usr/share/apt-cacher/apt-cacher-report.pl

7. Conclusion

apt-cacher is an easy and efficient package which will save you both time and bandwidth when using multiple machines with the same distribution like it could happen in a home network or in at a company.


Sources :
1. http://www.debuntu.org/how-to-set-up-a-repository-cache-with-apt-cacher
2. https://help.ubuntu.com/community/Apt-Cacher-Server
Continue Reading...

Thursday, December 24, 2009

registry hack for automatic login win xp

[Start] [Run] [Regedit]
Registry Key: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon
Modify/Create the Value Data Type(s) and Value Name(s) as detailed below.

Data Type: String Value // Value Name: DefaultUserName
Setting for Value Data: [Enter the account name to be automatically logged on]

Data Type: String Value // Value Name: DefaultPassword
Setting for Value Data: [Enter the account password]

Data Type: String Value // Value Name: AutoAdminLogon
Setting for Value Data: [0 = Disabled / 1 = Enabled]
Continue Reading...

how to setup legal notification in xp?

Create Legal Notice Logon Dialog Box

In situations where you need users to review a legal notice before logging on, this tweak will create the caption for the notice and the notice itself which you type directly into the string values.

[Start] [Run] [Regedit]
Registry Key: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon

Modify/Create the Value Name [LegalNoticeCaption] according to the Value Data listed below.
Data Type: REG_SZ [String Value] // Value Name: LegalNoticeCaption
Value Data for LegalNoticeCaption: [Type the Caption for the Dialog Box]

Modify/Create the Value Name [LegalNoticeText] according to the Value Data listed below.
Data Type: REG_SZ [String Value] // Value Name: LegalNoticeText
Value Data for LegalNoticeText: [Type the Data for the Legal Notice]
Exit Registry and Reboot

Continue Reading...

Wednesday, December 23, 2009

How to turn on automatic logon in Windows XP?

If you set a computer for automatic logon, anyone who can physically gain access to the computer can also gain access to everything that is on the computer, including any network or networks that the computer is connected to. Additionally, if you turn on automatic logon, the password is stored in the registry in plain text. The specific registry key that stores this value is remotely readable by the Authenticated Users group. Therefore, only use this setting if the computer is physically secured and if you make sure that users who you do not trust cannot remotely see the registry.

You can use Registry Editor to add your log on information. To do this, follow these steps:

Click Start, click Run, type regedit, and then click OK.

Locate the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon

Using your account name and password, double-click the DefaultUserName entry, type your user name, and then click OK.

Double-click the DefaultPassword entry, type your password under the value data box, and then click OK.

If there is no DefaultPassword value, create the value. To do this, follow these steps:
In Registry Editor, click Edit, click New, and then click String Value.

Type DefaultPassword as the value name, and then press ENTER.
Double-click the newly created key, and then type your password in the Value Data box.

If no DefaultPassword string is specified, Windows XP automatically changes the value of the AutoAdminLogon registry key from 1 (true) to 0 (false) to turn off the AutoAdminLogon feature.
Double-click the AutoAdminLogon entry, type 1 in the Value Data box, and then click OK.

If there is no AutoAdminLogon entry, create the entry. To do this, follow these steps:

In Registry Editor, click Edit, click New, and then click String Value.
Type AutoAdminLogon as the value name, and then press ENTER.
Double-click the newly created key, and then type 1 in the Value Data box.

Quit Registry Editor.

Click Start, click Restart, and then click OK.

After your computer restarts and Windows XP starts, you can log on automatically.

If you want to bypass the automatic logon to log on as a different user, hold down the SHIFT key after you log off or after Windows XP restarts. Note that this procedure applies only to the first logon. To enforce this setting for future logoffs, the administrator must set the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon

Value:ForceAutoLogon
Type: REG_SZ
Data: 1

You can also use turn on automatic logon without editing the registry in Microsoft Windows XP Home Edition and in Microsoft Windows XP Professional on a computer that is not joined to a domain. To do this, follow these steps:

Click Start, and then click Run.
In the Open box, type control userpasswords2, and then click OK.

Note When users try to display help information in the User Accounts window in Windows XP Home Edition, the help information is not displayed. Additionally, users receive the following
error message:
Cannot find the Drive:\Windows\System32\users.hlp Help file. Check to see that the file exists on your hard disk drive. If it does not exist, you must reinstall it.

Clear the "Users must enter a user name and password to use this computer" check box, and then click Apply.

In the Automatically Log On window, type the password in the Password box, and then retype the password in the Confirm Password box.

Click OK to close the Automatically Log On window, and then click OK to close the User Accounts window.
Continue Reading...

Wednesday, December 16, 2009

How can I install Remote Desktop Web Connection on Windows ?

Remote Desktop Web Connection is an optional World Wide Web Service component of Internet Information Services, which is included by default in Windows XP Professional, Windows 2000 and Windows Server 2003. Just like IIS, Remote Desktop Web Connection is not installed by default on Windows XP/2003, but must be installed using Add or Remove Programs.

The Remote Desktop Web Connection is an optional component of Windows Server 2003 and can be installed from the installation media.

Note: Users of Windows Server 2003 do not need to download this package. They can manually add this package from Add/Remove in the Control Panel. However, if you still want to download the package please read Download Remote Desktop Web Connection for Windows Server 2003.

When you install Remote Desktop Web Connection, the files are copied by default to the %systemroot%\Web\Tsweb directory of your webserver. The included sample default.htm and connect.asp page can be used as is, or you can modify them to meet the needs of your application.

The Remote Desktop Web Connection is a Win32-based ActiveX control (COM object) that can be used to run Remote Desktop sessions from within Internet Explorer.

The Remote Desktop Web Connection download package includes the downloadable ActiveX control and sample Web page that can be used as a starting point for running Windows-based programs inside Internet Explorer. Developers can also use the Remote Desktop Web Connection to develop client-side applications that interact with applications running on a terminal server.

The downloadable ActiveX control provides most of the same functionality as the full Remote Desktop Connection software in Windows Server 2003 (read Download RDP 5.2), but is designed to deliver this functionality over the Web. The Web Package Setup program installs the downloadable ActiveX control, the ActiveX Client Control Deployment Guide, and sample Web pages on a server running Internet Information Services 4.0 or later.

Remote Desktop Web Connection benefits include:

Run sessions within Internet Explorer - The Remote Desktop Web Connection is a Win32 ActiveX control that runs in Internet Explorer 5 and later versions—on any Windows 32-bit operating system. When users first navigate to a Web page embedded with the Remote Desktop Web Connection ActiveX control, they will see a dialog box that asks, "Do you want to install this control?" Using the sample Web pages as an example, the Web site administrator can design pages that either link directly to a terminal server-hosted application, or simply run the entire desktop.


Quick and easy access to computers running Windows XP Professional with Remote Desktop enabled or Windows Terminal Servers
- The Remote Desktop Web Connection is especially useful for fast, on-demand access to terminal servers by both users and administrators.

Ability to be embedded in Web pages or launched in separate pages - Using the functionality of Internet Explorer, Remote Desktop sessions can be embedded in an existing Web page, or launched in a separate Internet Explorer window. A Web site administrator can create simple scripting code that allows users to launch multiple Remote Desktop sessions from the same Web page, or start multiple Remote Desktop sessions within a single Web page.

Programmability - As with any ActiveX control or COM object, many applications such as Internet Explorer or Visual Basic, and Visual C++ development systems can insert and set properties on the Remote Desktop Web Connection. The Web site author or programmer can write scripts that communicate between an application running on the desktop and a Terminal Services-hosted application using the Remote Desktop Web Connection and the Remote Desktop Protocol virtual channel architecture.

Remote Desktop Web Connection Security - The Remote Desktop Web Connection is a high-encryption, Remote Desktop Protocol (RDP) 5.0 client and uses RSA Security’s RC4 cipher with a key strength of 40-, 56-, or 128-bit, as determined by the server to which it is connecting. The Remote Desktop Web Connection uses the well-known RDP TCP port (3389) to communicate to the server. Unlike some other display protocols, which send data over the network using clear text or with an easily decodable "scrambling" algorithm, Remote Desktop Web Connection's built-in encryption makes it safe to use over any network - including the Internet - as the protocol cannot be easily sniffed to discover passwords and other sensitive data.

To install Remote Desktop Web Connection

1. Open Add or Remove Programs in Control Panel.
2. Click Add/Remove Windows Components.
3. Select Internet Information Services, and then click Details.
4. In the Subcomponents of Internet Information Services list, select World Wide Web Service, and then click Details.
5. In the Subcomponents for World Wide Web Service list, click the Remote Desktop Web Connection check box, and then click OK.
6. In the Windows Components Wizard, click Next.
7. Open Internet Services Manager. run "
%systemroot%\system32\inetsrv\iis.msc"
8. Expand the folder hierarchy until you reach the local computer name\Web Sites\Default Web Site\tsweb folder.
9. Right-click the tsweb folder and then click Properties.
10. Click the Directory Security tab on the Properties dialog box.
11. In Anonymous access and authentication control, click Edit.
12. Check the Anonymous access check box on the Authentication Methods dialog box, and then click OK twice.

To connect to another computer using Remote Desktop Web Connection

1. Ensure that Remote Desktop Web Connection is installed and running on the Web server.
2. Ensure that your client computer has an active network connection and that the WINS server service (or other name resolution method) is functioning.
3. On your client computer, start Microsoft Internet Explorer.
4. In the Address box, type the Uniform Resource Locator (URL) for the home directory of the Web server hosting Remote Desktop Web Connection.
5. The URL is "http://" followed by the Windows Networking name of your server, followed by the path of the directory containing the Remote Desktop Web Connection files (default = /Tsweb/). (Note the forward slash marks.) For example, if your Web server is registered with the WINS server as "Admin1", in the Address box you type: http://admin1/tsweb/, and then press ENTER. The Remote Desktop Web Connection page appears on the screen.

6. In Server, type the name of the remote computer to which you want to connect.
7. Optionally, specify the screen size and logon information for your connection.
8. Click Connect.

9. After you supply your username and password the Windows Server 2003 desktop appears and you can begin to work.


Source : http://www.headtreez.com/site/JohnsHeadTree/450b1b8f-0739-4fb8-b0b1-9130b57c3035
Continue Reading...

Monday, December 14, 2009

How do I Use Multiple Screens on One Terminal over ssh session?

Most of the time GUI is not available on remote Linux system, you login over ssh and start to work, if you need to run two or three task at a time, you login over ssh two or three times. However, with screen windows manager utility you can run multiple terminals at the same time from single console login over ssh session (UNIX guru uses the term called multiplexing for this concept). Any seasoned Linux admin should be aware of this nifty tool :)

Install screen if it is not installed under Debian Linux
Type the following command:
# apt-get install screen

FreeBSD user can use ports to install screen
# cd /usr/ports/misc/screen
# make install clean

Login to remote server over ssh
$ ssh me@myserver.com

(C) Start screen session. You can name your window/session (1 is name of session):
$ screen -S 1

Let us start pine mail reader on first session or window.
$ pine

(D) Next you would like to download something from ftp/http site while you are reading emails. You need to create another screen window by pressing special key combination. Press CTRL + a followed by c key (first hit CTRL+a, releases both keys and press c). As soon as you hit 'c' you will get new shell prompt at console. Now use wget to download belenix.iso.bz2 (Solaris live CD) from net: $ wget http://www.genunix.org/distributions/belenix_site/binfiles/belenix.iso.bz2

(E) But how do I switch between these two tasks?
Switching between windows is the specialty of screen utility. So to switch between pine and wget window (or session) press CTRL+a followed by n key (first hit CTRL+a, releases both keys and press n).

To list all windows use the command CTRL+a followed by " key (first hit CTRL+a, releases both keys and press " ).

To switch to window by number use the command CTRL+a followed by ' (first hit CTRL+a, releases both keys and press ' it will prompt for window number).

Common screen commands
screen command Task
Ctrl+a c Create new window

Ctrl+a k Kill the current window / session
Ctrl+a w List all windows
Ctrl+a 0-9 Go to a window numbered 0 9, use Ctrl+a w to see number
Ctrl+a Ctrl+a Toggle / switch between the current and previous window
Ctrl+a S Split terminal horizontally into regions and press Ctrl+a c to create new window there
Ctrl+a :resize Resize region
Ctrl+a :fit Fit screen size to new terminal size. You can also hit Ctrl+a F for the the same task
Ctrl+a :remove Remove / delete region. You can also hit Ctrl+a X for the same taks
Ctrl+a tab Move to next region
Ctrl+a D (Shift-d) Power detach and logout
Ctrl+a d Detach but keep shell window open
Ctrl-a Ctrl-\ Quit screen
Ctrl-a ? Display help screen i.e. display a list of commands

Suggested readings:
See screen command man page for further details:
man screen

Source : http://www.cyberciti.biz/tips/linux-screen-command-howto.html
Continue Reading...