We are currently porting from CefSharp to EO web control. We have an authentication related code from our WPF application where we used CefSharp embedded web control. The embedded web control is set with an URL to authentication server. After the login page is displayed and user submits the page, we need to handle the redirect URL coming from the server.
Here is how we did with CefSharp.
Code: C#
browser = new ChromiumWebBrowser(uri);
browser.RequestHandler = new RequestHandler(new LoginResourceRequestHandler(this));
// OnResourceRedirect is called after the server redirect
class LoginResourceRequestHandler : IResourceRequestHandler
{
public void OnResourceRedirect(IWebBrowser chromiumWebBrowser, IBrowser browser, IFrame frame, IRequest request, IResponse response, ref string newUrl)
{
// We need value of this redirect url - newUrl
// Check the value of the redirect and handle it
if (newUrl.StartsWith("com.myclientapp://myclientapp.com/callback"))
{
...
}
}
...
}
We need a way to get this redirect url from EO web browser. Not sure how to do this in EO yet. Any help is highly appreciated.