Title: `HttpTransferCache` can cache authenticated responses when using `withRequestsMadeViaParent` · Issue #69777 · angular/angular · GitHub
Open Graph Title: `HttpTransferCache` can cache authenticated responses when using `withRequestsMadeViaParent` · Issue #69777 · angular/angular
X Title: `HttpTransferCache` can cache authenticated responses when using `withRequestsMadeViaParent` · Issue #69777 · angular/angular
Description: Which @angular/* package(s) are the source of the bug? common Is this a regression? No Description In SSR TransferCache when a child HttpClient useswithRequestsMadeViaParent(). The child request starts without authentication. A parent in...
Open Graph Description: Which @angular/* package(s) are the source of the bug? common Is this a regression? No Description In SSR TransferCache when a child HttpClient useswithRequestsMadeViaParent(). The child request st...
X Description: Which @angular/* package(s) are the source of the bug? common Is this a regression? No Description In SSR TransferCache when a child HttpClient useswithRequestsMadeViaParent(). The child request st...
Opengraph URL: https://github.com/angular/angular/issues/69777
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`HttpTransferCache` can cache authenticated responses when using `withRequestsMadeViaParent`","articleBody":"### Which @angular/* package(s) are the source of the bug?\n\ncommon\n\n### Is this a regression?\n\nNo\n\n### Description\n\nIn SSR `TransferCache` when a child `HttpClient` uses`withRequestsMadeViaParent()`.\n\nThe child request starts without authentication. A parent interceptor then adds a server-only `Authorization` header before sending it to an internal API. The request passes through two TransferCache interceptors:\n\n```text\nchild `HttpClient`\n -> child `TransferCache` sees an anonymous request\n -> parent authentication interceptor adds `Authorization`\n -> parent `TransferCache` sees the authenticated request and skips it\n -> backend returns a private response\n -> child TransferCache stores that response\n```\n\nThe child `TransferCache` decides that the request is safe before the parent adds authentication, but it later receives the response produced by the authenticated request. That response is then written to `TransferState` and included in the SSR HTML.\n\nThe same thing happens with a custom filter. \nEg: If the parent adds `X-API-KEY`, this filter is evaluated once before the header exists and once after it exists:\n\n```ts\nwithHttpTransferCacheOptions({\n filter: (request) => !request.headers.has('X-API-KEY'),\n});\n```\n\nThe parent `TransferCache` skips the request, but the child `TransferCache` still stores the response.\n\n### Expected behavior\n\n`TransferCache` should evaluate the final request after the parent interceptors have run. If that request is authenticated or rejected by the configured filter, the response should not be added to `TransferState`.\n\n### Actual behavior\n\nThe authenticated response is stored using the decision made from the original anonymous child request. \n","author":{"url":"https://github.com/SkyZeroZx","@type":"Person","name":"SkyZeroZx"},"datePublished":"2026-07-15T04:58:39Z","url":"https://github.com/angular/angular/issues/69777"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:97c68f6c-c4be-e8f6-8533-d69c5e472d7b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | CF52:3FE6B6:7BA32C:A9AFA7:6AFDEF8E |
| html-safe-nonce | 55a227bea67864c60780fd3e8de35859ebcf24174ef67be00090822db167e14b |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDRjUyOjNGRTZCNjo3QkEzMkM6QTlBRkE3OjZBRkRFRjhFIiwidmlzaXRvcl9pZCI6IjE0MTM4MzE4NDQ2OTE4MzI3MTgiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2a0765f5d2382ec9b0463649715056fe74f35768c641fb2b8300592787f06ce6 |
| hovercard-subject-tag | issue:4889423926 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/angular/angular/69777/issue_layout |
| twitter:image | https://opengraph.githubassets.com/d69917400ac6acad28217c4c30c302b6f45469857f33994801e7d1b1969b0617/angular/angular/issues/69777 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/d69917400ac6acad28217c4c30c302b6f45469857f33994801e7d1b1969b0617/angular/angular/issues/69777 |
| og:image:alt | Which @angular/* package(s) are the source of the bug? common Is this a regression? No Description In SSR TransferCache when a child HttpClient useswithRequestsMadeViaParent(). The child request st... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | SkyZeroZx |
| hostname | github.com |
| expected-hostname | github.com |
| None | dd812ec581ecac95855f5ec917ef9827506c39a9da1443f43ddb4179a46471eb |
| turbo-cache-control | no-preview |
| go-import | github.com/angular/angular git https://github.com/angular/angular.git |
| octolytics-dimension-user_id | 139426 |
| octolytics-dimension-user_login | angular |
| octolytics-dimension-repository_id | 24195339 |
| octolytics-dimension-repository_nwo | angular/angular |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 24195339 |
| octolytics-dimension-repository_network_root_nwo | angular/angular |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 32ac708bac264dafdc28e10ff49b4d137f0c34a7 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width