Monday, October 5, 2009

A Virus Program to Disable USB Ports

Virus to disable USB portsIn this post I will show how to create a simple virus that disables/blocks the USB ports on the computer (PC). As usual I use my favorite C programming language to create this virus. Anyone with a basic knowledge of C language should be able to understand the working of this virus program.

Once this virus is executed it will immediately disable all the USB ports on the computer. As a result the you’ll will not be able to use your pen drive or any other USB peripheral on the computer. The source code for this virus is available for download. You can test this virus on your own computer without any worries since I have also given a program to re-enable all the USB ports.

1. Download the USB_Block.rar file on to your computer.

2. It contains the following 4 files.

  • block_usb.c (source code)
  • unblock_usb.c (source code)

3. You need to compile them before you can run it. A step-by-step procedure to compile C programs is given in my post - How to Compile C Programs.

3. Upon compilation of block_usb.c you get block_usb.exe which is a simple virus that will block (disable) all the USB ports on the computer upon execution (double click).

4. To test this virus, just run the block_usb.exe file and insert a USB pen drive (thumb drive). Now you can see that your pen drive will never get detected. To re-enable the USB ports just run the unblock_usb.exe (you need to compile unblock_usb.c) file. Now insert the pen drive and it should get detected.

5. You can also change the icon of this file to make it look like a legitimate program. For more details on this refer my post – How to Change the ICON of an EXE file (This step is also optional).

I hope you like this post. Please pass your comments.

Monday, September 28, 2009

Counter Strike 2009 Lag,LOSS,Choke Problems Solved

Counter Strike 2009 Lag,LOSS,Choke Problems Solved !

What is Tickrate?
Valve explains Tickrate as: "During each tick, the server processes incoming user commands, runs a physical simulation step, checks the game rules, and updates all object states. After simulating a tick, the server decides if any client needs a world update and takes a snapshot of the current world state if necessary. A higher tickrate increases the simulation precision, but also requires more CPU power and available bandwidth on both server and client." DONT CONFUSE IT WITH sys_ticrate

What is use of good tickrate ?
Sometimes you may have heard players saying that their bullets dont register or they are framing.Sometimes you may shoot some players behind a player & still able to hit him a headshot.This all happens if u have low ticrate server.

What is tickrate of my server ?
When your server is running, type "sv_maxupdaterate" in console, it will tell you the tickrate of your server.
Commonly used tickrates are 30 or 60 or 101 but it can lie anywhere between 20-100

You must be thinking that if 101 ticrate server gives better performance why doont everyone run 101 tickrate server
Answer is running server on high tickrate costs more resources & bandwidth on both server & client sides

When play on a 30 tickrate server, type 'net_graph 3' in console.
Click Here
As you can see that 6.50 k/s is the bandwidth being used
on a 101 tickrate server bandwidth usage will be much more
Dont waste your time running a server if you dont have adequate bandwidth
To run a good server with 101 tickrate you need 1Mbits/s upload and download bandwidth

How to set tickrate of your server ?
Open you server's cstrike\server.cfg

For 101 Tickrate---
Change these values
sv_minupdaterate 10
sv_minupdaterate 101
sv_minrate 0
sv_maxrate 25000
fps_max 101
sys_ticrate 250

For 60 Tickrate---
Change these values
sv_minupdaterate 10
sv_minupdaterate 60
sv_minrate 0
sv_maxrate 12000
fps_max 101
sys_ticrate 250

For 30 Tickrate---
Change these values
sv_minupdaterate 10
sv_minupdaterate 30
sv_minrate 0
sv_maxrate 7000
fps_max 101
sys_ticrate 250

A simple advice is that you must not install HL Booster.It just screws up server.

We did some research on it and found that it only controls sys_ticrate value in realtime
so if u put sys_ticrate 250 your server will run very fine
If you increase this value above 250 you wont see any effect on Internet but on LAN it will.

NOTE:Achieving 101 tickrate on a server is not possible without Pingboosting. Ping boosting is done on server side
But it can be done only on Linux not on windows.

Where can i change tickrate of server?
Server's Tickrate cant be changed via RCON or any other tool
You need to have access to server console

That was a explanation for Host or Server

Now comes Client or Player

If u play on a 101 tickrate server with settings those of 30 tickrate you wont see any difference
You should always play on these settings...these should be put in config.cfg of your game
cl_cmdrate 101
cl_updaterate 101
rate 25000
cl_interp 0.1
fps_max 101

If u get choke even if you are using these settings, then it is possible that server is running on low tickrate
Try lowering your cl_updaterate to 60 & see if choke is decreased
Do same untill you have 0 choke
That was how to solve choke problem

If u have loss problem,that means there is some packet loss between you and server
This indicate some network connection problem either with your connection or server's

If you are only one who gets loss, it is problem with your connection

I Hope it solves your lag problem to certain extent.