Wednesday, March 14, 2007

Wireless zero config service in winxp

Another example that proves Privacy and Security can not stay along with Convenience, the wireless zero config service in window xp. With this service turn on, an xp machine will automatically search for network from its preferred network list, which was build in the past which the machine used to connect to the internet. To find this network, the machine will periodically send out prone request that with SSID from teh preferred list in order to try connect the the network. The problem is, if someone sniffing and catch this wi-fi packet, he would know all these SSID, which is not cool at all.

Yeah, it is true that the wirelss zero configure brought convenience that it helps a user to reconnect to the internet automatically; however, it can also expose all the SSID to the outside world. It would be better to turn this service off.

Download this update from microsoft to turn it off: Wireless Client Update for Windows XP with Service Pack 2

Monday, March 12, 2007

To find prime number


public class prime{
public static void main(String args[]){
for(int i = 0; i <= 100; i++){
if(isPrime(i))
System.out.println(i);
}
}

public static boolean isPrime(int checkNumber) {
double root = Math.sqrt(checkNumber);
for (int i = 2; i <= root; i++) {
if (checkNumber % i == 0)
return false;
}
return true;
}
}

Wednesday, March 07, 2007

Check if a string is parlidrom


bool isparlidrom( char* str){

if(str == null){
return false
}
char* endStr = str;
while(*endStr != '\0'){
endStr++;
}
endStr--;

while(endStr > str){
if( *endStr ! = *str){
return false;
}
endStr--;
str++;
}
return true;
}

Monday, March 05, 2007

Open wireless access point

Last time I went to Toronto with my friend and we discovered that there are so many open wireless access point in downtown Toronto. I am glad that people were such generous that they willing to share bandwidth with others; however, open WAP may post serious security issue.
Why I saying this is because WAP acts like a hub in the network, anyone who put a "packet sniffer" onto the wire can monitor all traffic going in and out. The result is everything you do will be transparent.
I believe that it is necessary to encrypt our wireless network once we set the network up using WEP or WPA. But what if in the airport or coffee shop, where wireless connection is available but not encrypted? One approach is to turn on your local firewall. And possibly to use SSL or VPN.

Stwitch vs. Hubs

Switch and Hub is very similar but they are in fact different. Switch is more intelligence and bandwidth efficiency than hubs.

When packets get to a hub, a hub COPY and BROADCAST all received traffic.




When packets get to a switch, a switch only forward the traffic to its destination.

Thursday, March 01, 2007

Hardware DEP

Turn your hardware DEP on to protect your computer. DEP --> Data Executable Prevention. Nowadays, many computers has hardware DEP build=in; however, not many of us know about it. With DEP enable, a computer can at some point prevent from being control by malicious hackers. One example use of DEP is to make the stack as non-executable such that prevent buffer overflow exploit.