plain java unrar util (former sf project)
Clone or download
Pull request Compare This branch is 65 commits ahead of edmund-wagner:master.
Latest commit affab56 Aug 19, 2018


Read and extracts from a .rar file. This is a fork of the junrar codebase, formerly on sourceforge.

Code may not be used to develop a RAR (WinRAR) compatible archiver.

If you are using a version below 1.0.1 please upgrade

Dependency on maven:


Extract from files:

Junrar.extract("/tmp/foo.rar", "/tmp");
final File rar = new File("foo.rar");  
final File destinationFolder = new File("destinationFolder");
Junrar.extract(rar, destinationFolder);    
final InputStream resourceAsStream = Foo.class.getResourceAsStream("foo.rar");//only for a single rar file
Junrar.extract(resourceAsStream, tempFolder);

List files:

final List<ContentDescription> contentDescriptions = Junrar.getContentsDescription(testDocuments);