Example #1
0
 def attach(self, user):
     """
     Attach a user to the domain
     :param user: the user to attach
     """
     self.attachingUsers.append(user)
     pdu = MCSAttachUserRequestPDU()
     self.mcs.send(pdu)
Example #2
0
    def parseAttachUserRequest(self, stream: BytesIO) -> MCSAttachUserRequestPDU:
        """
        Parse an Attach User Request PDU
        :param stream: stream containing the data
        """
        if len(stream.read()) > 0:
            raise ParsingError("Unexpected payload")

        return MCSAttachUserRequestPDU()