2
0
mirror of https://github.com/xcat2/confluent.git synced 2025-01-09 21:15:53 +00:00

Fix discovery of pre-nonce firmware

This commit is contained in:
Jarrod Johnson 2021-11-17 09:39:34 -05:00
parent 44cc580364
commit 4a13711972

View File

@ -149,6 +149,7 @@ class NodeHandler(immhandler.NodeHandler):
headers = {'Connection': 'keep-alive',
'Content-Type': 'application/json'}
rsp, status = wc.grab_json_response_with_status('/api/providers/get_nonce', {})
nonce = None
if status == 200:
nonce = rsp.get('nonce', None)
headers['Content-Security-Policy'] = 'nonce={0}'.format(nonce)