Authentication for Videoview in android

前端 未结 3 1664
说谎
说谎 2021-01-06 11:37

I\'m using a Videoview to play http video.That Http video url needs Authentication.

So please let me know how authentication can be

3条回答
  •  [愿得一人]
    2021-01-06 12:19

    First you should know what kind of authentication is required by this server: http://unixpapa.com/auth/index.html

    Second, depending of auth type, you should provide auth parameters (username/password) inside the URL. Usually this will be accepted (but not necessatilly, you should test): http://username:password@www.yourhostname.com/whatever

    This are basic, http-style authentications. Modern sites use other options such as OpenID and OAuth. This are a bit harder to implement.

    Anyhow, you should know type type of authentication, before you start looking for solution.

提交回复
热议问题