X-Git-Url: http://www.project-moonshot.org/gitweb/?p=shibboleth%2Fcpp-opensaml.git;a=blobdiff_plain;f=saml%2Fsaml2%2Fbinding%2Fimpl%2FSAML2POSTEncoder.cpp;h=6fc4bc6ab738e38fa13c8f4cb75a0dac0e80f02a;hp=146621cbf1d292fd6e8cf87d4d79a547b7924171;hb=07dbbcf3a8fc0aba6fefe741f1760442a0a6ea65;hpb=425c0161d1296040504e2696a3c46e3c5caaf6b7 diff --git a/saml/saml2/binding/impl/SAML2POSTEncoder.cpp b/saml/saml2/binding/impl/SAML2POSTEncoder.cpp index 146621c..6fc4bc6 100644 --- a/saml/saml2/binding/impl/SAML2POSTEncoder.cpp +++ b/saml/saml2/binding/impl/SAML2POSTEncoder.cpp @@ -29,6 +29,7 @@ #include #include #include +#include #include #include #include @@ -221,6 +222,12 @@ long SAML2POSTEncoder::encode( stringstream s; engine->run(infile, s, pmap); genericResponse.setContentType("text/html"); + HTTPResponse* httpResponse = dynamic_cast(&genericResponse); + if (httpResponse) { + httpResponse->setResponseHeader("Expires", "01-Jan-1997 12:00:00 GMT"); + httpResponse->setResponseHeader("Cache-Control", "no-cache, no-store, must-revalidate, private"); + httpResponse->setResponseHeader("Pragma", "no-cache"); + } long ret = genericResponse.sendResponse(s); // Cleanup by destroying XML.