PPP miscellaneous functions. More...
Go to the source code of this file.
Functions | |
error_t | pppSendConfigureAckNak (PppContext *context, const PppConfigurePacket *configureReqPacket, PppProtocol protocol, PppCode code) |
Send Configure-Ack, Nak or Reject packet. More... | |
error_t | pppSendTerminateReq (PppContext *context, uint8_t identifier, PppProtocol protocol) |
Send Terminate-Request packet. More... | |
error_t | pppSendTerminateAck (PppContext *context, uint8_t identifier, PppProtocol protocol) |
Send Terminate-Ack packet. More... | |
error_t | pppSendCodeRej (PppContext *context, const PppPacket *packet, uint8_t identifier, PppProtocol protocol) |
Send Code-Reject packet. More... | |
error_t | pppSendProtocolRej (PppContext *context, uint8_t identifier, uint16_t protocol, const uint8_t *information, size_t length) |
Send Protocol-Reject packet. More... | |
error_t | pppSendEchoRep (PppContext *context, const PppEchoPacket *echoReqPacket, PppProtocol protocol) |
Send Echo-Reply packet. More... | |
error_t | pppAddOption (PppConfigurePacket *packet, uint8_t optionType, const void *optionValue, uint8_t optionLen) |
Add an option to a Configure packet. More... | |
Detailed Description
PPP miscellaneous functions.
License
SPDX-License-Identifier: GPL-2.0-or-later
Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.
This file is part of CycloneTCP Open.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- Version
- 2.4.4
Definition in file ppp_misc.h.
Function Documentation
◆ pppAddOption()
error_t pppAddOption | ( | PppConfigurePacket * | packet, |
uint8_t | optionType, | ||
const void * | optionValue, | ||
uint8_t | optionLen | ||
) |
Add an option to a Configure packet.
- Parameters
-
[in,out] packet Pointer to the Configure packet [in] optionType Option type [in] optionValue Option value [in] optionLen Length of the option value
- Returns
- Error code
Definition at line 454 of file ppp_misc.c.
◆ pppSendCodeRej()
error_t pppSendCodeRej | ( | PppContext * | context, |
const PppPacket * | packet, | ||
uint8_t | identifier, | ||
PppProtocol | protocol | ||
) |
Send Code-Reject packet.
- Parameters
-
[in] context PPP context [in] packet Un-interpretable packet received from the peer [in] identifier Identifier field [in] protocol Protocol field
- Returns
- Error code
Definition at line 268 of file ppp_misc.c.
◆ pppSendConfigureAckNak()
error_t pppSendConfigureAckNak | ( | PppContext * | context, |
const PppConfigurePacket * | configureReqPacket, | ||
PppProtocol | protocol, | ||
PppCode | code | ||
) |
Send Configure-Ack, Nak or Reject packet.
- Parameters
-
[in] context PPP context [in] configureReqPacket Pointer to the incoming Configure-Request [in] protocol Protocol field [in] code Code field
- Returns
- Error code
Definition at line 56 of file ppp_misc.c.
◆ pppSendEchoRep()
error_t pppSendEchoRep | ( | PppContext * | context, |
const PppEchoPacket * | echoReqPacket, | ||
PppProtocol | protocol | ||
) |
Send Echo-Reply packet.
- Parameters
-
[in] context PPP context [in] echoReqPacket Echo-Request packet received from the peer [in] protocol Protocol field
- Returns
- Error code
Definition at line 390 of file ppp_misc.c.
◆ pppSendProtocolRej()
error_t pppSendProtocolRej | ( | PppContext * | context, |
uint8_t | identifier, | ||
uint16_t | protocol, | ||
const uint8_t * | information, | ||
size_t | length | ||
) |
Send Protocol-Reject packet.
- Parameters
-
[in] context PPP context [in] identifier Identifier field [in] protocol Rejected protocol [in] information Rejected information [in] length Length of the rejected information
- Returns
- Error code
Definition at line 329 of file ppp_misc.c.
◆ pppSendTerminateAck()
error_t pppSendTerminateAck | ( | PppContext * | context, |
uint8_t | identifier, | ||
PppProtocol | protocol | ||
) |
Send Terminate-Ack packet.
- Parameters
-
[in] context PPP context [in] identifier Identifier field [in] protocol Protocol field
- Returns
- Error code
Definition at line 217 of file ppp_misc.c.
◆ pppSendTerminateReq()
error_t pppSendTerminateReq | ( | PppContext * | context, |
uint8_t | identifier, | ||
PppProtocol | protocol | ||
) |
Send Terminate-Request packet.
- Parameters
-
[in] context PPP context [in] identifier Identifier field [in] protocol Protocol field
- Returns
- Error code
Definition at line 167 of file ppp_misc.c.