I have a node.js app that needs to extract a MAC address from a string.
var str = "bridge=vmbr1,virtio=32:65:63:62:36:35";
The problem lies in the fact that the string is dynamic - it is not always in that format. It could also appear as...
var str = "bridge=vmbr1,virtio=32:65:63:62:36:35,firewall=1";
...among many other variations. For that reason, using something like split or substring won't work. I assume I might need to use some regex to extract just the 32:65:63:62:36:35
part from the string.
Any help is appreciated.