Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Subsequent installs giving JWT error

I have developed basic jira application with npm connect framework. I host is on heroku with postgresql. First installation is fine. Subsequent installs seems fine until I try to open my pages then it is giving me this error:

 Authentication verification error (400): Unable to decode JWT token: Error: Signature verification failed for input: eyJ0.... with method sha256 

 If I empty DB it works fine. This error is happening when there are duplicate entries in DB with this Query:

SELECT "id", "clientKey", "key", "val" FROM "AddonSettings" AS "AddonSetting"

|5 |9b8b3c4d-f33b-3f03-8cab-8d9562498a61 |clientInfo |{"key":"AO-apppp","clientKey":"9b8b3c4d-f33b-3f03-8cab-8....","oauthClientId":"eyJob3N0S2V....|
|6 |9b8b3c4d-f33b-3f03-8cab-8d9562498a61 |clientInfo |{"key":"AO-apppp","clientKey":"9b8b3c4d-f33b-3f03-8cab-8d...","oauthClientId":"eyJob3N0S2V...|

 If I delete this it works fine but if try to install again new entries come. I store data on DB so I cant reset it.

1 answer

1 accepted

1 vote
Answer accepted
Dario B Atlassian Team Nov 27, 2020

Hello @Odin Son ,

Welcome to the Atlassian Community!

If I understand correctly you are trying to report a bug you have found when you reinstall the connect app you have built. 

I have searched a bit around and I can see someone else already reported the same issue in our developers service desk:

I am not sure why this issue has been logged as improvement instead of bug. I am going to check with DEV if it can be moved to bug.

In the meanwhile you can set your self as a watcher so that you will be notified in case of any update and you can add a comment to the issue if you want to add more details or ask any question.

 

Finally, for the future, please notice that this is not the best place to get help on development  related questions.

The right resources are listed in https://developer.atlassian.com/resources. 

Specifically:

 

Cheers,
Dario

Multiple entries in the DB is causing this issue. I resolved the problem for now by adding these endpoints to the index.js

app.get('/installed', function (req, res) {        res.send(200)    });        

app.post('/installed', function (req, res) {         res.send(200)    });
Like Dario B likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS
Community showcase
Posted in Jira Software

Presenting the "Best of 2020" Jira Software roundup!

Catch up with Atlassian Product Managers in our 2020 Demo Den round-up! From Advanced Roadmaps to Code in Jira to Next-Gen Workflows, check out the videos below to help up-level your work in the new ...

7,138 views 8 28
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you