leveraging virtuous side-effect of using strictest setting for webrtc local IP address prevention, see https://github.com/uBlockOrigin/uAssets/issues/333#issuecomment-289426678

This commit is contained in:
gorhill 2017-03-27 10:09:10 -04:00
parent 419fad084e
commit 69b7dc3289
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2
1 changed files with 6 additions and 10 deletions

View File

@ -169,16 +169,12 @@ vAPI.browserSettings = (function() {
scope: 'regular'
}, this.noopCallback);
} else {
// Respect current stricter setting if any.
cpn.webRTCIPHandlingPolicy.get({}, function(details) {
var value = details.value === 'disable_non_proxied_udp' ?
'disable_non_proxied_udp' :
'default_public_interface_only';
cpn.webRTCIPHandlingPolicy.set({
value: value,
scope: 'regular'
}, this.noopCallback);
}.bind(this));
// https://github.com/uBlockOrigin/uAssets/issues/333#issuecomment-289426678
// - Leverage virtuous side-effect of strictest setting.
cpn.webRTCIPHandlingPolicy.set({
value: 'disable_non_proxied_udp',
scope: 'regular'
}, this.noopCallback);
}
} catch(ex) {
console.error(ex);