[asterisk-commits] rizzo: branch rizzo/astobj2 r47932 - /team/rizzo/astobj2/channels/chan_sip.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Wed Nov 22 10:33:57 MST 2006


Author: rizzo
Date: Wed Nov 22 11:33:56 2006
New Revision: 47932

URL: http://svn.digium.com/view/asterisk?view=rev&rev=47932
Log:
less verbose default...


Modified:
    team/rizzo/astobj2/channels/chan_sip.c

Modified: team/rizzo/astobj2/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/rizzo/astobj2/channels/chan_sip.c?view=diff&rev=47932&r1=47931&r2=47932
==============================================================================
--- team/rizzo/astobj2/channels/chan_sip.c (original)
+++ team/rizzo/astobj2/channels/chan_sip.c Wed Nov 22 11:33:56 2006
@@ -7587,13 +7587,16 @@
 	
 	if (auth) {	/* Add auth header */
 		add_header(&req, authheader, auth);
-		ast_verbose("REGISTER attempt %d to %s@%s, %s: %s\n",
-			r->regattempts, r->username, r->hostname,
-			authheader, auth);
+		if (option_debug > 3)
+			ast_verbose("REGISTER attempt %d to %s@%s, %s: %s\n",
+				r->regattempts, r->username, r->hostname, authheader, auth);
 	} else if (!ast_strlen_zero(r->nonce)) {
 		char digest[1024];
 
-		/* We have auth data to reuse, build a digest header! */
+		/* We have auth data to reuse, build a digest header!
+		 * Actually this doesn't seem terribly useful, as some parties usually
+		 * do not like the old nonce (for good reasons) and challenge us again.
+		 */
 		if (sipdebug)
 			ast_log(LOG_DEBUG, "   >>> Re-using Auth data for %s@%s\n", r->username, r->hostname);
 		ast_string_field_set(p, realm, r->realm);
@@ -7606,9 +7609,9 @@
 		memset(digest,0,sizeof(digest));
 		if(!build_reply_digest(p, SIP_REGISTER, digest, sizeof(digest))) {
 			add_header(&req, "Authorization", digest);
-			ast_verbose("REUSE REGISTER attempt %d to %s@%s, %s: %s\n",
-				r->regattempts, r->username, r->hostname,
-				"Authorization", digest);
+			if (option_debug > 3)
+				ast_verbose("REUSE REGISTER attempt %d to %s@%s, %s: %s\n",
+					r->regattempts, r->username, r->hostname, "Authorization", digest);
 		} else
 			ast_log(LOG_NOTICE, "No authorization available for authentication of registration to %s@%s\n", r->username, r->hostname);
 	



More information about the asterisk-commits mailing list