def _checkSendFilters(self):
        "MT Filters check"

        if (self.user.mt_credential.getValueFilter('destination_address') is None or
                not self.user.mt_credential.getValueFilter('destination_address').match(self.submit_sm.params['destination_addr'])):
            raise FilterError(
                'Value filter failed for username [%s] (destination_address filter mismatch).' % self.user,
                'destination_address')
        if (self.user.mt_credential.getValueFilter('source_address') is None or
                not self.user.mt_credential.getValueFilter('source_address').match(self.submit_sm.params['source_addr'])):
            raise FilterError(
                'Value filter failed for username [%s] (source_address filter mismatch).' % self.user,
                'source_address')
        if (self.user.mt_credential.getValueFilter('priority') is None or
                not self.user.mt_credential.getValueFilter('priority').match(
                    str(self.submit_sm.params['priority_flag'].index))):
            raise FilterError(
                'Value filter failed for username [%s] (priority filter mismatch).' % self.user,
                'priority')
        if (self.user.mt_credential.getValueFilter('content') is None or
                not self.user.mt_credential.getValueFilter('content').match(self.submit_sm.params['short_message'])):
            raise FilterError(
                'Value filter failed for username [%s] (content filter mismatch).' % self.user,
                'content')
dataset/ETHPy150Open jookies/jasmin/jasmin/protocols/smpp/validation.py/SmppsCredentialValidator._checkSendFilters/original