Package org.rat.free.security.makifx.base

Examples of org.rat.free.security.makifx.base.EncryptedMap


                return false;
            }

            AES.encryptFile(master_password, test_file, new_text_file);
            String text_reloaded = AES.decryptFile(master_password, test_file);
            EncryptedMap em = reloadEncryptedSavedData(text_reloaded);

            if (em == null) {
                log("checkNewFileToSave - EM IS NULL!");
                return false;
            } else {
View Full Code Here


                + "Continue, and open your data account directory.";
        try {

            AES.encryptFile(master_password, maki_file_map, text);
            String text_reloaded = AES.decryptFile(master_password, maki_file_map);
            EncryptedMap em = reloadEncryptedSavedData(text_reloaded);

            if (em == null) {
                log("SAVE - ecryptToFileFinally - ERROR EncryptedMap is NULL!");
                throw new BaseApplicationException(__ERROR_TEXT_UNMAR)
                        .setErrorType(BaseApplicationException.ErrorType.ERROR);
View Full Code Here

    private EncryptedMap reloadEncryptedSavedData(@Nonnull final String text_reloaded) throws Exception {
        StringReader reader;
        JAXBContext cx = JAXBContext.newInstance(EncryptedMap.class);
        Unmarshaller um = cx.createUnmarshaller();
        EncryptedMap em = (EncryptedMap) um.unmarshal(reader = new StringReader(text_reloaded));
        if (reader != null) {
            reader.close();
        }
        return em;
    }
View Full Code Here

                    @Override public void run() {
                        try {
                            //UtilityFX.saveText(testo, "test\\prima.xml");
                            //String trr = testo.substring(0, 522729) + "<value></value>" + testo.substring(522775);
                            //UtilityFX.saveText(trr, "test\\dopo.xml");
                            EncryptedMap em = (EncryptedMap) um.unmarshal(new StringReader(testo));

                            if (em != null) {
                                log("Date Creation:" + em.getDateCreation());
                                RIS.add(em);
                            }
                        } catch (Exception exc) {
                            log("Error in reading file data. Wrong username and password?");
                            exc.printStackTrace();
View Full Code Here

TOP

Related Classes of org.rat.free.security.makifx.base.EncryptedMap

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.