html5 getusermedia() 不使用 ssl 捕获视频

html5 getusermedia() capture video without ssl

我需要从网络摄像头捕获视频并将其上传到我的 IIS。 我已经使用 html5 和 JS 与 webrtc 来做到这一点。一切正常,但 chrome 和歌剧说,需要 ssl。如何避免这个问题?

你无法避免它;从 Chrome 49 开始,getUserMedia API 仅在 "secure contexts" 中可用(即 https 站点和 localhost)。