ftp

package
v0.0.153 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 20, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AuthenticateUser

func AuthenticateUser(ctx context.Context, target, username, password string, timeoutMs int) (bool, string, error)

AuthenticateUser attempts a single FTP authentication and returns success, message, error. Used by the spray module for credential spraying.

func ConnectAndLogin added in v0.0.150

func ConnectAndLogin(ctx context.Context, target, username, password string, timeoutMs int) (*goftp.ServerConn, error)

ConnectAndLogin establishes an FTP connection and authenticates with the provided credentials. Returns a connected and authenticated ServerConn, or an error.

func PerformDownloadWithContext added in v0.0.150

func PerformDownloadWithContext(ctx context.Context, target, username, password string, config *ftpfern.PentestFtpConfig) (*ftpfern.DownloadResult, error)

PerformDownloadWithContext downloads files from an FTP server and returns their content as base64.

func PerformListWithContext added in v0.0.150

func PerformListWithContext(ctx context.Context, target, username, password string, config *ftpfern.PentestFtpConfig) (*ftpfern.ListResult, error)

PerformListWithContext enumerates files and directories on an FTP server.

func PerformUploadWithContext added in v0.0.150

func PerformUploadWithContext(ctx context.Context, target, username, password string, config *ftpfern.PentestFtpConfig) (*ftpfern.UploadResult, error)

PerformUploadWithContext uploads files to an FTP server from in-memory content.

func PerformWriteTestWithContext added in v0.0.150

func PerformWriteTestWithContext(ctx context.Context, target, username, password string, config *ftpfern.PentestFtpConfig) (*ftpfern.WriteTestResult, error)

PerformWriteTestWithContext tests write/delete/rename permissions on FTP directories.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL