Skip to content

Commit

Permalink
Fix to access to store account with RBAC.
Browse files Browse the repository at this point in the history
  • Loading branch information
antoniotarricone committed Oct 30, 2023
1 parent b8220eb commit fc44817
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
*/
package it.pagopa.swclient.mil.auth.azure.storage.client;

import org.eclipse.microprofile.rest.client.annotation.ClientHeaderParam;
import org.eclipse.microprofile.rest.client.inject.RegisterRestClient;

import io.smallrye.mutiny.Uni;
Expand All @@ -28,6 +29,7 @@ public interface AzureAuthDataRepositoryClient {
*/
@Path("clients/{clientId}.json")
@GET
@ClientHeaderParam(name = "x-ms-version", value = "${azure-storage-api.version}")
Uni<Client> getClient(@HeaderParam("Authorization") String authorization, @PathParam("clientId") String clientId);

/**
Expand All @@ -41,6 +43,7 @@ public interface AzureAuthDataRepositoryClient {
*/
@Path("roles/{acquirerId}/{channel}/{clientId}/{merchantId}/{terminalId}/roles.json")
@GET
@ClientHeaderParam(name = "x-ms-version", value = "${azure-storage-api.version}")
Uni<Role> getRoles(
@HeaderParam("Authorization") String authorization,
@PathParam("acquirerId") String acquirerId,
Expand All @@ -56,5 +59,6 @@ Uni<Role> getRoles(
*/
@Path("users/{userHash}.json")
@GET
@ClientHeaderParam(name = "x-ms-version", value = "${azure-storage-api.version}")
Uni<User> getUser(@HeaderParam("Authorization") String authorization, @PathParam("userHash") String userHash);
}
3 changes: 2 additions & 1 deletion src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ poynt-api.version=1.2
# Authorization data repository (clients, roles)
# ------------------------------------------------------------------------------
quarkus.rest-client.auth-data-repository.url=https://mildconfst.blob.core.windows.net
azure-storage-api.version=2019-07-07
%prod.quarkus.rest-client.auth-data-repository.url=${auth.data.url}

# ------------------------------------------------------------------------------
Expand All @@ -79,4 +80,4 @@ azure-key-vault-api.version=7.4
quarkus.rest-client.azure-key-vault-api.url=http://dummy

%prod.azure-key-vault-api.version=${auth.keyvault.api-version}
%prod.quarkus.rest-client.azure-key-vault-api.url=${auth.keyvault.url}
%prod.quarkus.rest-client.azure-key-vault-api.url=${auth.keyvault.url}

0 comments on commit fc44817

Please sign in to comment.