Repository navigation
feat(ocm): add OCM HTTP signatures - #1104
Draft
MahdiBaghbani wants to merge 16 commits into
Draft
MahdiBaghbani wants to merge 16 commits into
MahdiBaghbani wants to merge 16 commits into
Conversation
Not up to standards ⛔🔴 Issues
|
| Category | Results |
|---|---|
| Security | 11 critical (11 false positives) |
🟢 Metrics 1174 complexity · 51 duplication
Metric Results Complexity 1174 Duplication 51
AI Reviewer: first review requested successfully. AI can make mistakes. Always validate suggestions.
TIP This summary will be updated as you push new changes.
This was referenced Dec 4, 2026
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>
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>
MahdiBaghbani
force-pushed
the
ocm-signed-notifications
branch
from
December 4, 2026 17:49
bc99fa1 to
158a1ff
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is part of cs3org/OCM-STA#54
Summary
Add OCM HTTP signatures to every OCM request OpenCloud sends and receives, the same way CERNBox does since cs3org#5968 and cs3org#6031. Invites, share creation and notifications are signed when a
signing_keyis set, andocmdverifies them whenhttp_sigis onIt's off by default. In
permissivemode an unsigned request is still accepted if the sender doesn't advertisehttp-sig.strictrejects anything unsigned and addsmust-use-http-sigto discovery. Unlike cs3org#6031 the key stays optional, so existing setups don't changePeers that advertise
notificationsget signed standard notifications, everyone else gets the existing OpenCloud ones. Those older notifications don't name a sender, so permissive mode still accepts them unsignedDiscovery also lists
foldernext tofile. OpenCloud already sends folder shares, but CERNBox refuses a resource type the sender doesn't advertiseflowchart LR A["Incoming OCM request"] --> B{"Signed?"} B -->|yes| C["Verify with the sender's published key"] B -->|no| D{"Strict, or sender advertises http-sig?"} D -->|yes| E["Reject"] D -->|no| F["Accept"] C -->|valid| F C -->|invalid| EI tested invites, shares, permission changes and withdrawals between OpenCloud servers in strict, permissive and off mode, with an older OpenCloud, and with a CERNBox development build in both modes
The signing library needs Go 1.27, and the integration timeout goes from 15 to 20 minutes since the suite takes about 15 minutes here
The OpenCloud configuration is in opencloud-eu/opencloud#4222