Skip to content

storage: Use standard URL to use path instead of subdomain for bucket#638

Merged
stephenplusplus merged 2 commits intogoogleapis:masterfrom
phw:storage-fix-generic-url
Jun 4, 2015
Merged

storage: Use standard URL to use path instead of subdomain for bucket#638
stephenplusplus merged 2 commits intogoogleapis:masterfrom
phw:storage-fix-generic-url

Conversation

@phw
Copy link
Contributor

@phw phw commented Jun 4, 2015

Fixes the SSL certificate being invalid for buckets containing dots.

E.g. if you want to access the bucket mybucket.example.com without this patch this results in the URL https://mybucket.example.com.storage.googleapis.com/ for which the SSL certificate is not valid (the certificate captures direct subdomains only). This patch uses the equally generic URL https://storage.googleapis.com/mybucket.example.com/.

…cket.

Fixes the SSL certificate being invalid for buckets containing dots.
@googlebot
Copy link

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project, in which case you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.


  • If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
  • If you signed the CLA as a corporation, please let us know the company's name.

@googlebot googlebot added the cla: no This human has *not* signed the Contributor License Agreement. label Jun 4, 2015
@phw
Copy link
Contributor Author

phw commented Jun 4, 2015

For reference: This bugs was introduced in 93d7a12

@stephenplusplus
Copy link
Contributor

Cool, thanks. This should resolve #624 then as well, right?

@phw
Copy link
Contributor Author

phw commented Jun 4, 2015

I signed it!

@googlebot
Copy link

CLAs look good, thanks!

@googlebot googlebot added cla: yes This human has signed the Contributor License Agreement. and removed cla: no This human has *not* signed the Contributor License Agreement. labels Jun 4, 2015
@stephenplusplus
Copy link
Contributor

Do you want to fix the tests or have me worry about it?

@phw
Copy link
Contributor Author

phw commented Jun 4, 2015

I think that should fix #624 and it looks IMHO better than the fix provided there (seems a bit hacky). Will fix the unit test in a moment.

@phw
Copy link
Contributor Author

phw commented Jun 4, 2015

Done. Or do you prefer the commits squashed together?

@stephenplusplus
Copy link
Contributor

This is perfect, thanks very much!

stephenplusplus added a commit that referenced this pull request Jun 4, 2015
storage: Use standard URL to use path instead of subdomain for bucket
@stephenplusplus stephenplusplus merged commit 8e98bdf into googleapis:master Jun 4, 2015
@phw
Copy link
Contributor Author

phw commented Jun 4, 2015

Thank you very much, never got anything merged upstream that fast. Saves me some headaches for the deployment today :)

@phw phw deleted the storage-fix-generic-url branch June 4, 2015 13:51
@stephenplusplus
Copy link
Contributor

Great! Never fear submitting patches and ideas here, we'll always get back pretty quickly :)

sofisl pushed a commit that referenced this pull request Nov 10, 2022
We should be running `compile-protos` as part of prepare, do so.

Fixes #632
sofisl pushed a commit that referenced this pull request Nov 11, 2022
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [ts-loader](https://togithub.com/TypeStrong/ts-loader) | devDependencies | major | [`^7.0.0` -> `^8.0.0`](https://renovatebot.com/diffs/npm/ts-loader/7.0.5/8.0.0) |

---

### Release Notes

<details>
<summary>TypeStrong/ts-loader</summary>

### [`v8.0.0`](https://togithub.com/TypeStrong/ts-loader/blob/master/CHANGELOG.md#v800)

[Compare Source](https://togithub.com/TypeStrong/ts-loader/compare/v7.0.5...v8.0.0)

-   [Support for symlinks in project references](https://togithub.com/TypeStrong/ts-loader/pull/1136) - thanks [@&#8203;sheetalkamat](https://togithub.com/sheetalkamat)!
-   `ts-loader` now supports TypeScript 3.6 and greater **BREAKING CHANGE**

</details>

---

### Renovate configuration

:date: **Schedule**: "after 9am and before 3pm" (UTC).

:vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

:recycle: **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

:no_bell: **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/nodejs-dialogflow).
sofisl pushed a commit that referenced this pull request Nov 17, 2022
[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@types/node](https://togithub.com/DefinitelyTyped/DefinitelyTyped) | [`^14.17.3` -> `^16.0.0`](https://renovatebot.com/diffs/npm/@types%2fnode/14.17.32/16.11.6) | [![age](https://badges.renovateapi.com/packages/npm/@types%2fnode/16.11.6/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/npm/@types%2fnode/16.11.6/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/npm/@types%2fnode/16.11.6/compatibility-slim/14.17.32)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/npm/@types%2fnode/16.11.6/confidence-slim/14.17.32)](https://docs.renovatebot.com/merge-confidence/) |

---

### Configuration

📅 **Schedule**: "after 9am and before 3pm" (UTC).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox.

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/nodejs-compute).
sofisl pushed a commit that referenced this pull request Feb 4, 2026
Source-Link: googleapis/synthtool@cd78529
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-nodejs:latest@sha256:ddb19a6df6c1fa081bc99fb29658f306dd64668bc26f75d1353b28296f3a78e6
sofisl pushed a commit that referenced this pull request Feb 25, 2026
* feat: v4 signed url WIP

* make version an optinoal

* lint

* add required host header

* fix canonical query params joining

* add test for defaulting to v2

* fix v4 signing with test

* fix tests

* refactor post-signing url construction v2/v4

* add v4 tests: response-content-type and generate parameters

* convert signature to HEX

* add conformance test

* npm run fix

* remove reduntant toLowerCase

* do not promisify getDate()

* add system-test for v4 signing

* run conformance test along with system test

* fix tests

* add content-md5 and content-type to signed headers if given

* Object.entries in not ES5

* npm run fix

* split out conformance test

* test: invalid version param given

* mock out Date when testing instead of override Date

* use Array.map to build canonical query

* refactor: use dateformat library instead of writing a function

* refactor: remove unused

* remove reference to deleted methods

* refactor: use string interpolation and dot accessor

* refactor: use method chaining

* add a comment about singled valued header

* refactor signedHeaders

* Number(x)

* refactor: use query-string module as url.parse is deprecated

* npm run fix

* use query-string to build canonicalQueryParams

* refactor: verb => method

* refactor: use sinon.FakeTimers instead of timekeeper

* npm run fix

* use async/await for new system-test

* use async/await for new test (2)

* convert getSignedUrl tests to async/await

* refactor: correctly filter out undefined header values

* npm run fix

* make v4 multi-valued header delimiter consistent with v2, (single `,`, no space)

* copy stack trace

* fix: replace ALL sequential spaces

* OutgoingHttpHeaders use generic type .map; rename flattenObject => objectEntries

* refactor: use build-in querystring

* break up v2/v4 signed url query interface

* add comments about the construction of canonical headers

* npm run fix

* git merge failed to put code in right place

* test: assert SigningError thrown

* test(v4): resumable upload

* prefer string.includes over indexOf

* npm run fix

* docs: add a note on POST and X-Goog-Resumable

* SEVEN_DAYS = 604800

* emit warning when using default version

* emitWarning if using default version for signing

* restore stub

* add new line

* test: v4 signed URL: conformance test (#638)

* Revert "split out conformance test"

This reverts commit ce00255c738e97bf6e3e602f7cca23fae3793d05.

* sync conformance-test cases; parse cases without modification

* this.skip

* refactor: lift interface

* remove default v2 warning

* docs(samples): Samples for v4 Signed URL (#654)

* remove timeout on conformance-test

* npm run fix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants