Another way is with the Read-Host commandlet. If you ask it to return a `SecureString`, it will show a password field (as a modal dialog in Sitecore Powershell). You then have to convert the so-called secure string back into a normal string to validate credentials:

    $username = [Sitecore.Context]::User.Name
    $securePassword = Read-Host -Prompt 'Please enter your password' -AsSecureString
    $bstr = [System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($securePassword)
    $password = [System.Runtime.InteropServices.Marshal]::PtrToStringAuto($bstr)
    $isValid = [System.Web.Security.Membership]::ValidateUser($username, $password)

One issue with this method is you can't control the dialog's title. But it's a quick fix.