Package org.apache.abdera.security

Examples of org.apache.abdera.security.EncryptionOptions


        Document<Element> doc = getDocument(wrapper);
        if (doc != null) {
          Encryption enc = security.getEncryption();
          if (enc.isEncrypted(doc)) {
            Object arg = initArg(request);
            EncryptionOptions options = initEncryptionOptions(request,response,enc,arg);
            doDecryption(doc, options, enc, wrapper);
          }
        }
      } catch (Exception e) {
      } finally {wrapper.reset();}
View Full Code Here


  protected EncryptionOptions initEncryptionOptions(
      ServletRequest request,
      ServletResponse response,
      Encryption enc,
      Object arg) {
    EncryptionOptions options = null;
    try {
      DHContext context = (DHContext) arg;
      options = context.getEncryptionOptions(enc);
      returnPublicKey((HttpServletResponse)response,context);
    } catch (Exception e) {}
View Full Code Here

        ka.doPhase(publicKey, true);
        return ka.generateSecret("DESede");
    }

    public EncryptionOptions getEncryptionOptions(Encryption enc) throws InvalidKeyException, NoSuchAlgorithmException {
        EncryptionOptions options = enc.getDefaultEncryptionOptions();
        options.setDataEncryptionKey(generateSecret());
        options.setDataCipherAlgorithm(XMLCipher.TRIPLEDES);
        return options;
    }
View Full Code Here

TOP

Related Classes of org.apache.abdera.security.EncryptionOptions

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.