X-Git-Url: http://www.project-moonshot.org/gitweb/?p=shibboleth%2Fsp.git;a=blobdiff_plain;f=shibsp%2Fhandler%2Fimpl%2FShib1SessionInitiator.cpp;h=38fb2d301bdd53f03c7d486108b4f83f2b8dc05e;hp=8d5e0653f0a5df258912ce99d1f9222e8b7203c1;hb=4927f4cf1ef86bd5ad3f200ac650a08b1f5da40a;hpb=e5917b2d3067fe20087ed1901a1908b5cb4435a0 diff --git a/shibsp/handler/impl/Shib1SessionInitiator.cpp b/shibsp/handler/impl/Shib1SessionInitiator.cpp index 8d5e065..38fb2d3 100644 --- a/shibsp/handler/impl/Shib1SessionInitiator.cpp +++ b/shibsp/handler/impl/Shib1SessionInitiator.cpp @@ -66,7 +66,7 @@ namespace shibsp { void setParent(const PropertySet* parent); void receive(DDF& in, ostream& out); - pair run(SPRequest& request, const char* entityID=NULL, bool isHandler=true) const; + pair run(SPRequest& request, string& entityID, bool isHandler=true) const; private: pair doRequest( @@ -103,10 +103,10 @@ void Shib1SessionInitiator::setParent(const PropertySet* parent) } } -pair Shib1SessionInitiator::run(SPRequest& request, const char* entityID, bool isHandler) const +pair Shib1SessionInitiator::run(SPRequest& request, string& entityID, bool isHandler) const { // We have to know the IdP to function. - if (!entityID || !*entityID) + if (entityID.empty()) return make_pair(false,0L); string target; @@ -162,16 +162,16 @@ pair Shib1SessionInitiator::run(SPRequest& request, const char* entit target = option; } - m_log.debug("attempting to initiate session using Shibboleth with provider (%s)", entityID); + m_log.debug("attempting to initiate session using Shibboleth with provider (%s)", entityID.c_str()); if (SPConfig::getConfig().isEnabled(SPConfig::OutOfProcess)) - return doRequest(app, request, entityID, ACSloc.c_str(), target); + return doRequest(app, request, entityID.c_str(), ACSloc.c_str(), target); // Remote the call. DDF out,in = DDF(m_address.c_str()).structure(); DDFJanitor jin(in), jout(out); in.addmember("application_id").string(app.getId()); - in.addmember("entity_id").string(entityID); + in.addmember("entity_id").string(entityID.c_str()); in.addmember("acsLocation").string(ACSloc.c_str()); if (!target.empty()) in.addmember("RelayState").string(target.c_str());