You have a few options. Not sure which one is better and whether any of these are taboo.
Option A: Add a WebBrowser control to your WebForms app. 2 sub-options come to mind: 1) Create a CAS protected web page/HttpHandler somewhere. Redirect to it when your app starts. It will redirect to CAS, CAS will redirect back if the login is successful. Parse something out of that page that only authenticated users would have access to. 2) Have the WebBrowser redirect directly to the CAS server. When the user logs into CAS, scan the document's Cookies collection for a ticket granting cookie. I'm not sure whether the TGT is good enough to ensure that your request is authenticated. If not, you could collect the TGT, create a WebClient with that cookie present and request a service ticket, and validate it using HTTP calls behind-the-scenes outside of the browser. Option B: Deploy & execute your app via ClickOnce. Instead of double clicking on an icon installed on their computer, users would browse to a CAS protected launch page on a web server. The launch page would pass a proxy ticket into the ClickOnce app via a URL/Commandline parameter. Your app verifies the proxy ticket to authenticate. The DotNetCasClient example web site contains a sample ClickOnce app that does proxy ticket validation. From: Victor Careaga [mailto:[email protected]] Sent: Wednesday, September 29, 2010 10:58 AM To: [email protected] Subject: Re: [cas-user] using CAS from url Hi scott i am using Webforms and we have a little client in C#.net and Basic.net working on .net 2003 framework 1.1 i am trying with a script on CAS side but niot work for me grettings 2010/9/29 Scott M. Holodak <[email protected]> What technology is your app based on? i.e., WinForms, WPF, WebForms, MVC? From: Victor Careaga [mailto:[email protected]] Sent: Tuesday, September 28, 2010 11:36 AM To: [email protected] Subject: [cas-user] using CAS from url hi folks well iam searching a way to use CAS from a url this mean use a url type http:/casservice/?service=myurl&username=admin&password=1234 i need authentification from a .net form, maybe exist another solution, well thx for all grettings and thanks for the advices -- Z (LI) ¿Suspiras al recordar aquellos días del Minix-1.1, cuando los hombres eran hombres y escribían sus propios drivers? Errare humanum est blog personal http://bicho-soft.blogspot.com/ -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user -- Z (LI) ¿Suspiras al recordar aquellos días del Minix-1.1, cuando los hombres eran hombres y escribían sus propios drivers? Errare humanum est blog personal http://bicho-soft.blogspot.com/ -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user
