Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auth feature - fourth iteration #133

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

The-CodeINN
Copy link

@The-CodeINN The-CodeINN commented Dec 21, 2024

Fixes #30

Implement the OAuth flow state object storage in cookies and the signout/disconnect feature.

  • Store the OAuth flow state object in cookies in src/lib/actions/do-auth.js and compare it with the state param in the doAuth function.
  • Retrieve the stored state from cookies in src/pages/api/github/oauth/callback.js, compare it with the state param, and delete the stored state from cookies after comparison.
  • Update the signout/disconnect link in src/components/islands/profile.jsx to point to the new signout route.
  • Update the signout logic in src/pages/logout.astro to use the new signout function from doAuth.

Fixes jargonsdev#30

Implement the OAuth flow state object storage in cookies and the signout/disconnect feature.

* Store the OAuth flow state object in cookies in `src/lib/actions/do-auth.js` and compare it with the `state` param in the `doAuth` function.
* Retrieve the stored state from cookies in `src/pages/api/github/oauth/callback.js`, compare it with the `state` param, and delete the stored state from cookies after comparison.
* Update the signout/disconnect link in `src/components/islands/profile.jsx` to point to the new signout route.
* Update the signout logic in `src/pages/logout.astro` to use the new signout function from `doAuth`.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/jargonsdev/jargons.dev/issues/30?shareId=XXXX-XXXX-XXXX-XXXX).
Copy link

vercel bot commented Dec 21, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
jargons-dev ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 21, 2024 0:01am

@babblebey
Copy link
Member

Hi @The-CodeINN,

Gotta start by saying great stuff with the change here! 😉 But, it's always imperative to ask to work on an issue, wait for it to be assigned to you before working on it, here's why ☝🏾

For the particular related issue #30, there's been some changes in its specification and that hasn't been updated in the description (my bad for that being the case)... This changes in spec occurred due to the introduction of the logout functionality (see 956f8e4) in #111

The logout feature hence shouldn't be in the specification of the "Auth Iteration 4th", if you had asked to work on it first, then we'd have talked about this, before you started work on it 😃

Well, we'd still like you to work on this PR anyway, but you'll have to remove the logout functionality from the change and please write a comment on the issue #30 still, so to enable us assign you to the issue 😉

Happy Contributing 😁

@The-CodeINN
Copy link
Author

Hi @The-CodeINN,

Gotta start by saying great stuff with the change here! 😉 But, it's always imperative to ask to work on an issue, wait for it to be assigned to you before working on it, here's why ☝🏾

For the particular related issue #30, there's been some changes in its specification and that hasn't been updated in the description (my bad for that being the case)... This changes in spec occurred due to the introduction of the logout functionality (see 956f8e4) in #111

The logout feature hence shouldn't be in the specification of the "Auth Iteration 4th", if you had asked to work on it first, then we'd have talked about this, before you started work on it 😃

Well, we'd still like you to work on this PR anyway, but you'll have to remove the logout functionality from the change and please write a comment on the issue #30 still, so to enable us assign you to the issue 😉

Happy Contributing 😁

Noted!
I could close this then, kindly update the specification and assign it

@babblebey babblebey reopened this Dec 21, 2024
@babblebey
Copy link
Member

Please continue with this PR, just remove changes associated to the logout feature 😉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Auth Feature - Fourth Iteration
2 participants