X-Git-Url: http://lists.indexdata.com/cgi-bin?a=blobdiff_plain;f=src%2Ffilter_auth_simple.cpp;h=d394777f94d99a276e97e78d61b91fc01620c75f;hb=321a33889c06bb119e16843edc3f56c4d472b7af;hp=d974217ddc145119ec8c63b2ca0596020198f0c6;hpb=637a685d61a9ff0e3f398a59da426979815c4d68;p=metaproxy-moved-to-github.git diff --git a/src/filter_auth_simple.cpp b/src/filter_auth_simple.cpp index d974217..d394777 100644 --- a/src/filter_auth_simple.cpp +++ b/src/filter_auth_simple.cpp @@ -1,4 +1,4 @@ -/* $Id: filter_auth_simple.cpp,v 1.23 2007-05-09 21:23:09 adam Exp $ +/* $Id: filter_auth_simple.cpp,v 1.25 2008-02-20 15:07:51 adam Exp $ Copyright (c) 2005-2007, Index Data. This file is part of Metaproxy. @@ -76,7 +76,7 @@ static void die(std::string s) { throw mp::filter::FilterException(s); } // Read XML config.. Put config info in m_p. -void mp::filter::AuthSimple::configure(const xmlNode * ptr) +void mp::filter::AuthSimple::configure(const xmlNode * ptr, bool test_only) { std::string userRegisterName; std::string targetRegisterName; @@ -357,8 +357,8 @@ void yf::AuthSimple::check_targets(mp::Package & package) const std::list authorisedTargets = m_p->targetsByUser[user]; std::list targets; - Z_OtherInformation *otherInfo = initReq->otherInfo; - mp::util::get_vhost_otherinfo(otherInfo, targets); + Z_OtherInformation **otherInfo = &initReq->otherInfo; + mp::util::remove_vhost_otherinfo(otherInfo, targets); // Check each of the targets specified in the otherInfo package std::list::iterator i; @@ -381,9 +381,8 @@ void yf::AuthSimple::check_targets(mp::Package & package) const YAZ_BIB1_ACCESS_TO_SPECIFIED_DATABASE_DENIED, // ### It would be better to use the Z-db name "all databases"); - mp::odr odr; - mp::util::set_vhost_otherinfo(&otherInfo, odr, targets); + mp::util::set_vhost_otherinfo(otherInfo, odr, targets); package.move(); }