Skip to content

sumitshresht/SecureZip

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📦 SecureZip — Java File Encryption, Compression & Integrity Library

Maven Central License: MIT Java JUnit


🚀 Overview

SecureZip is a Java library that provides robust file encryption, compression, and integrity utilities. It supports AES encryption, standard and AES-encrypted ZIP compression, secure file deletion, file splitting/merging, and integrity checks (SHA-256, MD5).


🎯 Features

  • 🔐 AES File Encryption & Decryption (Password-based)
  • 📦 ZIP File Compression & Extraction
  • 🔑 Password-Protected ZIP (Standard & AES-256)
  • 🔍 List ZIP File Contents
  • 🧠 File Integrity Check (SHA-256, SHA-1, MD5)
  • ✂️ File Split and Merge (like WinRAR/7-Zip parts)
  • 🔥 Secure File Delete (Wipe data before deletion)
  • ✅ Fully Unit Tested with JUnit 5
  • 💯 Easy to use, lightweight, no external dependencies

🔧 Installation

Maven:

<dependency>
    <groupId>io.securezip</groupId>
    <artifactId>securezip</artifactId>
    <version>1.0.0</version>
</dependency>

Gradle:

dependencies {
    implementation 'io.securezip:securezip:1.0.0'
}

🚀 Usage Examples

🔐 Encrypt and Decrypt a File

EncryptionUtils.encryptFile("/path/to/file.txt", "password");
EncryptionUtils.decryptFile("/path/to/file.txt.enc", "password");

📦 Compress and Extract ZIP

CompressionUtils.compressFolder("/path/to/folder", "/path/to/output.zip");
CompressionUtils.extractZip("/path/to/output.zip", "/path/to/destination");

🔑 Password Protected ZIP

CompressionUtils.createPasswordProtectedZip("/path/to/file", "/path/to/secure.zip", "password");
CompressionUtils.extractPasswordProtectedZip("/path/to/secure.zip", "password", "/path/to/extract");

🔍 List ZIP Contents

CompressionUtils.listZipContents("/path/to/file.zip");

🧠 Check File Integrity (Hash)

String sha256 = HashUtils.getSHA256("/path/to/file.txt");
String md5 = HashUtils.getMD5("/path/to/file.txt");
System.out.println("SHA-256: " + sha256);

✂️ File Split and Merge

// Split file into 5MB parts
List<String> parts = FileSplitterUtils.splitFile("/path/to/largefile.zip", 5);

// Merge back
FileSplitterUtils.mergeFiles(parts, "/path/to/merged.zip");

🔥 Secure File Delete (Wipe)

SecureDeleteUtils.secureDelete("/path/to/secretfile.txt");

🧪 Running Tests

  • Right-click on test/java → Run All Tests or
  • Use:
mvn test

or

gradle test

📁 Project Structure

SecureZip/
 ├── src/
 │   ├── main/java/io/securezip/...
 │   └── test/java/io/securezip/...
 ├── pom.xml
 ├── README.md
 └── LICENSE

📜 License

This project is licensed under the MIT License.


🌟 Contributions Welcome!

If you have ideas, bug reports, or improvements — feel free to open issues or pull requests.


💥 Star this repo ⭐ if you like it!


About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages