regulaforensics / RegulaDocumentReader-Android

[Deprecated] Regula Document Reader SDK for Android
15 stars 2 forks source link

DocumentReader.Instance().Init(MainActivity.this, license) returns false #1

Closed efredz closed 7 years ago

efredz commented 7 years ago

I've generated a demo license with the package for our demo application, copied the license to the specified location (res/raw/regula.license), the file is read correctly but after checking the license:

bool validLicense = DocumentReader.Instance().Init(InCapture.this, license)

The method returns false, what else should I check?

mskvorcovs commented 7 years ago

Hi,

The license should be matching applicationId, not the package name. Please, check you applicationId inside build.gradle file. It should look like this:

defaultConfig {
        applicationId "your.app.id"
        minSdkVersion 14
        targetSdkVersion 25

        versionCode 1
        versionName "1.0"
    }

If this is ok, please, send us your logcat output.

efredz commented 7 years ago

I used my package name to generate the license, but there was a mismatch between my applicationId and the package name. Fixed that and now everything is working.