C networking

Can anybody help me regarding networking using c language

i know how to capture the packets and to verify it`s protocol destination and source ip etc.

Can anybody help me to direct a packet coming to an ip to some other ip of my choice ........

Hope reply
pleaseeeeeeeee....................