From b2e79759bb9ca013bd49c739182672ce53872432 Mon Sep 17 00:00:00 2001 From: Blair Allen Date: Mon, 1 Jul 2019 13:26:02 -0400 Subject: [PATCH] Added CAS v3.0 references where appropriate --- DotNetCasClient/CasAuthentication.cs | 15 ++++++++------- .../Cas30ServiceTicketValidator.cs | 2 +- .../TicketValidator/ITicketValidator.cs | 1 + ExampleWebSite/web.config.sample | 4 ++-- README.md | 2 +- 5 files changed, 13 insertions(+), 11 deletions(-) diff --git a/DotNetCasClient/CasAuthentication.cs b/DotNetCasClient/CasAuthentication.cs index 6b3e71a..b4da595 100644 --- a/DotNetCasClient/CasAuthentication.cs +++ b/DotNetCasClient/CasAuthentication.cs @@ -848,14 +848,15 @@ internal static bool ProcessProxyCallbackRequest() /// /// Validates a ticket contained in the URL, presumably generated by - /// the CAS server after a successful authentication. The actual ticket + /// the CAS server after a successful authentication. The actual ticket /// validation is performed by the configured TicketValidator - /// (i.e., CAS 1.0, CAS 2.0, SAML 1.0). If the validation succeeds, the - /// request is authenticated and a FormsAuthenticationCookie and - /// corresponding CasAuthenticationTicket are created for the purpose of - /// authenticating subsequent requests (see ProcessTicketValidation - /// method). If the validation fails, the authentication status remains - /// unchanged (generally the user is and remains anonymous). + /// (i.e., CAS 1.0, CAS 2.0, CAS 3.0, SAML 1.0). If the validation + /// succeeds, the request is authenticated and a + /// FormsAuthenticationCookie and corresponding CasAuthenticationTicket + /// are created for the purpose of authenticating subsequent requests + /// (see ProcessTicketValidation method). If the validation fails, the + /// authentication status remains unchanged (generally the user is and + /// remains anonymous). /// internal static void ProcessTicketValidation() { diff --git a/DotNetCasClient/Validation/TicketValidator/Cas30ServiceTicketValidator.cs b/DotNetCasClient/Validation/TicketValidator/Cas30ServiceTicketValidator.cs index f19a3b0..9608adf 100644 --- a/DotNetCasClient/Validation/TicketValidator/Cas30ServiceTicketValidator.cs +++ b/DotNetCasClient/Validation/TicketValidator/Cas30ServiceTicketValidator.cs @@ -100,7 +100,7 @@ protected override ICasPrincipal ParseResponseFromServer(string response, string } catch (InvalidOperationException) { - throw new TicketValidationException("CAS Server response does not conform to CAS 2.0/3.0 schema"); + throw new TicketValidationException("CAS Server response does not conform to CAS 3.0 schema"); } if (serviceResponse.IsAuthenticationSuccess) diff --git a/DotNetCasClient/Validation/TicketValidator/ITicketValidator.cs b/DotNetCasClient/Validation/TicketValidator/ITicketValidator.cs index 4e8e1ab..6ff0f63 100644 --- a/DotNetCasClient/Validation/TicketValidator/ITicketValidator.cs +++ b/DotNetCasClient/Validation/TicketValidator/ITicketValidator.cs @@ -65,6 +65,7 @@ string ServiceParameterName /// /// CAS 1.0: validate /// CAS 2.0: serviceValidate or proxyValidate + /// CAS 3.0: p3/serviceValidate or p3/proxyValidate /// SAML 1.1: samlValidate /// /// diff --git a/ExampleWebSite/web.config.sample b/ExampleWebSite/web.config.sample index b0611a7..0b36907 100644 --- a/ExampleWebSite/web.config.sample +++ b/ExampleWebSite/web.config.sample @@ -56,7 +56,7 @@ - casServerUrlPrefix URL to root of CAS server application. - ticketValidatorName - Supported values: Cas10, Cas20, and Saml11. + Supported values: Cas10, Cas20, Cas30, and Saml11. Name of ticket validator that validates CAS tickets using a particular protocol. Optional Attributes: @@ -116,7 +116,7 @@ renew="false" singleSignOut="true" ticketTimeTolerance="5000" - ticketValidatorName="Cas20" + ticketValidatorName="Cas30" proxyTicketManager="CacheProxyTicketManager" serviceTicketManager="CacheServiceTicketManager" gatewayStatusCookieName="CasGatewayStatus" /> diff --git a/README.md b/README.md index f9f060c..881170a 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ The Apereo .NET CAS client provides CAS integration for the Microsoft Windows pl ## Features ## -- Supports CAS Protocol 1.0 and 2.0 and SAML 1.1 +- Supports CAS Protocol 1.0, 2.0, and 3.0 and SAML 1.1 - Supports CAS single sign-out - Rich support for Microsoft ASP.NET platform integration through Forms Authentication framework