Coder Social home page Coder Social logo

Comments (11)

lostintangent avatar lostintangent commented on May 18, 2024

@ne0c0de Hey! We haven't seen anyone using the CordovaCrypt plugin along with CodePush, so it's definitely possible there is an issue there we need to investigate. Thanks a lot for reporting this.

Just as a first level triage, could you confirm that you are releasing the platform-specific www folder to CodePush (e.g. platforms/android/assets/www) after running "cordova prepare"?

The error you are getting is an indication that the CodePush plugin wasn't able to find the HTML file in the update contents which corresponds to your app's configured start page (e.g. index.html. We don't attempt to read the HTM file at this point, so if it was encrypted, that shouldn't matter, as long as the file name wasn't changed.

If that isn't the issue, then I suppose it's possible that we are running into problems trying to read the app's start page from the config.xml, if it is encrypted.

We'll take a look at the Crypt plugin you're using in parallel while waiting for your response to see if that sheds any light on the potential issue. Thanks!

from cordova-plugin-code-push.

ne0c0de avatar ne0c0de commented on May 18, 2024

Hi @lostintangent

I removed the plugin from my source for testing and it works without any error.

This is the proof of the problem caused by that plugin.

I always first make cordova prepare and than code-push release . but as i said the problem was caused by cordova crypt plugin

This is the plugin page that i'm using: https://github.com/tkyaji/cordova-plugin-crypt-file

from cordova-plugin-code-push.

lostintangent avatar lostintangent commented on May 18, 2024

@ne0c0de Ah OK, thanks a lot for confirming that. I just wanted to double check :) I'll take a look at that plugin right now, and will likely have some follow up questions if that is cool. Thanks for the patience, and sorry for the inconvenience! We try to make sure we are as compatible as possible with other plugins, but our coverage could always be better.

from cordova-plugin-code-push.

lostintangent avatar lostintangent commented on May 18, 2024

Ah I see the problem. On Android, the crypt plugin rewrites the start page in your config.xml to be prefixed with "http://localhost" (e.g. "Index.html" becomes "http://localhost/index.html"). When the CodePush plugin attempts to find your start page in the update contents, it would look for a file called "http://localhost/index.html" and obviously fail :)

It's possible that we could special case this scenario and strip the prefix, but I'll have to think about the potential issues that could cause.

from cordova-plugin-code-push.

ne0c0de avatar ne0c0de commented on May 18, 2024

Hello @lostintangent

Is there an estimation when this bug will be fixed?

Because i want to use code-push on my next version that we will publish very soon but i don't want to disable cordova encrypt because of security. If this will be fixed soon i want to postpone our publish date for few days.

from cordova-plugin-code-push.

lostintangent avatar lostintangent commented on May 18, 2024

@ne0c0de We'll send out a PR for this fix today and should have it published to NPM by tomorrow at the latest. Thanks for the patience!

from cordova-plugin-code-push.

lostintangent avatar lostintangent commented on May 18, 2024

@ne0c0de Unfortunately this isn't actually a simple fix like we had hoped, and we would need to submit a PR to the crypt plugin to actually enable interoping with CodePush. We will look into doing this, but for now, I think it might make sense for you to do your release without CodePush for now, and we'll let you know once we resolve this.

from cordova-plugin-code-push.

lostintangent avatar lostintangent commented on May 18, 2024

I'm going to close this issue for now since it isn't immediately actionable. At some point I want to support E2E encryption, but we'll need to determine if relying on this plugin is the right choice. Thanks again for reporting this, and please re-open it if you think we should continue pursuing support for this plugin specifically.

from cordova-plugin-code-push.

bil-ash avatar bil-ash commented on May 18, 2024

@lostintangent It's almost two years the issue was closed but still seems to be no way for end to end encryption in conjunction with code-push-plugin.
I would suggest that instead of using a separate plugin, the functionalities of cordova-crypt-file plugin can actually be integrated into the code-push plugin. Also this issue needs to be addressed asap,its burried for almost 2 years.

from cordova-plugin-code-push.

foolishsailor avatar foolishsailor commented on May 18, 2024

Any updates? I imagine anyone using code-push with Android would like to see ability to have an obfuscated APK that could be used with code-push

from cordova-plugin-code-push.

SamarBakr avatar SamarBakr commented on May 18, 2024

Any updates ? I'm facing same issue , Is there any alternative plugin for cordova-plugin-crypt-file that is compatible with Code-Push?

from cordova-plugin-code-push.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.