Huffman Tree and Binary Conversion for Efficient and Secure Data Encryption and Decryption
This study proposes the Huffman Tree and Binary Conversion (HTB) which is a preprocessing algorithm to transform the Huffman tree into binary representation before the encryption process. In fact, HTB can improve the structural readiness of plaintext by combining the Huffman code with a deterministic binary representation of the Huffman tree. In addition, binary representation of the Huffman tree and the compressed information will be encrypted by standard cryptographic algorithms. Six datasets, divided into two groups (short and long texts), were chosen to evaluate compression behavior and the processing cost. Moreover, AES and RSA are chosen to combine with the proposed method to analyze the encryption and decryption cycles. The experimental results show that HTB introduces a small linear-time overhead. That means, it is slightly slower than applying only the Huffman code. Across these datasets, HTB maintained a consistently low processing cost. The processing time is below one millisecond in both encoding and decoding processes. However, for long texts, the structural conversion cost becomes amortized across larger encoded messages, and the reduction in plaintext size leads to fewer encryption blocks for both AES and RSA. The reduced plaintext size lowers the number of AES encryption blocks by approximately 30–45% and decreases the number of encryption and decryption rounds in RSA. The encrypted binary representation of the Huffman tree also decreased structural ambiguity and reduced the potential exposure of frequency-related metadata. Although HTB does not replace cryptographic security, it enhances the structural consistency of compression. Therefore, the proposed method demonstrates scalability, predictable overhead, and improved suitability for cryptographic workflows.
Authors
- Kritsanapong Somsuk (ORCID: https://orcid.org/0000-0002-1311-8222)
- Chanwit Suwannapong (ORCID: https://orcid.org/0000-0002-7970-3088)
- Sarutte Atsawaraungsuk (ORCID: https://orcid.org/0000-0002-6853-6480)
- Suchart Khummanee
- T. Cheawchanwattana
Institutions
- Nakhon Phanom University (TH)
- Mahasarakham University (TH)
- Udon Thani Rajabhat University (TH)
Publication Details
- Journal
- Journal of Cybersecurity and Privacy
- Published
- 2025-12-22
- DOI
- https://doi.org/10.3390/jcp6010001
- Primary Topic
- Chaos-based Image/Signal Encryption
- Type
- article
- Field-Weighted Citation Impact
- 0.00
Funders
- Mahasarakham University