jcifs Jar包下载地址https://www.jcifs.org/
在使用中报错
jcifs.smb.SmbException: NTLMv2 requires extendedsecurity (jcifs.smb.client.useExtendedSecurity must be
true ifjcifs.smb.lmCompatibility >=3
为了确保兼容性设置COMPATIBILITY生效我们需要下载源码并修改jcifs.smb.NtlmPasswordAuthentication,将44行LM_COMPATIBILITY变量去掉final声明。eclispe下会自动生成编译的class类。我们用winrar打开原jar包,拖入替换该类。
当使用jcifsJar包时遇到NTLMv2兼容性问题,需要修改源码以允许使用高级安全性。通过取消jcifs.smb.NtlmPasswordAuthentication中LM_COMPATIBILITY变量的final声明,然后在Eclipse环境下重新编译并替换原jar包中的类文件,可以解决此错误。
378

被折叠的 条评论
为什么被折叠?



