Hello,

> -----Ursprüngliche Nachricht-----
> Von: Kenaw, Seretseab <seretseab.ke...@ecolab.com.INVALID>
> Gesendet: Montag, 27. Juni 2022 15:01
> An: users@tomcat.apache.org
> Betreff: Root Module Deployment Error
> 
> Hello,
> 
> We just upgraded from Tomcat 9.0.12 to 9.0.62, and after the upgrade the
> new Tomcat version is throwing an error while deploying the ROOT module.
> All the ROOT module has is a redirection to a specific page when the user
> tries to access the website. Here is the error message, any help is
> appreciated.
> SEVERE: Error deploying deployment descriptor [E:\EBX1\EBX
> Server\conf\Catalina\localhost\ROOT.xml]
> java.lang.IllegalStateException: Error starting child
>               at
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
> :729)
>               at
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:698)
>               at
> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:696)
>               at
> org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:69
> 0)
>               at
> org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.jav
> a:1889)
>               at
> java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.ja
> va:515)
>               at 
> java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
>               at
> org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecuto
> rService.java:75)
>               at
> java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExec
> utorService.java:118)
>               at
> org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:5
> 83)
>               at
> org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:473)
>               at 
> org.apache.catalina.startup.HostConfig.start(HostConfig.java:1618)
>               at
> org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:319)
>               at
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:1
> 23)
>               at
> org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:423
> )
>               at
> org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:366)
>               at
> org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:946
> )
>               at
> org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:835)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               at
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1
> 396)
>               at
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1
> 386)
>               at 
> java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
>               at
> org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecuto
> rService.java:75)
>               at
> java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExec
> utorService.java:140)
>               at
> org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:919
> )
>               at
> org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:2
> 63)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               at
> org.apache.catalina.core.StandardService.startInternal(StandardService.java:
> 432)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               at
> org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:9
> 27)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               at org.apache.catalina.startup.Catalina.start(Catalina.java:772)
>               at
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>               at
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMet
> hodAccessorImpl.java:62)
>               at
> java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Delega
> tingMethodAccessorImpl.java:43)
>               at java.base/java.lang.reflect.Method.invoke(Method.java:566)
>               at 
> org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:345)
>               at 
> org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:476)
> Caused by: org.apache.catalina.LifecycleException: Failed to start component
> [OpenIDConnectAuthenticator[StandardEngine[Catalina].StandardHost[local
> host].StandardContext[]]]
>               at
> org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBas
> e.java:440)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198)
>               at
> org.apache.catalina.core.StandardPipeline.startInternal(StandardPipeline.jav
> a:176)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               at
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.jav
> a:5147)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               at
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
> :726)
>               ... 37 more
> Caused by: java.lang.IllegalStateException: Impossible modulus [1]
>               at
> org.apache.tomcat.util.codec.binary.Base64.decode(Base64.java:682)
>               at
> org.apache.tomcat.util.codec.binary.BaseNCodec.decode(BaseNCodec.java:
> 362)
>               at
> org.apache.tomcat.util.codec.binary.Base64.decodeBase64(Base64.java:157)
>               at
> org.apache.tomcat.util.codec.binary.Base64.decodeBase64(Base64.java:152)
>               at
> org.apache.tomcat.util.codec.binary.Base64.decodeInteger(Base64.java:189)
>               at
> org.bsworks.catalina.authenticator.oidc.JWKSet.<init>(JWKSet.java:58)
>               at
> org.bsworks.catalina.authenticator.oidc.OPConfiguration$1.parseDocument(
> OPConfiguration.java:63)
>               at
> org.bsworks.catalina.authenticator.oidc.OPConfiguration$1.parseDocument(
> OPConfiguration.java:1)
>               at
> org.bsworks.catalina.authenticator.oidc.ConfigProvider.loadDocument(Confi
> gProvider.java:146)
>               at
> org.bsworks.catalina.authenticator.oidc.ConfigProvider.get(ConfigProvider.j
> ava:106)
>               at
> org.bsworks.catalina.authenticator.oidc.OPConfiguration.<init>(OPConfigura
> tion.java:66)
>               at
> org.bsworks.catalina.authenticator.oidc.OPConfigurationsProvider$1.parseD
> ocument(OPConfigurationsProvider.java:40)
>               at
> org.bsworks.catalina.authenticator.oidc.OPConfigurationsProvider$1.parseD
> ocument(OPConfigurationsProvider.java:1)
>               at
> org.bsworks.catalina.authenticator.oidc.ConfigProvider.loadDocument(Confi
> gProvider.java:146)
>               at
> org.bsworks.catalina.authenticator.oidc.ConfigProvider.get(ConfigProvider.j
> ava:106)
>               at
> org.bsworks.catalina.authenticator.oidc.OPConfigurationsProvider.getOPCon
> figuration(OPConfigurationsProvider.java:72)
>               at
> org.bsworks.catalina.authenticator.oidc.BaseOpenIDConnectAuthenticator.s
> tartInternal(BaseOpenIDConnectAuthenticator.java:765)
>               at 
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
>               ... 42 more
> 
> Thank you
> Seretseab Kenaw
> 


according to the sources the modulus 1 is not supported and was not supported: 
https://github.com/apache/tomcat/blob/9.0.x/java/org/apache/tomcat/util/codec/binary/Base64.java
 
Apache commons library can use the modulus of one.

Did you use the tomcat.util package before or did you use another 
package/library for decoding the byte[] Array?
How does the Byte array look like which you feed into decodeInteger(....) ?

The relevant part of the stacktrace is:
> org.apache.tomcat.util.codec.binary.Base64.decodeInteger(Base64.java:189)
>               at
> org.bsworks.catalina.authenticator.oidc.JWKSet.<init>(JWKSet.java:58)

Greetings,
Thomas

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to