easybackup | A Short and Easy Website Files/DB FTP Backup Script | Continuous Backup library
kandi X-RAY | easybackup Summary
kandi X-RAY | easybackup Summary
A Short and Easy Website Files/DB FTP Backup Script. Works for websites with single DB.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of easybackup
easybackup Key Features
easybackup Examples and Code Snippets
Community Discussions
Trending Discussions on easybackup
QUESTION
I have created a backup system which I sell called EasyBackup for servers. The system works great, and it uses zipped files. Someone requested that I add a feature to add a password to the zipped folder, but I could not find a way to do that with Java's zip utility classes, so I decided to use Zip4j.
Zip4j adds passwords perfectly, but when I add a folder, it adds all files and subfolders.
I have an option for users to exempt files and folders, so I need a way to retain this ability.
How can I exempt files and folders with Zip4J. Is there a way to add folders and files manually so the children are not added?
If not, would modifying the sourcecode for Zip4J be practical? Is there another library that does this already?
...ANSWER
Answered 2018-Apr-03 at 19:48I solved this by modifying Zip4j. I made a crude change which kind of abuses static, but it is in a Utility class, so I am not too concerned.
I made the following changes in the Zip4jUtil class, and I created an interface called ExemptFileHandler with one method:
public boolean isExempt(File file);
Then in the Zip4jUtil class I made the following static object:
private static ExemptFileHandler handler;
Finially, I modified the getFilesInDirectoryRec
recursive method as so:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install easybackup
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page