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

Chrome Extension #724

Merged
merged 14 commits into from
Jan 3, 2024
Merged

Chrome Extension #724

merged 14 commits into from
Jan 3, 2024

Conversation

maximized
Copy link
Contributor

No description provided.

@maximized
Copy link
Contributor Author

Dockerfile Outdated Show resolved Hide resolved
@rgossiaux rgossiaux marked this pull request as draft January 2, 2024 00:05
@maximized maximized marked this pull request as ready for review January 2, 2024 05:19
@maximized maximized marked this pull request as draft January 2, 2024 05:20
@maximized maximized removed the request for review from rgossiaux January 2, 2024 05:20
@maximized
Copy link
Contributor Author

Waiting for the prod version to be up so I can test that this works in prod too

@maximized
Copy link
Contributor Author

I need the CSRF_TRUSTED_ORIGINS change in settings.py to be checked in to test it with prod.

@maximized maximized changed the title [WIP] Chrome Extension Chrome Extension Jan 3, 2024
@maximized maximized marked this pull request as ready for review January 3, 2024 06:56
@@ -43,6 +43,9 @@
"cardinality-cardboard.herokuapp.com",
]

# For Cardboard Chrome Extension
CSRF_TRUSTED_ORIGINS = ["chrome-extension://cahmppnjflkbimomgndbcmbdoafdegbi"]
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this guaranteed to be the same for everyone? Or is it different per user?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This just got published in the Chrome extensions store. The one that everyone will download with have a fixed ID. In development, or if you side load the extension, you will have a different ID. Do you have a problem if we wildcard it instead "chrome-extension://*"?

Copy link
Contributor

Choose a reason for hiding this comment

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

Ok got it. I guess as a bandaid we can do the wildcard, it's sort of a security hole but realistically there's not much to attack.

I think the way this "should" work is with token based auth. We could add oauth login to cardboard (link) and then use chrome.identity in the extension to authenticate with cardboard.

I think it's probably not actually that much work to implement this but we can punt on it for now and track it in a separate issue.

chrome_extension/cardboard.zip Outdated Show resolved Hide resolved
chrome_extension/cardboard/manifest.json Show resolved Hide resolved
chrome_extension/cardboard/manifest.json Show resolved Hide resolved
Add published Cardboard Chrome extension ID
All for other local host permissions
@maximized maximized merged commit 8401cbc into main Jan 3, 2024
2 checks passed
@maximized maximized deleted the max_extension branch January 3, 2024 22:47
@rgossiaux rgossiaux mentioned this pull request Jan 4, 2024
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.

2 participants