pub enum WebRtcPolicy {
AllowAll,
DisableNonProxied,
BlockAll,
}Expand description
Controls how WebRTC connections are handled to prevent IP leakage.
§Example
use stygian_browser::webrtc::WebRtcPolicy;
assert_eq!(WebRtcPolicy::default(), WebRtcPolicy::DisableNonProxied);Variants§
AllowAll
No WebRTC restrictions. The real IP may be exposed.
DisableNonProxied
Force WebRTC traffic through the configured proxy.
Applies the disable_non_proxied_udp handling policy via
--force-webrtc-ip-handling-policy. This is the recommended setting
when a proxy is in use.
BlockAll
Completely block WebRTC by overriding RTCPeerConnection with a stub
that never emits ICE candidates. Breaks real-time communication on
target pages but provides the strongest IP protection.
Trait Implementations§
Source§impl Clone for WebRtcPolicy
impl Clone for WebRtcPolicy
Source§fn clone(&self) -> WebRtcPolicy
fn clone(&self) -> WebRtcPolicy
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for WebRtcPolicy
impl Debug for WebRtcPolicy
Source§impl Default for WebRtcPolicy
impl Default for WebRtcPolicy
Source§fn default() -> WebRtcPolicy
fn default() -> WebRtcPolicy
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for WebRtcPolicy
impl<'de> Deserialize<'de> for WebRtcPolicy
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for WebRtcPolicy
impl PartialEq for WebRtcPolicy
Source§impl Serialize for WebRtcPolicy
impl Serialize for WebRtcPolicy
impl Copy for WebRtcPolicy
impl Eq for WebRtcPolicy
impl StructuralPartialEq for WebRtcPolicy
Auto Trait Implementations§
impl Freeze for WebRtcPolicy
impl RefUnwindSafe for WebRtcPolicy
impl Send for WebRtcPolicy
impl Sync for WebRtcPolicy
impl Unpin for WebRtcPolicy
impl UnwindSafe for WebRtcPolicy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.