<div dir="ltr"><div>Hi<br><br></div><div>I recently managed to execute Android commands from outside of Alien Dalvik.<br></div><div>This was achieved by looking at how it's done when apps are launched and Alien Dalvik is started normally.<br><br></div><div>To see the resulting scripts, go here: <a href="https://github.com/attah/alien-tools">https://github.com/attah/alien-tools<br></a><br></div><div>Now to the point, I think these should be exposed for use in sailfish native apps.<br></div><div>The way I see it being done is by adding a daemon that forwards intents that it receives over dbus.<br></div><div>This solves a couple of things, firstly that it seems to require root for the intents to take effect and secondly it enables us to add a layer of security so that the user is prompted when app wants to invoke an intent. This obviously needs a "allow permanently" option, otherwise intents won't be very useful. Using a daemon also takes care of the fact that it would have to execute in a rather particular environment. That is what i have managed to set up in alien-tools, but it is essentially the same as in /opt/alien/system/script/start_alien.sh, which is what is invoked by the aliendalvik.service. So spawning the daemon from there would work. <br><br>Polkit seems to be the way to do handle permissions, so that should work out. I also think that this whole thing is better done, at least in part, by Jolla. Especially since it needs to work with Alien Dalvik which is 3rd-party, and so that it goes together well with the workflow of the os in general. Thus this email. :)<br><br></div><div>I'm not sure how much else, apart from intents, that we'd like to have exposed. I found that the "input" application works as well, and many other should too. The scary part her is that i could send input without being root. Not sure that is a very good idea. And even if we would add som security layer, who is to check what is ok and what is not? Intents at least have a limited scope whereas input can do pretty much anything.<br><br></div><div>What do you guys think?<br><br></div><div>Regards,<br></div><div>Anton (attah)<br></div></div>