We have verified the issue on our end and we’re working on fixing the issue. Thanks a lot for pointing this out, it is an embarrassing security issue that was a combination of bad defaults and negligence from our side.
We’re releasing a new version of resinOS asap with a fix. Also, we’ve patched the library upstream for the benefit of any other pubnub user https://github.com/pubnub/javascript/pull/89 and we’re also working on an action plan to fix existing devices in the field.