keeper-sdk-dotnet icon indicating copy to clipboard operation
keeper-sdk-dotnet copied to clipboard

Bug: On Linux, The prompts in Connect-Keeper echo the input if the input is longer than the terminal's width

Open bror-lauritz-sk opened this issue 1 year ago • 2 comments

When using Connect-Keeper in PowerShell on Linux: if your input is longer than the length of the terminal, the line is echoed back per character you enter (see image).

The main problem is when it asks for the SSO Token, which is 576 (?) characters. Pasting it in will cause a lot of echoing, which locks the terminal for a 5-10 seconds while it processes the output.

image

https://github.com/Keeper-Security/keeper-sdk-dotnet/assets/168429125/58f8d727-35b8-433f-91d4-1870b56bf420

Specs

OS: RHEL 7 and Fedora 40 Terminal: Gnome terminal, Kitty, Putty and the terminal in Visual Studio Code Powershell version: 7.3.12 and 7.4.3 PowerCommander: 0.9.10 and 0.9.11

This is not a problem on Windows, as far as I can tell.

bror-lauritz-sk avatar Jun 30 '24 16:06 bror-lauritz-sk

This issue was reported long time. https://github.com/PowerShell/PowerShell/issues/11636

The PowerCommander will use [Console]::ReadLine or PSReadLine module if it is installed.

sk-keeper avatar Jul 01 '24 19:07 sk-keeper

PSReadLine is installed by default in the PowerShell Core version of Powershell.

I'm not sure what you mean that PowerCommander uses PSReadLine to read the input, as PSReadLine doesn't have any functions that mimic "Read-Host". PSReadLine is designed to provide shell-like editing on the CLI, and MS hasn't implemented a way to use it to read input.

Well, it does have one, but it adds everything it reads into the shell history, which doesn't seem very secure.

bror-lauritz-sk avatar Jul 02 '24 07:07 bror-lauritz-sk