Could you please confirm if :
- You are using the secret to create a new policy key with expiry time same, as defined while generating the secret?
- You are using the secret to edit an existing policy key with expiry time same, as defined while generating the secret?
- You are using the secret to create a new policy key with expiry time different from what was defined while generating the secret?
Update #1
I would recommend to create a new policy and use your newly generated secret.
As per, B2C policy key documentation:
The keys in a keyset are not replaceable or removable. If you need to change an existing key:We recommend adding a new key with the activation date set to the current date and time. Azure AD B2C will activate the new key and stop using the prior active key.
Alternatively, you can create a new keyset with the correct keys. Update your policy to use the new keyset, and then remove the old keyset.
Please "Accept the answer (Yes)" and "share your feedback ". This will help us and others in the community as well.
Thanks, Akshay Kaushik