[jdom-interest] Can file for Document be deleted?

Phill_Perryman at Mitel.COM Phill_Perryman at Mitel.COM
Tue Dec 2 01:43:17 PST 2003


We have been using encrypted files for quite a while now and not had any 
problems, we do not however write out  a plain file, we build directly 
from the encrypt stream

                if (encrypt == true) {

                        byte[] b = { magic numbers go here };

                        // Create PBE Cipher
                        Cipher pbeCipher = createCipher(b, false);

                        FileInputStream fis = new FileInputStream(file.toString());
                        in = new CipherInputStream(fis, pbeCipher);

                } else {
                        in = new FileInputStream(file.toString());
                }
                SAXBuilder builder = new SAXBuilder();
                builder.setFactory(jdomFactory);
                doc = builder.build(in);

/Phill
IS Dept, Software Engineer.
phill_perryman at mitel.com
http://www.mitel.com
Tel: +44 1291 436023




"ÁÎÃûѧ" <mxliao at mails.gscas.ac.cn>
Sent by: jdom-interest-admin at jdom.org
02/12/2003 02:57
Please respond to "ÁÎÃûѧ"

 
        To:     jdom-interest at jdom.org
        cc: 
        Subject:        [jdom-interest] Can file for Document be deleted?


Sometimes I use an encrypted(by FlowFish) xml file to construct a 
Document.
Firstly I decrypt the file to a plain .xml file, then extract an instance 
of
Document from the plain file. Generally, for the sake of security,the 
plain file
should be deleted. I have done it this way and all does work. But I am not 
sure
whether the Document instance will be somehow affected under some certain
circumstance unknown to me.


_______________________________________________
To control your jdom-interest membership:
http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@yourhost.com


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://jdom.org/pipermail/jdom-interest/attachments/20031202/6ffcf128/attachment.htm


More information about the jdom-interest mailing list