title: JWT signature does not match locally computed signature
body: <p>I am using </p>
  
  <pre><code>JwtBuilder builder = Jwts.builder()
                      .setId(user.getEmail())
                      .signWith(signatureAlgorithm, signingKey);
  </code></pre>
  
  <p>to create a token then</p>
  
  <pre><code>Jwts.parser().setSigningKey(secret).parse(token);
  </code></pre>
  
  <p>to authenticate.  When I run this in a JUnit test, it works fine.  However, when I authenticate token passed as a header over REST call, authentication fails with SignatureException.  I have verified the token on both ends of the HTTP call and the token string is identical.  Code to create/authenticate is static, therefore, the secret is same on each side. </p>