MCPcopy Create free account
hub / github.com/Keeper-Security/Commander / self_managed_key_error

Function self_managed_key_error

keepercommander/rest_api.py:406–417  ·  view source on GitHub ↗

Why a host that is not a Keeper cloud host rejected the transmission key.

(context)

Source from the content-addressed store, hash-verified

404
405
406def self_managed_key_error(context): # type: (RestApiContext) -> str
407 """Why a host that is not a Keeper cloud host rejected the transmission key."""
408 host = server_host(context.server_base)
409 key = _resolved_server_keys.get(host)
410 if key:
411 return (f'{host} rejected the server key {key.source} (key ID {key.key_id}, '
412 f'{server_key_fingerprint(key.public_key)}). Compare this fingerprint with the one the '
413 f'deployment shows, or set the key: server {host} --key-id <ID> --public-key <KEY>')
414 reason = _server_key_errors.get(host) or 'not found'
415 return (f'{host} is not a Keeper cloud host and does not accept Keeper\'s server keys. Its own key &#x27;
416 f'could not be found: {reason}. '
417 f'Set it: server {host} --key-id <ID> --public-key <KEY>')
418
419
420DEFAULT_TIMEOUT = (15, 300)

Callers 1

execute_restFunction · 0.85

Calls 3

server_hostFunction · 0.85
server_key_fingerprintFunction · 0.85
getMethod · 0.45

Tested by

no test coverage detected