From beedfb0600794cf9487c9dada2cba9c5ef3e1634 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 11 Jul 2018 16:29:45 -0400 Subject: [PATCH] If a drone doesn't exist, treat it as if it's an invalid certificate --- confluent_server/confluent/collective/manager.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/confluent_server/confluent/collective/manager.py b/confluent_server/confluent/collective/manager.py index 5eefcc1c..ae9d3364 100644 --- a/confluent_server/confluent/collective/manager.py +++ b/confluent_server/confluent/collective/manager.py @@ -287,7 +287,8 @@ def handle_connection(connection, cert, request, local=False): return drone = request['name'] droneinfo = cfm.get_collective_member(drone) - if not util.cert_matches(droneinfo['fingerprint'], cert): + if not (droneinfo and util.cert_matches(droneinfo['fingerprint'], + cert)): tlvdata.send(connection, {'error': 'Invalid certificate, ' 'redo invitation process'})