解決密碼過期造成遠端桌面(RDP)無法連線

最近陸續接到同事回報遠端桌面無法連線的問題,錯誤訊息如下;

You must change your password before logging on the first time. For assistance, contact your system administrator or technical support.

經過測試,這是因為帳號密碼過期,Domain policy 強制要求更換密碼導致,畫面如下;

1

但在測試中我們也發現一些異狀; 同一個帳號在Windows 7 的 RDP client 並沒有看到這個錯誤訊息,也不是連線到所有的 Server 都會有這個錯誤。

我們將問題情況整理如下表:

2
Windows 7 的 RDP client 在Windows server 2008 R2 & Windows server 2012 R2 都沒有問題

Windows 8.1 跟 Windows 10 的 RDP client 在 Windows server 2012 R2 上面會出現同樣的錯誤

問題判斷完了,接下來要找解決方式,先找找 google 有沒有類似的問題; 運氣不錯,幾篇文章都指出問題出在 Network Level Authentication (NLA) 跟 Credential Security Support Provider (CredSSP), 但是測試我們的 Server 不管有沒有勾選 NLA 結果還是一樣。

用 NLA 跟 CredSSP 當關鍵字,找到了兩個解法;

第一個解法 (client side) :

Adding “enablecredsspsupport:i:0” to *.rdp file is used to disable “Credential Security Support Provider”(CredSSP) in the RDP client

4

修改 Document 資料夾下面的隱藏檔案 Default.rdp ,以記事本開啟,加入 enablecredsspsupport:i:0

第二種解法 (server side) :

By applying the Require user authentication for remote connections by using Network Level Authentication Group Policy setting.

This Group Policy setting is located in Computer Configuration\Policies\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Session Host\Security

新增 Group policy ,修改 Computer Configuration\Policies\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Session Host\Security\Require user authentication for remote (RDP) connections

將選項設為 Enable ,Security Level 選擇 RDP

5

Apply Group Policy 之後,問題解決!

 

參考文件

Disable credSSP and NLA server side

Configure Network Level Authentication for Remote Desktop Services Connections

RDP Message: You must change your password before logging on the first time. Please update your password or contact …

 

 

廣告

發表迴響

在下方填入你的資料或按右方圖示以社群網站登入:

WordPress.com 標誌

您的留言將使用 WordPress.com 帳號。 登出 /  變更 )

Facebook照片

您的留言將使用 Facebook 帳號。 登出 /  變更 )

連結到 %s

%d 位部落客按了讚: