2017-06-21 66 views
1

我有一個SSRS報表服務器的基本身份驗證,以避免從Web服務器擊中SSRS報表服務器時登錄彈出窗口。我在url本身發送憑據。這是谷歌鉻58,但現在它更新爲鉻59.現在我無法在瀏覽器URL中發送憑據。在URL中不支持發送url中的憑據chrome 59

https://gooduser:[email protected]

用戶名:gooduser 密碼:secredpassword

在此請您幫助!

+1

顯然不再支持。 https://www.chromestatus.com/feature/5669008342777856 – niktrs

+0

簡而言之:谷歌破壞了它,似乎並不想解決它。可能以「改善安全性」或類似的藉口爲藉口。有沒有可以遊說的地方來消除這種精神錯亂? – Ray

回答

0

我用chrome擴展解決了同樣的問題。

在擴展background.js

chrome.extension.onMessage.addListener( function(request, sender, sendResponse){ 
    chrome.webRequest.onAuthRequired.addListener(
     function(details, callbackFn) { 
      console.log("onAuthRequired!", details, callbackFn); 
      callbackFn({ 
       authCredentials: {username: request.username, password: request.password } 
      }); 
     }, 
     {urls: request.url + "/*"]}, 
     ['asyncBlocking'] 
    ); 
}); 

在擴展contentscript.js

window.addEventListener("message", function(event) { 
    if (event.type == "BASIC_AUTH") { 
    chrome.runtime.sendMessage( 
      event.data, 
      event.data.sender, 
      function (response) {}  
     ); 
    } 
}); 

在HTML的JavaScript

window.postMessage({ type: "BASIC_AUTH", url:"www.mydomain.com", username:"myusername", password:"mypassword" }, "*"); 

如果你喜歡從Chrome網上應用店使用的擴展名如:MultiPass for HTTP basic authentication