Maven dependencies for jjwt (json web token) on a spring boot project

9.3k Views Asked by At

Which maven dependency in my pom.xml should I add to resolve these errors: -SignatureException cannot be resolved to a type -ExpiredJwtException cannot be resolved to a type -UnsupportedJwtException cannot be resolved to a type

1

There are 1 best solutions below

2
alia On BEST ANSWER

I have resolved this issue by adding these dependencies on my pom.xml:

<dependency>
            <groupId>io.jsonwebtoken</groupId>
            <artifactId>jjwt-api</artifactId>
            <version>0.11.5</version>
        </dependency>
        <dependency>
            <groupId>io.jsonwebtoken</groupId>
            <artifactId>jjwt-impl</artifactId>
            <version>0.11.5</version>
        </dependency>
        <dependency>
            <groupId>io.jsonwebtoken</groupId>
            <artifactId>jjwt-jackson</artifactId>
            <version>0.11.5</version>
      </dependency>