-
Notifications
You must be signed in to change notification settings - Fork 113
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
OCM WebDAV service #2739
Comments
Looking at the specific reva services and APIs, the workflow would look like:
Relavant code: |
How Bob would be able to access the files received by him:
|
What?
The Open Cloud Mesh (OCM) is a protocol that enables sharing of data across various cloud providers, given that they agree on the APIs that they'll be exposing to users from these other providers. For different reva deployments, each of which might connect to different storage backends and authentication providers, this is supposed to work out of the box.
The workflow
Invitation workflow
Alice
atCERN
wants to share data withBob
atCESNET
. Both the reva deployments at these two organizations will come to know of the other sites by either reading from a json config file or connecting to a central database, we support both the options. Let's say for now that both the sites have the json files with the following content:Alice@CERN
will send a/invites/forward
request toBob@CESNET
, asking Bob if he wants to begin sharing of data.Bob
accepts the invite, the reva deployment at CESNET will send some metadata about Bob to CERN and then Alice can search for Bob and begin sharing of data with him.Note that the invitation workflow is already implemented and not under the scope of this project. I've described it only for developers to get a better understanding of how OCM works.
OCM sharing
POST /shares
request to Reva@CERN with the following parameters:/ocm/shares
. So Reva@CERN will send aPOST /ocm/shares
request to Reva@CESNET with the following parameters:/users/alice/myFolder
at CERN, it'll use the token it received as part of the request to access it and Reva@CERN should have mechanisms to verify that this token has access to that particular path and allow the request to go through. This request will be send to theWebdav
endpoint specified in the config file at the top. So this request would look likeCurrent implementation
Looking at the above workflow, step 4 seems simple but how we implement right now is a hack. As part of the
Token
parameter in thePOST /ocm/shares
request, we send Alice's identifier token which allows access to Alice's complete namespace and is short-lived.Bob
can use the token to access/users/alice/secretFolder
and our current implementation would allow it.New design
Token
parameter, we won't send Alice's token but generate a random ID and send that as part of thePOST /ocm/shares
call. So this would look like:Webdav endpoint
in the config file to point to this new service. Let's say it's exposed at/ocm/webdav
. So now Bob@CESNET will send a request likeThere's one other alternative. Since reva@CERN will know what path this share ID points to, the request could skip specifying the path and look like
We'll consider the pros and cons of both approaches before implementing.
random-share-id
exists or not, and if it does, see if the request has the appropriate permissions. For example, if Alice creates a share withReader
permissions and Bob tries to write to the file, this should not be allowed.The text was updated successfully, but these errors were encountered: