Get the connection with SSL

def get_ssl_connection(config):
    """
    Get the connection with SSL
    """
    cd = pymqi.CD()
    cd.ChannelName = config.channel
    cd.ConnectionName = config.host_and_port
    cd.ChannelType = pymqi.CMQC.MQCHT_CLNTCONN
    cd.TransportType = pymqi.CMQC.MQXPT_TCP
    cd.SSLCipherSpec = config.ssl_cipher_spec

    sco = pymqi.SCO()
    sco.KeyRepository = config.ssl_key_repository_location

    queue_manager = pymqi.QueueManager(None)
    queue_manager.connect_with_options(config.queue_manager_name, cd, sco)

    return queue_manager