Examples of importPKCS12Key()


Examples of com.adito.boot.KeyStoreManager.importPKCS12Key()

            mgr.setStorePassword(passphrase);

            if (keyStoreType.equals(KeyStoreManager.TYPE_PKCS12)) {
                mgr.setKeyStoreType(KeyStoreManager.TYPE_JKS);
                alias = mgr.importPKCS12Key(uploadedFile, passphrase, alias, SERVER_CERTIFICATE);
            } else {
              FileOutputStream out = new FileOutputStream(mgr.getKeyStoreFile());
                try {
                    FileInputStream in = new FileInputStream(uploadedFile);
                    try {
View Full Code Here

Examples of com.adito.boot.KeyStoreManager.importPKCS12Key()

    /* (non-Javadoc)
     * @see com.adito.keystore.wizards.AbstractKeyStoreImportType#doInstall(java.io.File, java.lang.String, java.lang.String, com.adito.wizard.AbstractWizardSequence)
     */
    public void doInstall(File file, String alias, String passphrase, AbstractWizardSequence seq, SessionInfo sessionInfo) throws Exception {
        KeyStoreManager mgr = KeyStoreManager.getInstance(KeyStoreManager.SERVER_AUTHENTICATION_CERTIFICATES_KEY_STORE);
        alias = mgr.importPKCS12Key(file, passphrase, alias, alias);
        mgr.reloadKeystore();
        Certificate certif = mgr.getCertificate(alias);

        CoreEvent coreEvent = new CoreEvent(this, CoreEventConstants.KEYSTORE_SERVER_AUTHENTICATION_CERTIFICATE_IMPORTED, KeyStoreManager.SERVER_AUTHENTICATION_CERTIFICATES_KEY_STORE, seq.getSession())
                        .addAttribute(CoreAttributeConstants.EVENT_ATTR_CERTIFICATE_ALIAS, alias)
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.