sleirsgoevy/brutejudge

Google OAuth support

Closed this issue · 3 comments

The repository contains code that is meant to pass Google OAuth without using a browser. However this code no longer works for some reason, and ends up with an "Unsupported browser" page, probably due to the fact that it doesn't execute JavaScript (obviously!).

Possible options to get working OAuth:

  • Use a headless browser (e.g. PhantomJS or selenium under xvfb) to perform the authentication. This option is not preferred because it's highly platform-dependent.
  • Implement a special authentication flow for Google OAuth using a real browser to perform the sign-up (and implement it in the CLI).
  • Try to fix the broken code without involving a browser:
    ** Reverse-engineer JavaScript code involved in the process, and rewrite it in Python. This is going to break as Google may change the code at any time.
    ** Try to perform JS-like AJAX requests without actually executing the code (e.g. by using tokens obtained from the no-JS pass). This may be impossible as there are tokens that cannot be obtained that way.

Added support for PhantomJS-based authentication. However that doesn't seem like a proper solution.

Proper solution is deprecate all backends except JJS and drop them eventually

Google OAuth is now fully supported, with proper browser-based authorization flow. Closing this issue.