Shopify / Shopify/shopify-app-template-php
Signature verification failed
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 340
- Forks
- 108
- PR merge metrics
- No merged PRs in 30d
Description
Issue summary
I used the CLI, and successfully created an app using npm run dev and ngrok into the local install. However, once I deployed to production I ran into both a "CSRF token mismatch" and "Firebase\JWT\SignatureInvalidException: Signature verification failed" error.
In order to resolve the CSRF issue I removed the middleware, which probably isn't the best solution.
However, I'm stumped on how to resolve the JWT issue.
Expected behavior
After following the official Shopify tutorial and deploying to production, the application should work successfully.
Actual behavior
Production installs result in CSRF and JWT issues.
Steps to reproduce the problem
- Run Shopify CLI and use the PHP template.
- Deploy to production server using
composer installandSHOPIFY_API_KEY=** npm run build - Install the app to a test store using
Test your app > Select store.
Reduced test case
Deploy the Shopify CLI PHP template.
Checklist
- I have described this issue in a way that is actionable (if possible)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the production deployment steps using composer install and SHOPIFY_API_KEY=** npm run build, then inspect app/Http/Kernel.php and the reported CSRF and Firebase JWT errors. Reproduce the CLI template installation against a test store; done means the production app installs and operates without the CSRF token mismatch or signature verification failure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- authentication, backend, security
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100