Error Creating Session Using Vonage Video API .NET SDK
Symptom
When using Vonage Video API .NET SDK, you experience errors related to creating sessions.
OpenTokSDK.Exception.OpenTokWebException: Error with request submission
at OpenTokSDK.Util.HttpClient.DoRequest(String url, Dictionary`2 specificHeaders, Dictionary`2 bodyData)
at OpenTokSDK.Util.HttpClient.Post(String url, Dictionary`2 headers, Dictionary`2 data)
at OpenTokSDK.OpenTok.CreateSession(String location, MediaMode mediaMode, ArchiveMode archiveMode)
Object reference not set to an instance of an object. at OpenTokSDK.Util.HttpClient.DoRequest(String url, Dictionary`2 specificHeaders, Dictionary`2 bodyData)
Sometimes there can also be NullPointerException while creating session due to any of the above exception.
Applies To
- .NET SDK
- Video API
- TLS 1.0
Resolution
- Make sure you are using our current SDK version.
- Try forcing TLS 1.2 using the code SecurityProtocol = SecurityProtocolType.Tls12.
- Servers running on .NET 4.0 need to upgrade their .NET version to 4.6 .NET framework or a more recent version.
- Send a request to https://preview.opentok.com/tls-check.json from within your application and check the response you get. You should get 1.2.
Cause
This is related to the deprecation of TLS 1.0.
Additional Information
For more information, see Desupporting TLS 1.0.
Comments
0 comments
Article is closed for comments.