From 00cf8f3ff49abe1302b671632adaf5966fb35daa Mon Sep 17 00:00:00 2001 From: Alexander Borsuk Date: Fri, 2 Jul 2021 17:12:58 +0200 Subject: [PATCH] Fixed failing OSM login The reason was that the format of the form values in response was changed by OSM developers. TODO: Properly parse the web page response and extract proper permissions and form values instead of hard-coding them. Signed-off-by: Alexander Borsuk --- editor/osm_auth.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/editor/osm_auth.cpp b/editor/osm_auth.cpp index 289ef8c818..5b45208d95 100644 --- a/editor/osm_auth.cpp +++ b/editor/osm_auth.cpp @@ -216,10 +216,10 @@ string OsmOAuth::SendAuthRequest(string const & requestTokenKey, SessionID const {"oauth_token", requestTokenKey}, {"oauth_callback", ""}, {"authenticity_token", sid.m_token}, - {"allow_read_prefs", "yes"}, - {"allow_write_api", "yes"}, - {"allow_write_gpx", "yes"}, - {"allow_write_notes", "yes"}, + {"allow_read_prefs", "1"}, + {"allow_write_api", "1"}, + {"allow_write_gpx", "1"}, + {"allow_write_notes", "1"}, {"commit", "Save changes"} }; HttpClient request(m_baseUrl + "/oauth/authorize");