久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

  • <i id='YbuHe'><tr id='YbuHe'><dt id='YbuHe'><q id='YbuHe'><span id='YbuHe'><b id='YbuHe'><form id='YbuHe'><ins id='YbuHe'></ins><ul id='YbuHe'></ul><sub id='YbuHe'></sub></form><legend id='YbuHe'></legend><bdo id='YbuHe'><pre id='YbuHe'><center id='YbuHe'></center></pre></bdo></b><th id='YbuHe'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='YbuHe'><tfoot id='YbuHe'></tfoot><dl id='YbuHe'><fieldset id='YbuHe'></fieldset></dl></div>

    • <bdo id='YbuHe'></bdo><ul id='YbuHe'></ul>

    <small id='YbuHe'></small><noframes id='YbuHe'>

    <tfoot id='YbuHe'></tfoot>
  • <legend id='YbuHe'><style id='YbuHe'><dir id='YbuHe'><q id='YbuHe'></q></dir></style></legend>

        .NET Google api 1.7 beta 使用刷新令牌進(jìn)行身份驗(yàn)證

        .NET Google api 1.7 beta authenticating with refresh token(.NET Google api 1.7 beta 使用刷新令牌進(jìn)行身份驗(yàn)證)
          1. <small id='bo9FN'></small><noframes id='bo9FN'>

              <bdo id='bo9FN'></bdo><ul id='bo9FN'></ul>
              <legend id='bo9FN'><style id='bo9FN'><dir id='bo9FN'><q id='bo9FN'></q></dir></style></legend>

              <tfoot id='bo9FN'></tfoot>

                  <i id='bo9FN'><tr id='bo9FN'><dt id='bo9FN'><q id='bo9FN'><span id='bo9FN'><b id='bo9FN'><form id='bo9FN'><ins id='bo9FN'></ins><ul id='bo9FN'></ul><sub id='bo9FN'></sub></form><legend id='bo9FN'></legend><bdo id='bo9FN'><pre id='bo9FN'><center id='bo9FN'></center></pre></bdo></b><th id='bo9FN'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='bo9FN'><tfoot id='bo9FN'></tfoot><dl id='bo9FN'><fieldset id='bo9FN'></fieldset></dl></div>
                    <tbody id='bo9FN'></tbody>
                  本文介紹了.NET Google api 1.7 beta 使用刷新令牌進(jìn)行身份驗(yàn)證的處理方法,對(duì)大家解決問(wèn)題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧!

                  問(wèn)題描述

                  我一直在查看 Oauth .Net Google API,以便通過(guò) OAuth 進(jìn)行身份驗(yàn)證并使用 Google drive API.

                  I've been looking at the Oauth .Net Google Apis in order to authenticate via OAuth and use the Google drive Apis.

                  具體來(lái)說(shuō),我想使用我已經(jīng)存儲(chǔ)的刷新令牌來(lái)實(shí)例化 GoogleDrive 服務(wù).

                  Specifically, I want to use a refresh token I already have stored in order to use it to instantiate a GoogleDrive service.

                  我找到了類似的樣本https:///code.google.com/p/google-api-dotnet-client/source/browse/Tasks.SimpleOAuth2/Program.cs?repo=samples

                  這似乎使用GoogleWebAuthorizationBroker.AuthorizeAsync",但我不確定如何使用刷新令牌而不是您在本示例中提供的客戶端機(jī)密來(lái)使用該方法.

                  That seem to use "GoogleWebAuthorizationBroker.AuthorizeAsync" but I'm not sure how I can use that method with a refresh token rather than the client secrets you seem to be feeding it in this example.

                  推薦答案

                  如果我理解正確,您是在問(wèn)如何根據(jù)現(xiàn)有的刷新令牌創(chuàng)建新的 Google 服務(wù).

                  If I understand you correctly, you are asking how can you create a new Google service, based on an existing refresh token.

                  因此,您可以執(zhí)行以下操作:

                  So, you can do the following:

                  var token = new TokenResponse { RefreshToken = "YOUR_REFRESH_TOKEN_HERE" }; 
                  var credentials = new UserCredential(new GoogleAuthorizationCodeFlow(
                      new GoogleAuthorizationCodeFlow.Initializer 
                      {
                        ClientSecrets = [your_client_secrets_here]
                      }), "user", token);
                  

                  然后您可以將您的憑據(jù)傳遞給服務(wù)的初始化程序.

                  Then you can pass your credentials to the service's initializer.

                  通過(guò)執(zhí)行上述操作,GoogleAuthorizationCodeFlow 將根據(jù)您刷新令牌和客戶端機(jī)密獲取新的訪問(wèn)令牌.

                  By doing the above, GoogleAuthorizationCodeFlow will get a new access token based on you refresh token and client secrets.

                  請(qǐng)注意,您必須在此處擁有客戶端密碼,否則您將無(wú)法獲得訪問(wèn)令牌.

                  Note that you must have client secrets here, without that, you won't be able to get an access token.

                  這篇關(guān)于.NET Google api 1.7 beta 使用刷新令牌進(jìn)行身份驗(yàn)證的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來(lái)源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問(wèn)題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Ignore whitespace while reading XML(讀取 XML 時(shí)忽略空格)
                  XML to LINQ with Checking Null Elements(帶有檢查空元素的 XML 到 LINQ)
                  Reading XML with unclosed tags in C#(在 C# 中讀取帶有未閉合標(biāo)簽的 XML)
                  Parsing tables, cells with Html agility in C#(在 C# 中使用 Html 敏捷性解析表格、單元格)
                  delete element from xml using LINQ(使用 LINQ 從 xml 中刪除元素)
                  Parse malformed XML(解析格式錯(cuò)誤的 XML)
                  <i id='ZoRhx'><tr id='ZoRhx'><dt id='ZoRhx'><q id='ZoRhx'><span id='ZoRhx'><b id='ZoRhx'><form id='ZoRhx'><ins id='ZoRhx'></ins><ul id='ZoRhx'></ul><sub id='ZoRhx'></sub></form><legend id='ZoRhx'></legend><bdo id='ZoRhx'><pre id='ZoRhx'><center id='ZoRhx'></center></pre></bdo></b><th id='ZoRhx'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='ZoRhx'><tfoot id='ZoRhx'></tfoot><dl id='ZoRhx'><fieldset id='ZoRhx'></fieldset></dl></div>
                • <legend id='ZoRhx'><style id='ZoRhx'><dir id='ZoRhx'><q id='ZoRhx'></q></dir></style></legend>

                    <small id='ZoRhx'></small><noframes id='ZoRhx'>

                          <bdo id='ZoRhx'></bdo><ul id='ZoRhx'></ul>
                              <tbody id='ZoRhx'></tbody>
                          • <tfoot id='ZoRhx'></tfoot>
                            主站蜘蛛池模板: 亚洲一区二区三区在线 | 日韩一区二区三区精品 | 国产一级片免费观看 | 91精品国自产在线观看 | 中文字幕第一区 | 日韩精品一区在线观看 | 欧美久久久久久久久久 | 亚洲高清视频在线观看 | 超碰在线99 | www国产在线观看 | 国产精品一二三区 | a级片网址| 进去里视频在线观看 | 成年免费视频黄网站在线观看 | 天天曰天天干 | 国产丝袜视频 | 黑人操亚洲人 | 久久久久久国产精品 | 久久av片 | 一区二区在线免费观看 | 亚洲激情文学 | 国产成人影视 | 欧美黄色片视频 | 欧美一级精品 | 亚洲最新网址 | 99视频网| 日韩少妇| 欧美日韩在线精品 | av日韩在线播放 | 国产一区精品在线观看 | 久草福利资源站 | 国产精品成人国产乱 | 国产精品av一区二区 | 亚洲三级在线播放 | 美日韩丰满少妇在线观看 | 国产高清一区二区三区 | 成人精品一区二区三区 | 午夜在线影院 | 欧美片网站免费 | 欧美日韩在线一区二区 | 三级黄色片 |