5
I am developing a python application that will work by the terminal
At a certain point, I need to login:
print('É necessário informar suas credenciais para se comunicar com a API')
email = input('Email: ')
password = input('Senha: ')
The problem is that the output on the console stays that way:
É necessário informar suas credenciais para se comunicar com a API:
Email: [email protected]
Senha: senhaTeste
I need the password field to not show the characters, replace them with "*" or something like that:
The exit I look for in the terminal is something like this:
É necessário informar suas credenciais para se comunicar com a API:
Email: [email protected]
Senha: **********
Great, that already solves my problem, but do you know if there is a possibility instead of being blank with each letter insert a '*'? For those who are using can realize that they are actually typing
– José Henrique Luckmann
Then just implementing something, @Joséhenriqueluckmann. I don’t think it’s a good idea, I’ve never seen a terminal show asterisks while typing a password, and it’s much more work for little result.
– Jéf Bueno
Do not appear
*
on terminals for safety... Knowing the amount of characters a password is much easier to make a Joy force... It’s a design decision– fernandosavio
And +1 for the answer and the question. I didn’t know this module
– fernandosavio