Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AutoAllowPermissionChecker ¶ added in v0.22.0
type AutoAllowPermissionChecker struct{}
AutoAllowPermissionChecker always allows operations (for --accept mode or testing).
func (*AutoAllowPermissionChecker) CheckPermission ¶ added in v0.22.0
func (a *AutoAllowPermissionChecker) CheckPermission(op sftp.Operation, client sftp.ClientInfo, paths ...string) (sftp.PermissionResult, error)
CheckPermission always returns PermissionAllowed.
func (*AutoAllowPermissionChecker) ClearSession ¶ added in v0.22.0
func (a *AutoAllowPermissionChecker) ClearSession(sessionID string)
ClearSession is a no-op since AutoAllowPermissionChecker doesn't track sessions.
type DialogPermissionChecker ¶ added in v0.22.0
type DialogPermissionChecker struct {
// contains filtered or unexported fields
}
DialogPermissionChecker shows GUI dialogs for permission prompts.
func (*DialogPermissionChecker) CheckPermission ¶ added in v0.22.0
func (d *DialogPermissionChecker) CheckPermission(op sftp.Operation, client sftp.ClientInfo, paths ...string) (sftp.PermissionResult, error)
CheckPermission shows a dialog for the operation. For two-path operations (rename, symlink, link), both source and target paths are passed.
func (*DialogPermissionChecker) ClearSession ¶ added in v0.22.0
func (d *DialogPermissionChecker) ClearSession(sessionID string)
ClearSession removes cached permissions for the given session.
type SilentError ¶ added in v0.22.0
type SilentError struct {
Err error
}
SilentError wraps an error that has already been displayed to the user. main.go checks for this type to avoid duplicate logging.
func (SilentError) Error ¶ added in v0.22.0
func (e SilentError) Error() string
func (SilentError) Unwrap ¶ added in v0.22.0
func (e SilentError) Unwrap() error
type UserDiscardedError ¶ added in v0.15.0
type UserDiscardedError struct{}
UserDiscardedError represents a user's intentional choice to discard the session
func (UserDiscardedError) Error ¶ added in v0.15.0
func (e UserDiscardedError) Error() string
type UserInterruptedError ¶ added in v0.15.0
type UserInterruptedError struct{}
UserInterruptedError represents a user's Ctrl+C interruption
func (UserInterruptedError) Error ¶ added in v0.15.0
func (e UserInterruptedError) Error() string