diff options
Diffstat (limited to 'tools/src/py/qpid-cluster')
-rwxr-xr-x | tools/src/py/qpid-cluster | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/src/py/qpid-cluster b/tools/src/py/qpid-cluster index 7d800b52fb..d75a10f6e8 100755 --- a/tools/src/py/qpid-cluster +++ b/tools/src/py/qpid-cluster @@ -244,6 +244,7 @@ def main(argv=None): parser.add_option("-t", "--timeout", action="store", type="int", default=10, metavar="SECS", help="Maximum time to wait for broker connection (in seconds)") parser.add_option("--sasl-mechanism", action="store", type="string", metavar="<mech>", help="SASL mechanism for authentication (e.g. EXTERNAL, ANONYMOUS, PLAIN, CRAM-MD, DIGEST-MD5, GSSAPI). SASL automatically picks the most secure available mechanism - use this option to override.") parser.add_option("--ssl-certificate", action="store", type="string", metavar="<cert>", help="Client SSL certificate (PEM Format)") + parser.add_option("--ssl-key", action="store", type="string", metavar="<key>", help="Client SSL private key (PEM Format)") parser.add_option("-C", "--all-connections", action="store_true", default=False, help="View client connections to all cluster members") parser.add_option("-c", "--connections", metavar="ID", help="View client connections to specified member") parser.add_option("-d", "--del-connection", metavar="HOST:PORT", help="Disconnect a client connection") @@ -280,6 +281,9 @@ def main(argv=None): if len(config._stopId.split(":")) != 2: parser.error("Member ID must be of form: <host or ip>:<number>") + if opts.ssl_key and not opts.ssl_certificate: + parser.error("missing '--ssl-certificate' (required by '--ssl-key')") + config._stopAll = opts.all_stop config._force = opts.force config._numeric = opts.numeric @@ -289,6 +293,8 @@ def main(argv=None): conn_options['mechanisms'] = opts.sasl_mechanism if opts.ssl_certificate: conn_options['ssl_certfile'] = opts.ssl_certificate + if opts.ssl_key: + conn_options['ssl_keyfile'] = opts.ssl_key bm = BrokerManager(config, conn_options) |