Chrome 浏览器获取音频设备权限问题 Microphone and Camera access no longer works on insecure origins

1.Chrome 浏览器使用 navigator.mediaDevices.getUserMedia获取资源时报错

Cannot read property getUserMedia of undefined

Chrome 浏览器获取音频设备权限问题 Microphone and Camera access no longer works on insecure origins

 

2.Chrome 浏览器http无法调用音频设备

Microphone and Camera access no longer works on insecure origins. To use this feature, you should consider switching your application to a secure origin, such as HTTPS. See https://goo.gl/rStTGz for more details.

Chrome 浏览器获取音频设备权限问题 Microphone and Camera access no longer works on insecure origins

 

 

解决Chrome浏览器安全权限问题

我们可以通过以下方式解决:

一、网页使用https方式访问

此操作需要依赖web服务提供者实现https的访问方式。

二、修改浏览器安全配置(最直接、简单)

1、浏览器地址栏输入:

chrome://flags/#unsafely-treat-insecure-origin-as-secure

Chrome 浏览器获取音频设备权限问题 Microphone and Camera access no longer works on insecure origins 

2、开启Insecure origins treated as secure

在输入栏内输入你需要访问音频设备的地址url,然后将右侧Disabled 改成 Enabled,浏览器会提示重启(Relaunch)

Chrome 浏览器获取音频设备权限问题 Microphone and Camera access no longer works on insecure origins

 

上一篇:#python&装饰器(*****)


下一篇:2022-过TP附加调试(地下城与勇士DNF)