| 1 |
/* |
| 2 |
* ccp.h - Definitions for PPP Compression Control Protocol. |
| 3 |
* |
| 4 |
* Copyright (c) 1994-2024 Paul Mackerras. All rights reserved. |
| 5 |
* |
| 6 |
* Redistribution and use in source and binary forms, with or without |
| 7 |
* modification, are permitted provided that the following conditions |
| 8 |
* are met: |
| 9 |
* |
| 10 |
* 1. Redistributions of source code must retain the above copyright |
| 11 |
* notice, this list of conditions and the following disclaimer. |
| 12 |
* |
| 13 |
* 2. Redistributions in binary form must reproduce the above copyright |
| 14 |
* notice, this list of conditions and the following disclaimer in |
| 15 |
* the documentation and/or other materials provided with the |
| 16 |
* distribution. |
| 17 |
* |
| 18 |
* THE AUTHORS OF THIS SOFTWARE DISCLAIM ALL WARRANTIES WITH REGARD TO |
| 19 |
* THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY |
| 20 |
* AND FITNESS, IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY |
| 21 |
* SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
| 22 |
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN |
| 23 |
* AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING |
| 24 |
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
| 25 |
*/ |
| 26 |
#ifndef PPP_CCP_H |
| 27 |
#define PPP_CCP_H |
| 28 |
|
| 29 |
#include "pppdconf.h" |
| 30 |
|
| 31 |
#ifdef __cplusplus |
| 32 |
extern "C" { |
| 33 |
#endif |
| 34 |
|
| 35 |
typedef struct ccp_options { |
| 36 |
bool bsd_compress; /* do BSD Compress? */ |
| 37 |
bool deflate; /* do Deflate? */ |
| 38 |
bool predictor_1; /* do Predictor-1? */ |
| 39 |
bool predictor_2; /* do Predictor-2? */ |
| 40 |
bool deflate_correct; /* use correct code for deflate? */ |
| 41 |
bool deflate_draft; /* use draft RFC code for deflate? */ |
| 42 |
unsigned char mppe; /* MPPE bitfield */ |
| 43 |
unsigned short bsd_bits; /* # bits/code for BSD Compress */ |
| 44 |
unsigned short deflate_size; /* lg(window size) for Deflate */ |
| 45 |
short method; /* code for chosen compression method */ |
| 46 |
} ccp_options; |
| 47 |
|
| 48 |
extern fsm ccp_fsm[]; |
| 49 |
extern ccp_options ccp_wantoptions[]; |
| 50 |
extern ccp_options ccp_gotoptions[]; |
| 51 |
extern ccp_options ccp_allowoptions[]; |
| 52 |
extern ccp_options ccp_hisoptions[]; |
| 53 |
|
| 54 |
extern struct protent ccp_protent; |
| 55 |
|
| 56 |
#ifdef __cplusplus |
| 57 |
} |
| 58 |
#endif |
| 59 |
|
| 60 |
#endif // PPP_CCP_H |