X-Git-Url: http://git.madism.org/?a=blobdiff_plain;f=pop%2Fpop_auth.c;h=df6de737565268783bcfb59ef15f37a1f71b03c6;hb=2f928128cac1c0bc2ce2465671e5abe2a9671d28;hp=749981603c36296022271ec9fb0b84c82d97dc78;hpb=203e950e3d3c76795fa49895d040f732adad2049;p=apps%2Fmadmutt.git diff --git a/pop/pop_auth.c b/pop/pop_auth.c index 7499816..df6de73 100644 --- a/pop/pop_auth.c +++ b/pop/pop_auth.c @@ -106,11 +106,11 @@ static pop_auth_res_t pop_auth_sasl (POP_DATA * pop_data, const char *method) break; #ifdef USE_SASL2 - if (!mutt_strncmp (inbuf, "+ ", 2) + if (!safe_strncmp (inbuf, "+ ", 2) && sasl_decode64 (inbuf, strlen (inbuf), buf, LONG_STRING - 1, &len) != SASL_OK) #else - if (!mutt_strncmp (inbuf, "+ ", 2) + if (!safe_strncmp (inbuf, "+ ", 2) && sasl_decode64 (inbuf, strlen (inbuf), buf, &len) != SASL_OK) #endif { @@ -153,7 +153,7 @@ static pop_auth_res_t pop_auth_sasl (POP_DATA * pop_data, const char *method) if (rc != SASL_OK) goto bail; - if (!mutt_strncmp (inbuf, "+OK", 3)) { + if (!safe_strncmp (inbuf, "+OK", 3)) { mutt_sasl_setup_conn (pop_data->conn, saslconn); return POP_A_SUCCESS; } @@ -162,7 +162,7 @@ bail: sasl_dispose (&saslconn); /* terminate SASL sessoin if the last responce is not +OK nor -ERR */ - if (!mutt_strncmp (inbuf, "+ ", 2)) { + if (!safe_strncmp (inbuf, "+ ", 2)) { snprintf (buf, sizeof (buf), "*\r\n"); if (pop_query (pop_data, buf, sizeof (buf)) == PQ_NOT_CONNECTED) return POP_A_SOCKET;