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

Add MIME Type Detection and OAuth2 Token Refresh with Updated Authorization Flow #257

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

vsychov
Copy link

@vsychov vsychov commented Jan 10, 2025

This pull request introduces two key improvements and an essential update to the project:

  1. Automatic MIME Type Detection:

    • Implemented logic to automatically determine the MIME type of files based on their extensions.
    • Ensures that file previews in Google Drive work correctly by associating the appropriate MIME type.
  2. OAuth2 Token Refresh:

    • Added functionality to refresh OAuth2 tokens automatically.
    • Ensures continuous authentication without requiring manual intervention by persisting updated tokens to a file.
  3. Updated OAuth Redirect URL:

    • Replaced the deprecated urn:ietf:wg:oauth:2.0:oob flow with a "fake" https://localhost redirect URL.
    • This update complies with Google’s deprecation of the OOB flow and allows developers to copy the authorization code for successful authentication.

Key Benefits:

  • Enhanced user experience with accurate MIME type detection for file previews.
  • Improved reliability and usability of OAuth2 authentication with token refresh and updated redirect URL.
  • Compatibility with Google’s latest OAuth2 standards.

Please review the changes and provide feedback. Thank you!

Fix #214

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.

Cannot login - Google no longer supports Out of Band login flow
1 participant