Google provider: limit requested OAuth scopes
ClosedPublic

Authored by dvratil on Jan 6 2020, 9:44 AM.

Details

Summary

Limit the scopes to what is actually permitted in the Google App settings:
contacts and calendars for future PIM integration, GDrive for KIO-GDrive,
and Youtube (upload-only) for the Purpose sharing plugin. We can extend
this in the future if needed easilly, it's easier for us to get the
Google App verified if we can proof and show how the individual scopes
are used by KDE.

Diff Detail

Repository
R156 KAccounts Providers
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
dvratil requested review of this revision.Jan 6 2020, 9:44 AM
dvratil created this revision.
dvratil updated this revision to Diff 72859.Jan 6 2020, 9:46 AM
  • Remove unrelated changes
dvratil retitled this revision from Enable google-{contacts,calendar} services to Google provider: limit requested OAuth scopes.Jan 6 2020, 9:46 AM
dvratil edited the summary of this revision. (Show Details)
bshah accepted this revision.Jan 6 2020, 9:50 AM
This revision is now accepted and ready to land.Jan 6 2020, 9:50 AM
elvisangelaccio accepted this revision.Jan 6 2020, 1:20 PM
This revision was automatically updated to reflect the committed changes.
cgiboudeaux reopened this revision.Jan 13 2020, 2:49 PM
cgiboudeaux added a subscriber: cgiboudeaux.

After updating, I'm getting that:

15:42:28 - systemsettings(16291) -  : <Unknown File>:7: TypeError: Cannot read property 'contentX' of null

** (process:16291): WARNING **: 15:42:30.200: _ag_value_from_string: error parsing type "as" ``[
              'https://www.googleapis.com/auth/userinfo.email',
              'https://www.googleapis.com/auth/userinfo.profile',
              'https://www.googleapis.com/auth/calendar',
              'https://www.googleapis.com/auth/tasks',
              'https://www.google.com/m8/feeds/',
              'https://www.googleapis.com/auth/drive',
              'https://www.googleapis.com/auth/youtube.upload',
          ]'': 424:expected value
This revision is now accepted and ready to land.Jan 13 2020, 2:49 PM
cgiboudeaux closed this revision.Jan 13 2020, 2:57 PM

After updating, I'm getting that:

15:42:28 - systemsettings(16291) -  : <Unknown File>:7: TypeError: Cannot read property 'contentX' of null

** (process:16291): WARNING **: 15:42:30.200: _ag_value_from_string: error parsing type "as" ``[
              'https://www.googleapis.com/auth/userinfo.email',
              'https://www.googleapis.com/auth/userinfo.profile',
              'https://www.googleapis.com/auth/calendar',
              'https://www.googleapis.com/auth/tasks',
              'https://www.google.com/m8/feeds/',
              'https://www.googleapis.com/auth/drive',
              'https://www.googleapis.com/auth/youtube.upload',
          ]'': 424:expected value

Fixed: https://commits.kde.org/kaccounts-providers/5952bf25358b8b2545cfdeb898461f82a7b17971