Examples of base64DecodeAndDecrypt()


Examples of org.wso2.carbon.core.util.CryptoUtil.base64DecodeAndDecrypt()

    }

    private String getDecryptedPassword(String encryptedString) throws SecurityConfigException {
        CryptoUtil cryptoUtil = CryptoUtil.getDefaultCryptoUtil();
        try {
            return new String(cryptoUtil.base64DecodeAndDecrypt(encryptedString));
        } catch (CryptoException e) {
            String msg = "Unable to decode and decrypt password string.";
            log.error(msg, e);
            throw new SecurityConfigException(msg, e);
        }
View Full Code Here

Examples of org.wso2.carbon.core.util.CryptoUtil.base64DecodeAndDecrypt()

                        if (store.containsAlias(username)) {
                            Resource resource = (Resource) govRegistry.get(ks[i]);
                            CryptoUtil cryptoUtil = CryptoUtil.getDefaultCryptoUtil();
                            String encryptedPassword = resource
                                    .getProperty(SecurityConstants.PROP_PRIVATE_KEY_PASS);
                            password = new String(cryptoUtil
                                    .base64DecodeAndDecrypt(encryptedPassword));
                            break;
                        }
                    }
View Full Code Here

Examples of org.wso2.carbon.core.util.CryptoUtil.base64DecodeAndDecrypt()

        keyStoreType = resource.getProperty(SecurityConstants.PROP_TYPE);

        String encpass = resource.getProperty(SecurityConstants.PROP_PRIVATE_KEY_PASS);

        CryptoUtil util = CryptoUtil.getDefaultCryptoUtil();
        privateKeyPassowrd = new String(util.base64DecodeAndDecrypt(encpass));

      }
      // Fill the information about the certificates
      Enumeration<String> aliases = keyStore.aliases();
      List<org.wso2.carbon.security.keystore.service.CertData> certDataList = new ArrayList<CertData>();
View Full Code Here

Examples of org.wso2.carbon.core.util.CryptoUtil.base64DecodeAndDecrypt()

            bean.setUserName(resource.getProperty(CSGConstant.USER_NAME));
            bean.setPort(resource.getProperty(CSGConstant.PORT));
            bean.setDomainName(resource.getProperty(CSGConstant.DOMAIN_NAME));

            CryptoUtil cryptoUtil = CryptoUtil.getDefaultCryptoUtil();
            String plainPassWord = new String(cryptoUtil.base64DecodeAndDecrypt(
                    resource.getProperty(CSGConstant.PASS_WORD)));
            bean.setPassWord(plainPassWord);

            return bean;
        } catch (CryptoException e) {
View Full Code Here

Examples of org.wso2.carbon.core.util.CryptoUtil.base64DecodeAndDecrypt()

                    bean.setPort(resource.getProperty(CSGConstant.PORT));
                    bean.setDomainName(resource.getProperty(CSGConstant.DOMAIN_NAME));

                    CryptoUtil cryptoUtil = CryptoUtil.getDefaultCryptoUtil();

                    bean.setPassWord(new String(cryptoUtil.base64DecodeAndDecrypt(
                            resource.getProperty("password"))));
                } catch (CryptoException e) {
                    handleException("Cloud not convert into an AXIOM element");
                }
            } else {
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.