poi 3.2 SecurityException HPSFException signer information does not match signer information of other classes in the same package

SecurityException: class "org.apache.poi.hpsf.HPSFException"'s signer information does not match signer information of other classes in the same package

运行以下代码:

 

try {
    FileInputStream fis 
= new FileInputStream("e:\\test.doc");
    WordExtractor wordExtractor 
= new WordExtractor(fis);
    System.out.println(
"Word文件的内容:");
    System.out.println(wordExtractor.stripFields(wordExtractor.getText()));
catch (FileNotFoundException e) {
    e.printStackTrace();
catch (IOException e) {
    e.printStackTrace();
}

 

报“SecurityException: class "org.apache.poi.hpsf.HPSFException"'s signer information does not match signer information of other classes in the same package”异常。

 

原因:

      WEB-INF/lib目录下有poi-2.5.jar和poi-3.2.jar冲突了。

解决办法:

       删掉poi-2.5.jar,问题搞定。

posted on 2009-03-20 16:43  蓝色随想  阅读(1382)  评论(0编辑  收藏  举报