Search code examples
javaandroidstringbase32

Encode and Decode String using Base32


I want to use Base32 for encoding and decoding for a string. But I am getting error while am using Apache Commons Codec 1.11

I have used this answer but not work for me (link) (link2).

This is the error Screenshot which is I am facing...

Thanks...!!!

EDIT :-

Check this Screen shot

jar file downloaded from here : click me


Solution

  • One of this options should help you:

    Option 1: Add this to your build.gradle:

    android {
        // Your main config here...
        packagingOptions {
            exclude 'org/apache/commons/codec/language/bm/gen_approx_hungarian.txt'
        }
    }
    

    Make sure, that I copied conflicting file name correctly from your screenshot.

    Option 2: Remove test libraries from dependencies list: commons-codec-1.11-tests.jar commons-codec-1.11-test-sources.jar