disusered / cordova-safe

File encryption for Cordova.
MIT License
35 stars 22 forks source link

build error after install this plugin #28

Open santanu07 opened 6 years ago

santanu07 commented 6 years ago

:app:compileDebugJavaWithJavac ..\youtube-download\platforms\android\app\src\main\java\com\disusered\Safe.java:26: error: package com.facebook.android.crypto.keychain does not exist import com.facebook.android.crypto.keychain.SharedPrefsBackedKeyChain; ^ F:\santanu\youtube-download\platforms\android\app\src\main\java\com\disusered\Safe.java:120: error: cannot find symbol CRYPTO = new Crypto(new SharedPrefsBackedKeyChain(CONTEXT), new SystemNativeCryptoLibrary()); ^ symbol: class SharedPrefsBackedKeyChain location: class Safe 2 errors FAILED

FAILURE: Build failed with an exception.

BUILD FAILED in 1m 46s (node:3416) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: cmd: Command failed with exit code 1 Error output: F:\santanu\youtube-download\platforms\android\app\src\main\java\com\disusered\Safe.java:26: error: package com.facebook.android.crypto.keychain does not exist import com.facebook.android.crypto.keychain.SharedPrefsBackedKeyChain; ^ F:\santanu\youtube-download\platforms\android\app\src\main\java\com\disusered\Safe.java:120: error: cannot find symbol CRYPTO = new Crypto(new SharedPrefsBackedKeyChain(CONTEXT), new SystemNativeCryptoLibrary()); ^ symbol: class SharedPrefsBackedKeyChain location: class Safe 2 errors

UlisesCeca commented 5 years ago

I am having this issue too :/

Have you solved it yet?

BDominik commented 5 years ago

Same here. Any solution?

BDominik commented 5 years ago

I already found this solution somewhere else but then it's didn't worked. Ionic Info

Ionic:

ionic (Ionic CLI) : 4.0.5 (C:\Users\bdomi\AppData\Roaming\npm\node_modules\ionic) Ionic Framework : ionic-angular 3.9.2 @ionic/app-scripts : 3.1.11

Cordova:

cordova (Cordova CLI) : 8.0.0 Cordova Platforms : not available

System:

Android SDK Tools : 26.1.1 NodeJS : v8.11.3 (C:\Program Files\nodejs\node.exe) npm : 6.3.0 OS : Windows 10

So now what I did is the folowing. In the platforms/android/cordova-safe/starter-conceal.gradle change this compile('com.facebook.conceal:conceal:1.0.0@aar') to this compile('com.facebook.conceal:conceal:2.0.1@aar') I hope it will work for you too.

vonikshah commented 5 years ago

Thanks @BDominik

It worked for me. You save my day. Thanks alot.