Authentication with client certificate Sample (wodWebServer / wodWebServer.NET)
Hi.
I had to fix wodWebServer.NET for this to work - thanks for spotting this. Anyway, please download wodWebServer.NET again and install it (version 1.3.7) . Once installed you can do this:
web1.AuthenticateEvent += new WeOnlyDo.Server.WebServer.AuthenticateDelegate(web1_AuthenticateEvent);
web1.Secure = true;
web1.Authentication = WeOnlyDo.Server.WebAuthentications.Required;
web1.AuthenticationType = WeOnlyDo.Server.WebAuthenticationTypes.Certificate;
web1.Start();
and in authenticate event do with the certificate whatever you wish:
void web1_AuthenticateEvent(object Sender, WeOnlyDo.Server.WebAuthenticateArgs Args)
{
if (Args.Certificate != null)
Console.WriteLine(Args.Certificate.GetIssuerName());
Args.Action = WeOnlyDo.Server.WebActions.Allow;
}
Let me know how it goes!
Kreso
Complete thread:
- Authentication with client certificate Sample - Jeremy, 2014-05-02, 08:45
- Authentication with client certificate Sample - wodSupport, 2014-05-02, 08:51
- Authentication with client certificate Sample - Jeremy, 2014-05-02, 10:37
- Authentication with client certificate Sample - wodSupport, 2014-05-02, 13:10
- Authentication with client certificate Sample - Jeremy, 2014-05-02, 13:40
- Authentication with client certificate Sample - wodSupport, 2014-05-02, 21:03
- Authentication with client certificate Sample - Jeremy, 2014-05-04, 07:03
- Authentication with client certificate Sample - wodSupport, 2014-05-02, 21:03
- Authentication with client certificate Sample - Jeremy, 2014-05-02, 13:40
- Authentication with client certificate Sample - wodSupport, 2014-05-02, 13:10
- Authentication with client certificate Sample - Jeremy, 2014-05-02, 10:37
- Authentication with client certificate Sample - wodSupport, 2014-05-02, 08:51