bom galera a funçao getenv da biblioteca stdlib.h e equivalente ao $_SERVER do php, ela permite pegar algumas informaçao do cliente ou do servidor como ip, user agent etc
by hacker fts315
- Código:
#include <stdio.h>
#include <stdlib.h>
int main()
{
printf("Content-type: text/html \n\n");
printf("IP Cliente: %s <br>",getenv("REMOTE_ADDR"));
printf("Agente: %s <br>",getenv("HTTP_USER_AGENT"));
}
by hacker fts315