在UWP应用中使用WebAuthenticationBroker获取steam openid认证。
var uriStringBuilder = new StringBuilder("https://steamcommunity.com/openid/login");
uriStringBuilder.AppendFormat("?openid.ns={0}", "http://specs.openid.net/auth/2.0");
uriStringBuilder.AppendFormat("&openid.mode={0}", "checkid_setup");
uriStringBuilder.AppendFormat("&openid.return_to={0}", WebAuthenticationBroker.GetCurrentApplicationCallbackUri());
uriStringBuilder.AppendFormat("&openid.realm={0}", "https://SteamUWP.com");
uriStringBuilder.AppendFormat("&openid.identity={0}", "http://specs.openid.net/auth/2.0/identifier_select");
uriStringBuilder.AppendFormat("&openid.claimed_id={0}", "http://specs.openid.net/auth/2.0/identifier_select");
这一段,是我生成的URI。放到系统浏览器里能正常运行。但使用WebAuthenticationBroker就无法连接资源了。难道说是WebAuthenticationBroker不使用系统代理设置?有没有朋友写过steam登录?
中学为体,西学为用。