/** * This method returns a secret (symmetric) key. This is for XML Encryption. * @return the secret key contained in this KeyInfo * @throws KeyResolverException */ public SecretKey getSecretKey() throws KeyResolverException { SecretKey sk = this.getSecretKeyFromInternalResolvers(); if (sk != null) { LOG.debug("I could find a secret key using the per-KeyInfo key resolvers"); return sk; } LOG.debug("I couldn't find a secret key using the per-KeyInfo key resolvers"); sk = this.getSecretKeyFromStaticResolvers(); if (sk != null) { LOG.debug("I could find a secret key using the system-wide key resolvers"); return sk; } LOG.debug("I couldn't find a secret key using the system-wide key resolvers"); return null; }