* Check for packets smaller than the packet header.
*/
if (packet->data_len < AUTH_HDR_LEN) {
- librad_log("Malformed RADIUS packet from host %s: too small",
+ librad_log("Malformed RADIUS packet from host %s: too short",
ip_ntoa(host_ipaddr, packet->src_ipaddr));
free(packet->data);
free(packet);
count = totallen - AUTH_HDR_LEN;
while (count > 0) {
if (attr[1] < 2) {
- librad_log("Malformed RADIUS packet from host %s: packet attributes do NOT exactly fill the packet",
- ip_ntoa(host_ipaddr, packet->src_ipaddr));
+ librad_log("Malformed RADIUS packet from host %s: attribute %d too short",
+ ip_ntoa(host_ipaddr, packet->src_ipaddr),
+ attr[0]);
free(packet->data);
free(packet);
return NULL;
continue;
packet = rad_recv(fd);
- if (packet == NULL) continue;
+ if (packet == NULL) {
+ log(L_ERR, "%s", librad_errstr);
+ continue;
+ }
/*
* See if we know this client.