Azure Keyvault expired secret working after expiration date

Jigarkumar Patel 21 Reputation points
2024-08-07T13:38:37.6566667+00:00

Hi All,

I have stored a secret in key vault with expiration date. The secret is a connection string to connect to on-prem oracle database

This secret is used in linkedservice to connect to on-prem Oracle datasbase.

Now when I am running the adf pipeline to access the database via this linkedservice it is working.

My expectation was since the secret is expired, the pipeline should have failed. 

Is my understanding incorrect ?

Azure Key Vault
Azure Key Vault
An Azure service that is used to manage and protect cryptographic keys and other secrets used by cloud apps and services.
1,314 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sandeep G-MSFT 19,761 Reputation points Microsoft Employee
    2024-08-07T16:15:28.8433333+00:00

    @Jigarkumar Patel

    Thank you for posting this in Microsoft Q&A.

    As I understand in your environment you have a key vault secret that is used in linked service to connect to on-prem Oracle database. Now, you have the key vault secret expired and still the entire configuration is working even with the expired secret.

    By default, secrets do not expire. We recommend you rotate secrets in the key vault and set an explicit expiration time for all secrets. This ensures that the secrets cannot be used beyond their assigned lifetimes.

    There are 2 different things that get set,

    The expiration date is the date and time when the key will no longer be valid. This is set when you create the key.

    The expiry time is the time interval after which the key will be rotated. This is set when you configure the key rotation policy.

    The key rotation policy is used to automatically rotate the key after a specified time interval. The key rotation policy is used to ensure that the key is rotated regularly, which helps to maintain the security of the key.

    If both the expiration date and the expiry time are configured, the key will be rotated after the expiry time has elapsed. If the key is rotated, the new key will have the expiration date set when the key was created.

    I think in your environment here is a auto rotation of secret has been configured due to which your configuration is still working even after key vault secret is expired.

    Let us know if you have any further questions.

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


Your answer

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