HTML5 Voice Input mic access

15,861

Solution 1

The microphone isn't directly being exposed to the Web page—it's just posting the speech (and receiving text) through Google servers so it's not considered a security issue (and you have to click the microphone icon to start it). It's pretty similar to how voice input works on Android and Google's iPhone/Blackberry apps.

Solution 2

It is explicitly asking permission before giving access, that's what clicking the microphone icon is.

Think of it more like the <input type="file"> element -- you click "Browse", it shows you your file system, and the browser sends the selected file directly to the server.

Solution 3

For those saying that you can't style the button and it can't be exploited - it was done with Facebook like buttons - http://www.esrun.co.uk/blog/disguising-a-facebook-like-link/

So what's to stop it working for the Google Mic button?

Share:
15,861
Ali
Author by

Ali

Updated on July 19, 2022

Comments

  • Ali
    Ali almost 2 years

    How does the HTML5 Voice input on Chrome (Mac) get access to the mic? Is it because I have the google voice plugin installed?

    Shouldn't the browser explicitly ask for permission before giving access?

    http://slides.html5rocks.com/#speech-input

  • Ali
    Ali over 13 years
    But cant the field be hidden and the icon could be changed to look like another button? Also, how exactly is the script accessing the microphone? Is it a plug in like flash?
  • Jason Hall
    Jason Hall over 13 years
    It's not a plugin, it's built into the browser. That's why this doesn't work on any browser but Chrome (for now)
  • Nicholas Riley
    Nicholas Riley over 13 years
    If the field's hidden, you can't click on it to trigger it. The icon can't be styled.
  • tonyhb
    tonyhb about 13 years
    It's an input type="text" still, and the icon is hard-coded into webkit/chrome. The closest you can get to hiding the icon is by using a background gradient similar to -webkit-gradient(linear, 0 0, 0 bottom, from(#9A9A9A), to(#818181)). Even then, you have to click the button.
  • rahulserver
    rahulserver about 12 years
    " it's just posting the text"-no it is not! See this link:mikepultz.com/2011/03/accessing-google-speech-api-chrom‌​e-11 .U may edit ur answer!