1

I now that chrome applications can deliver an experience close to that of native applications, but I could not find a way yet to run a local command from a chrome application. Is there any API for this that could used after the user has given permission? How can this be done?

Thanks

mljrg
  • 4,430
  • 2
  • 36
  • 49
  • I would consider this a _huge_ security risk if it was possible. – PMF Feb 09 '14 at 16:41
  • @PMF Well, the user would be asked to trust the web application, which is nowadays normal to do in many platforms (e.g., Android, Java Web Start Apps, and normal desktop apps users download from the web). Anyhow, today users must trust the application authors, or install nothing at all. – mljrg Feb 09 '14 at 17:01
  • Of course, but it opens yet another hole to trick users into clicking yes... – PMF Feb 09 '14 at 18:34
  • No, this is not possible, and very likely will never be possible -- exactly out of the security concerns that PMF is referring to. – Sergey Shevchenko Feb 12 '14 at 19:55

1 Answers1

2

It is in principle possible via Native Messaging.

You can have a native app specifically designed to talk to your Chrome app, but the downside is that the native component cannot be bundled with the app in the Web Store. You'll have to use a separate installer.

Note that the above documentation is for extensions, but the corresponding calls are mentioned in the apps documentation as well.

Xan
  • 74,770
  • 16
  • 179
  • 206