Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 09-30-2019, 03:15 PM   #1
nunojpg
Junior Member
nunojpg began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Sep 2019
Device: KT4
lipc sendEvent to execute binaries still works?

I see for example in:

https://github.com/AerisDev/KindleMe...emenupage.html

Code:
nativeBridge.setLipcProperty("com.lab126.system", "sendEvent", "; su -c 'killall show_alert.sh; /mnt/us/extensions/kindlemenu/bin/sh/show_alert.sh " + status + " 3 &'");
But I've been unable to execute shell scripts / binaries with this approach.

Is there a equivalent way of doing it in recent versions?

Thanks
nunojpg is offline   Reply With Quote
Old 09-30-2019, 03:28 PM   #2
j.p.s
Grand Sorcerer
j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.
 
Posts: 5,786
Karma: 103362673
Join Date: Apr 2011
Device: pb360
Have you tried KUAL:
https://www.mobileread.com/forums/sh...d.php?t=203326
j.p.s is offline   Reply With Quote
Advert
Old 09-30-2019, 05:16 PM   #3
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
I'm fairly sure the nativeBridge stuff went the way of the dodo back in something like 5.1.x or something *reaaaaaaalllly* old.

As for the system() calls via lipc, yep that's gone for sure. Again, a crapload of time ago.
NiLuJe is offline   Reply With Quote
Old 09-30-2019, 09:02 PM   #4
knc1
Going Viral
knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.
 
knc1's Avatar
 
Posts: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
Quote:
Originally Posted by nunojpg View Post
I see for example in:

https://github.com/AerisDev/KindleMe...emenupage.html

Code:
nativeBridge.setLipcProperty("com.lab126.system", "sendEvent", "; su -c 'killall show_alert.sh; /mnt/us/extensions/kindlemenu/bin/sh/show_alert.sh " + status + " 3 &'");
But I've been unable to execute shell scripts / binaries with this approach.

Is there a equivalent way of doing it in recent versions?

Thanks
As you noted in the link you quoted, the most recent update of that code was December 17, 2013.
Hmm....
That is approximately a zillion firmware revisions ago.

- - - - -

Even if the above still worked, you would have to have a jail broken Kindle (the original, a K5) to use the code.

So if you really must have this "feature", buy an original K5, then install a firmware version earlier than 5.2, then jail break the device, and THEN you can play with that code.

- - - - -

Note: KUAL replaced KindleMenu in January of 2013.
So you are looking at some really, really old code (like back in the days of "NativeBridge".

Last edited by knc1; 09-30-2019 at 09:07 PM.
knc1 is offline   Reply With Quote
Old 10-01-2019, 01:27 AM   #5
nunojpg
Junior Member
nunojpg began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Sep 2019
Device: KT4
Thanks. I am using KUAL. I am just using "KindleMenu" as code snippet examples.

I'm trying to develop a WAF/Pillow app and wanted to have a way of interacting with shell scripts.

Maybe thats possible now by appending custom cmds to /usr/share/webkit-1.0/pillow/debug_cmds.jsonand invoking then from lipc.

Anyway, is there a recent WAF app source code available to take as example?
nunojpg is offline   Reply With Quote
Advert
Old 10-01-2019, 10:01 AM   #6
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
I'm fairly sure something awful happened to how "free" you were with WAF stuff, too, FWIW, which explains why you can't find anything recent .
NiLuJe is offline   Reply With Quote
Old 10-03-2019, 12:23 PM   #7
nunojpg
Junior Member
nunojpg began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Sep 2019
Device: KT4
I confirmed that it's possible to execute arbitrary commands by adding them to /usr/share/webkit-1.0/pillow/debug_cmds.json, and executing with eg:

nativeBridge.dbgCmd(";usbnetwork","")

The second parameter allows to pass parameters to the command, so a shell script with exec can be used as a arbitrary command proxy.
nunojpg is offline   Reply With Quote
Old 10-03-2019, 12:36 PM   #8
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
True, but that's considerably more intrusive .

(c.f., the bridge's piggybacking on ;log for an actual implementation of this idea).

Last edited by NiLuJe; 10-03-2019 at 12:38 PM.
NiLuJe is offline   Reply With Quote
Reply

Tags
lipc


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
LIPC: how to set a custom event? silver18 Kindle Developer's Corner 20 04-21-2025 10:36 AM
How to use the lipc-hash-prop command? NotaStudio Kindle Developer's Corner 2 06-03-2017 12:32 PM
lipc-daemon usage infos and ideas Aeris Kindle Developer's Corner 13 01-15-2015 08:36 AM
Recovery Binaries knc1 Kindle Developer's Corner 1 06-17-2012 01:14 PM


All times are GMT -4. The time now is 06:04 PM.


MobileRead.com is a privately owned, operated and funded community.