igmp_router_misc.h File Reference

Helper functions fore IGMP router. More...

#include "core/net.h"
#include "igmp/igmp_router.h"

Go to the source code of this file.

Functions

error_t igmpRouterSendGeneralQuery (IgmpRouterContext *context)
 Send General Query message. More...
 
error_t igmpRouterSendGroupSpecificQuery (IgmpRouterContext *context, Ipv4Addr groupAddr)
 Send Group-Specific Query message. More...
 
error_t igmpRouterSendMembershipQuery (IgmpRouterContext *context, Ipv4Addr destAddr, Ipv4Addr groupAddr, systime_t maxRespTime)
 Send Membership Query message. More...
 
void igmpRouterProcessMessage (IgmpRouterContext *context, const Ipv4PseudoHeader *pseudoHeader, const IgmpMessage *message, size_t length)
 Process incoming IGMP message. More...
 
void igmpRouterProcessMembershipQuery (IgmpRouterContext *context, const Ipv4PseudoHeader *pseudoHeader, const IgmpMessage *message, size_t length)
 Process incoming Membership Query message. More...
 
void igmpRouterProcessMembershipReport (IgmpRouterContext *context, const Ipv4PseudoHeader *pseudoHeader, const IgmpMessage *message, size_t length)
 Process incoming Membership Report message. More...
 
void igmpRouterProcessLeaveGroup (IgmpRouterContext *context, const Ipv4PseudoHeader *pseudoHeader, const IgmpMessage *message, size_t length)
 Process incoming Leave Group message. More...
 
IgmpRouterGroupigmpRouterCreateGroup (IgmpRouterContext *context, Ipv4Addr groupAddr)
 Create a new multicast group. More...
 
IgmpRouterGroupigmpRouterFindGroup (IgmpRouterContext *context, Ipv4Addr groupAddr)
 Search the list of multicast groups for a given group address. More...
 
void igmpRouterDeleteGroup (IgmpRouterContext *context, IgmpRouterGroup *group)
 Delete a multicast group. More...
 

Detailed Description

Helper functions fore IGMP router.

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.

Author
Oryx Embedded SARL (www.oryx-embedded.com)
Version
2.4.4

Definition in file igmp_router_misc.h.

Function Documentation

◆ igmpRouterCreateGroup()

IgmpRouterGroup* igmpRouterCreateGroup ( IgmpRouterContext context,
Ipv4Addr  groupAddr 
)

Create a new multicast group.

Parameters
[in]contextPointer to the IGMP router context
[in]groupAddrMulticast group address
Returns
Pointer to the newly created multicast group

Definition at line 426 of file igmp_router_misc.c.

◆ igmpRouterDeleteGroup()

void igmpRouterDeleteGroup ( IgmpRouterContext context,
IgmpRouterGroup group 
)

Delete a multicast group.

Parameters
[in]contextPointer to the IGMP router context
[in]groupMulticast group

Definition at line 506 of file igmp_router_misc.c.

◆ igmpRouterFindGroup()

IgmpRouterGroup* igmpRouterFindGroup ( IgmpRouterContext context,
Ipv4Addr  groupAddr 
)

Search the list of multicast groups for a given group address.

Parameters
[in]contextPointer to the IGMP router context
[in]groupAddrMulticast group address
Returns
Pointer to the matching multicast group, if any

Definition at line 472 of file igmp_router_misc.c.

◆ igmpRouterProcessLeaveGroup()

void igmpRouterProcessLeaveGroup ( IgmpRouterContext context,
const Ipv4PseudoHeader pseudoHeader,
const IgmpMessage message,
size_t  length 
)

Process incoming Leave Group message.

Parameters
[in]contextPointer to the IGMP router context
[in]pseudoHeaderIPv4 pseudo header
[in]messagePointer to the incoming IGMP message
[in]lengthLength of the IGMP message, in bytes

Definition at line 354 of file igmp_router_misc.c.

◆ igmpRouterProcessMembershipQuery()

void igmpRouterProcessMembershipQuery ( IgmpRouterContext context,
const Ipv4PseudoHeader pseudoHeader,
const IgmpMessage message,
size_t  length 
)

Process incoming Membership Query message.

Parameters
[in]contextPointer to the IGMP router context
[in]pseudoHeaderIPv4 pseudo header
[in]messagePointer to the incoming IGMP message
[in]lengthLength of the IGMP message, in bytes

Definition at line 185 of file igmp_router_misc.c.

◆ igmpRouterProcessMembershipReport()

void igmpRouterProcessMembershipReport ( IgmpRouterContext context,
const Ipv4PseudoHeader pseudoHeader,
const IgmpMessage message,
size_t  length 
)

Process incoming Membership Report message.

Parameters
[in]contextPointer to the IGMP router context
[in]pseudoHeaderIPv4 pseudo header
[in]messagePointer to the incoming IGMP message
[in]lengthLength of the IGMP message, in bytes

Definition at line 293 of file igmp_router_misc.c.

◆ igmpRouterProcessMessage()

void igmpRouterProcessMessage ( IgmpRouterContext context,
const Ipv4PseudoHeader pseudoHeader,
const IgmpMessage message,
size_t  length 
)

Process incoming IGMP message.

Parameters
[in]contextPointer to the IGMP router context
[in]pseudoHeaderIPv4 pseudo header
[in]messagePointer to the incoming IGMP message
[in]lengthLength of the IGMP message, in bytes

Definition at line 149 of file igmp_router_misc.c.

◆ igmpRouterSendGeneralQuery()

error_t igmpRouterSendGeneralQuery ( IgmpRouterContext context)

Send General Query message.

Parameters
[in]contextPointer to the IGMP router context
Returns
Error code

Definition at line 51 of file igmp_router_misc.c.

◆ igmpRouterSendGroupSpecificQuery()

error_t igmpRouterSendGroupSpecificQuery ( IgmpRouterContext context,
Ipv4Addr  groupAddr 
)

Send Group-Specific Query message.

Parameters
[in]contextPointer to the IGMP router context
[in]groupAddrMulticast address of the group being queried
Returns
Error code

Definition at line 68 of file igmp_router_misc.c.

◆ igmpRouterSendMembershipQuery()

error_t igmpRouterSendMembershipQuery ( IgmpRouterContext context,
Ipv4Addr  destAddr,
Ipv4Addr  groupAddr,
systime_t  maxRespTime 
)

Send Membership Query message.

Parameters
[in]contextPointer to the IGMP router context
[in]destAddrDestination IP address
[in]groupAddrMulticast group address
[in]maxRespTimeMaximum response time
Returns
Error code

Definition at line 87 of file igmp_router_misc.c.