Don't validate internal messages.

These fail the validate check every time (because they're not real
messages; they're not signed).
This commit is contained in:
Ralph Bean
2017-03-03 06:44:12 -05:00
parent 8f81e6e1ca
commit f12d6e0394

View File

@@ -107,6 +107,12 @@ class MBSConsumer(fedmsg.consumers.FedmsgConsumer):
def validate(self, message):
if conf.messaging == 'fedmsg':
# If this is a faked internal message, don't bother.
if isinstance(message, module_build_service.messaging.BaseMessage):
log.info("Skipping crypto validation for %r" % message)
return
# Otherwise, if it is a real message from the network, pass it
# through crypto validation.
super(MBSConsumer, self).validate(message)
def consume(self, message):