Package org.picketlink.identity.federation.core.exceptions

Examples of org.picketlink.identity.federation.core.exceptions.ProcessingException


        try {
            KeyFactory rsaKeyFactory = KeyFactory.getInstance("rsa");
            RSAPrivateKeySpec kspec = new RSAPrivateKeySpec(bigModulus,bigEx);
            return (RSAPrivateKey) rsaKeyFactory.generatePrivate(kspec);
        } catch (Exception e) {
            throw new ProcessingException(e);
        }
    }
View Full Code Here


        StaxUtil.flush(writer);
    }

    public void write(IDPSSODescriptorType idpSSODescriptor) throws ProcessingException {
        if (idpSSODescriptor == null)
            throw new ProcessingException(logger.nullArgumentError("IDPSSODescriptorType"));

        StaxUtil.writeStartElement(writer, METADATA_PREFIX, JBossSAMLConstants.IDP_SSO_DESCRIPTOR.get(), METADATA_NSURI.get());

        Boolean wantsAuthnRequestsSigned = idpSSODescriptor.isWantAuthnRequestsSigned();
        if (wantsAuthnRequestsSigned != null) {
View Full Code Here

        StaxUtil.flush(writer);
    }

    public void writeOrganization(OrganizationType org) throws ProcessingException {
        if (org == null)
            throw new ProcessingException(logger.nullArgumentError("Organization"));
        StaxUtil.writeStartElement(writer, METADATA_PREFIX, JBossSAMLConstants.ORGANIZATION.get(), METADATA_NSURI.get());

        ExtensionsType extensions = org.getExtensions();
        if (extensions != null) {
            StaxUtil.writeDOMElement(writer, extensions.getElement());
View Full Code Here

                return getDefaultRoles(doc.getDocumentElement());
            }
        } catch (ProcessingException e) {
            throw e;
        } catch (Exception e1) {
            throw new ProcessingException(e1);
        }
        return roles;
    }
View Full Code Here

        NodeList nl = elem.getElementsByTagName("authorize");
        if (nl != null) {
            int len = nl.getLength();

            if (len > 1)
                throw new ProcessingException(ErrorCodes.PROCESSING_EXCEPTION + "More than one authorize element");
            Node authorize = nl.item(0);
            roles.addAll(getRolesFromAuthorize((Element) authorize));
        }
        return roles;
    }
View Full Code Here

                    long skewMilis = Long.parseLong(skew);
                    expiredAssertion = AssertionUtil.hasExpired(assertion, skewMilis);
                } else
                    expiredAssertion = AssertionUtil.hasExpired(assertion);
            } catch (ConfigurationException e) {
                throw new ProcessingException(e);
            }
            if (expiredAssertion) {
                AssertionExpiredException aee = new AssertionExpiredException();
                aee.setId(assertion.getID());
                throw logger.assertionExpiredError(aee);
View Full Code Here

                        throw logger.samlIssuerNotTrustedError(issuer);
                    }
                } else
                    throw logger.samlHandlerTrustElementMissingError();
            } catch (Exception e) {
                throw new ProcessingException(logger.samlIssuerNotTrustedException(e));
            }
        }
View Full Code Here

        // Get the ID from the root
        String id = samlDocument.getDocumentElement().getAttribute(ID_ATTRIBUTE_NAME);
        try {
            sign(samlDocument, id, keypair);
        } catch (Exception e) {
            throw new ProcessingException(logger.signatureError(e));
        }
    }
View Full Code Here

    public boolean validate(Document signedDocument, PublicKey publicKey) throws ProcessingException {
        try {
            configureIdAttribute(signedDocument);
            return XMLSignatureUtil.validate(signedDocument, publicKey);
        } catch (MarshalException me) {
            throw new ProcessingException(logger.signatureError(me));
        } catch (XMLSignatureException xse) {
            throw new ProcessingException(logger.signatureError(xse));
        }
    }
View Full Code Here

     *
     * @see org.picketlink.identity.federation.PicketLinkLogger#resourceNotFound(java.lang.String)
     */
    @Override
    public ProcessingException resourceNotFound(String resource) {
        return new ProcessingException(ErrorCodes.RESOURCE_NOT_FOUND + resource + " could not be loaded");
    }
View Full Code Here

TOP

Related Classes of org.picketlink.identity.federation.core.exceptions.ProcessingException

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.