Comments (6)
The place to add support would be here:
https://github.com/google/neuroglancer/blob/master/src/neuroglancer/util/special_protocol_request.ts
However, there are a few issues to consider:
- You will need to know the bucket region in order to generate a correct signature. It is a bit tricky to figure it out, see e.g. the approach we take in tensorstore (https://github.com/google/tensorstore/blob/4e82af4392fe4939875d80f9fa5fd01c55beda64/tensorstore/kvstore/s3/s3_endpoint.cc#L211) but here there is the added challenge that it needs to work within the cross-origin request limitations of the browser. Alternatively you could require that the bucket region be specified manually as part of the datasource URL, though that is a bit annoying.
- If you put the access key in the datasource URL itself, then sharing the Neuroglancer URL/state will also share the access key. That may in some cases be desired, but you would need to be careful to use an access key with only the limited privileges that you intend to grant. It would be very easy to accidentally share a more privileged access key. For GCS, I implemented ngauth, which allows neuroglancer users to access private GCS buckets. It requires that you run an ngauth server, which verifies a given user has access to a bucket, and then provides a time-limited restrict authentication token. For S3, I think there may be a way to accomplish something similar, without even the need for a server, by using AWS Cognito combined with suitable S3 access policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_examples_s3_cognito-bucket.html). I expect in many cases that would be preferable to embedding the access token directly in the URL. Nonetheless, it could make sense to still support directly embedding the access token in the URL, and that is ultimately simpler.
- A final issue is that the access token would ideally come at the beginning of the URL, before the bucket name, rather than at the end, so that completion works.
from neuroglancer.
Related Issues (20)
- How to use the segment_split_merge_tool
- Expose `bind_port` in python server arguments HOT 1
- Zstandard support? HOT 1
- N5 now supports Zstandard HOT 2
- "StarredSegments" object has no attribute "_visible" on release 2.37
- Consider using SolidJS HOT 1
- Use FinalizationRegistry to manage inter-worker object mappings without reference counting
- undock layer side panel HOT 1
- Set matrix transform for ImageLayer via Python HOT 2
- Hiding yellow border for images? HOT 3
- neuroglancer default framebuffer size artificially limits resolution HOT 7
- MAX_DRAW_BUFFERS limit error with shader in Safari
- Spatial dimensions, xy, is rendering in the 'zy' plane instead of the 'xy' plane when using the zarr format HOT 3
- Annotation coloring by random seed
- Loading of precomputed data stalls HOT 2
- Import annotation from csv feature, is it still available? HOT 5
- precomputed annotation format related ID lookup HOT 2
- WebXR support
- feature request: change default shader for multi-channel images
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from neuroglancer.