Information about subscribers does not match

I get the following error in the log file.

(java.lang.SecurityException: class "com.adventnet.snmp.snmp2.SecurityModelTable" subscriber information does not match the subscriber information of other classes in the same packaged package

The fact is that I am running under the command, he says that the jar check is confirmed.

/usr/jdk/instances/jdk1.5.0/bin/jarsigner -verify -verbose Jarfile.jar 

If the jar file is checked, then how can this problem occur?

+16
java
Jan 16 2018-12-12T00:
source share
7 answers

This means that you have two or more classes in the same package with different signature data. This usually means that classes come from different JARs, one of which is signed and the other unsigned.

+16
Jan 16 2018-12-12T00: 00Z
source share

check pom dependency tree for the same packages of different versions .

I had this problem with itext-2.1.7 , including the old bouncycastle bcpkix , which was later included version in another place.

Use this pattern :

 <dependency> package X <exclusions> <exclusion> old package Y </exclusion> </exclusions> </dependency> <dependency> latest package Y </dependency> 

Update. To check the details of the package_Y dependency tree, you can use mvn dependency:tree -Dverbose -Dincludes=package_Y . For more information, check the maven documentation for resolving dependency tree problems. In addition, Eclipse has a pretty good view of the dependency tree.

+17
Mar 22 '13 at 10:27
source share

I encountered this exception when starting a Scala / Spark project in Eclipse (Mars) on Windows, and this prevented me from debugging and running the project in the IDE. The project used the Maven pom.xml file. It took some time to solve the problem, so I am posting the detailed steps here to help others:

  • Go to the folder where the pom.xml project file is located
  • Run the command: mvn dependency: tree -Dverbose> Depends.Txt Make sure you do not have a Depends.Txt file or it will be overwritten!
  • Search the Depends.Txt file for the unsigned class that the Eclipse IDE complains about. In my case, it was javax.servlet.
  • You can find it in the section that looks like this:

    + - org.apache.hadoop: hasoop-mapreduce-client-core: jar: 2.6.0: provided

    + - javax.servlet: servlet-api: jar: 2.5: provided

  • The identifier of the Maven group from which you want to exclude the duplicate class from the above: hasoop-mapreduce-client-core

  • Add an exception section that lists the exception group in pom.xml after the shell. In my case, it was groupid javax.servlet.

  • Please note that you cannot solve this problem by changing the build order of Java, as some of them posted a similar problem.

+1
Nov 20 '15 at 22:18
source share

java.lang.SecurityException: Subscriber information for class "org.bouncycastle.asn1.ASN1ObjectIdentifier" does not match subscriber information for other classes in one package

Ans: I also had the same exception when I tried to protect the PDF password.

I added below cans to solve the same.

Xtitextpdf-5.2.1.jar ◾bcmail-jdk16-1.46.jar ◾bcprov-jdk16-1.46.jar ◾bctsp-jdk16-1.46.jar

0
Dec 14 '16 at 9:25
source share

In my program, I downloaded two versions of the same packages. One is boprov-jdk15-140.jar , the other is bcprov-jdk15-151.jar . The two are in conflict.

In the MANIFEST.MF JIF package file, it has the following digest:

 Name: org/bouncycastle/crypto/digests/SM3Digest.class SHA1-Digest: xxxxxxxx 

Two JAR files have different SHA1-Digest information.

0
May 12 '17 at 6:06 a.m. a.m.
source share

In my case, I had:

 Caused by: java.lang.SecurityException: class "org.bouncycastle.util.Strings" signer information does not match signer information of other classes in the same package 

It was a project with a lot of dependencies and an mvn dependency: the tree information didn't really help me.

This is how I solved my problem:

  • I did a search for "Find in Files" using notepad ++ on all M2_REPO
  • I found a project that redefined the "Strings" class in a package that exactly matches "org.bouncycastle.util.Strings", which should come from the dependency "org.bouncycastle: bcprov-jdk15on".
  • After discovering, I moved all these problematic classes to a new package and updated this version of the project.
  • Finally, I updated the project motive, which caused me problems to use my dependency, which uses the new package name.

The problem is resolved.

0
04 Dec '17 at 20:41
source share

I ran into this problem in a Spring boot application. My problem was that I had Junit in the build path, which has Org.hamcrest.Matchers in it. * And Hamcrest, which was in the Spring Framework library in my pom.xml in the eclipse repository. So I removed Junit from my build path. Included Junit only in my pom.xml. Therefore, my application depended on Maven for Junit and * Matchers. So somehow you have two banks for one need. Maybe as a library and as a configuration file.

0
Jul 23 '19 at 20:06 on
source share



All Articles