MCPcopy
hub / github.com/saltstack/salt / fetch

Method fetch

salt/crypt.py:861–875  ·  view source on GitHub ↗

fetch from keystore, unmarshalling to object if possible

(self, name)

Source from the content-addressed store, hash-verified

859 return self.key.encrypt(*args, **kwargs)
860
861 def fetch(self, name):
862 """
863 fetch from keystore, unmarshalling to object if possible
864 """
865 key = self.cache.fetch("master_keys", name)
866
867 if not key:
868 return
869
870 if name.endswith(".pem"):
871 return PrivateKey.from_str(key)
872 elif name.endswith(".pub"):
873 return PublicKey.from_str(key)
874 else:
875 return key
876
877
878def _auth_singleton_key(opts):

Callers 13

__verify_minionMethod · 0.45
_returnMethod · 0.45
_auth_implMethod · 0.45
list_matchMethod · 0.45
list_keysMethod · 0.45
key_strMethod · 0.45
change_stateMethod · 0.45
fingerMethod · 0.45
_setup_keysMethod · 0.45
find_or_create_keysMethod · 0.45
get_pub_strMethod · 0.45

Calls 1

from_strMethod · 0.80

Tested by

no test coverage detected