pkg/flags - Unified CLI Framework
The flags package provides standardized command-line flag parsing that mirrors Impacket's interface.
Types
Options
Functions
Parse
Registers all standard flags, parses os.Args, and returns the populated Options.
Methods
Options.ApplyToSession
Copies parsed CLI flags into a Target and Credentials struct.
Handles -hashes, -k, -dc-ip, -dc-host, -target-ip, -port, -6, -aesKey, -keytab, and -no-pass.
Options.Command
Returns remaining positional arguments joined as a single string (useful for remote execution tools).
Adding Custom Flags
Use Go's flag package alongside flags.Parse():
Customizing Help Text