Skip to content

feat(ocm): define incoming share updates - #285

Open
MahdiBaghbani wants to merge 9 commits into
cs3org:mainfrom
MahdiBaghbani:ocm-incoming-share-updates
Open

MahdiBaghbani wants to merge 9 commits into
cs3org:mainfrom
MahdiBaghbani:ocm-incoming-share-updates

Conversation

@MahdiBaghbani

@MahdiBaghbani MahdiBaghbani commented Nov 25, 2026 •

Copy link
Copy Markdown
Member

This PR is part of cs3org/OCM-STA#52 and follows the share selectors in cs3org/OCM-API#433

Summary

Define RPCs to withdraw an incoming grant or replace its permission snapshot. Match the exact sender and grant, and allow an explicit empty snapshot to clear permissions

This is the first PR in the schema stack. All three target upstream main because the intermediate branches are on my fork
The companion PRs are #286 and #287

Buf build and breaking checks passed. Buf lint adds 8 RPC_REQUEST_RESPONSE_UNIQUE diagnostics relative to this base because Gateway and provider RPCs share request and response types

flowchart LR
    A["Verified share notice"] --> B["Match sender and grant"]
    B --> C["Withdraw matching grants"]
    B --> D["Replace permissions"]
Loading

Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>
Signed-off-by: Mahdi Baghbani <mahdi-baghbani@azadehafzar.io>

@glpatcern glpatcern left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Mahdi, as the CS3APIs are shared with ownCloud and OpenCloud, the overall objective should be to make the minimal possible extension. In this case, the API already has DeleteOCMIncomingShare (which is semantically equivalent to Withdraw) and UpdateOCMIncomingShare (which is semantically equivalent to Change), can you please use those?

As for the fields: I think we can remove legacy_shared_secret, and we should be able to go along without sender_ip as that would be validated at the HTTP layer, before going to the API.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants