openHAB (a smart home platform) uses the Smack library in several bindings. After upgrading to version 4.4.0 or later, we ran into issues loading the library in Karaf.
smack-core
depends onsun.security.pkcs11
. This is a Sun‑specific package that is not supported by all JREs, which limits the range of compatible runtimes. It is generally best practice not to usesun.*
packages directly. In addition, OSGi environments like Karaf do not export these packages, which prevents Smack from being used there. Typically, Bouncy Castle is used as an alternative for PKCS#11 functionality.smack-core
depends onhsluv
0.2, whose manifest is missing OSGi headers. We have already opened an issue in their repository (hsluv/hsluv#93) but also wanted to make you aware. If possible, it might make sense to drop or replace this dependency.