Disable P2P feature (WebRTC)

disable p2p connection on all page

目前為 2021-12-09 提交的版本,檢視 最新版本

  1. // ==UserScript==
  2. // @namespace https://github.com/NateScarlet/Scripts/tree/master/user-script
  3. // @name Disable P2P feature (WebRTC)
  4. // @description disable p2p connection on all page
  5. // @grant none
  6. // @run-at document-start
  7. // @include *
  8. // @version 2021.12.09+30c1d566
  9. // ==/UserScript==
  10.  
  11. (() => {
  12. // disable_p2p.ts
  13. delete window.RTCPeerConnection;
  14. delete window.mozRTCPeerConnection;
  15. delete window.webkitRTCPeerConnection;
  16. })();