Can I use OAuth 2.0 authorization in YouTube to authorize to a specific account without the user being required to enter their account information?

这一生的挚爱 提交于 2019-12-21 21:26:20

问题


I am trying to implement a web service where videos that are uploaded to a server are then also uploaded to a specific YouTube account under my control (i.e. I have the access credentials). Since I have the username and password, it looks like I should just be able to use something like ClientLogin to gain the ability to upload videos to this account. However, this method is deprecated by Google and they recommended to use OAuth 2.0 instead. Given that this is new development I would prefer to use a non-deprecated api. Apparently though every OAuth 2.0 authentication method requires a user to supply the account credentials through a browser redirect to gain authentication. This is a server side program, I do not want user involvement, and the user does not have the account credentials anyway. This should be something Google thought of, so is there any way to do ClientLogin type authentication with OAuth 2.0? I want to be able to authenticate completely using OAuth 2.0 programmatically with no user involvement.

I have found this answer: Migrating from YouTube ClientLogin to OAuth 2.0 Migrating from YouTube ClientLogin to OAuth 2.0

However, authenticating as a device STILL requires account credentials input from a user through a browser, as far as I can tell. This answer is almost a year old by now, and does not fix the problem, so does anyone have any new ideas?

Thank you.


回答1:


In the web services user will need to authorize through the pop up window for the first time. Once he grants access to your app, he doesn't need to anymore.

In mobile devices, it's a pop up bar, they can just pick their already saved account.

As a short answer, there is no work around it, cause this is built to have a better level security.



来源:https://stackoverflow.com/questions/15105942/can-i-use-oauth-2-0-authorization-in-youtube-to-authorize-to-a-specific-account

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!