Bug#1032093: jameica: missing dependencies

Thomas Uhle thomas.uhle at mailbox.tu-dresden.de
Mon Feb 27 19:58:17 GMT 2023


Package: jameica
Version: 2.10.3+dfsg-1
Severity: important
Tags: fixed-upstream
X-Debbugs-Cc: Jochen Sprickerhoff <jspricke at debian.org>

Dear maintainers,

Jameica dies with the following messages if it is started for the very 
first time, i.e., with an empty user profile directory $HOME/.jameica:

[Mon Feb 27 18:48:06 CET 2023][INFO][main][de.willuhn.jameica.gui.SplashScreen$3.run]  generating new keys and certificates ...
[Mon Feb 27 18:48:06 CET 2023][INFO][main][de.willuhn.jameica.security.SSLFactory.init]   generating rsa keypair
[Mon Feb 27 18:48:09 CET 2023][INFO][main][de.willuhn.jameica.security.SSLFactory.init]   generating selfsigned x.509 certificate
[Mon Feb 27 18:48:09 CET 2023][INFO][main][de.willuhn.jameica.security.SSLFactory.init]   using hostname: localhost
Exception in thread "main" java.lang.NoClassDefFoundError: org/bouncycastle/asn1/cms/CMSObjectIdentifiers
 	at org.bouncycastle.operator.DefaultSignatureNameFinder.<clinit>(Unknown Source)
 	at org.bouncycastle.operator.jcajce.OperatorHelper.<clinit>(Unknown Source)
 	at org.bouncycastle.operator.jcajce.JcaContentSignerBuilder.<init>(Unknown Source)
 	at de.willuhn.jameica.security.SSLFactory.init(SSLFactory.java:291)
 	at de.willuhn.jameica.services.SSLService.init(SSLService.java:45)
 	at de.willuhn.boot.BootLoader.resolve(BootLoader.java:139)
 	at de.willuhn.boot.BootLoader.resolve(BootLoader.java:119)
 	at de.willuhn.boot.BootLoader.resolve(BootLoader.java:119)
 	at de.willuhn.boot.BootLoader.getBootable(BootLoader.java:72)
 	at de.willuhn.jameica.system.Application.init(Application.java:103)
 	at de.willuhn.jameica.system.Application.newInstance(Application.java:87)
 	at de.willuhn.jameica.Main.main(Main.java:78)
Caused by: java.lang.ClassNotFoundException: org.bouncycastle.asn1.cms.CMSObjectIdentifiers
 	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
 	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
 	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
 	... 12 more

The reason is that in BouncyCastle version 1.69 some code was moved from 
bcprov.jar into the new bcutil.jar, and the class path of jameica.jar 
still references only bcprov.jar and bcpkix.jar but not bcutil.jar (please 
cf. https://github.com/willuhn/jameica/issues/42#issuecomment-1418240499). 
This is easily fixed by adding /usr/share/java/bcutil.jar to 
debian/patches/0001-Update-locations-of-Java-libraries.patch.  Maybe it 
makes sense to also add libbcutil-java to Jameica's package dependencies 
in debian/control because of its jar file being explicitly on the class 
path.


Another issue comes from switching default-jre to openjdk-17-jre which has 
been openjdk-11-jre before.  The bundled JavaScript engine has been 
removed in OpenJDK 15 which causes the following warning at the start:

[Mon Feb 27 19:05:01 CET 2023][WARN][main][de.willuhn.jameica.services.ScriptingService.init] java does not support scripting (RhinoScript)

So Jameica's scripting service is no longer usable unless rhino.jar and 
rhino-engine.jar is added to the class path of jameica.jar (please cf. 
https://github.com/willuhn/jameica/issues/43).  Similar to the previous 
fix, you can simply add /usr/share/java/rhino.jar to 
debian/patches/0001-Update-locations-of-Java-libraries.patch and add 
librhino-java to Jameica's package dependencies in debian/control.  It 
might make sense to already add /usr/share/java/rhino-engine.jar to the 
class path as well although Debian's current version of librhino-java 
contains all the code in one single file js-1.7.7.2.jar that rhino.jar 
is linking to.


Best regards,

Thomas Uhle



More information about the pkg-java-maintainers mailing list