Improve rlm_digest debug messages
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Tue, 26 Feb 2013 00:02:50 +0000 (19:02 -0500)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Tue, 26 Feb 2013 00:02:50 +0000 (19:02 -0500)
src/modules/rlm_digest/rlm_digest.c

index 01c21e3..91900c8 100644 (file)
@@ -71,7 +71,7 @@ static int digest_fix(REQUEST *request)
                         *      The attribute type must be valid
                         */
                        if ((p[0] == 0) || (p[0] > 10)) {
-                               RDEBUG("Not formatted as Digest-Attributes");
+                               RDEBUG("Not formatted as Digest-Attributes: TLV type (%u) invalid", (unsigned int) p[0]);
                                return RLM_MODULE_NOOP;
                        }
 
@@ -81,7 +81,7 @@ static int digest_fix(REQUEST *request)
                         *      Too short.
                         */
                        if (attrlen < 3) {
-                               RDEBUG("Not formatted as Digest-Attributes");
+                               RDEBUG("Not formatted as Digest-Attributes: TLV too short");
                                return RLM_MODULE_NOOP;
                        }
 
@@ -89,7 +89,7 @@ static int digest_fix(REQUEST *request)
                         *      Too long.
                         */
                        if (attrlen > length) {
-                               RDEBUG("Not formatted as Digest-Attributes");
+                               RDEBUG("Not formatted as Digest-Attributes: TLV too long)");
                                return RLM_MODULE_NOOP;
                        }