예제 #1
0
 def __init__(self, connection, resultCode, errCode, errMsg):
     super(
         L2tpv3StopCCN, self).__init__(L2tpv3RFC3931AVPs.ControlMessageAVP.StopCCN, connection.remoteConnID,
                                       resultCode, errCode, errMsg)
     assignedConnectionAvp = L2tpv3RFC3931AVPs.AssignedControlConnectionID(
         connection.localConnID)
     self.avps.append(assignedConnectionAvp)
예제 #2
0
    def localRequest(self, addr):
        # send a SCCRQ to remote

        msgAvp = L2tpv3RFC3931AVPs.ControlMessageAVP(
            L2tpv3RFC3931AVPs.ControlMessageAVP.SCCRQ)
        assignedAvp = L2tpv3RFC3931AVPs.AssignedControlConnectionID(
            self.localConnID)
        sccrq = L2tpv3ControlPacket.L2tpv3ControlPacket(0,
                                                        avps=(msgAvp,
                                                              assignedAvp))
        self.transport.SendPacket(sccrq, (addr, 0))

        self.fsm.localRequest()