public static bool IsUnauthorized(this Exception ex) { return HasStatus(ex as WebException, HttpStatusCode.Unauthorized); }