pfq-lang (Spec 0.1)

Safe HaskellNone

Network.PFQ.Lang.Experimental

Contents

Synopsis

Experimental Functions

This set of experimental functions may be subject to changes in future releases

dummy :: Int -> NetFunction #

dummy_strings :: [String] -> NetFunction #

steer_gtp_usr :: IPv4 -> Int -> NetFunction #

Dispatch the packet across the sockets with a randomized algorithm that guarantees per-user flows consistency on top of GTP tunnel protocol (Control-Plane packets are broadcasted to all sockets).

(steer_gtp_usr "192.168.0.0" 16)

steer_key :: FlowKey -> NetFunction #

Dispatch the packet to a given socket with id.

ip >-> steer_key key_5tuple

gtp :: NetFunction #

Evaluate to Pass Qbuff in case of GTP packet, Drop it otherwise.

gtp_cp :: NetFunction #

Evaluate to Pass Qbuff in case of GTP Control-Plane packet, Drop it otherwise.

gtp_up :: NetFunction #

Evaluate to Pass Qbuff in case of GTP User-Plane packet, Drop it otherwise.

is_gtp :: NetPredicate #

Evaluate to True if the Qbuff is a GTP packet.

is_gtp_cp :: NetPredicate #

Evaluate to True if the Qbuff is a GTP Control-Plane packet.

is_gtp_up :: NetPredicate #

Evaluate to True if the Qbuff is a GTP User-Plane packet.

trace :: NetFunction #

Log monadic/state information to syslog.

udp >-> log_msg "This is an UDP packet"

kernel_if :: NetPredicate -> NetFunction #

Conditional forwarder to kernel. Evaluate to Pass Qbuff.

kernel_if is_tcp

detour_if :: NetPredicate -> NetFunction #

Conditional forwarder to kernel. Evaluate to Drop if predicate evaluates to True, Pass otherwise.

detour_if is_tcp

is_broadcast :: NetPredicate #

Evaluate to True if the Qbuff is broadcast frame.

is_multicast :: NetPredicate #

Evaluate to True if the Qbuff is multicast frame.

is_ip_broadcast :: NetPredicate #

Evaluate to True if the Qbuff is broadcast IP packet.

is_ip_multicast :: NetPredicate #

Evaluate to True if the Qbuff is multicast IP packet.

is_ip_host :: NetPredicate #

Evaluate to True if the Qbuff IP address matches that of the incoming interface, False otherwise.

is_incoming_host :: NetPredicate #

Evaluate to True if the Qbuff IP address matches that of the incoming interface, is a broadcast or a multicast frame.

mac_broadcast :: NetFunction #

Evaluate to Pass Qbuff if it is a broadcast frame, Drop it otherwise.

mac_multicast :: NetFunction #

Evaluate to Pass Qbuff if it is a multicast frame, Drop it otherwise.

incoming_host :: NetFunction #

Evaluate to Pass Qbuff if the IP address matches that of the incoming interface, is a broadcast or a multicast frame, Drop it otherwise.

ip_broadcast :: NetFunction #

Evaluate to Pass Qbuff if it is a broadcast IP packet, Drop it otherwise.

ip_multicast :: NetFunction #

Evaluate to Pass Qbuff if it is a multicast IP packet, Drop it otherwise.

ip_host :: NetFunction #

Evaluate to Pass Qbuff if the IP address matches that of the incoming interface, Drop it otherwise.

is_eth_pup :: NetPredicate #

Ethernet protocols