I have upgraded the CefSharp.Wpf to 135.0.170. But after this upgrade the existing functionality was broken as the Cef fails to set the cookie which is required to pass along with the request. Due to this, Chrome shows the "User un authorized" error.
var requestHandler = new DialogRequestHandler(
request =>
{
if (_cookie != null)
{
var cookieManager = Cef.GetGlobalCookieManager();
_ = cookieManager.SetCookie(
request.Url,
new Cookie
{
Name = _cookie.Name,
Value = _cookie.Value,
Expires = _cookie.Expires,
Secure = _cookie.Secure,
Domain = _cookie.Domain,
HttpOnly = _cookie.HttpOnly,
Creation = _cookie.TimeStamp,
Path = _cookie.Path
});
}
return false;
});
This was working fine before upgrade. the latest version of Cefsharp.Wpf doesn't support "Creation" attribute so removed it. SetCookie returns true but can't find the cookie after launch. anything missing ?