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

Feature request: use OAuth 2.0 for Devices in -headless mode #109

Closed
0x1eaf opened this issue Jan 13, 2015 · 2 comments
Closed

Feature request: use OAuth 2.0 for Devices in -headless mode #109

0x1eaf opened this issue Jan 13, 2015 · 2 comments

Comments

@0x1eaf
Copy link

0x1eaf commented Jan 13, 2015

There is a painless way to authenticate in headless mode:
https://developers.google.com/accounts/docs/OAuth2ForDevices

@w-flo
Copy link

w-flo commented Apr 21, 2015

Dirty workaround that worked for me:

  • Backup /usr/bin/xdg-open
  • Create new /usr/bin/xdg-open file, and make sure to mark it executable. Contents:
#!/bin/sh
echo $1 1>&2
exit 0

(Not sure if exit 0 is required, I guess not. Just make sure not to echo anything to STDOUT, that apparently makes google-drive-ocamlfuse think that something failed and exit instead of polling for access grant.)

  • Run google-drive-ocamlfuse, which should print the URL and you can use your favourite web access method to go to that URL and grant access, then follow the usual docs. Don't forget to put the original xdg-open script back in place.

@astrada
Copy link
Owner

astrada commented Nov 20, 2016

Unfortunately, it looks like OAuth 2.0 for TV and Limited Input Device Applications doesn't support Google Drive: https://developers.google.com/identity/protocols/OAuth2ForDevices#allowedscopes

@astrada astrada closed this as completed Nov 20, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants