You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cookie-encryption-password configuration parameter take only a single character, it should take a string.
Environment Details
Helidon Version: 2.5.1
Helidon SE or Helidon MP: Helidon MP
JDK version: 1.8
OS: Linux
Docker version (if applicable):
Problem Description
cookie-encryption-password configuration parameter take only a single character, it should take a string.
Configuration - security.providers.oidc.cookie-encryption-password: “masterpassword”
Stack trace
Exception in thread "main" java.lang.IllegalArgumentException: Failed to convert property "security.providers.1.oidc.cookie-encryption-password" from its value "masterpassword" to char
at io.helidon.config.mp.MpConfigImpl.convert(MpConfigImpl.java:308)
at io.helidon.config.mp.MpConfigImpl.toArray(MpConfigImpl.java:346)
at io.helidon.config.mp.MpConfigImpl.optionalValue(MpConfigImpl.java:135)
at io.helidon.config.mp.MpConfigImpl.getOptionalValue(MpConfigImpl.java:120)
at io.helidon.config.mp.SeConfig.as(SeConfig.java:199)
at io.helidon.security.providers.oidc.common.OidcConfig$Builder.config(OidcConfig.java:1248)
at io.helidon.security.providers.oidc.common.OidcConfig.create(OidcConfig.java:463)
at io.helidon.security.providers.oidc.OidcProvider$Builder.config(OidcProvider.java:699)
at io.helidon.security.providers.oidc.OidcProvider.create(OidcProvider.java:207)
at io.helidon.security.providers.oidc.OidcProviderService.providerInstance(OidcProviderService.java:45)
at io.helidon.security.Security$Builder.providerFromConfig(Security.java:1336)
at io.helidon.security.Security$Builder.lambda$fromConfig$1(Security.java:1191)
at java.base/java.lang.Iterable.forEach(Iterable.java:75)
at io.helidon.security.Security$Builder.lambda$fromConfig$2(Security.java:1191)
at java.base/java.util.Optional.ifPresent(Optional.java:183)
at io.helidon.config.ConfigValue.ifPresent(ConfigValue.java:227)
at io.helidon.security.Security$Builder.fromConfig(Security.java:1190)
at io.helidon.security.Security$Builder.config(Security.java:1046)
at io.helidon.microprofile.security.SecurityCdiExtension.configure(SecurityCdiExtension.java:69)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.jboss.weld.injection.StaticMethodInje
ctionPoint.invoke(StaticMethodInjectionPoint.java:95)
at org.jboss.weld.injection.StaticMethodInjectionPoint.invoke(StaticMethodInjectionPoint.java:85)
at org.jboss.weld.injection.MethodInvocationStrategy$SimpleMethodInvocationStrategy.invoke(MethodInvocationStrategy.java:168)
at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:330)
at org.jboss.weld.event.ExtensionObserverMethodImpl.sendEvent(ExtensionObserverMethodImpl.java:123)
at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:308)
at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:286)
at javax.enterprise.inject.spi.ObserverMethod.notify(ObserverMethod.java:124)
at org.jboss.weld.util.Observers.notify(Observers.java:166)
at org.jboss.weld.event.ObserverNotifier.notifySyncObservers(ObserverNotifier.java:285)
at org.jboss.weld.event.ObserverNotifier.notify(ObserverNotifier.java:273)
at org.jboss.weld.event.EventImpl.fire(EventImpl.java:96)
at io.helidon.microprofile.cdi.H
elidonContainerImpl.doStart(HelidonContainerImpl.java:297)
at io.helidon.common.context.Contexts.runInContext(Contexts.java:137)
at io.helidon.microprofile.cdi.HelidonContainerImpl.start(HelidonContainerImpl.java:251)
at io.helidon.microprofile.cdi.Main.main(Main.java:80)
Caused by: java.lang.IllegalArgumentException: The string to map must be a single character, but is: masterpassword
at io.helidon.config.mp.MpConfigBuilder.toChar(MpConfigBuilder.java:118)
at io.helidon.config.mp.MpConfigImpl.lambda$findComponentConverter$cad3d4ae$1(MpConfigImpl.java:252)
Steps to reproduce
Set config value security.providers.oidc.cookie-encryption-password: “masterpassword”
Run the application
The text was updated successfully, but these errors were encountered:
…gle character rather than a string (#4512) (#4657)
* Configuration parameter 'cookie-encryption-password' takes only a single character rather than a string (#4512)
* Simplify cookie-password-encryption conversion and improve the unit test
klustria
added a commit
to klustria/helidon
that referenced
this issue
Aug 4, 2022
…gle character rather than a string (helidon-io#4512) (helidon-io#4657)
* Configuration parameter 'cookie-encryption-password' takes only a single character rather than a string (helidon-io#4512)
* Simplify cookie-password-encryption conversion and improve the unit test
…gle character rather than a string (#4512) (#4657) (#4675)
* Configuration parameter 'cookie-encryption-password' takes only a single character rather than a string (#4512)
* Simplify cookie-password-encryption conversion and improve the unit test
cookie-encryption-password configuration parameter take only a single character, it should take a string.
Environment Details
Problem Description
cookie-encryption-password configuration parameter take only a single character, it should take a string.
Configuration - security.providers.oidc.cookie-encryption-password: “masterpassword”
Stack trace
Steps to reproduce
The text was updated successfully, but these errors were encountered: