Documentation
¶
Index ¶
- Variables
- func AskForPassword(tty *os.File, ttyNum int, settings DialogSettings) (*memguard.LockedBuffer, int, error)
- func AskToConfirm(tty *os.File, ttyNum int, settings DialogSettings) (bool, error)
- func LockTTY(tty *os.File)
- func ReadPassword(tty *os.File, output []byte, echoChar string) ([]byte, error)
- func ShowMessage(tty *os.File, ttyNum int, settings DialogSettings) error
- func UnlockTTY(tty *os.File)
- func WritePrompt(tty *os.File, settings DialogSettings) error
- type DialogSettings
- type ExeContext
Constants ¶
This section is empty.
Variables ¶
View Source
var FirstTty = -1
Functions ¶
func AskForPassword ¶
func AskForPassword(tty *os.File, ttyNum int, settings DialogSettings) (*memguard.LockedBuffer, int, error)
AskForPassword does everything needed to get a password from user through specified TTY.
Returned values are: Pointer to password buffer, length of password, error if any.
func AskToConfirm ¶
func ReadPassword ¶
ReadPassword configures TTY to non-canonical mode and reads password byte-by-byte showing '*' for each character.
func ShowMessage ¶
func ShowMessage(tty *os.File, ttyNum int, settings DialogSettings) error
func WritePrompt ¶
func WritePrompt(tty *os.File, settings DialogSettings) error
Types ¶
type DialogSettings ¶
type ExeContext ¶
type ExeContext struct { User string Group string ParentPID string ParentPath string StartupTime time.Time }
func CaptureExeCtx ¶
func CaptureExeCtx() (*ExeContext, error)
func (ExeContext) String ¶
func (ctx ExeContext) String() string
Click to show internal directories.
Click to hide internal directories.