X-Git-Url: http://git.indexdata.com/?p=yazproxy-moved-to-github.git;a=blobdiff_plain;f=src%2Fyaz-proxy.cpp;h=814c0f89d1f1f385be7be5790833190b601af0af;hp=1d6e22c09adb4133c072b432fbae361b3d3083ea;hb=3481ecb892e17f707a06335f955e65e62be35f30;hpb=dfdff5f2d2825a500d3d27200d2ec32ee063a975 diff --git a/src/yaz-proxy.cpp b/src/yaz-proxy.cpp index 1d6e22c..814c0f8 100644 --- a/src/yaz-proxy.cpp +++ b/src/yaz-proxy.cpp @@ -2819,7 +2819,14 @@ void Yaz_Proxy::handle_incoming_HTTP(Z_HTTP_Request *hreq) m_s2z_stylesheet = 0; Z_IdAuthentication *auth = NULL; - if (srw_pdu->username && srw_pdu->password) + if (srw_pdu->username && !srw_pdu->password) + { + yaz_log(YLOG_LOG, "username: %s\n", srw_pdu->username); + auth = (Z_IdAuthentication *) odr_malloc(m_s2z_odr_init, sizeof(Z_IdAuthentication)); + auth->which = Z_IdAuthentication_open; + auth->u.open = odr_strdup(m_s2z_odr_init, srw_pdu->username); + } + else if (srw_pdu->username && srw_pdu->password) { yaz_log(YLOG_LOG, "username/password: %s/%s\n", srw_pdu->username, srw_pdu->password);