[−][src]Enum nng::options::RecvMaxSize
The maximum message size that the will be accepted from a remote peer.
If a peer attempts to send a message larger than this, then the message will be discarded. If the value of this is zero, then no limit on message sizes is enforced. This option exists to prevent certain kinds of denial-of-service attacks, where a malicious agent can claim to want to send an extraordinarily large message, without sending any data. This option can be set for the socket, but may be overridden for on a per-dialer or per-listener basis.
Note that some transports may have further message size restrictions.
Support
- Dialers and Listeners can use this with the following transports:
- TCP
- ZeroTier
- IPC
- TLS
- WebSocket
- Pipes can read this value on the following transports:
- ZeroTier
- Sockets can utilize this to set a new default value.
Trait Implementations
impl Opt for RecvMaxSize
[src]
impl GetOpt<RecvMaxSize> for Dialer
[src]
impl GetOpt<RecvMaxSize> for DialerOptions
[src]
impl GetOpt<RecvMaxSize> for Pipe
[src]
impl SetOpt<RecvMaxSize> for DialerOptions
[src]
impl SetOpt<RecvMaxSize> for ListenerOptions
[src]
impl SetOpt<RecvMaxSize> for Socket
[src]
impl Clone for RecvMaxSize
[src]
fn clone(&self) -> RecvMaxSize
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for RecvMaxSize
[src]
impl Eq for RecvMaxSize
[src]
impl Ord for RecvMaxSize
[src]
fn cmp(&self, other: &RecvMaxSize) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
1.21.0[src]
fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<RecvMaxSize> for RecvMaxSize
[src]
fn eq(&self, other: &RecvMaxSize) -> bool
[src]
#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl PartialOrd<RecvMaxSize> for RecvMaxSize
[src]
fn partial_cmp(&self, other: &RecvMaxSize) -> Option<Ordering>
[src]
#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl Debug for RecvMaxSize
[src]
impl Display for RecvMaxSize
[src]
impl Hash for RecvMaxSize
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl StructuralPartialEq for RecvMaxSize
[src]
impl StructuralEq for RecvMaxSize
[src]
Auto Trait Implementations
impl Send for RecvMaxSize
impl Sync for RecvMaxSize
impl Unpin for RecvMaxSize
impl UnwindSafe for RecvMaxSize
impl RefUnwindSafe for RecvMaxSize
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,