According to this post this error message may be caused by using an old version of rclone. Try installing the latest version if you haven't already done that.
Also you shouldn't post your client ID and secret. You should revoke them and re-create them.
I am using rclone 1.60, I still got the same error but I fixed it. You need to add rclone's Redirect URL to the Authorized redirect URIs section of the OAuth 2.0 Client ID that you created for rclone (in the Google API console).
First create your own client ID as described on the rclone website. Make sure it has a secret - click 'Reset Secret' if it doesn't. Remember to save after creating the secret.
Then you need to get the redirect URL:
Start rclone config and proceed through the wizard, giving it the client ID and the secret when it asks for it.
Continue with rclone config until it gets to the auto config part of the wizard (Use auto config?). Answer 'n' to this question.
In its output rclone gives you a command to execute that looks like this: clone authorize "drive" "XXXX". Execute that command in another terminal session.
The rclone authorize command will cause the Google Accounts page to be opened, which gets the error message Error 400: redirect_uri_mismatch
In the rclone output is this text: Make sure your Redirect URL is set to "http://127.0.0.1:53682/"
Now you need to add the redirect URL to the Client ID's Authorized redirect URIs.
Click on 'Credentials' in the left part of the screen.
Click on Client ID in the section 'OAuth 2.0 Client IDs'.
Put the Redirect URL in the section 'Authorized redirect URIs' and click 'Save'.
Complete the authorization process:
Go back to the rclone authorize session - in its output there will be a line that starts with 'If your browser doesn't open automatically...'. Follow the link in that line. The web page that opens will say 'Success!'.
The rclone authorize session will have produced a token. Copy that token and paste it into the rclone config session (which is waiting for a token).
Complete the wizard. The remote should be setup and working now.
发布评论
评论(1)
根据此帖子此错误消息可能是通过使用旧版本的Rclone引起的。如果您尚未完成此操作,请尝试安装最新版本。
另外,您不应该发布客户ID和秘密。您应该撤销它们并重新创建它们。
我正在使用Rclone 1.60,但我仍然有相同的错误,但我将其修复了。您需要将Rclone的重定向URL添加到您为Rclone创建的OAuth 2.0客户端ID的授权重定向URIS部分(在Google API控制台中)。
首先创建自己的客户端ID,如 rclone网站。确保它具有秘密 - 如果没有,请单击“重置秘密”。创建秘密后,请记住要保存。
然后,您需要获取重定向的URL:
rclone config
并通过向导进行,在要求它时将其赋予客户端ID和秘密。rclone config
,直到它到达向导的自动配置部分(使用auto config?
)。回答这个问题的“ n”。克隆授权“驱动器”“ xxxx”
。在另一个终端会话中执行该命令。rclone授权
命令将导致打开Google帐户页面,其中获取错误消息错误400:redirect_uri_mismatch
确保确保您的重定向URL设置为“ http://127.0.0.1:53682/”
现在,您需要将重定向URL添加到客户端ID的授权重定向URI中。
完成授权过程:
rclone授权
session-在其输出中,将有一条线以“如果您的浏览器不自动打开...”。按照该行中的链接。打开的网页将说“成功!”。RCLONE授权
会话将产生令牌。复制令牌并将其粘贴到rclone config
session(正在等待令牌)中。According to this post this error message may be caused by using an old version of rclone. Try installing the latest version if you haven't already done that.
Also you shouldn't post your client ID and secret. You should revoke them and re-create them.
I am using rclone 1.60, I still got the same error but I fixed it. You need to add rclone's Redirect URL to the Authorized redirect URIs section of the OAuth 2.0 Client ID that you created for rclone (in the Google API console).
First create your own client ID as described on the rclone website. Make sure it has a secret - click 'Reset Secret' if it doesn't. Remember to save after creating the secret.
Then you need to get the redirect URL:
rclone config
and proceed through the wizard, giving it the client ID and the secret when it asks for it.rclone config
until it gets to the auto config part of the wizard (Use auto config?
). Answer 'n' to this question.clone authorize "drive" "XXXX"
. Execute that command in another terminal session.rclone authorize
command will cause the Google Accounts page to be opened, which gets the error messageError 400: redirect_uri_mismatch
Make sure your Redirect URL is set to "http://127.0.0.1:53682/"
Now you need to add the redirect URL to the Client ID's Authorized redirect URIs.
Complete the authorization process:
rclone authorize
session - in its output there will be a line that starts with 'If your browser doesn't open automatically...'. Follow the link in that line. The web page that opens will say 'Success!'.rclone authorize
session will have produced a token. Copy that token and paste it into therclone config
session (which is waiting for a token).