The existing techniques of reversible data hiding in encrypted JPEG images vacates space for data hiding after
encrypting the image. As the entropy of encrypted images is higher, there is a chance for information loss as well as the
computational complexity of image reconstruction will be higher. The proposed method therefore finds space for data hiding
before encrypting the image using the method of quadtree compression. The simplicity of quadtree data structure reduces
computational complexity. The image is encrypted using RC4 encryption algorithm. The vacant spaces obtained after quadtree
compression is used for data hiding with the help of a data hiding key. At the receiver side, data extraction and image recovery
are made separable such that the data can be extracted without knowing the image contents. The original pixel restoration is
done using prediction error method.