~/talk

WebAssembly in Android Apps — Do WASM Dream of JNI?

TalkinJapaneseat DroidKaigi 2026 · 2026-09-01..09-03· [android, webassembly, security]
links:none on file
slides:none on file

Compiles the OpenJPEG JP2K decoder to WebAssembly and packages it as jp2k-decoder-android, then runs it inside the Jetpack JavaScript Engine sandbox on Android to contain, not eliminate, native-vulnerability blast radius. Measures practical trade-offs for embedding WASM payloads in APKs: Base64 increases size to ~133%, Base85 shrinks to ~88% but adds CPU cost, and a custom 32,768-char encoding reaches ~106% with very slow decode. Uses Binder IPC with a 1 MB message limit and a file-descriptor/pipe workaround; recommends using Jetpack JSE 1.1.0’s MessagePort API for true byte-array roundtrips.

AI-written summary · about

  1. 0:00Introduction
  2. 1:13JPEG2000 processing challenges
  3. 5:12WebAssembly basics on Android
  4. 7:20OpenJPEG with WebAssembly
  5. 8:05Running WASM on Android steps
  6. 13:48Isolated execution with JS engine
  7. 16:55WebAssembly versus JNI
  8. 18:21Data transfer challenges
  9. 21:11Encoding method comparison
  10. 27:39Optimal encoding conclusion
  11. 28:00JS engine 1.1.0 features
  12. 30:28Graceful degradation importance
  13. 33:26Multi-layer security
  14. 35:55WASM and JNI future roles
  15. 36:40Summary
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.