You could try that. Long term, it should also be possible to route this communication through the internet, or use the Chrome/Firefox/WebExtension NativeMessaging API [0][1].
0. https://developer.chrome.com/apps/nativeMessaging.
1. https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/Web...