|
INET Framework for OMNeT++/OMNEST
|
#include <Igmpv2.h>
|
| enum | RouterState { IGMP_RS_INITIAL,
IGMP_RS_QUERIER,
IGMP_RS_NON_QUERIER
} |
| |
| enum | RouterGroupState { IGMP_RGS_NO_MEMBERS_PRESENT,
IGMP_RGS_MEMBERS_PRESENT,
IGMP_RGS_V1_MEMBERS_PRESENT,
IGMP_RGS_CHECKING_MEMBERSHIP
} |
| |
| enum | HostGroupState { IGMP_HGS_NON_MEMBER,
IGMP_HGS_DELAYING_MEMBER,
IGMP_HGS_IDLE_MEMBER
} |
| |
| enum | IgmpTimerKind { IGMP_QUERY_TIMER,
IGMP_HOSTGROUP_TIMER,
IGMP_LEAVE_TIMER,
IGMP_REXMT_TIMER
} |
| |
| typedef std::map< Ipv4Address, HostGroupData * > | GroupToHostDataMap |
| |
| typedef std::map< Ipv4Address, RouterGroupData * > | GroupToRouterDataMap |
| |
| typedef std::map< int, HostInterfaceData * > | InterfaceToHostDataMap |
| |
| typedef std::map< int, RouterInterfaceData * > | InterfaceToRouterDataMap |
| |
|
| virtual int | numInitStages () const override |
| |
| virtual void | initialize (int stage) override |
| |
| virtual void | handleMessage (cMessage *msg) override |
| |
| virtual void | handleRegisterService (const Protocol &protocol, cGate *gate, ServicePrimitive servicePrimitive) override |
| |
| virtual void | handleRegisterProtocol (const Protocol &protocol, cGate *gate, ServicePrimitive servicePrimitive) override |
| |
| virtual void | receiveSignal (cComponent *source, simsignal_t signalID, cObject *obj, cObject *details) override |
| |
| virtual | ~Igmpv2 () |
| |
| void | addWatches () |
| |
| virtual void | multicastGroupJoined (NetworkInterface *ie, const Ipv4Address &groupAddr) |
| |
| virtual void | multicastGroupLeft (NetworkInterface *ie, const Ipv4Address &groupAddr) |
| |
| virtual void | configureInterface (NetworkInterface *ie) |
| |
| virtual void | deleteHostInterfaceData (int interfaceId) |
| |
| virtual void | deleteRouterInterfaceData (int interfaceId) |
| |
| virtual void | processQueryTimer (cMessage *msg) |
| |
| virtual void | processHostGroupTimer (cMessage *msg) |
| |
| virtual void | processLeaveTimer (cMessage *msg) |
| |
| virtual void | processRexmtTimer (cMessage *msg) |
| |
| virtual void | startTimer (cMessage *timer, double interval) |
| |
| virtual void | startHostTimer (NetworkInterface *ie, HostGroupData *group, double maxRespTime) |
| |
| virtual void | processIgmpMessage (Packet *packet) |
| |
| virtual void | processQuery (NetworkInterface *ie, Packet *packet) |
| |
| virtual void | processGroupQuery (NetworkInterface *ie, HostGroupData *group, simtime_t maxRespTime) |
| |
| virtual void | processV2Report (NetworkInterface *ie, Packet *packet) |
| |
| virtual void | processLeave (NetworkInterface *ie, Packet *packet) |
| |
| virtual void | sendQuery (NetworkInterface *ie, const Ipv4Address &groupAddr, double maxRespTime) |
| |
| virtual void | sendReport (NetworkInterface *ie, HostGroupData *group) |
| |
| virtual void | sendLeave (NetworkInterface *ie, HostGroupData *group) |
| |
| virtual void | sendToIP (Packet *msg, NetworkInterface *ie, const Ipv4Address &dest) |
| |
| virtual RouterGroupData * | createRouterGroupData (NetworkInterface *ie, const Ipv4Address &group) |
| |
| virtual HostGroupData * | createHostGroupData (NetworkInterface *ie, const Ipv4Address &group) |
| |
| virtual RouterGroupData * | getRouterGroupData (NetworkInterface *ie, const Ipv4Address &group) |
| |
| virtual HostGroupData * | getHostGroupData (NetworkInterface *ie, const Ipv4Address &group) |
| |
| virtual void | deleteRouterGroupData (NetworkInterface *ie, const Ipv4Address &group) |
| |
| virtual void | deleteHostGroupData (NetworkInterface *ie, const Ipv4Address &group) |
| |
| virtual RouterInterfaceData * | getRouterInterfaceData (NetworkInterface *ie) |
| |
| virtual RouterInterfaceData * | createRouterInterfaceData () |
| |
| virtual HostInterfaceData * | getHostInterfaceData (NetworkInterface *ie) |
| |
| virtual HostInterfaceData * | createHostInterfaceData () |
| |
◆ GroupToHostDataMap
◆ GroupToRouterDataMap
◆ InterfaceToHostDataMap
◆ InterfaceToRouterDataMap
◆ HostGroupState
| Enumerator |
|---|
| IGMP_HGS_NON_MEMBER | |
| IGMP_HGS_DELAYING_MEMBER | |
| IGMP_HGS_IDLE_MEMBER | |
◆ IgmpTimerKind
| Enumerator |
|---|
| IGMP_QUERY_TIMER | |
| IGMP_HOSTGROUP_TIMER | |
| IGMP_LEAVE_TIMER | |
| IGMP_REXMT_TIMER | |
◆ RouterGroupState
| Enumerator |
|---|
| IGMP_RGS_NO_MEMBERS_PRESENT | |
| IGMP_RGS_MEMBERS_PRESENT | |
| IGMP_RGS_V1_MEMBERS_PRESENT | |
| IGMP_RGS_CHECKING_MEMBERSHIP | |
◆ RouterState
| Enumerator |
|---|
| IGMP_RS_INITIAL | |
| IGMP_RS_QUERIER | |
| IGMP_RS_NON_QUERIER | |
◆ ~Igmpv2()
| inet::Igmpv2::~Igmpv2 |
( |
| ) |
|
|
protectedvirtual |
◆ addWatches()
| void inet::Igmpv2::addWatches |
( |
| ) |
|
|
protected |
◆ configureInterface()
◆ createHostGroupData()
754 ASSERT(!
containsKey(interfaceData->groups, group));
755 HostGroupData *data =
new HostGroupData(
this, group);
756 interfaceData->groups[group] = data;
Referenced by multicastGroupJoined().
◆ createHostInterfaceData()
◆ createRouterGroupData()
745 ASSERT(!
containsKey(interfaceData->groups, group));
746 RouterGroupData *data =
new RouterGroupData(
this, group);
747 interfaceData->groups[group] = data;
Referenced by processV2Report().
◆ createRouterInterfaceData()
◆ deleteHostGroupData()
788 auto it = interfaceData->groups.find(group);
789 if (it != interfaceData->groups.end()) {
790 HostGroupData *data = it->second;
791 interfaceData->groups.erase(it);
Referenced by multicastGroupLeft().
◆ deleteHostInterfaceData()
| void inet::Igmpv2::deleteHostInterfaceData |
( |
int |
interfaceId | ) |
|
|
protectedvirtual |
◆ deleteRouterGroupData()
777 auto it = interfaceData->groups.find(group);
778 if (it != interfaceData->groups.end()) {
779 RouterGroupData *data = it->second;
780 interfaceData->groups.erase(it);
Referenced by processLeaveTimer().
◆ deleteRouterInterfaceData()
| void inet::Igmpv2::deleteRouterInterfaceData |
( |
int |
interfaceId | ) |
|
|
protectedvirtual |
◆ getHostGroupData()
◆ getHostGroupStateString()
952 return "DELAYING_MEMBER";
954 return "IDLE_MEMBER";
◆ getHostInterfaceData()
◆ getRouterGroupData()
◆ getRouterGroupStateString()
936 return "NO_MEMBERS_PRESENT";
938 return "MEMBERS_PRESENT";
940 return "V1_MEMBERS_PRESENT";
942 return "CHECKING_MEMBERSHIP";
◆ getRouterInterfaceData()
◆ getRouterStateString()
928 return "NON_QUERIER";
◆ handleMessage()
| void inet::Igmpv2::handleMessage |
( |
cMessage * |
msg | ) |
|
|
overrideprotectedvirtual |
328 if (!msg->isSelfMessage()) {
329 EV_ERROR <<
"Igmpv2 disabled, dropping packet.\n";
335 if (msg->isSelfMessage()) {
336 switch (msg->getKind()) {
358 else if (!strcmp(msg->getArrivalGate()->getName(),
"routerIn"))
361 auto packet = check_and_cast<Packet *>(msg);
◆ handleRegisterProtocol()
| void inet::Igmpv2::handleRegisterProtocol |
( |
const Protocol & |
protocol, |
|
|
cGate * |
gate, |
|
|
ServicePrimitive |
servicePrimitive |
|
) |
| |
|
overrideprotectedvirtual |
◆ handleRegisterService()
◆ initialize()
| void inet::Igmpv2::initialize |
( |
int |
stage | ) |
|
|
overrideprotectedvirtual |
147 cSimpleModule::initialize(stage);
150 ift.reference(
this,
"interfaceTableModule",
true);
151 rt.reference(
this,
"routingTableModule",
true);
166 const char *crcModeString = par(
"crcMode");
175 for (
int i = 0; i <
ift->getNumInterfaces(); ++i) {
176 NetworkInterface *ie =
ift->getInterface(i);
177 if (ie->isMulticast()) {
178 if (
auto ipv4interfaceData = ie->findProtocolData<Ipv4InterfaceData>()) {
179 int n = ipv4interfaceData->getNumOfJoinedMulticastGroups();
180 for (
int j = 0; j < n; j++) {
181 auto groupAddress = ipv4interfaceData->getJoinedMulticastGroup(j);
188 for (
int i = 0; i <
ift->getNumInterfaces(); ++i) {
189 NetworkInterface *ie =
ift->getInterface(i);
190 if (ie->isMulticast())
◆ insertCrc() [1/2]
| void inet::Igmpv2::insertCrc |
( |
const Ptr< IgmpMessage > & |
igmpMsg, |
|
|
Packet * |
payload |
|
) |
| |
|
inline |
◆ insertCrc() [2/2]
965 igmpMsg->setCrc(0xC00D);
969 igmpMsg->setCrc(0xBAAD);
973 igmpMsg->setCrc(0x0000);
974 MemoryOutputStream igmpStream;
978 igmpMsg->setCrc(crc);
982 throw cRuntimeError(
"Unknown CRC mode");
Referenced by sendLeave(), sendQuery(), and sendReport().
◆ multicastGroupJoined()
255 ASSERT(ie && ie->isMulticast());
256 ASSERT(groupAddr.isMulticast());
258 if (
enabled && !groupAddr.isLinkLocalMulticast()) {
264 groupData->flag =
true;
Referenced by initialize(), and receiveSignal().
◆ multicastGroupLeft()
272 ASSERT(ie && ie->isMulticast());
273 ASSERT(groupAddr.isMulticast());
275 if (
enabled && !groupAddr.isLinkLocalMulticast()) {
279 cancelEvent(groupData->timer);
Referenced by receiveSignal().
◆ numInitStages()
| virtual int inet::Igmpv2::numInitStages |
( |
| ) |
const |
|
inlineoverrideprotectedvirtual |
◆ processGroupQuery()
549 double maxRespTimeSecs = maxRespTime.dbl();
552 cMessage *timer = group->timer;
553 simtime_t maxAbsoluteRespTime = simTime() + maxRespTimeSecs;
554 if (timer->isScheduled() && maxAbsoluteRespTime < timer->getArrivalTime())
Referenced by processQuery().
◆ processHostGroupTimer()
| void inet::Igmpv2::processHostGroupTimer |
( |
cMessage * |
msg | ) |
|
|
protectedvirtual |
396 IgmpHostTimerContext *ctx = (IgmpHostTimerContext *)msg->getContextPointer();
397 EV_DEBUG <<
"Igmpv2: Host Timer expired for group=" << ctx->hostGroup->groupAddr <<
" iface=" << ctx->ie->getInterfaceName() <<
"\n";
399 ctx->hostGroup->flag =
true;
Referenced by handleMessage().
◆ processIgmpMessage()
| void inet::Igmpv2::processIgmpMessage |
( |
Packet * |
packet | ) |
|
|
protectedvirtual |
452 EV_WARN <<
"incoming IGMP packet has wrong CRC, dropped\n";
454 PacketDropDetails details;
461 const auto& igmp = packet->peekAtFront<IgmpMessage>();
462 NetworkInterface *ie =
ift->getInterfaceById(packet->getTag<InterfaceInd>()->getInterfaceId());
463 switch (igmp->getType()) {
482 send(packet,
"routerOut");
485 throw cRuntimeError(
"Igmpv2: Unhandled message type (%d) in packet %s", igmp->getType(), packet->getName());
Referenced by handleMessage().
◆ processLeave()
627 ASSERT(ie->isMulticast());
629 const auto& msg = packet->peekAtFront<Igmpv2Leave>();
631 EV_INFO <<
"Igmpv2: received Leave Group for group=" << msg->getGroupAddress() <<
" iface=" << ie->getInterfaceName() <<
"\n";
635 if (
rt->isMulticastForwardingEnabled()) {
637 send(packet,
"routerOut");
641 Ipv4Address groupAddr = msg->getGroupAddress();
Referenced by processIgmpMessage().
◆ processLeaveTimer()
| void inet::Igmpv2::processLeaveTimer |
( |
cMessage * |
msg | ) |
|
|
protectedvirtual |
405 IgmpRouterTimerContext *ctx = (IgmpRouterTimerContext *)msg->getContextPointer();
406 EV_DEBUG <<
"Igmpv2: Leave Timer expired, deleting " << ctx->routerGroup->groupAddr <<
" from listener list of '" << ctx->ie->getInterfaceName() <<
"'\n";
409 ctx->ie->getProtocolDataForUpdate<Ipv4InterfaceData>()->removeMulticastListener(ctx->routerGroup->groupAddr);
413 cancelEvent(ctx->routerGroup->rexmtTimer);
Referenced by handleMessage().
◆ processQuery()
493 ASSERT(ie->isMulticast());
495 Ipv4Address sender = packet->getTag<
L3AddressInd>()->getSrcAddress().toIpv4();
497 const auto& igmpQry = packet->peekAtFront<IgmpQuery>(
b(packet->getBitLength()));
501 Ipv4Address groupAddr = igmpQry->getGroupAddress();
502 const Ptr<const Igmpv2Query>& v2Query = dynamicPtrCast<const Igmpv2Query>(igmpQry);
503 simtime_t maxRespTime = SimTime(v2Query ? v2Query->getMaxRespTimeCode() : 100, (SimTimeUnit) - 1);
505 if (groupAddr.isUnspecified()) {
507 EV_INFO <<
"Igmpv2: received General Membership Query on iface=" << ie->getInterfaceName() <<
"\n";
509 for (
auto& elem : interfaceData->groups)
514 EV_INFO <<
"Igmpv2: received Membership Query for group=" << groupAddr <<
" iface=" << ie->getInterfaceName() <<
"\n";
516 auto it = interfaceData->groups.find(groupAddr);
517 if (it != interfaceData->groups.end())
521 if (
rt->isMulticastForwardingEnabled()) {
523 send(packet,
"routerOut");
528 if (sender < ie->getProtocolData<Ipv4InterfaceData>()->getIPAddress()) {
533 if (!groupAddr.isUnspecified() && routerInterfaceData->igmpRouterState ==
IGMP_RS_NON_QUERIER) {
542 EV_INFO <<
"Igmpv2: multicast forwarding is not enabled on this node. \n";
Referenced by processIgmpMessage().
◆ processQueryTimer()
| void inet::Igmpv2::processQueryTimer |
( |
cMessage * |
msg | ) |
|
|
protectedvirtual |
382 NetworkInterface *ie = (NetworkInterface *)msg->getContextPointer();
384 EV_DEBUG <<
"Igmpv2: General Query timer expired, iface=" << ie->getInterfaceName() <<
"\n";
386 RouterState state = interfaceData->igmpRouterState;
Referenced by handleMessage().
◆ processRexmtTimer()
| void inet::Igmpv2::processRexmtTimer |
( |
cMessage * |
msg | ) |
|
|
protectedvirtual |
422 IgmpRouterTimerContext *ctx = (IgmpRouterTimerContext *)msg->getContextPointer();
423 EV_DEBUG <<
"Igmpv2: Rexmt Timer expired for group=" << ctx->routerGroup->groupAddr <<
" iface=" << ctx->ie->getInterfaceName() <<
"\n";
Referenced by handleMessage().
◆ processV2Report()
568 ASSERT(ie->isMulticast());
570 const auto& msg = packet->peekAtFront<Igmpv2Report>();
572 Ipv4Address groupAddr = msg->getGroupAddress();
574 EV_INFO <<
"Igmpv2: received V2 Membership Report for group=" << groupAddr <<
" iface=" << ie->getInterfaceName() <<
"\n";
581 cancelEvent(hostGroupData->timer);
582 hostGroupData->flag =
false;
587 if (
rt->isMulticastForwardingEnabled()) {
589 send(packet,
"routerOut");
594 if (!routerGroupData) {
599 if (!routerGroupData->timer) {
600 routerGroupData->timer =
new cMessage(
"Igmpv2 leave timer",
IGMP_LEAVE_TIMER);
601 routerGroupData->timer->setContextPointer(
new IgmpRouterTimerContext(ie, routerGroupData));
603 if (!routerGroupData->rexmtTimer) {
604 routerGroupData->rexmtTimer =
new cMessage(
"Igmpv2 rexmt timer",
IGMP_REXMT_TIMER);
605 routerGroupData->rexmtTimer->setContextPointer(
new IgmpRouterTimerContext(ie, routerGroupData));
610 ie->getProtocolDataForUpdate<Ipv4InterfaceData>()->addMulticastListener(groupAddr);
614 cancelEvent(routerGroupData->rexmtTimer);
620 EV_INFO <<
"Igmpv2: multicast forwarding is not enabled on this node. \n";
Referenced by processIgmpMessage().
◆ receiveSignal()
| void inet::Igmpv2::receiveSignal |
( |
cComponent * |
source, |
|
|
simsignal_t |
signalID, |
|
|
cObject * |
obj, |
|
|
cObject * |
details |
|
) |
| |
|
overrideprotectedvirtual |
224 Enter_Method(
"%s", cComponent::getSignalName(signalID));
226 NetworkInterface *ie;
228 const Ipv4MulticastGroupInfo *info;
231 info = check_and_cast<const Ipv4MulticastGroupInfo *>(obj);
235 info = check_and_cast<const Ipv4MulticastGroupInfo *>(obj);
239 ie = check_and_cast<NetworkInterface *>(obj);
240 if (ie->isMulticast())
244 ie = check_and_cast<NetworkInterface *>(obj);
245 if (ie->isMulticast()) {
246 interfaceId = ie->getInterfaceId();
◆ sendLeave()
709 ASSERT(group->groupAddr.isMulticast() && !group->groupAddr.isLinkLocalMulticast());
711 EV_INFO <<
"Igmpv2: sending Leave Group for group=" << group->groupAddr <<
" on iface=" << ie->getInterfaceName() <<
"\n";
712 Packet *packet =
new Packet(
"Igmpv2 leave");
713 const auto& msg = makeShared<Igmpv2Leave>();
714 msg->setGroupAddress(group->groupAddr);
715 msg->setChunkLength(
B(8));
717 packet->insertAtFront(msg);
719 auto raOption =
new Ipv4OptionRouterAlert();
720 packet->addTag<Ipv4OptionsReq>()->appendOption(raOption);
Referenced by multicastGroupLeft().
◆ sendQuery()
661 ASSERT(groupAddr.isUnspecified() || (groupAddr.isMulticast() && !groupAddr.isLinkLocalMulticast()));
666 if (groupAddr.isUnspecified())
667 EV_INFO <<
"Igmpv2: sending General Membership Query on iface=" << ie->getInterfaceName() <<
"\n";
669 EV_INFO <<
"Igmpv2: sending Membership Query for group=" << groupAddr <<
" on iface=" << ie->getInterfaceName() <<
"\n";
671 Packet *packet =
new Packet(
"Igmpv2 query");
672 const auto& msg = makeShared<Igmpv2Query>();
674 msg->setGroupAddress(groupAddr);
675 msg->setMaxRespTimeCode(SimTime(maxRespTime).inUnit((SimTimeUnit) - 1));
676 msg->setChunkLength(
B(8));
678 packet->insertAtFront(msg);
682 if (groupAddr.isUnspecified())
Referenced by configureInterface(), processLeave(), processQueryTimer(), and processRexmtTimer().
◆ sendReport()
691 ASSERT(group->groupAddr.isMulticast() && !group->groupAddr.isLinkLocalMulticast());
693 EV_INFO <<
"Igmpv2: sending Membership Report for group=" << group->groupAddr <<
" on iface=" << ie->getInterfaceName() <<
"\n";
694 Packet *packet =
new Packet(
"Igmpv2 report");
695 const auto& msg = makeShared<Igmpv2Report>();
696 msg->setGroupAddress(group->groupAddr);
697 msg->setChunkLength(
B(8));
699 packet->insertAtFront(msg);
701 auto raOption =
new Ipv4OptionRouterAlert();
702 packet->addTag<Ipv4OptionsReq>()->appendOption(raOption);
703 sendToIP(packet, ie, group->groupAddr);
Referenced by multicastGroupJoined(), and processHostGroupTimer().
◆ sendToIP()
728 ASSERT(ie->isMulticast());
731 msg->addTagIfAbsent<DispatchProtocolInd>()->setProtocol(&
Protocol::igmp);
733 msg->addTagIfAbsent<
InterfaceReq>()->setInterfaceId(ie->getInterfaceId());
734 msg->addTagIfAbsent<L3AddressReq>()->setDestAddress(dest);
735 msg->addTagIfAbsent<
HopLimitReq>()->setHopLimit(1);
Referenced by sendLeave(), sendQuery(), and sendReport().
◆ startHostTimer()
439 group->timer->setContextPointer(
new IgmpHostTimerContext(ie, group));
442 double delay = uniform(0.0, maxRespTime);
443 EV_DEBUG <<
"setting host timer for " << ie->getInterfaceName() <<
" and group " << group->groupAddr.str() <<
" to " << delay <<
"\n";
Referenced by multicastGroupJoined(), and processGroupQuery().
◆ startTimer()
| void inet::Igmpv2::startTimer |
( |
cMessage * |
timer, |
|
|
double |
interval |
|
) |
| |
|
protectedvirtual |
◆ verifyCrc()
| bool inet::Igmpv2::verifyCrc |
( |
const Packet * |
packet | ) |
|
989 switch (igmpMsg->getCrcMode()) {
992 return igmpMsg->isCorrect();
1001 return crc == 0 && igmpMsg->isCorrect();
1004 throw cRuntimeError(
"Unknown CRC mode");
Referenced by processIgmpMessage().
◆ crcMode
◆ enabled
| bool inet::Igmpv2::enabled |
|
protected |
◆ externalRouter
| bool inet::Igmpv2::externalRouter |
|
protected |
◆ groupMembershipInterval
| double inet::Igmpv2::groupMembershipInterval |
|
protected |
◆ hostData
◆ ift
◆ lastMemberQueryCount
| int inet::Igmpv2::lastMemberQueryCount |
|
protected |
◆ lastMemberQueryInterval
| double inet::Igmpv2::lastMemberQueryInterval |
|
protected |
◆ numGeneralQueriesRecv
| int inet::Igmpv2::numGeneralQueriesRecv = 0 |
|
protected |
◆ numGeneralQueriesSent
| int inet::Igmpv2::numGeneralQueriesSent = 0 |
|
protected |
◆ numGroups
| int inet::Igmpv2::numGroups = 0 |
|
protected |
◆ numGroupSpecificQueriesRecv
| int inet::Igmpv2::numGroupSpecificQueriesRecv = 0 |
|
protected |
◆ numGroupSpecificQueriesSent
| int inet::Igmpv2::numGroupSpecificQueriesSent = 0 |
|
protected |
◆ numHostGroups
| int inet::Igmpv2::numHostGroups = 0 |
|
protected |
◆ numLeavesRecv
| int inet::Igmpv2::numLeavesRecv = 0 |
|
protected |
◆ numLeavesSent
| int inet::Igmpv2::numLeavesSent = 0 |
|
protected |
◆ numQueriesRecv
| int inet::Igmpv2::numQueriesRecv = 0 |
|
protected |
◆ numQueriesSent
| int inet::Igmpv2::numQueriesSent = 0 |
|
protected |
◆ numReportsRecv
| int inet::Igmpv2::numReportsRecv = 0 |
|
protected |
◆ numReportsSent
| int inet::Igmpv2::numReportsSent = 0 |
|
protected |
◆ numRouterGroups
| int inet::Igmpv2::numRouterGroups = 0 |
|
protected |
◆ otherQuerierPresentInterval
| double inet::Igmpv2::otherQuerierPresentInterval |
|
protected |
◆ queryInterval
| double inet::Igmpv2::queryInterval |
|
protected |
◆ queryResponseInterval
| double inet::Igmpv2::queryResponseInterval |
|
protected |
◆ robustness
| int inet::Igmpv2::robustness |
|
protected |
◆ routerData
◆ rt
◆ startupQueryCount
| int inet::Igmpv2::startupQueryCount |
|
protected |
◆ startupQueryInterval
| double inet::Igmpv2::startupQueryInterval |
|
protected |
◆ unsolicitedReportInterval
| double inet::Igmpv2::unsolicitedReportInterval |
|
protected |
The documentation for this class was generated from the following files:
virtual void configureInterface(NetworkInterface *ie)
Definition: Igmpv2.cc:291
virtual void processRexmtTimer(cMessage *msg)
Definition: Igmpv2.cc:420
virtual void deleteRouterGroupData(NetworkInterface *ie, const Ipv4Address &group)
Definition: Igmpv2.cc:774
int startupQueryCount
Definition: Igmpv2.h:149
int numGeneralQueriesSent
Definition: Igmpv2.h:163
InterfaceToRouterDataMap routerData
Definition: Igmpv2.h:180
@ IGMP_RS_NON_QUERIER
Definition: Igmpv2.h:31
int lastMemberQueryCount
Definition: Igmpv2.h:151
simsignal_t ipv4MulticastGroupLeftSignal
Definition: Simsignals.cc:50
removed DscpReq Ipv4ControlInfo Ipv6ControlInfo up L3AddressInd DispatchProtocolReq L4PortInd Ipv4ControlInfo Ipv6ControlInfo down protocol
Definition: IUdp-gates.txt:25
double queryInterval
Definition: Igmpv2.h:144
virtual void multicastGroupLeft(NetworkInterface *ie, const Ipv4Address &groupAddr)
Definition: Igmpv2.cc:270
virtual void deleteRouterInterfaceData(int interfaceId)
Definition: Igmpv2.cc:315
int numGeneralQueriesRecv
Definition: Igmpv2.h:164
@ INCORRECTLY_RECEIVED
Definition: Simsignals_m.h:71
static const Protocol ipv4
Definition: Protocol.h:93
@ IGMP_RGS_NO_MEMBERS_PRESENT
Definition: Igmpv2.h:35
int numLeavesRecv
Definition: Igmpv2.h:170
double otherQuerierPresentInterval
Definition: Igmpv2.h:147
virtual RouterInterfaceData * getRouterInterfaceData(NetworkInterface *ie)
Definition: Igmpv2.cc:798
int numQueriesSent
Definition: Igmpv2.h:161
int numQueriesRecv
Definition: Igmpv2.h:162
cModule * getContainingNode(const cModule *from)
Find the node containing the given module.
Definition: ModuleAccess.cc:40
@ CRC_COMPUTED
Definition: CrcMode_m.h:59
@ IGMPV2_LEAVE_GROUP
Definition: IgmpMessage_m.h:74
virtual void deleteHostInterfaceData(int interfaceId)
Definition: Igmpv2.cc:305
virtual void processHostGroupTimer(cMessage *msg)
Definition: Igmpv2.cc:394
virtual void processGroupQuery(NetworkInterface *ie, HostGroupData *group, simtime_t maxRespTime)
Definition: Igmpv2.cc:547
removed InterfaceReq
Definition: IUdp-gates.txt:11
static void serialize(MemoryOutputStream &stream, const Ptr< const Chunk > &chunk, b offset=b(0), b length=b(-1))
Serializes a chunk into the given stream.
Definition: Chunk.cc:175
removed DscpReq Ipv4ControlInfo Ipv6ControlInfo up L3AddressInd DispatchProtocolReq L4PortInd Ipv4ControlInfo Ipv6ControlInfo down DispatchProtocolReq
Definition: IUdp-gates.txt:25
simsignal_t ipv4MulticastGroupJoinedSignal
Definition: Simsignals.cc:49
removed DscpReq Ipv4ControlInfo Ipv6ControlInfo up L3AddressInd L3AddressInd
Definition: IUdp-gates.txt:20
bool enabled
Definition: Igmpv2.h:141
@ IGMP_MEMBERSHIP_QUERY
Definition: IgmpMessage_m.h:71
virtual void sendReport(NetworkInterface *ie, HostGroupData *group)
Definition: Igmpv2.cc:689
CrcMode parseCrcMode(const char *crcModeString, bool allowDisable)
Definition: CrcMode.cc:14
@ IGMP_LEAVE_TIMER
Definition: Igmpv2.h:50
int numGroupSpecificQueriesSent
Definition: Igmpv2.h:165
virtual HostInterfaceData * createHostInterfaceData()
Definition: Igmpv2.cc:829
int numReportsSent
Definition: Igmpv2.h:167
bool verifyCrc(const Packet *packet)
Definition: Igmpv2.cc:986
simsignal_t packetDroppedSignal
Definition: Simsignals.cc:85
@ IGMP_HGS_DELAYING_MEMBER
Definition: Igmpv2.h:43
removed DscpReq Ipv4ControlInfo Ipv6ControlInfo up L3AddressInd DispatchProtocolReq L4PortInd Ipv4ControlInfo Ipv6ControlInfo down PacketProtocolTag
Definition: IUdp-gates.txt:25
virtual void processLeaveTimer(cMessage *msg)
Definition: Igmpv2.cc:403
virtual void sendQuery(NetworkInterface *ie, const Ipv4Address &groupAddr, double maxRespTime)
Definition: Igmpv2.cc:659
simsignal_t interfaceDeletedSignal
Definition: Simsignals.cc:31
@ IGMP_REXMT_TIMER
Definition: Igmpv2.h:51
virtual HostGroupData * createHostGroupData(NetworkInterface *ie, const Ipv4Address &group)
Definition: Igmpv2.cc:751
virtual void startHostTimer(NetworkInterface *ie, HostGroupData *group, double maxRespTime)
Definition: Igmpv2.cc:435
intscale< b, 1, 8 > B
Definition: Units.h:1168
virtual void processQueryTimer(cMessage *msg)
Definition: Igmpv2.cc:380
double lastMemberQueryInterval
Definition: Igmpv2.h:150
static const Ipv4Address ALL_ROUTERS_MCAST
224.0.0.2 All routers on a subnet
Definition: Ipv4Address.h:97
static void insertCrc(CrcMode crcMode, const Ptr< IgmpMessage > &igmpMsg, Packet *payload)
Definition: Igmpv2.cc:959
@ IGMP_RS_QUERIER
Definition: Igmpv2.h:30
int numHostGroups
Definition: Igmpv2.h:157
@ IGMP_HGS_NON_MEMBER
Definition: Igmpv2.h:42
@ IGMP_HGS_IDLE_MEMBER
Definition: Igmpv2.h:44
@ PF_ALLOW_EMPTY
Definition: Chunk.h:279
double queryResponseInterval
Definition: Igmpv2.h:145
removed HopLimitReq
Definition: IUdp-gates.txt:11
int numReportsRecv
Definition: Igmpv2.h:168
virtual RouterInterfaceData * createRouterInterfaceData()
Definition: Igmpv2.cc:811
double startupQueryInterval
Definition: Igmpv2.h:148
@ IGMPV2_MEMBERSHIP_REPORT
Definition: IgmpMessage_m.h:73
INET_API InitStage INITSTAGE_LOCAL
Initialization of local state that don't use or affect other modules includes:
@ IGMP_RGS_V1_MEMBERS_PRESENT
Definition: Igmpv2.h:37
@ IGMP_HOSTGROUP_TIMER
Definition: Igmpv2.h:49
virtual void sendToIP(Packet *msg, NetworkInterface *ie, const Ipv4Address &dest)
Definition: Igmpv2.cc:726
value< int64_t, units::b > b
Definition: Units.h:1241
#define NUM_INIT_STAGES
Definition: InitStageRegistry.h:73
@ PF_ALLOW_INCORRECT
Definition: Chunk.h:281
@ IGMP_QUERY_TIMER
Definition: Igmpv2.h:48
@ SP_INDICATION
Definition: ProtocolTag_m.h:175
static const Protocol igmp
Definition: Protocol.h:91
static uint16_t checksum(const void *addr, unsigned int count)
Definition: TcpIpChecksum.h:33
virtual RouterGroupData * createRouterGroupData(NetworkInterface *ie, const Ipv4Address &group)
Definition: Igmpv2.cc:742
@ CRC_DECLARED_CORRECT
Definition: CrcMode_m.h:57
void addWatches()
Definition: Igmpv2.cc:201
virtual void sendLeave(NetworkInterface *ie, HostGroupData *group)
Definition: Igmpv2.cc:707
virtual void processIgmpMessage(Packet *packet)
Definition: Igmpv2.cc:449
double groupMembershipInterval
Definition: Igmpv2.h:146
@ CRC_DECLARED_INCORRECT
Definition: CrcMode_m.h:58
ModuleRefByPar< IIpv4RoutingTable > rt
Definition: Igmpv2.h:138
double unsolicitedReportInterval
Definition: Igmpv2.h:152
virtual RouterGroupData * getRouterGroupData(NetworkInterface *ie, const Ipv4Address &group)
Definition: Igmpv2.cc:760
#define Enter_Method(...)
Definition: SelfDoc.h:71
InterfaceToHostDataMap hostData
Definition: Igmpv2.h:179
int numLeavesSent
Definition: Igmpv2.h:169
virtual HostInterfaceData * getHostInterfaceData(NetworkInterface *ie)
Definition: Igmpv2.cc:816
@ IGMP_RS_INITIAL
Definition: Igmpv2.h:29
ModuleRefByPar< IInterfaceTable > ift
Definition: Igmpv2.h:139
virtual void processV2Report(NetworkInterface *ie, Packet *packet)
Definition: Igmpv2.cc:566
@ IGMP_RGS_CHECKING_MEMBERSHIP
Definition: Igmpv2.h:38
static const Ipv4Address ALL_HOSTS_MCAST
224.0.0.1 All hosts on a subnet
Definition: Ipv4Address.h:96
@ IGMP_RGS_MEMBERS_PRESENT
Definition: Igmpv2.h:36
virtual void processQuery(NetworkInterface *ie, Packet *packet)
Definition: Igmpv2.cc:491
virtual HostGroupData * getHostGroupData(NetworkInterface *ie, const Ipv4Address &group)
Definition: Igmpv2.cc:767
CrcMode crcMode
Definition: Igmpv2.h:173
simsignal_t interfaceCreatedSignal
Definition: Simsignals.cc:30
RouterState
Definition: Igmpv2.h:28
bool externalRouter
Definition: Igmpv2.h:142
int numRouterGroups
Definition: Igmpv2.h:158
virtual void processLeave(NetworkInterface *ie, Packet *packet)
Definition: Igmpv2.cc:625
void registerProtocol(const Protocol &protocol, cGate *gate, ServicePrimitive servicePrimitive)
Registers a protocol primitive (PDU processing) at the given gate.
Definition: IProtocolRegistrationListener.cc:83
virtual void multicastGroupJoined(NetworkInterface *ie, const Ipv4Address &groupAddr)
Definition: Igmpv2.cc:253
virtual void deleteHostGroupData(NetworkInterface *ie, const Ipv4Address &group)
Definition: Igmpv2.cc:785
int numGroups
Definition: Igmpv2.h:156
int robustness
Definition: Igmpv2.h:143
int numGroupSpecificQueriesRecv
Definition: Igmpv2.h:166
INET_API InitStage INITSTAGE_NETWORK_LAYER_PROTOCOLS
Initialization of network layer protocols over IP.
virtual void startTimer(cMessage *timer, double interval)
Definition: Igmpv2.cc:429
bool containsKey(const std::map< K, V, _C > &m, const Tk &a)
Definition: stlutils.h:80