Skip to content

492 fiware secure header does not support dynamic update#493

Merged
djs0109 merged 10 commits intomasterfrom
492-FIWARE-secure-header-does-not-support-dynamic-update
Apr 22, 2026
Merged

492 fiware secure header does not support dynamic update#493
djs0109 merged 10 commits intomasterfrom
492-FIWARE-secure-header-does-not-support-dynamic-update

Conversation

@djs0109
Copy link
Copy Markdown
Collaborator

@djs0109 djs0109 commented Mar 31, 2026

closes #492

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses #492 by ensuring FIWARE headers (including dynamically computed secure tokens) are composed at request time rather than being snapshotted at client initialization.

Changes:

  • Added a central BaseHttpClient.request() helper that re-dumps fiware_headers for every outgoing call, and refactored HTTP verb helpers to use it.
  • Refactored NGSI v2 / NGSI-LD pagination helpers to route through the centralized request path.
  • Added a unit test for dynamic header refresh behavior and updated the secure-header example + changelog.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
filip/clients/base_http_client.py Introduces per-request FIWARE header injection and routes all HTTP verbs through a shared request helper.
filip/clients/ngsi_v2/cb.py Pagination now uses the shared request helper (and thus the new header injection behavior).
filip/clients/ngsi_ld/cb.py Same pagination refactor as NGSI v2, via the shared request helper.
filip/clients/ngsi_v2/iota.py Adjusts service/path checks to use fiware_service properties; tweaks admin log header handling.
tests/clients/test_ngsi_v2_client.py Adds a regression test ensuring Authorization is recomputed per request.
examples/ngsi_v2/e13_ngsi_v2_secure_fiware_headers.py Updates example to demonstrate request-time token refresh using a Keycloak-backed computed header.
CHANGELOG.md Notes the dynamic header composition fix.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread filip/clients/base_http_client.py
Comment thread filip/clients/ngsi_v2/cb.py Outdated
Comment thread filip/clients/ngsi_ld/cb.py Outdated
Comment thread tests/clients/test_ngsi_v2_client.py
Comment thread examples/ngsi_v2/e13_ngsi_v2_secure_fiware_headers.py
Comment thread filip/clients/ngsi_v2/iota.py Outdated
Comment thread filip/clients/ngsi_v2/iota.py
djs0109 and others added 4 commits April 22, 2026 13:22
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@djs0109 djs0109 merged commit 9f10306 into master Apr 22, 2026
13 of 15 checks passed
@djs0109 djs0109 deleted the 492-FIWARE-secure-header-does-not-support-dynamic-update branch April 22, 2026 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FIWARE secure header does not support dynamic update

3 participants