ng_deflate.4 (233648) | ng_deflate.4 (242997) |
---|---|
1.\" 2.\" Author: Alexander Motin <mav@alkar.net> 3.\" 4.\" Copyright (c) 2006, Alexander Motin <mav@alkar.net> 5.\" All rights reserved. 6.\" 7.\" Redistribution and use in source and binary forms, with or without 8.\" modification, are permitted provided that the following conditions --- 12 unchanged lines hidden (view full) --- 21.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27.\" SUCH DAMAGE. 28.\" | 1.\" 2.\" Author: Alexander Motin <mav@alkar.net> 3.\" 4.\" Copyright (c) 2006, Alexander Motin <mav@alkar.net> 5.\" All rights reserved. 6.\" 7.\" Redistribution and use in source and binary forms, with or without 8.\" modification, are permitted provided that the following conditions --- 12 unchanged lines hidden (view full) --- 21.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27.\" SUCH DAMAGE. 28.\" |
29.\" $FreeBSD: head/share/man/man4/ng_deflate.4 233648 2012-03-29 05:02:12Z eadler $ | 29.\" $FreeBSD: head/share/man/man4/ng_deflate.4 242997 2012-11-13 20:41:36Z joel $ |
30.\" 31.Dd December 23, 2006 32.Dt NG_DEFLATE 4 33.Os 34.Sh NAME 35.Nm ng_deflate 36.Nd Deflate PPP compression (RFC 1979) netgraph node type 37.Sh SYNOPSIS --- 18 unchanged lines hidden (view full) --- 56Corresponding 57.Xr ng_ppp 4 58node hook must be switched to 59.Dv NG_PPP_DECOMPRESS_FULL 60mode to permit sending uncompressed frames. 61.Sh HOOKS 62This node type supports the following hooks: 63.Pp | 30.\" 31.Dd December 23, 2006 32.Dt NG_DEFLATE 4 33.Os 34.Sh NAME 35.Nm ng_deflate 36.Nd Deflate PPP compression (RFC 1979) netgraph node type 37.Sh SYNOPSIS --- 18 unchanged lines hidden (view full) --- 56Corresponding 57.Xr ng_ppp 4 58node hook must be switched to 59.Dv NG_PPP_DECOMPRESS_FULL 60mode to permit sending uncompressed frames. 61.Sh HOOKS 62This node type supports the following hooks: 63.Pp |
64.Bl -tag -compact -width decomp | 64.Bl -tag -compact -width ".Va decomp" |
65.It Va comp 66Connection to 67.Xr ng_ppp 4 68.Va comp 69hook. 70Incoming frames are compressed (if possible) and sent back out the same hook. 71.It Va decomp 72Connection to --- 4 unchanged lines hidden (view full) --- 77back out the same hook. 78.El 79.Pp 80Only one hook can be connected at the same time, specifying node's 81operation mode. 82.Sh CONTROL MESSAGES 83This node type supports the generic control messages, plus the following: 84.Bl -tag -width foo | 65.It Va comp 66Connection to 67.Xr ng_ppp 4 68.Va comp 69hook. 70Incoming frames are compressed (if possible) and sent back out the same hook. 71.It Va decomp 72Connection to --- 4 unchanged lines hidden (view full) --- 77back out the same hook. 78.El 79.Pp 80Only one hook can be connected at the same time, specifying node's 81operation mode. 82.Sh CONTROL MESSAGES 83This node type supports the generic control messages, plus the following: 84.Bl -tag -width foo |
85.It Dv NGM_DEFLATE_CONFIG Pq Li config | 85.It Dv NGM_DEFLATE_CONFIG Pq Ic config |
86This command resets and configures the node for a session 87(i.e., for compression or decompression). 88This command takes a 89.Vt "struct ng_deflate_config" 90as an argument: 91.Bd -literal -offset 0n 92struct ng_deflate_config { 93 u_char enable; /* node enabled */ 94 u_char windowBits; /* log2(Window size) */ 95}; 96.Ed 97The 98.Fa enabled 99field enables traffic flow through the node. 100The 101.Fa windowBits 102specify compression windows size as negotiated by the 103Compression Control Protocol (CCP) in PPP. | 86This command resets and configures the node for a session 87(i.e., for compression or decompression). 88This command takes a 89.Vt "struct ng_deflate_config" 90as an argument: 91.Bd -literal -offset 0n 92struct ng_deflate_config { 93 u_char enable; /* node enabled */ 94 u_char windowBits; /* log2(Window size) */ 95}; 96.Ed 97The 98.Fa enabled 99field enables traffic flow through the node. 100The 101.Fa windowBits 102specify compression windows size as negotiated by the 103Compression Control Protocol (CCP) in PPP. |
104.It Dv NGM_DEFLATE_RESETREQ Pq Li resetreq | 104.It Dv NGM_DEFLATE_RESETREQ Pq Ic resetreq |
105This message contains no arguments, and is bi-directional. 106If an error is detected during decompression, this message is sent by the 107node to the originator of the 108.Dv NGM_DEFLATE_CONFIG 109message that initiated the session. 110The receiver should respond by sending a PPP CCP Reset-Request to the peer. 111.Pp 112This message may also be received by this node type when a CCP Reset-Request 113or Reset-Ack is received by the local PPP entity. 114The node will respond by flushing its compression state so the sides 115can resynchronize. | 105This message contains no arguments, and is bi-directional. 106If an error is detected during decompression, this message is sent by the 107node to the originator of the 108.Dv NGM_DEFLATE_CONFIG 109message that initiated the session. 110The receiver should respond by sending a PPP CCP Reset-Request to the peer. 111.Pp 112This message may also be received by this node type when a CCP Reset-Request 113or Reset-Ack is received by the local PPP entity. 114The node will respond by flushing its compression state so the sides 115can resynchronize. |
116.It Dv NGM_DEFLATE_GET_STATS Pq Li getstats | 116.It Dv NGM_DEFLATE_GET_STATS Pq Ic getstats |
117This control message obtains statistics for a given hook. 118The statistics are returned in 119.Vt "struct ng_deflate_stats" : 120.Bd -literal 121struct ng_deflate_stats { 122 uint64_t FramesPlain; 123 uint64_t FramesComp; 124 uint64_t FramesUncomp; 125 uint64_t InOctets; 126 uint64_t OutOctets; 127 uint64_t Errors; 128}; 129.Ed | 117This control message obtains statistics for a given hook. 118The statistics are returned in 119.Vt "struct ng_deflate_stats" : 120.Bd -literal 121struct ng_deflate_stats { 122 uint64_t FramesPlain; 123 uint64_t FramesComp; 124 uint64_t FramesUncomp; 125 uint64_t InOctets; 126 uint64_t OutOctets; 127 uint64_t Errors; 128}; 129.Ed |
130.It Dv NGM_DEFLATE_CLR_STATS Pq Li clrstats | 130.It Dv NGM_DEFLATE_CLR_STATS Pq Ic clrstats |
131This control message clears statistics for a given hook. | 131This control message clears statistics for a given hook. |
132.It Dv NGM_DEFLATE_GETCLR_STATS Pq Li getclrstats | 132.It Dv NGM_DEFLATE_GETCLR_STATS Pq Ic getclrstats |
133This control message obtains and clears statistics for a given hook. 134.El 135.Sh SHUTDOWN 136This node shuts down upon receipt of a 137.Dv NGM_SHUTDOWN 138control message, or when hook have been disconnected. 139.Sh SEE ALSO 140.Xr netgraph 4 , --- 18 unchanged lines hidden --- | 133This control message obtains and clears statistics for a given hook. 134.El 135.Sh SHUTDOWN 136This node shuts down upon receipt of a 137.Dv NGM_SHUTDOWN 138control message, or when hook have been disconnected. 139.Sh SEE ALSO 140.Xr netgraph 4 , --- 18 unchanged lines hidden --- |