From 2a92f0a588fec9c2b461af8a2ebfd7c5812b113e Mon Sep 17 00:00:00 2001 From: luk3yx Date: Fri, 13 May 2022 08:05:16 +1200 Subject: Send unknown command numeric and add more options to proxy --- idc_irc_proxy.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'idc_irc_proxy.py') diff --git a/idc_irc_proxy.py b/idc_irc_proxy.py index 1faa5f2..de5c7ba 100755 --- a/idc_irc_proxy.py +++ b/idc_irc_proxy.py @@ -218,14 +218,16 @@ class Server: def main(): import argparse parser = argparse.ArgumentParser() - parser.add_argument('local_port', type=int) + parser.add_argument('bind_port', type=int) parser.add_argument('username') parser.add_argument('password') parser.add_argument('--debug', '-v', action='store_true') + parser.add_argument('--idc-ip', default='andrewyu.org') + parser.add_argument('--idc-port', type=int, default=6835) args = parser.parse_args() - Server('andrewyu.org', 6835, '', ssl=True, persist=False, - local_addr=('127.0.0.1', args.local_port), debug=args.debug, + Server(args.idc_ip, args.idc_port, '', ssl=True, persist=False, + local_addr=('127.0.0.1', args.bind_port), debug=args.debug, ns_identity=(args.username, args.password)).main() if __name__ == '__main__': -- cgit v1.2.3