Search in sources :

Example 6 with AppsSAML20Details

use of org.maxkey.entity.apps.AppsSAML20Details in project MaxKey by dromara.

the class AppsSaml20DetailsService method getAppDetails.

public AppsSAML20Details getAppDetails(String id, boolean cached) {
    AppsSAML20Details details = null;
    if (cached) {
        details = detailsCache.getIfPresent(id);
        if (details == null) {
            details = getMapper().getAppDetails(id);
            detailsCache.put(id, details);
        }
    } else {
        details = getMapper().getAppDetails(id);
    }
    return details;
}
Also used : AppsSAML20Details(org.maxkey.entity.apps.AppsSAML20Details)

Example 7 with AppsSAML20Details

use of org.maxkey.entity.apps.AppsSAML20Details in project MaxKey by dromara.

the class SAML20DetailsController method forwardAdd.

@RequestMapping(value = { "/forwardAdd" })
public ModelAndView forwardAdd() {
    ModelAndView modelAndView = new ModelAndView("apps/saml20/appAdd");
    AppsSAML20Details saml20Details = new AppsSAML20Details();
    saml20Details.setSecret(ReciprocalUtils.generateKey(""));
    saml20Details.setProtocol(ConstsProtocols.SAML20);
    saml20Details.setId(saml20Details.generateId());
    modelAndView.addObject("model", saml20Details);
    return modelAndView;
}
Also used : AppsSAML20Details(org.maxkey.entity.apps.AppsSAML20Details) ModelAndView(org.springframework.web.servlet.ModelAndView) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Aggregations

AppsSAML20Details (org.maxkey.entity.apps.AppsSAML20Details)7 RequestMapping (org.springframework.web.bind.annotation.RequestMapping)4 KeyStore (java.security.KeyStore)3 HashMap (java.util.HashMap)2 AuthnRequestInfo (org.maxkey.authz.saml.common.AuthnRequestInfo)2 MessageDecodingException (org.opensaml.ws.message.decoder.MessageDecodingException)2 SecurityException (org.opensaml.xml.security.SecurityException)2 ValidationException (org.opensaml.xml.validation.ValidationException)2 ModelAndView (org.springframework.web.servlet.ModelAndView)2 Operation (io.swagger.v3.oas.annotations.Operation)1 ByteArrayInputStream (java.io.ByteArrayInputStream)1 InputStream (java.io.InputStream)1 HttpServletResponse (javax.servlet.http.HttpServletResponse)1 SigninPrincipal (org.maxkey.authn.SigninPrincipal)1 TrustResolver (org.maxkey.authz.saml.common.TrustResolver)1 IdentityProviderAuthenticationException (org.maxkey.authz.saml20.consumer.spring.IdentityProviderAuthenticationException)1 ServiceProviderAuthenticationException (org.maxkey.authz.saml20.consumer.spring.ServiceProviderAuthenticationException)1 AuthnResponseGenerator (org.maxkey.authz.saml20.provider.xml.AuthnResponseGenerator)1 Response (org.opensaml.saml2.core.Response)1 Endpoint (org.opensaml.saml2.metadata.Endpoint)1