This article was published on April 11, 2016

Two Googlers created an API to connect USB devices directly to the Web


Two Googlers created an API to connect USB devices directly to the Web

Two Google engineers have introduced a new API called WebUSB to the World Wide Web Consortium’s Incubator Community Group (W3C WICG) that would allow USB devices to connect to the Web safely.

The API isn’t meant for USB flash drives, but other peripherals like keyboards or various Internet of Things crap gadgets. The process isn’t meant for some sort of advanced file transfer, either; it’s to safely connect hardware to the Web without the need for a dedicated platform.

In their proposal, the Googlers explain their aim:

API hardware manufacturers will have the ability to build cross-platform JavaScript SDKs for their devices. This will be good for the web because, instead of waiting for a new kind of device to be popular enough for browsers to provide a specific API, new and innovative hardware can be built for the web from day one.

The engineers also touch on security. A USB device and a computer trust one another by default, so there has to be a safeguard for your data. To help, the engineers plan to invent a type of Cross-Origin Resource Sharing (CORS) which prevents Webpages from requesting data from anything other than the page you’re visiting.

That means a Webpage couldn’t ever use the USB device to access your computer, or any files that it or the USB device itself may hold.

Luckily, the API was also designed to be backwards compatible, which may allow developers to breathe new life into old peripherals. If you want to check out the full WebUSB codebase, it’s being hosted on GitHub.

The 💜 of EU tech

The latest rumblings from the EU tech scene, a story from our wise ol' founder Boris, and some questionable AI art. It's free, every week, in your inbox. Sign up now!

via Softpedia

Get the TNW newsletter

Get the most important tech news in your inbox each week.

Also tagged with