From: Alan T. DeKok Date: Thu, 4 Jun 2015 14:49:19 +0000 (-0400) Subject: No need for WARNING in message X-Git-Tag: release_3_0_9~278 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5af66f4c46b6f85803cc5790813fe4aab5120fc8;p=thirdparty%2Ffreeradius-server.git No need for WARNING in message --- diff --git a/src/lib/radius.c b/src/lib/radius.c index 4160da76500..02ef5a2c1c5 100644 --- a/src/lib/radius.c +++ b/src/lib/radius.c @@ -2266,7 +2266,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * "The minimum length is 20 ..." */ if (packet->data_len < RADIUS_HDR_LEN) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: too short (received %zu < minimum %d)", + fr_strerror_printf("Malformed RADIUS packet from host %s: too short (received %zu < minimum %d)", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2290,7 +2290,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) */ if ((hdr->code == 0) || (hdr->code >= FR_MAX_PACKET_CODE)) { - fr_strerror_printf("WARNING: Bad RADIUS packet from host %s: unknown packet code %d", + fr_strerror_printf("Bad RADIUS packet from host %s: unknown packet code %d", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2322,7 +2322,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * "The minimum length is 20 ..." */ if (totallen < RADIUS_HDR_LEN) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: too short (length %zu < minimum %d)", + fr_strerror_printf("Malformed RADIUS packet from host %s: too short (length %zu < minimum %d)", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2355,7 +2355,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * i.e. No response to the NAS. */ if (packet->data_len < totallen) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: received %zu octets, packet length says %zu", + fr_strerror_printf("Malformed RADIUS packet from host %s: received %zu octets, packet length says %zu", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2401,7 +2401,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * attribute header. */ if (count < 2) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: attribute header overflows the packet", + fr_strerror_printf("Malformed RADIUS packet from host %s: attribute header overflows the packet", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr))); @@ -2413,7 +2413,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * Attribute number zero is NOT defined. */ if (attr[0] == 0) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: Invalid attribute 0", + fr_strerror_printf("Malformed RADIUS packet from host %s: Invalid attribute 0", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr))); @@ -2426,7 +2426,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * fields. Anything shorter is an invalid attribute. */ if (attr[1] < 2) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: attribute %u too short", + fr_strerror_printf("Malformed RADIUS packet from host %s: attribute %u too short", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2440,7 +2440,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * attribute, it's a bad packet. */ if (count < attr[1]) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: attribute %u data overflows the packet", + fr_strerror_printf("Malformed RADIUS packet from host %s: attribute %u data overflows the packet", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2466,7 +2466,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) case PW_MESSAGE_AUTHENTICATOR: if (attr[1] != 2 + AUTH_VECTOR_LEN) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: Message-Authenticator has invalid length %d", + fr_strerror_printf("Malformed RADIUS packet from host %s: Message-Authenticator has invalid length %d", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2495,7 +2495,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * If not, we complain, and throw the packet away. */ if (count != 0) { - fr_strerror_printf("WARNING: Malformed RADIUS packet from host %s: packet attributes do NOT exactly fill the packet", + fr_strerror_printf("Malformed RADIUS packet from host %s: packet attributes do NOT exactly fill the packet", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr))); @@ -2510,7 +2510,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) */ if ((fr_max_attributes > 0) && (num_attributes > fr_max_attributes)) { - fr_strerror_printf("WARNING: Possible DoS attack from host %s: Too many attributes in request (received %d, max %d are allowed).", + fr_strerror_printf("Possible DoS attack from host %s: Too many attributes in request (received %d, max %d are allowed).", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)), @@ -2531,7 +2531,7 @@ bool rad_packet_ok(RADIUS_PACKET *packet, int flags, decode_fail_t *reason) * Message-Authenticator attributes. */ if (require_ma && !seen_ma) { - fr_strerror_printf("WARNING: Insecure packet from host %s: Packet does not contain required Message-Authenticator attribute", + fr_strerror_printf("Insecure packet from host %s: Packet does not contain required Message-Authenticator attribute", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr))); @@ -4057,7 +4057,7 @@ int rad_decode(RADIUS_PACKET *packet, RADIUS_PACKET *original, char host_ipaddr[128]; pairfree(&head); - fr_strerror_printf("WARNING: Possible DoS attack from host %s: Too many attributes in request (received %d, max %d are allowed).", + fr_strerror_printf("Possible DoS attack from host %s: Too many attributes in request (received %d, max %d are allowed).", inet_ntop(packet->src_ipaddr.af, &packet->src_ipaddr.ipaddr, host_ipaddr, sizeof(host_ipaddr)),