Changeset 1536
- Timestamp:
- 01/23/08 22:15:12 (7 months ago)
- Files:
-
- honeytrap/trunk/src/attack.c (modified) (3 diffs)
- honeytrap/trunk/src/dynsrv.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
honeytrap/trunk/src/attack.c
r1490 r1536 36 36 37 37 38 Attack *new_virtattack(struct in_addr l_addr, struct in_addr r_addr, uint16_t l_port, uint16_t r_port, uint16_t proto) {38 Attack *new_virtattack(struct in_addr r_addr, struct in_addr l_addr, uint16_t r_port, uint16_t l_port, uint16_t proto) { 39 39 Attack *a; 40 40 41 if ((a = new_attack( l_addr, r_addr, l_port, r_port, proto)) == NULL) return(NULL);41 if ((a = new_attack(r_addr, l_addr, r_port, l_port, proto)) == NULL) return(NULL); 42 42 43 43 a->virtual = 1; … … 47 47 48 48 49 Attack *new_attack(struct in_addr l_addr, struct in_addr r_addr, uint16_t l_port, uint16_t r_port, uint16_t proto) {49 Attack *new_attack(struct in_addr r_addr, struct in_addr l_addr, uint16_t r_port, uint16_t l_port, uint16_t proto) { 50 50 Attack *a; 51 51 … … 102 102 103 103 if (!a_size) { 104 addr = (struct in_addr *) &(a->a_conn. l_addr);104 addr = (struct in_addr *) &(a->a_conn.r_addr); 105 105 logmsg(LOG_NOTICE, 1, " * %u/%s\t No bytes received from %s:%u.\n", 106 106 (uint16_t) a->a_conn.l_port, PROTO(a->a_conn.protocol), 107 107 inet_ntoa(*addr), a->a_conn.r_port); 108 108 } else { 109 addr = (struct in_addr *) &(a->a_conn. l_addr);109 addr = (struct in_addr *) &(a->a_conn.r_addr); 110 110 logmsg(LOG_NOTICE, 1, " * %u/%s\t %d bytes attack string from %s:%u.\n", 111 111 (uint16_t) a->a_conn.l_port, PROTO(a->a_conn.protocol), a_size, honeytrap/trunk/src/dynsrv.c
r1490 r1536 291 291 292 292 /* initialize attack record */ 293 if ((attack = new_attack(cliaddr.sin_addr, srvaddr.sin_addr, ntohs(srvaddr.sin_port), 0, proto)) == NULL) {293 if ((attack = new_attack(cliaddr.sin_addr, srvaddr.sin_addr, 0, ntohs(srvaddr.sin_port), proto)) == NULL) { 294 294 logmsg(LOG_ERR, 1, "Error - Could not initialize attack record.\n"); 295 295 free(attack);
