Mercurial > pidgin
comparison libpurple/protocols/jabber/jabber.c @ 30929:b07841f6cd15
jabber: Print out plaintext-equivalent passwords when PURPLE_UNSAFE_DEBUG is set.
Refs #a14565.
author | Paul Aurich <paul@darkrain42.org> |
---|---|
date | Sat, 20 Nov 2010 02:42:59 +0000 |
parents | bc0bccdbc28f |
children | a8cc50c2279f |
comparison
equal
deleted
inserted
replaced
30927:02c0a2640fc2 | 30929:b07841f6cd15 |
---|---|
475 if(strcmp(data, "\t")) { | 475 if(strcmp(data, "\t")) { |
476 const char *username; | 476 const char *username; |
477 char *text = NULL, *last_part = NULL, *tag_start = NULL; | 477 char *text = NULL, *last_part = NULL, *tag_start = NULL; |
478 | 478 |
479 /* Because debug logs with plaintext passwords make me sad */ | 479 /* Because debug logs with plaintext passwords make me sad */ |
480 if(js->state != JABBER_STREAM_CONNECTED && | 480 if (!purple_debug_is_unsafe() && js->state != JABBER_STREAM_CONNECTED && |
481 /* Either <auth> or <query><password>... */ | 481 /* Either <auth> or <query><password>... */ |
482 (((tag_start = strstr(data, "<auth ")) && | 482 (((tag_start = strstr(data, "<auth ")) && |
483 strstr(data, "xmlns='" NS_XMPP_SASL "'")) || | 483 strstr(data, "xmlns='" NS_XMPP_SASL "'")) || |
484 ((tag_start = strstr(data, "<query ")) && | 484 ((tag_start = strstr(data, "<query ")) && |
485 strstr(data, "xmlns='jabber:iq:auth'>") && | 485 strstr(data, "xmlns='jabber:iq:auth'>") && |