Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ee774fc

Browse filesBrowse files
authored
Merge pull request GoogleCloudPlatform#1395 from noerog/patch-2
Import ssl, set TLS v1.2
2 parents b56ac42 + 07659b2 commit ee774fc
Copy full SHA for ee774fc

File tree

Expand file treeCollapse file tree

1 file changed

+2
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-1
lines changed

‎iot/api-client/end_to_end_example/cloudiot_pubsub_example_mqtt_device.py

Copy file name to clipboardExpand all lines: iot/api-client/end_to_end_example/cloudiot_pubsub_example_mqtt_device.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@
4545
import datetime
4646
import json
4747
import os
48+
import ssl
4849
import time
4950

5051
import jwt
@@ -208,7 +209,7 @@ def main():
208209
args.project_id,
209210
args.private_key_file,
210211
args.algorithm))
211-
client.tls_set(ca_certs=args.ca_certs)
212+
client.tls_set(ca_certs=args.ca_certs, tls_version=ssl.PROTOCOL_TLSv1_2)
212213

213214
device = Device()
214215

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.