Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ add google workspace calendar and acl resources #4282

Merged
merged 1 commit into from
Jun 24, 2024

Conversation

imilchev
Copy link
Member

@imilchev imilchev commented Jun 21, 2024

Adds support for google workspace calendars and their acl rules.

New scopes required for the permissions:

https://www.googleapis.com/auth/calendar.readonly
https://www.googleapis.com/auth/calendar.settings.readonly
https://www.googleapis.com/auth/calendar

Note that the last scope is not a readonly scope but it is required to retrieve the ACL for the calendars as per Google's documentation

Fixes #4271

This comment has been minimized.

@imilchev imilchev force-pushed the ivan/google-workspace-calendar-acl branch from 98fcfd6 to fc3b706 Compare June 21, 2024 12:14
Copy link
Contributor

github-actions bot commented Jun 21, 2024

Test Results

3 071 tests  ±0   3 070 ✅ ±0   1m 22s ⏱️ -14s
  363 suites ±0       1 💤 ±0 
   27 files   ±0       0 ❌ ±0 

Results for commit feb812f. ± Comparison against base commit 183360f.

♻️ This comment has been updated with latest results.

This comment has been minimized.

@imilchev imilchev force-pushed the ivan/google-workspace-calendar-acl branch from fc3b706 to feb812f Compare June 21, 2024 12:20
summary: {}
summaryOverride: {}
is_private: true
min_mondoo_version: latest
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The last PRs I saw, this was always set to 9.0.0 because it's only a provider update.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for this provider for all resources it says latest

@mm-weber
Copy link
Contributor

Works as expected, thanks @imilchev :

cnspec> googleworkspace.calendars.all(acl.where(scope.type == "domain").all(role != "freeBusyReader") )
[failed] [].all()
  actual:   [
    0: googleworkspace.calendar summary="[email protected]" {
      acl: [
        0: googleworkspace.calendar googleworkspace.calendar.aclRule id = user:[email protected]
        1: googleworkspace.calendar googleworkspace.calendar.aclRule id = domain:lunalectric.com
      ]
    }
  ]

@czunker czunker merged commit f4f5bac into main Jun 24, 2024
15 checks passed
@czunker czunker deleted the ivan/google-workspace-calendar-acl branch June 24, 2024 07:51
@github-actions github-actions bot locked and limited conversation to collaborators Jun 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Need resource googleworkspace.calendar.aclRules
3 participants