Closed Bug 794479 Opened 7 years ago Closed 7 years ago
Add support for loading java code in addons
Turns out it's not that hard to load arbitrary java code from an addon into Fennec. 1. Apply the attached WIP to fennec 2. Grab the sample addon from https://github.com/staktrace/fennec-addon-javaddon and install it into fennec 3. ??? 4. Profit! If we want to expose this we should probably have some well-defined API interfaces that the addon java code can be compiled against, and that are provided to the addon java code at runtime.
Adding sec-review-needed since this will allow running arbitrary java code in the fennec process.
Holy crap this is a small patch. Exciting!
Comment on attachment 664984 [details] [diff] [review] WIP Brad suggested landing this patch and putting together a proper API for addons in follow-up bugs. So requesting review here.
Attachment #664984 - Flags: review?(mark.finkle)
Comment on attachment 664984 [details] [diff] [review] WIP I am eager to see what projects this feature can open up in Firefox. I wouldn't mind seeing some examples and a brief doc on what can _and_can't be done using this idea. For example, I assume we can run standalone Java code, but can the code interact with the Firefox UI?
Attachment #664984 - Flags: review?(mark.finkle) → review+
7 years ago
Assignee: nobody → bugmail.mozilla
Also, we might want to move to a JS ctypes -> JNI approach instead of the Dex:Load JSON message.
(In reply to Mark Finkle (:mfinkle) from comment #4) > I wouldn't mind seeing some examples and a brief doc on what can _and_can't > be done using this idea. For example, I assume we can run standalone Java > code, but can the code interact with the Firefox UI? It should be able to, since it's in the same process.
7 years ago
Landed on inbound: https://hg.mozilla.org/integration/mozilla-inbound/rev/3cc4987101b8 Filed bug 799631 for adding proper APIs.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 19
Flags: sec-review? → sec-review?(mgoodwin)
Dealt with (along with Java APIs in bug 805436) in https://wiki.mozilla.org/Security/Reviews/MobileJavaAddOns
Flags: sec-review?(mgoodwin) → sec-review+
You need to log in before you can comment on or make changes to this bug.