class
Crowbar::Rules::FTPRule
- Crowbar::Rules::FTPRule
- Crowbar::Rule
- Reference
- Object
Overview
Structure-preserving rule for RFC 959 FTP command and response streams. Maintains strict CRLF line framing while mutating command arguments (e.g. PORT octets, RETR paths, credentials) or response status codes and messages.
Defined in:
crowbar/rules/ftp.crConstant Summary
-
COMMON_COMMANDS =
["USER", "PASS", "ACCT", "CWD", "CDUP", "SMNT", "QUIT", "REIN", "PORT", "PASV", "TYPE", "STRU", "MODE", "RETR", "STOR", "STOU", "APPE", "ALLO", "REST", "RNFR", "RNTO", "ABOR", "DELE", "RMD", "MKD", "PWD", "LIST", "NLST", "SITE", "SYST", "STAT", "HELP", "NOOP", "FEAT", "SIZE", "EPSV", "EPRT", "AUTH", "PBSZ", "PROT"] -
RESPONSE_CODES =
["125", "150", "200", "211", "215", "220", "221", "226", "227", "230", "331", "332", "350", "421", "425", "426", "450", "451", "500", "501", "502", "503", "504", "530", "550", "552", "553", "999", "000"]
Constructors
Instance Method Summary
-
#apply(context : Context, buffer : Buffer) : Bool
Applies a structure-preserving transformation to the buffer
- #description : String
-
#match?(buffer : Buffer) : Bool
Checks whether the buffer matches the format handled by this rule
- #mutate_responses=(mutate_responses : Bool)
- #mutate_responses? : Bool
- #mutate_verbs=(mutate_verbs : Bool)
- #mutate_verbs? : Bool
- #name : String
Instance methods inherited from class Crowbar::Rule
apply(context : Context, buffer : Buffer) : Bool
apply,
description : String
description,
match?(buffer : Buffer) : Bool
match?,
name : String
name,
targets(*targets : Symbol)
targets,
weight : Float64
weight,
weight=(weight : Float64)
weight=
Constructor methods inherited from class Crowbar::Rule
new(weight : Float64 = 1.0)
new
Constructor Detail
Instance Method Detail
Description copied from class Crowbar::Rule
Applies a structure-preserving transformation to the buffer
Description copied from class Crowbar::Rule
Checks whether the buffer matches the format handled by this rule