Skip to content
This repository has been archived by the owner on Nov 30, 2022. It is now read-only.

feature/cookieless #847

Merged
merged 94 commits into from Jun 25, 2021
Merged

feature/cookieless #847

merged 94 commits into from Jun 25, 2021

Conversation

gnikyt
Copy link
Owner

@gnikyt gnikyt commented Jun 24, 2021

  • Removes dependency on cookies
  • Enables JWT as first-class
  • Several internal adjustments for auth flow
  • Support for XHR, jQuery, Axios, TurboLinks and others for session tokens
  • Includes recent updates from master such as helpers moved Utils, CI and analysis improvements, and more

Many months of work from various contributors! PR is ready to be reviewed and merged if all is well.

gnikyt added 30 commits April 7, 2021 13:42
* Combining AuthShopify, AuthToken into new VerifyShopify middleware
* SessionToken value object created to verify and validate all aspects of the JWT
* New unauthenticated route and view added
* VerifyShopify: Cleaned up methods to be smaller and clearer
* VerifyShopify: Handle cases for no token, no hmac
* VerifyShopify: Adjusted to not rely on ShopSession service anymore.
* Moved AuthorizeShop to InstallShop
* Condensed InstallShop and modified to return an array
* Modified InstallShop to track access token update time
* Modified Shop command to track access token update time
* Removed authenticate.oauth route
* Removed oauthfailure method on authenticate controller
* Removed ShopSession class
* Updated shopify-config to reference new authenticate routes (install, token)
* Updated shopify-config to remove old authenticate routes
* Updated ShopModel's getToken to getAccessToken for naming conflict purposes
* Removed old ITP and authenticate routes from built-in route provider
@gnikyt gnikyt self-assigned this Jun 25, 2021
@gnikyt gnikyt linked an issue Jun 25, 2021 that may be closed by this pull request
* Ignore `factory()` in tests
* Ignore `tokenRoute` static method in src as it is dynamic macro
* Ignore `tokenRedirect` static method in src as it is dynamic macro
@gnikyt
Copy link
Owner Author

gnikyt commented Jun 25, 2021

@lucasmichot I am fine with all the changes currently.

  • Things seem to be in a working state
  • Items can of course be refactored down the road if need-be, unless it's something urgent
  • Tests are passing
  • I've left one comment about query string generation

Only thing missing from this branch is the "per-user" auth abilities... I think this can be a minor release to add the feature after this big release is out.

@lucasmichot
Copy link
Collaborator

@lucasmichot I am fine with all the changes currently.

  • Things seem to be in a working state
  • Items can of course be refactored down the road if need-be, unless it's something urgent
  • Tests are passing
  • I've left one comment about query string generation

Only thing missing from this branch is the "per-user" auth abilities... I think this can be a minor release to add the feature after this big release is out.

Hey @osiset, yes I would totally merge this and create a new major release, as lots of BC have been introduced.

Also I very agree with you on adding "per-user" auth ability later

Plenty of things can also be added/improved later - but at least the new release would have a fresh new codebase to work on 👍

Copy link
Collaborator

@lucasmichot lucasmichot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A comment added on URL generation, other than that GTM 🚀

Co-authored-by: Lucas Michot <lucas@semalead.com>
@gnikyt
Copy link
Owner Author

gnikyt commented Jun 25, 2021

A comment added on URL generation, other than that GTM

Solid. Yeah good suggestion. Going for the merge!

@gnikyt gnikyt merged commit 4efa931 into master Jun 25, 2021
@gnikyt gnikyt deleted the feature/cookieless branch June 25, 2021 14:21
@squatto
Copy link
Contributor

squatto commented Jun 30, 2021

@osiset On the v17.0.0 release in the "Internal" section you mention ShopContext - should that be SessionContext?

@gnikyt
Copy link
Owner Author

gnikyt commented Jun 30, 2021

@osiset On the v17.0.0 release in the "Internal" section you mention ShopContext - should that be SessionContext?

Your correct, will update :)

@squatto
Copy link
Contributor

squatto commented Jun 30, 2021

OK great, thank you! I just wanted to make sure I wasn't missing something I wasn't aware of 😬

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature Enhancement to the code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Auth Flow Refactoring
5 participants