question

Upvotes
Accepted
1 1 2 2

PermId API calling error

using (var client = new HttpClient())

{

var req = client.GetAsync("https://permid.org/1-55835312773?access-token=<token>&format=json-ld").Result;

Console.WriteLine(req.Content.ReadAsStringAsync().Result);

}


During this connection establishment only- We are getting below error message exception:



permid-apiintelligent-tagging-apiopen-permid-api
1621425391799.png (14.1 KiB)
1621425413133.png (14.3 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@alexandra.hening
I have removed the token from the question.
The client uses Windows 7. I will verify the problem.
Upvotes
Accepted
79.1k 250 52 74

@alexandra.hening

From my finding, it relates to the Cipher Suites used by permid.org. Refer to https://www.ssllabs.com/ssltest/analyze.html?d=permid.org, permid.org supports the following Cipher Suites for TLS 1.2.

1628226080761.jpeg

However, It looks like Windows 7 doesn’t support these cipher suites (https://social.technet.microsoft.com/Forums/ie/en-US/d1a10844-18fb-4400-b649-60183c5f58c6/how-to-add-cipher-suite-to-windows-7-tlsrsawithaes128gcmsha256?forum=w7itprosecurity).


1628226080761.jpeg (29.3 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
79.1k 250 52 74

@alexandra.hening

I found a solution on the StackOverflow.

If I use .NET Framework 4.5, the code looks like this:

using System;
using System.Net;
using System.Net.Http;

namespace ConsoleApp12
{
    class Program
    {
        static void Main(string[] args)
        {
            ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
            using (var client = new HttpClient())

            {

                var req = client.GetAsync("https://permid.org/1-55835312773?access-token=<token>&format=json-ld").Result;

                Console.WriteLine(req.Content.ReadAsStringAsync().Result);

            }
        }
    }
}
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.