File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -63,15 +63,15 @@ def parse_service_accept(self, m):
63
63
64
64
65
65
def validate_remote_host (remote_host ):
66
- if re .match (r"^[\w. ]+(:[0-9]+ )?$" , remote_host ):
66
+ if re .match (r"^[^\: ]+(:[0-9]{5} )?$" , remote_host ):
67
67
return remote_host
68
68
raise argparse .ArgumentTypeError ('remot host must be in format hostname:port' )
69
69
70
70
71
71
def validate_honeypot (remote_host ):
72
- if re .match (r"^[\S ]+:[\S ]+@[\w.]+(: [0-9]+ )?$" , remote_host ):
72
+ if re .match (r"^[^\: ]+:[^@ ]+@[^\:]+:( [0-9]{5} )?$" , remote_host ):
73
73
return remote_host
74
- raise argparse .ArgumentTypeError ('honeypot address must be in format username_password @hostname:port' )
74
+ raise argparse .ArgumentTypeError ('honeypot address must be in format username:password @hostname:port' )
75
75
76
76
77
77
class Authenticator (BaseModule ):
You can’t perform that action at this time.
0 commit comments