Struct redbpf_probes::xdp::XdpContext[][src]

pub struct XdpContext {
    pub ctx: *mut xdp_md,
}
Expand description

Context object provided to XDP programs.

XDP programs are passed a XdpContext instance as their argument. Through the context, programs can inspect, modify and redirect the underlying networking data.

Fields

ctx: *mut xdp_md

Implementations

Returns the raw xdp_md context passed by the kernel.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Returns the packet length.

Returns a raw pointer to a given address inside the buffer. Read more

Returns a raw pointer to the address following prev plus the size of a T Read more

Returns the packet’s Ethernet header if present.

Returns the packet’s IP header if present.

Returns the packet’s transport header if present.

Returns the packet’s data starting after the transport headers.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.