Uh oh!
There was an error while loading. Please reload this page.
Storage: add support for V4 signed URLs - #7460
Conversation
tseaver
commented
Mar 4, 2019
The docs build failure on CI is unrelated to this PR: it was fixed in #7458. |
| .. note:: | ||
| If you are on Google Compute Engine, you can't generate a signed URL. | ||
| Follow `Issue 922`_ for updates on this. If you'd like to be able to |
There was a problem hiding this comment.
@tseaver this is supported in the Python auth library. Is this a typo?
There was a problem hiding this comment.
@frankyngoogleapis/google-auth-library-python#50 is still open: AFAIK, the only way to get signing done on GCE is to use the IAM-based workaround. I plan to add that here (following your Ruby PoC) once we're OK with the surface.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
tseaver
commented
Mar 11, 2019
@frankyn A question: the current Python V2 version allows for passing |
At a blob level, yes. The resumable header is also supported when using V4 signed URLs. One request I have is to state in the documentation that the |
tseaver
commented
Mar 12, 2019
Flaky spanner systest reported in #7504. |
tseaver
commented
Mar 12, 2019
@crwilcox Can you check what is hanging the Kokoro builds here? |
frankyn
commented
Mar 12, 2019
@tseaver please do not support signed URLs at a client level. |
Uh oh!
There was an error while loading. Please reload this page.
crwilcox
commented
Mar 28, 2019
@tseaver do you need anything from me to move this along? |
frankyn
left a comment
There was a problem hiding this comment.
Python doesn't have the timestamp offset bug mentioned in email.
tseaver
commented
Apr 1, 2019
tseaver
commented
Apr 1, 2019
tseaver
commented
Apr 1, 2019
@frankyn I believe the only remaining work is to add support for IAM / access token signing: note that the feature does not exist yet for V2 in Python. |
| credentials = client._credentials | ||
| return generate_signed_url( | ||
| if version == "v2": |
There was a problem hiding this comment.
@tseaver could you add a warning as log output that V2 will change to V4 in the future:
You have generated a signed URL using the default v2 signing implementation. In the future, this will default to v4. You may experience breaking changes if you use longer than 7 day expiration times with v4. To opt-in to the behavior specify
version="v2".
tseaver
commented
Apr 1, 2019
Exclusive with 'expiration', to permit clearer semantics for users.
Headers have to be sorted *after* lower-casing the keys.
In addition to stripping leading / trailing spaces, collapse multiple interior spaces into one.
tseaver
commented
Apr 17, 2019
@frankyn PTAL. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Partial support for the new feature: adds a
versionargument toBlob.generate_signed_url, and uses it to switch between the two signing algorithms.Remaining work:
Bucket.generate_signed_url, to permit listing bucket contents.Deferred work:
X-Goog-Signedheader) (Storage: un-skip system tests for 'Bucket.generate_signed_url' #7625).No longer in scope:
AddClient.generate_signed_url, to permit listing buckets.