Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ This format follows [Keep a Changelog](https://keepachangelog.com/) and adheres
ADLS path ACLs.

### Fixed
- **Hosted Cockpit delegated consent now targets the Log Analytics API.**
Deployment preflight resolves the `Data.Read` scope from the correct resource
application, allowing tenant administrators to grant the required permission.
- **Developer installs include the hosted Cockpit test dependencies.** The
standard development environment can collect and run the FastAPI integration
tests used by CI.
Expand Down
2 changes: 1 addition & 1 deletion src/agentops/services/cockpit_deployment.py
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ def now(self) -> datetime:

FIC_AUDIENCE = "api://AzureADTokenExchange"
MAX_FEDERATED_CREDENTIALS = 20
LOG_ANALYTICS_API_APP_ID = "de8bc8b5-d9f9-48b1-a8ad-b748da725064"
LOG_ANALYTICS_API_APP_ID = "ca7f3f0b-7d91-482c-8e09-c5d840d0eac5"
LOG_ANALYTICS_DELEGATED_SCOPE = "Data.Read"

# Built-in Azure role definition GUIDs. These are stable, well-known IDs
Expand Down
8 changes: 6 additions & 2 deletions tests/unit/test_cockpit_deployment_preview.py
Original file line number Diff line number Diff line change
Expand Up @@ -927,7 +927,7 @@ def test_azcli_app_registration_client_get_app_registration(monkeypatch):
"sp",
"show",
"--id",
"de8bc8b5-d9f9-48b1-a8ad-b748da725064",
"ca7f3f0b-7d91-482c-8e09-c5d840d0eac5",
): (
0,
'{"id": "log-analytics-service-principal"}',
Expand All @@ -950,6 +950,10 @@ def test_azcli_app_registration_client_get_app_registration(monkeypatch):

info = client.get_app_registration(tenant_id=TENANT_ID, client_id=CLIENT_ID)

assert cockpit_deployment.LOG_ANALYTICS_API_APP_ID == (
"ca7f3f0b-7d91-482c-8e09-c5d840d0eac5"
)
assert cockpit_deployment.LOG_ANALYTICS_DELEGATED_SCOPE == "Data.Read"
assert info.application_object_id == APP_OBJECT_ID
assert info.client_id == CLIENT_ID
assert info.service_principal_object_id == SP_OBJECT_ID
Expand Down Expand Up @@ -981,7 +985,7 @@ def test_azcli_app_registration_rejects_unrelated_delegated_consent(monkeypatch)
"sp",
"show",
"--id",
"de8bc8b5-d9f9-48b1-a8ad-b748da725064",
"ca7f3f0b-7d91-482c-8e09-c5d840d0eac5",
): (0, '{"id": "log-analytics-service-principal"}', ""),
("az", "ad", "sp", "show"): (0, '{"id": "%s"}' % SP_OBJECT_ID, ""),
("az", "rest"): (
Expand Down
Loading