输入密码时是否有golang函数来填充特殊字符?

I would like to know if there is a way in Go to populate a password output with special characters when you are typing the password.

For example, I want to type the word "password" in the password field when it prompts me for the password. I want the output on the screen to look like this:

Enter Password: ********

Where the "********" are the characters of "password". Does GOLANG have something that will allow me to do this?

Take a look at this.

I know, it might not answer your question. But, this is an alternative to the answer. Instead of using ********* to mask the password, actually it will use the standard "blank" password masking on the terminal.

Here is the screenshot of the program when executed: Screenshot of running program

You can see at the Enter Password: part, that it is blank instead of asterisks ********* or other symbols.