Skip to content

Commit

Permalink
Merge pull request #169 from DMTF/Regex-Fix
Browse files Browse the repository at this point in the history
Corrected the regex pattern when trying to discover the local system's address when directly hosting firmware images
  • Loading branch information
mraineri authored Sep 27, 2024
2 parents cc4d28d + 06c5619 commit a1a0f3e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/rf_update.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ def print_error_payload(response):
# TODO: Find a better way of getting your own IP address
# socket.gethostbyname( socket.gethostname() ) returns 127.0.0.1 on many systems
# This will open a socket with the target, and pulls the address of the socket
groups = re.search("^(https?)://([^:]+)(:(\d+))?$", args.rhost)
groups = re.search("^(https?)://([^:]+)(:(\\d+))?$", args.rhost)
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
remote_port = groups.group(4)
if remote_port is None:
Expand Down

0 comments on commit a1a0f3e

Please sign in to comment.