mirror of
https://github.com/tailscale/tailscale.git
synced 2025-04-16 03:31:39 +00:00
util/winutil/s4u: fix some doc comments in the s4u package
This is #cleanup Signed-off-by: Aaron Klotz <aaron@tailscale.com>
This commit is contained in:
parent
c4b20c5411
commit
e181f12a7b
@ -119,7 +119,7 @@ const (
|
|||||||
// Login logs user u into Windows on behalf of service srcName, loads the user's
|
// Login logs user u into Windows on behalf of service srcName, loads the user's
|
||||||
// profile, and returns a Session that may be used for impersonating that user,
|
// profile, and returns a Session that may be used for impersonating that user,
|
||||||
// or optionally creating processes as that user. Logs will be written to logf,
|
// or optionally creating processes as that user. Logs will be written to logf,
|
||||||
// if provided. srcName must be non-empty, ASCII-only, and no longer than 8
|
// if provided. srcName must be non-empty, ASCII-only, and no longer than 8
|
||||||
// characters.
|
// characters.
|
||||||
//
|
//
|
||||||
// The current OS thread's access token must have SeTcbPrivilege.
|
// The current OS thread's access token must have SeTcbPrivilege.
|
||||||
@ -281,10 +281,11 @@ type startProcessOpts struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// StartProcess creates a new process running under ss via cmdLineInfo.
|
// StartProcess creates a new process running under ss via cmdLineInfo.
|
||||||
// The process will be started with its working directory set to the S4U user's
|
// The process will either be started with its working directory set to the S4U
|
||||||
// profile directory and its environment set to the S4U user's environment.
|
// user's profile directory, or for Administrative users, the system32
|
||||||
// extraEnv, when specified, contains any additional environment variables to
|
// directory. The child process will receive the S4U user's environment.
|
||||||
// be added to the process's environment.
|
// extraEnv, when specified, contains any additional environment
|
||||||
|
// variables to be inserted into the environment.
|
||||||
//
|
//
|
||||||
// If called after ss has already been closed, StartProcess will panic.
|
// If called after ss has already been closed, StartProcess will panic.
|
||||||
func (ss *Session) StartProcess(cmdLineInfo winutil.CommandLineInfo, extraEnv map[string]string) (psp *Process, err error) {
|
func (ss *Session) StartProcess(cmdLineInfo winutil.CommandLineInfo, extraEnv map[string]string) (psp *Process, err error) {
|
||||||
@ -302,10 +303,11 @@ func (ss *Session) StartProcess(cmdLineInfo winutil.CommandLineInfo, extraEnv ma
|
|||||||
// StartProcessWithPTY creates a new process running under ss via cmdLineInfo
|
// StartProcessWithPTY creates a new process running under ss via cmdLineInfo
|
||||||
// with a pseudoconsole initialized to initialPtySize. The resulting Process
|
// with a pseudoconsole initialized to initialPtySize. The resulting Process
|
||||||
// will return non-nil values from Stdin and Stdout, but Stderr will return nil.
|
// will return non-nil values from Stdin and Stdout, but Stderr will return nil.
|
||||||
// The process will be started with its working directory set to the S4U user's
|
// The process will either be started with its working directory set to the S4U
|
||||||
// profile directory and its environment set to the S4U user's environment.
|
// user's profile directory, or for Administrative users, the system32
|
||||||
// extraEnv, when specified, contains any additional environment variables to
|
// directory. The child process will receive the S4U user's environment.
|
||||||
// be added to the process's environment.
|
// extraEnv, when specified, contains any additional environment
|
||||||
|
// variables to be inserted into the environment.
|
||||||
//
|
//
|
||||||
// If called after ss has already been closed, StartProcessWithPTY will panic.
|
// If called after ss has already been closed, StartProcessWithPTY will panic.
|
||||||
func (ss *Session) StartProcessWithPTY(cmdLineInfo winutil.CommandLineInfo, extraEnv map[string]string, initialPtySize windows.Coord) (psp *Process, err error) {
|
func (ss *Session) StartProcessWithPTY(cmdLineInfo winutil.CommandLineInfo, extraEnv map[string]string, initialPtySize windows.Coord) (psp *Process, err error) {
|
||||||
@ -324,10 +326,11 @@ func (ss *Session) StartProcessWithPTY(cmdLineInfo winutil.CommandLineInfo, extr
|
|||||||
// StartProcessWithPipes creates a new process running under ss via cmdLineInfo
|
// StartProcessWithPipes creates a new process running under ss via cmdLineInfo
|
||||||
// with all standard handles set to pipes. The resulting Process will return
|
// with all standard handles set to pipes. The resulting Process will return
|
||||||
// non-nil values from Stdin, Stdout, and Stderr.
|
// non-nil values from Stdin, Stdout, and Stderr.
|
||||||
// The process will be started with its working directory set to the S4U user's
|
// The process will either be started with its working directory set to the S4U
|
||||||
// profile directory and its environment set to the S4U user's environment.
|
// user's profile directory, or for Administrative users, the system32
|
||||||
// extraEnv, when specified, contains any additional environment variables to
|
// directory. The child process will receive the S4U user's environment.
|
||||||
// be added to the process's environment.
|
// extraEnv, when specified, contains any additional environment
|
||||||
|
// variables to be inserted into the environment.
|
||||||
//
|
//
|
||||||
// If called after ss has already been closed, StartProcessWithPipes will panic.
|
// If called after ss has already been closed, StartProcessWithPipes will panic.
|
||||||
func (ss *Session) StartProcessWithPipes(cmdLineInfo winutil.CommandLineInfo, extraEnv map[string]string) (psp *Process, err error) {
|
func (ss *Session) StartProcessWithPipes(cmdLineInfo winutil.CommandLineInfo, extraEnv map[string]string) (psp *Process, err error) {
|
||||||
|
@ -647,7 +647,8 @@ func LogonSessionID(token windows.Token) (logonSessionID windows.LUID, err error
|
|||||||
return origin.originatingLogonSession, nil
|
return origin.originatingLogonSession, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// BufUnit is a type constraint for buffers passed into AllocateContiguousBuffer.
|
// BufUnit is a type constraint for buffers passed into AllocateContiguousBuffer
|
||||||
|
// and SetNTString.
|
||||||
type BufUnit interface {
|
type BufUnit interface {
|
||||||
byte | uint16
|
byte | uint16
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user