Skip to content
This repository has been archived by the owner on Mar 27, 2020. It is now read-only.

FileEncryption plugin is not installed. #25

Open
hydrococcous opened this issue Mar 29, 2018 · 3 comments
Open

FileEncryption plugin is not installed. #25

hydrococcous opened this issue Mar 29, 2018 · 3 comments

Comments

@hydrococcous
Copy link

hydrococcous commented Mar 29, 2018

i try to install this plugin, but ionic say: "FileEncryption plugin is not installed."
But I installed with:

$ ionic cordova plugin add cordova-safe
$ npm install --save @ionic-native/file-encryption

And I use it as following:

import { Component } from '@angular/core';
import { NavController, Platform } from 'ionic-angular';
import { FileEncryption } from '@ionic-native/file-encryption';

@Component({
  selector: 'page-home',
  templateUrl: 'home.html'
})

export class HomePage {

  constructor(public navCtrl: NavController,
              private fileEncryption: FileEncryption,
              public platform: Platform) {

              this.platform.ready().then(() => {


                console.log('Platform ready!!!');

                this.fileEncryption.decrypt('assets/json/secret.json', 'secretKey');
                this.fileEncryption.encrypt('assets/json/secret.json', 'secretKey');

              });

  }

}

Native: tried calling FileEncryption.decrypt, but the FileEncryption plugin is not installed.
Install the FileEncryption plugin: 'ionic cordova plugin add cordova-safe'

This is my Configuration:

cli packages: (C:\Users\username.npm-packages\node_modules)

@ionic/cli-utils  : 1.19.2
ionic (Ionic CLI) : 3.20.0

global packages:

cordova (Cordova CLI) : 7.1.0

local packages:

@ionic/app-scripts : 3.1.8
Cordova Platforms  : android 6.3.0
Ionic Framework    : ionic-angular 3.9.2

System:

Node : v6.9.4
npm  : 5.6.0
OS   : Windows 10

Environment Variables:

ANDROID_HOME : not set

Misc:

backend : pro
@soicem
Copy link

soicem commented Jun 24, 2018

I have a same issue with you. and after running my app with that error messages, I can't build it anymore

@clickervinod
Copy link

clickervinod commented Sep 22, 2018

hi,

change this line in plugins/cordova-safe/src/android/conceal.gradle

repositories {
  mavenCentral()
}

dependencies {
// change version 1.0.0 ro 1.1.3
  compile('com.facebook.conceal:conceal:1.1.3@aar') {
    transitive = true
  }
}

android {
  packagingOptions {
    exclude 'META-INF/NOTICE'
    exclude 'META-INF/LICENSE'
  }
}

@SanthoshPixmonks
Copy link

@clickervinod I have tried your solution app is building but when using the plugin inside the application it is throwing Native: plugin is not installed error.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants