You must Sign In to post a response.
  • Category: WCF

    Remove Old SSL Certificate or Disbale & Always Take latest SSL certificate

    I have create the wcf service and here i am generating the SSL certificate. I want previous SSL certificate remove or disable and always take new SSL certificate.

    how i can do it asp.net with c#. Where i will do it.

    Thanks
    Nitin Sharma
  • #768652
    Hi,

    We can do this in coding wise. But we should have both the SSL version. Some programming also use TLS for connecting the secure connection.


    var test_servers = new Dictionary<string, string>();
    test_servers["SSL 2"] = "https://www.ssllabs.com:10200";
    test_servers["SSL 3"] = "https://www.ssllabs.com:10300";


    //using this we can take this server variables

    var supported = new Func<string, bool>(url =>
    {
    try { return new HttpClient().GetAsync(url).Result.IsSuccessStatusCode; }
    catch { return false; }
    });

    var supported_protocols = test_servers.Where(server => supported(server.Value));
    Console.WriteLine(string.Join(", ", supported_protocols.Select(x => x.Key)));



    We can also do TLS with the same coding ideas.

    Thanks,
    Mani


Sign In to post your comments