Adding ability to sign URL from GAE.#921
Conversation
|
@jgeewax I was actually reminded of this old bug when discussing some performance issues of Is there a GCE equivalent (I assume via metadata server) of from google.appengine.api import app_identity
_, signed_bytes = app_identity.sign_blob(string_to_sign)Is there someone who works on GCE who might be worth asking? |
|
@ludoch : Do you know if there's a GCE equivalent of GAE Python's |
|
@tseaver PTAL |
gcloud/credentials.py
Outdated
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Also refactoring _get_signed_query_params and the related tests so that the signing process and service account name determination are isolated methods. Fixes googleapis#607.
|
@tseaver Done (and rebased on top of HEAD). |
|
LGTM |
Adding ability to sign URL from GAE.
Source-Link: googleapis/synthtool@8767740 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:023a21377a2a00008057f99f0118edadc30a19d1636a3fee47189ebec2f3921c Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Source-Link: googleapis/synthtool@8767740 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:023a21377a2a00008057f99f0118edadc30a19d1636a3fee47189ebec2f3921c Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Source-Link: googleapis/synthtool@bc07fd4 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:30470597773378105e239b59fce8eb27cc97375580d592699206d17d117143d0 Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Source-Link: googleapis/synthtool@dede53f Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:fac304457974bb530cc5396abd4ab25d26a469cd3bc97cbfb18c8d4324c584eb Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
🤖 I have created a release *beep* *boop* --- ## [2.4.0](googleapis/google-auth-library-python@v2.3.3...v2.4.0) (2022-01-20) ### Features * add 'py.typed' declaration ([#919](googleapis/google-auth-library-python#919)) ([c993504](googleapis/google-auth-library-python@c993504)) * add api key support ([#826](googleapis/google-auth-library-python#826)) ([3b15092](googleapis/google-auth-library-python@3b15092)) ### Bug Fixes * **deps:** allow cachetools 5.0 for python 3.7+ ([#937](googleapis/google-auth-library-python#937)) ([1eae37d](googleapis/google-auth-library-python@1eae37d)) * fix the message format for metadata server exception ([#916](googleapis/google-auth-library-python#916)) ([e756f08](googleapis/google-auth-library-python@e756f08)) ### Documentation * fix intersphinx link for 'requests-oauthlib' ([#921](googleapis/google-auth-library-python#921)) ([967be4f](googleapis/google-auth-library-python@967be4f)) * note ValueError in `verify_oauth2_token` ([#928](googleapis/google-auth-library-python#928)) ([82bc5f0](googleapis/google-auth-library-python@82bc5f0)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
* Docs: Add Attributes to pubsub_v1.types * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix lint * fix indent * Apply suggestions from code review Co-authored-by: Dan Lee <71398022+dandhlee@users.noreply.github.com> * Apply suggestions from code review Co-authored-by: Dan Lee <71398022+dandhlee@users.noreply.github.com> --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Dan Lee <71398022+dandhlee@users.noreply.github.com>
* feat: Proto Columns Feature (#909) * feat: adding proto autogenerated code changes for proto column feature * feat: add implementation for Proto columns DDL * feat: add implementation for Proto columns DML * feat: add implementation for Proto columns DQL * feat: add NoneType check during Proto deserialization * feat: add code changes for Proto DDL support * feat: add required proto files to execute samples and tests * feat: add sample snippets for Proto columns DDL * feat: add tests for proto columns ddl, dml, dql snippets * feat: code refactoring * feat: remove staging endpoint from snippets.py * feat: comment refactor * feat: add license file * feat: update proto column data in insertion sample * feat: move column_info argument to the end to avoid breaking code * feat: Proto column feature tests and samples (#921) * feat: add integration tests for Proto Columns * feat: add unit tests for Proto Columns * feat: update tests to add column_info argument at end * feat: remove deepcopy during deserialization of proto message * feat: tests refactoring * feat: integration tests refactoring * feat: samples and sample tests refactoring * feat: lint tests folder * feat:lint samples directory * feat: stop running emulator with proto ddl commands * feat: close the file after reading * feat: update protobuf version lower bound to >3.20 to check proto message compatibility * feat: update setup for snippets_tests.py file * feat: add integration tests * feat: remove duplicate integration tests * feat: add proto_descriptor parameter to required tests * feat: add compatibility tests between Proto message, Bytes and Proto Enum, Int64 * feat: add index tests for proto columns * feat: replace duplicates with sample data * feat: update protobuf lower bound version in setup.py file to add support for proto messages and enum * feat: lint fixes * feat: lint fix * feat: tests refactoring * feat: change comment from dml to dql for read * feat: tests refactoring for update db operation * feat: rever autogenerated code * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix: fix code * fix: fix code * fix(spanner): fix code * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix(spanner): skip emulator due to b/338557401 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix(spanner): remove samples * fix(spanner): update coverage * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * chore(spanner): update coverage * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix(spanner): add samples and update proto schema * fix(spanner): update samples database and emulator DDL * fix(spanner): update admin test to use autogenerated interfaces * fix(spanner): comment refactoring --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Also refactoring
_get_signed_query_paramsand the related tests so that the signing process and service account name determination are isolated methods.Fixes #607.