Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Compiling the source code....
- $g++ -std=c++11 main.cpp -o demo -lm -pthread -lgmpxx -lgmp -lreadline 2>&1
- main.cpp: In function �int make_socket(char*, char*)�:
- main.cpp:2:25: error: aggregate �make_socket(char*, char*)::addrinfo hints� has incomplete type and cannot be defined
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:5:40: error: �memset� was not declared in this scope
- memset(&hints, 0, sizeof(hints));
- ^
- main.cpp:6:27: error: �AF_UNSPEC� was not declared in this scope
- hints.ai_family = AF_UNSPEC;
- ^
- main.cpp:7:29: error: �SOCK_STREAM� was not declared in this scope
- hints.ai_socktype = SOCK_STREAM;
- ^
- main.cpp:8:56: error: �getaddrinfo� was not declared in this scope
- if((r=getaddrinfo(host, port, &hints, &servinfo))!=0) {
- ^
- main.cpp:9:25: error: �stderr� was not declared in this scope
- fprintf(stderr, "getaddrinfo: %s\n", gai_strerror(r));
- ^
- main.cpp:9:68: error: �gai_strerror� was not declared in this scope
- fprintf(stderr, "getaddrinfo: %s\n", gai_strerror(r));
- ^
- main.cpp:9:69: error: �fprintf� was not declared in this scope
- fprintf(stderr, "getaddrinfo: %s\n", gai_strerror(r));
- ^
- main.cpp:10:23: error: �exit� was not declared in this scope
- exit(0);
- ^
- main.cpp:12:32: error: �NULL� was not declared in this scope
- for(p = servinfo; p != NULL; p = p->ai_next) {
- ^
- main.cpp:12:43: error: invalid use of incomplete type �struct make_socket(char*, char*)::addrinfo�
- for(p = servinfo; p != NULL; p = p->ai_next) {
- ^
- main.cpp:2:16: error: forward declaration of �struct make_socket(char*, char*)::addrinfo�
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:13:36: error: invalid use of incomplete type �struct make_socket(char*, char*)::addrinfo�
- if((sock = socket(p->ai_family, p->ai_socktype, p->ai_protocol)) == -1) {
- ^
- main.cpp:2:16: error: forward declaration of �struct make_socket(char*, char*)::addrinfo�
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:13:50: error: invalid use of incomplete type �struct make_socket(char*, char*)::addrinfo�
- if((sock = socket(p->ai_family, p->ai_socktype, p->ai_protocol)) == -1) {
- ^
- main.cpp:2:16: error: forward declaration of �struct make_socket(char*, char*)::addrinfo�
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:13:66: error: invalid use of incomplete type �struct make_socket(char*, char*)::addrinfo�
- if((sock = socket(p->ai_family, p->ai_socktype, p->ai_protocol)) == -1) {
- ^
- main.cpp:2:16: error: forward declaration of �struct make_socket(char*, char*)::addrinfo�
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:13:79: error: �socket� was not declared in this scope
- if((sock = socket(p->ai_family, p->ai_socktype, p->ai_protocol)) == -1) {
- ^
- main.cpp:16:35: error: invalid use of incomplete type �struct make_socket(char*, char*)::addrinfo�
- if(connect(sock, p->ai_addr, p->ai_addrlen)==-1) {
- ^
- main.cpp:2:16: error: forward declaration of �struct make_socket(char*, char*)::addrinfo�
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:16:47: error: invalid use of incomplete type �struct make_socket(char*, char*)::addrinfo�
- if(connect(sock, p->ai_addr, p->ai_addrlen)==-1) {
- ^
- main.cpp:2:16: error: forward declaration of �struct make_socket(char*, char*)::addrinfo�
- struct addrinfo hints, *servinfo, *p;
- ^
- main.cpp:16:59: error: �connect� was not declared in this scope
- if(connect(sock, p->ai_addr, p->ai_addrlen)==-1) {
- ^
- main.cpp:17:35: error: �close� was not declared in this scope
- close(sock);
- ^
- main.cpp:22:17: error: �NULL� was not declared in this scope
- if(p == NULL) {
- ^
- main.cpp:24:46: error: �freeaddrinfo� was not declared in this scope
- freeaddrinfo(servinfo);
- ^
- main.cpp:25:25: error: �stderr� was not declared in this scope
- fprintf(stderr, "No connection could be made\n");
- ^
- main.cpp:25:64: error: �fprintf� was not declared in this scope
- fprintf(stderr, "No connection could be made\n");
- ^
- main.cpp:26:23: error: �exit� was not declared in this scope
- exit(0);
- ^
- main.cpp:29:38: error: �freeaddrinfo� was not declared in this scope
- freeaddrinfo(servinfo);
- ^
- main.cpp:30:17: error: �stderr� was not declared in this scope
- fprintf(stderr, "[Connected -> %s:%s]\n", host, port);
- ^
- main.cpp:30:61: error: �fprintf� was not declared in this scope
- fprintf(stderr, "[Connected -> %s:%s]\n", host, port);
- ^
- main.cpp: In function �void attack(char*, char*, int)�:
- main.cpp:46:16: error: �SIGPIPE� was not declared in this scope
- signal(SIGPIPE, &broke);
- ^
- main.cpp:46:31: error: �signal� was not declared in this scope
- signal(SIGPIPE, &broke);
- ^
- main.cpp:51:52: error: �write� was not declared in this scope
- r=write(sockets[x], "\0", 1);
- ^
- main.cpp:53:49: error: �close� was not declared in this scope
- close(sockets[x]);
- ^
- main.cpp:57:33: error: �stderr� was not declared in this scope
- fprintf(stderr, "[%i: Voly Sent]\n", id);
- ^
- main.cpp:57:64: error: �fprintf� was not declared in this scope
- fprintf(stderr, "[%i: Voly Sent]\n", id);
- ^
- main.cpp:59:25: error: �stderr� was not declared in this scope
- fprintf(stderr, "[%i: Voly Sent]\n", id);
- ^
- main.cpp:59:56: error: �fprintf� was not declared in this scope
- fprintf(stderr, "[%i: Voly Sent]\n", id);
- ^
- main.cpp:60:30: error: �usleep� was not declared in this scope
- usleep(300000);
- ^
- main.cpp: In function �void cycle_identity()�:
- main.cpp:66:53: warning: deprecated conversion from string constant to �char*� [-Wwrite-strings]
- int socket = make_socket("localhost", "9050");
- ^
- main.cpp:66:53: warning: deprecated conversion from string constant to �char*� [-Wwrite-strings]
- main.cpp:67:48: error: �write� was not declared in this scope
- write(socket, "AUTHENTICATE \"\"\n", 16);
- ^
- main.cpp:70:25: error: �stderr� was not declared in this scope
- fprintf(stderr, "[%i: cycle_identity -> signal NEWNYM\n", r);
- ^
- main.cpp:70:76: error: �fprintf� was not declared in this scope
- fprintf(stderr, "[%i: cycle_identity -> signal NEWNYM\n", r);
- ^
- main.cpp:71:30: error: �usleep� was not declared in this scope
- usleep(300000);
- ^
- main.cpp: In function �int main(int, char**)�:
- main.cpp:80:25: error: �fork� was not declared in this scope
- if(fork())
- ^
- main.cpp:82:30: error: �usleep� was not declared in this scope
- usleep(200000);
- ^
- main.cpp:84:14: error: �stdin� was not declared in this scope
- getc(stdin);
- ^
- main.cpp:84:19: error: �getc� was not declared in this scope
- getc(stdin);
- ^
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement