[jcifs] Manifest missing OSGi configuration

Brevard Swart bswart at magnet.ie
Thu Sep 9 10:08:29 MDT 2010


Hi,

We are not sure you're aware of this but the latest version of Java mail library (1.4.3) supports NTLM authentication through your jcifs 1.3.12+ library.
You will run into problems while running mail enabled web applications on OSGi web containers (e.g. Glassfish v3) even having jcifs package on the application classpath.
The reason is because of your Maven generated META-INF/MANIFEST.MF doesn't have any useful OSGi information in it.

The fix we used was as follows:

1.         A. You need to modify and replace the manifest (META-INF\Manifest.mf) of jcifs-1.3.14.jar with:

Manifest-Version: 1.0
Bundle-Version: 1.3.14
Bundle-Name: jcifs
Bundle-ManifestVersion: 2
Bundle-SymbolicName: jcifs
Export-Package: jcifs, jcifs.dcerpc, jcifs.dcerpc.msrpc, jcifs.dcerpc.ndr, jcifs.http, jcifs.https, jcifs.netbios, jcifs.ntlmssp, jcifs.smb, jcifs.util, jcifs.util.transport

B. Another option to consider would be to use a maven-osgi-plugin or maven-bundle-plugin to make MANIFEST.MF OSGi-compliant.

2.         And you need to copy the jcifs-1.3.14.jar to {Glassfish_Home}\glassfishv3\glassfish\modules (it is also missing from modules because it is considered optional...).


Regards,

Brevard Swart
& Pawel Pietrzak
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.samba.org/pipermail/jcifs/attachments/20100909/83d88e4d/attachment.html>


More information about the jCIFS mailing list