Merge remote-tracking branch 'upstream/develop' into develop
Merge remote-tracking branch 'upstream/develop' into develop
add master_sign_key_name and generation of the actual sign-key-files if activated
make MasterKeys() more flexible by allowing different key-names.

MasterKeys() should be able to handle more than one hardcoded key.
The default is still to just handle master.* files but can also generate
new key-pairs with different names and return the pub-key.
fix join()'s to form the correct file names
add key name to logging output
add settings for master and minion to sign the public / verify pubkey signature

Add a setting for the master to generate a new signing key-pair for signing purposes
and use the key-pair to sign the masters public key that is send to authenticated
minions.

Add a setting for the minion to verify the signature of a public key received from
the master. Requires to have the signing key-pair from the master on the minion.
Add optional signing of the master pubkey if enabled in config.

Uses salt.crypt.sign_message() to create a signature of the pubkey
and adds that signature to the payload send to authenticated minions.
add verification of signed master pubkeys

Adds the verification of the master pubkey by checking the pubkey
signature in payload['pub_sig'] with the signing keypairs pubkey.
Merge remote-tracking branch 'upstream/develop' into sign_master_keys
cleanup and add some more comments
fix path to signing pubkey
lint fixes
Merge remote-tracking branch 'upstream/develop' into sign_master_keys
verify master pubkey signature on first pubkey connection

previously the minion would take any master pubkey for granted and
write it to minion_master.pub.
cleanup old sreqs if the master changed

Jumping back and forth between different masters will over time add more
and more sreqs to the sreq_cache. That might be ok in MultiMaster, with
signed master-pubkeys, we only want one single master sreq we re-use and
remove all the others.
make function more flexible and work with different master-ips and status
track connected status and re-init subsystems on new master

keep track of self.connected and re-init the zmq-context, poller and
socket, if connecting to a new master
fix event-cal to be correct dict
remove unneeded re import