Flask_Mqtt No cipher can be selected

i’m starting using HiveMq cloud with flask_mqtt and encountered this error
context.set_ciphers(ciphers)
ssl.SSLError: (‘No cipher can be selected.’,)
This is my config
app = Flask(name)

app.config[‘MQTT_BROKER_URL’] = ‘5c463a42551f40b4ba7f07a18da6866d.s1.eu.hivemq.cloud’

app.config[‘MQTT_BROKER_PORT’] = 8883

app.config[‘MQTT_USERNAME’] = ‘mqtt123’

app.config[‘MQTT_PASSWORD’] = ‘HoangDepTrai123’

app.config[‘MQTT_KEEPALIVE’] = 60

app.config[‘MQTT_TLS_ENABLED’] = True

app.config[‘MQTT_TLS_CA_CERTS’] = ‘paho/isrgrootx1.pem’

app.config[‘MQTT_TLS_CIPHERS’] = ‘TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256’

app.config[‘MQTT_TLS_KEYFILE’] = ‘server.key’

Hello @vohoang

Welcome to HiveMQ Community! The error you’re seeing, ssl.SSLError: (‘No cipher can be selected.’,), suggests that the Python environment in which your Flask MQTT app is running doesn’t have any available SSL/TLS ciphers to establish a secure connection.

Are you importing/using the Python’s ssl Module? If you can share your full Flask code I can help you further.

Kind regards,
Diego from HiveMQ Team