Unable to scan Azure SQL server DB in Purview due to complicated User access process

Mudassar A 496 Reputation points
2021-05-31T04:08:41.357+00:00

I m unable to scan Azure SQL server DB in Purview due to complicated User access process .

Error: (3867) Failed to access the Azure SQL database. The given credential has not been applied or does not have permission on the target database.

Attached is the screenshot.

100880-image.png

The whole process is so complicated , not sure who designed it , truly just to scan a simple resource is a challenge.

I have attached screenshot for reference. I have a key vault in the same region as the Purview is in.

I know my Purview managed identity and how should it be mapped to provide access to SQL DB and PURVIEW ?

I had provided Purview managed identity with owner access and yet it fails to connect

100908-image.png

100943-purview-account-provided-owner-access.png

100933-purview-access.png

Microsoft Security | Microsoft Purview
0 comments No comments
{count} votes

Answer accepted by question author
  1. PRADEEPCHEEKATLA 91,496 Reputation points Moderator
    2021-05-31T10:42:19.94+00:00

    Hello @Anonymous ,

    Thanks for the question and using MS Q&A platform.

    As per the question, you want to use SQL authentication using Azure Key vault.

    You need to follow the below steps to use the SQL authentication to scan Azure SQL Database.

    Step1: Create a Secret in the Azure Key vault.

    I had created Azure SQL authentication password in the secret called chepra.

    101082-image.png

    Step2: Assign access using using Key Vault Access Policy

    101083-image.png

    Step3: Create Azure Key Vaults connections in your Azure Purview account

    101111-image.png

    Step4: Create a new credential

    101027-image.png

    Step5: Register an Azure SQL Database data source

    101112-image.png

    Step6: Now create a scan rule by selecting the previously created credentials.

    101028-image.png

    101073-image.png

    101121-purview-azsqldbscan.gif

    Hope this helps. Do let us know if you any further queries.

    ---------------------------------------------------------------------------

    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.


1 additional answer

Sort by: Most helpful
  1. Nipuna Weerasinghe 21 Reputation points
    2023-01-28T13:35:24.8933333+00:00

    @PRADEEPCHEEKATLA

    I tried to scan the azure SQL , but I m getting an error "Error: (20503) Failed to access the Azure key vault. Please grant Purview MSI permissions to get secrets on your key vault."

    Can you please help me with this?

    Thanks.

    User's image

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.