Package org.opensaml.ws.transport.http

Examples of org.opensaml.ws.transport.http.HttpServletResponseAdapter


        expect(request.getContextPath()).andReturn("/");
        replyMock();

        samlContext = contextProvider.getLocalAndPeerEntity(request, response);
        samlContext.setInboundMessageTransport(new HttpServletRequestAdapter(request));
        samlContext.setOutboundMessageTransport(new HttpServletResponseAdapter(response, false));

        verifyMock();

        expect(response.getOutputStream()).andReturn(output).anyTimes();
View Full Code Here


        metadata.setIdpDiscoveryURL("http://test.fi/idpDisco/");
        context.setLocalExtendedMetadata(metadata);
        context.setLocalEntityId("localId");

        context.setInboundMessageTransport(new HttpServletRequestAdapter(request));
        context.setOutboundMessageTransport(new HttpServletResponseAdapter(response, false));

        response.sendRedirect("http://test.fi/idpDisco/?entityID=localId&returnIDParam=idp");

        replayMock();
        entryPoint.initializeDiscovery(context);
View Full Code Here

        metadata.setIdpDiscoveryURL("test.fi/idpDisco/");
        context.setLocalExtendedMetadata(metadata);
        context.setLocalEntityId("localId");

        context.setInboundMessageTransport(new HttpServletRequestAdapter(request));
        context.setOutboundMessageTransport(new HttpServletResponseAdapter(response, false));

        replayMock();
        entryPoint.initializeDiscovery(context);
        verifyMock();
View Full Code Here

        replyMock();

        samlContext = contextProvider.getLocalAndPeerEntity(request, response);
        samlContext.setInboundMessageTransport(new HttpServletRequestAdapter(request));
        samlContext.setOutboundMessageTransport(new HttpServletResponseAdapter(response, false));

        verifyMock();

        expect(response.getOutputStream()).andReturn(output).anyTimes();
View Full Code Here

    }

    protected void populateGenericContext(HttpServletRequest request, HttpServletResponse response, SAMLMessageContext context) throws MetadataProviderException {

        HttpServletRequestAdapter inTransport = new HttpServletRequestAdapter(request);
        HttpServletResponseAdapter outTransport = new HttpServletResponseAdapter(response, request.isSecure());

        // Store attribute which cannot be located from InTransport directly
        request.setAttribute(org.springframework.security.saml.SAMLConstants.LOCAL_CONTEXT_PATH, request.getContextPath());

        context.setMetadataProvider(metadata);
View Full Code Here

                }
            }
            prepareResponse(samlResponse, model);

            final BasicSAMLMessageContext messageContext = new BasicSAMLMessageContext();
            messageContext.setOutboundMessageTransport(new HttpServletResponseAdapter(response, request.isSecure()));
            messageContext.setOutboundSAMLMessage(samlResponse);
            this.encoder.encode(messageContext);
        } catch (final Exception e) {
            logger.error("Error generating SAML response for service {}.", serviceId);
            throw e;
View Full Code Here

TOP

Related Classes of org.opensaml.ws.transport.http.HttpServletResponseAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.