summaryrefslogtreecommitdiff
path: root/config_host
diff options
context:
space:
mode:
authorChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2021-02-16 14:07:34 +0100
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2021-07-28 01:50:39 +0200
commit73041de9563c9a973d1b5394c6e5520a7d799980 (patch)
treeb9c696ea086dab9de385d57009f0c30ffd84fcec /config_host
parent5411aafbfd8656f043bcf30588bc41b061f1b60b (diff)
tdf#101630 - gdrive support w/oAuth and Drive API v3
LibreOffice is only using drive.file scope, so can only see files it owns/that were created by LibreOffice. In addition, also store the refresh token in LO's password-store if the user enabled persistent storage, removing the need to to the copy'n'paste dance to grant access each time LO is launched. related tdf#115643 also store the refresh token for onedrive consolidate the fallback-auth provides for onedrive/gdrive into one, they are all the same login in browser, then copy code method that ultimately should be changed to having LO listen on local port for the code Change-Id: I97e3843682c302d2884e35ece6e72bc3a07e2539 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119572 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Diffstat (limited to 'config_host')
-rw-r--r--config_host/config_oauth2.h.in8
1 files changed, 4 insertions, 4 deletions
diff --git a/config_host/config_oauth2.h.in b/config_host/config_oauth2.h.in
index a95015b41f3e..9945dda3dda5 100644
--- a/config_host/config_oauth2.h.in
+++ b/config_host/config_oauth2.h.in
@@ -15,13 +15,13 @@
/* Google Drive settings */
-#define GDRIVE_BASE_URL "https://www.googleapis.com/drive/v2"
+#define GDRIVE_BASE_URL "https://www.googleapis.com/drive/v3"
#define GDRIVE_CLIENT_ID ""
#define GDRIVE_CLIENT_SECRET ""
-#define GDRIVE_AUTH_URL "https://accounts.google.com/o/oauth2/auth"
-#define GDRIVE_TOKEN_URL "https://accounts.google.com/o/oauth2/token"
+#define GDRIVE_AUTH_URL "https://accounts.google.com/o/oauth2/v2/auth"
+#define GDRIVE_TOKEN_URL "https://oauth2.googleapis.com/token"
#define GDRIVE_REDIRECT_URI "urn:ietf:wg:oauth:2.0:oob"
-#define GDRIVE_SCOPE "https://www.googleapis.com/auth/drive"
+#define GDRIVE_SCOPE "https://www.googleapis.com/auth/drive.file"
/* Alfresco Cloud */