I set up Google OAuth for my seafile installation. When I’m using it, after logging into Google and being redirected to /oauth/callback, I see the “Error, please contact administrator message.” The logfile says
[ERROR] seahub.oauth.views:136 oauth_callback (insecure_transport) OAuth 2 MUST utilize https.
All the URLs in the settings are https. The seafile sign-on page, the Google OAuth login page and the callback page are all https and yet I see this error. Here is my seahub_settings:
I started getting this error randomly a couple weeks after upgrading from Seafile 12.x to 13.x. For me, the root cause was that I had set SEAFILE_SERVER_PROTOCOL to http, since my reverse proxy (Traefik) is doing TLS termination. Setting this environment variable to https fixed the issue for me, no workaround required.
No clue why the error started appearing without me making any changes. I thought I’d leave my fix here in case anyone encounters this on more recent versions (12+) of Seafile, where the accepted answer no longer applies.