-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
security:client-registrations doesn't take propertyconfigurer properties #9491
Comments
Thanks for the report, @florinco. Since this feature has already been added, I think we'd need to see a sample to understand why it isn't working for you. Would you be able to provide a minimal sample demonstrating the issue you are experiencing? |
Thanks for reply Josh.
I can confirm that the placeholders are resolved if I write them as environmental variables. They are not resolved if I store them in a .property file. |
@florinco The The key point here is that the resolution applies only to the You need to ensure the properties are available in the I'm going to close this issue as the behaviour is expected. |
My apologies of digging up an issue that has been closed for over a year, but I am having a terrible time getting our client -id and client-secrets values into our application securely. From my limited understanding, it seems as though the environment variables (via Is there an example of how to use Or is there another way to inject secrets into a spring java application that won't leak secrets that I'm missing? I am grateful for your time and all your work. It has saved us a tremendous amount of time. |
Hi @jgrandja , does this solution work only for properties supplied via JVM properties? I want my properties to be supplied from a factory-method created bean like this:
But this doesn't work. The property is not resolved here:
But it is still resolved in common beans:
I'm not setting the property via |
This issue is similar to #8453
I'm using Spring Security 5.4.5.
The placeholders in security:clientRegistration tag are not resolved. Hard-coded values works fine.
I have a XML configuration containig:
<context:property-placeholder location="classpath*:oauth2.properties"/>
security:client-registrations
<security:client-registration registration-id="microsoft"
client-id="${oauth2.client.id}"
client-secret="${oauth2.client.secret}"
...
provider-id="..."/>
</security:client-registrations>
Placeholders are resolved if used in a bean tag.
The text was updated successfully, but these errors were encountered: