[python]regex to find mac address

This is my interface mac address To search for the substring from the lines of string i use the search method. This is the pattern pattern = r"([0-9a-fA-F]{2}:){5}[0-9a-fA-F]{2}" And in order to return the substring only use the group() method. If you print the re.search result without using group method you will get the entire … Continue reading [python]regex to find mac address