RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Advanced Search

Keywords

Category

Minimum Rating

Results per Page

Search Results: 11 regular expressions found.

   Displaying page 1 of 1 pages; Items 1 to 11
Title Test Details Pattern Title
Expression
^([0-9a-fA-F][0-9a-fA-F]:){5}([0-9a-fA-F][0-9a-fA-F])$
Description
This will grep for a valid MAC address , with colons seperating octets. It will ignore strings too short or long, or with invalid characters. It will accept mixed case hexadecimal. Use extended grep.
Matches
01:23:45:67:89:ab | 01:23:45:67:89:AB | fE:dC:bA:98:76:54
Non-Matches
01:23:45:67:89:ab:cd | 01:23:45:67:89:Az | 01:23:45:56:
Author Rating: Not yet rated. Ted Rudyk
Title Test Details Pattern Title
Expression
((\d|([a-f]|[A-F])){2}:){5}(\d|([a-f]|[A-F])){2}
Description
Deisgned to verify a MAC address with hex values seperated by a colon.
Matches
00:00:39:F9:3C:59 | 00:90:83:6A:B3:B7 | 00:00:39:59:30:5C
Non-Matches
00:0H:39:59:30:5C | 00:39:59:30:5C | 00:39:59:30:5C:BZ
Author Rating: Not yet rated. Jason Jenisch
Title Test Details MAC Address Validator
Expression
^(?:(?'1'[0-9a-fA-F]{2})(?:\:)(?'2'[0-9a-fA-F]{2})(?:\:)(?'3'[0-9a-fA-F]{2})(?:\:)(?'4'[0-9a-fA-F]{2})(?:\:)(?'5'[0-9a-fA-F]{2})(?:\:)(?'6'[0-9a-fA-F]{2}))$|^(?:(?'1'[0-9a-fA-F]{2})(?:\-)(?'2'[0-9a-fA-F]{2})(?:\-)(?'3'[0-9a-fA-F]{2})(?:\-)(?'4'[0-9a-fA-F]{2})(?:\-)(?'5'[0-9a-fA-F]{2})(?:\-)(?'6'[0-9a-fA-F]{2}))$
Description
<b>MAC Address Validator</b><br><br>Works with ":" linux style separator or "-" windows style separator and groups each octet to the corresponding group.<br>Quite extensive, but functional.<br><br>Any suggestions, feel free to comment.<br><br>
Matches
00-00-00-00-00-00
Non-Matches
00-00-00-00-00-GG
Author Rating: The rating for this expression. Fernando Nunes
Title Test Details MAC Address Catcher
Expression
(?:(?'1'[0-9a-fA-F]{2})(?:\:)(?'2'[0-9a-fA-F]{2})(?:\:)(?'3'[0-9a-fA-F]{2})(?:\:)(?'4'[0-9a-fA-F]{2})(?:\:)(?'5'[0-9a-fA-F]{2})(?:\:)(?'6'[0-9a-fA-F]{2}))|(?:(?'1'[0-9a-fA-F]{2})(?:\-)(?'2'[0-9a-fA-F]{2})(?:\-)(?'3'[0-9a-fA-F]{2})(?:\-)(?'4'[0-9a-fA-F]{2})(?:\-)(?'5'[0-9a-fA-F]{2})(?:\-)(?'6'[0-9a-fA-F]{2}))
Description
<b>MAC Address Catcher</b><br><br>Catches MAC Addresses on any string.<br>Works with ":" linux style separator or "-" windows style separator and groups each octet to the corresponding group.<br>Quite extensive, but functional.<br><br>Any suggestions, feel free to comment.<br><br>
Matches
I Can Eat Glass 00-11-22-33-44-55 I Can Eat Glass 00-11-22-33-44-55
Non-Matches
I Can Eat Glass 00-11-22-33-44-55-66 (7th octet will be ignored)
Author Rating: Not yet rated. Fernando Nunes
Title Test Details IP Tables
Expression
^(?<Date>.+\s\d+\s\d+\:\d+\:\d+).+\:.+\:(?<Traffic>.+)\:(?<Rule>.+)\:IN\=(?<InboundInterface>.+)\sOUT\=(?<OutboundIntercace>.*?)\s(?:MAC\=(?<MacAddress>.+)\s|)SRC\=(?<Source>.+)\sDST\=(?<Destination>.+)\sLEN\=.+TOS\=.+PROTO\=(?<Protocol>.+)\sSPT\=(?<SourcePort>.+)\sDPT\=(?<DestinationPort>.+)\s.+$
Description
The goal of my regular expression is to allow me to break apart IP Table log files so that I can build a basic web front-end to allow me to view the traffic on the network. The MAC address is optional, because the way that this firewall works, is by providing the MAC address when the outbound address is not available.
Matches
Jul 20 13:05:08 123.123.123.123 kernel: Shorewall:loc2net:REJECT:IN=eth0 OUT=eth1 SRC=444.333.222.111 DST=111.222.333.444 LEN=59 TOS=0x00 PREC=0x00 TTL=127 ID=12267 PROTO=UDP SPT=2121 DPT=53 LEN=39
Non-Matches
Anything Else
Author Rating: The rating for this expression. Sean McIlvenna
Title Test Details Pattern Title
Expression
^(((\d|([a-f]|[A-F])){2}:){5}(\d|([a-f]|[A-F])){2})$|^(((\d|([a-f]|[A-F])){2}-){5}(\d|([a-f]|[A-F])){2})$|^$
Description
Designed to verify a MAC address with no spaces allowed, hex values separated by linux style separator ":" or by windows style separator "-". Also empty string entry is allowed.
Matches
A0:B1:C2:D3:E4:F5|A0-B1-C2-D3-E4-F5|
Non-Matches
A0-B1-C2-D3-E4:F5|A0 - B1 - C2 - D3 - E4 - F5|A0:B1:C2:D3:E4:G5
Author Rating: Not yet rated. Yavuz Oztemel
Title Test Details Cisco dotted MAC notation
Expression
^([0-9a-f]{4}\.[0-9a-f]{4}\.[0-9a-f]{4})$
Description
Matches against dumps of Cisco MAC address tables on newer versions of Cisco IOS.
Matches
001e.1324.683f|1234.abcd.1234|ffff.ffff.ffff
Non-Matches
001E.1324.683f|001234.abcd.abcd|abcd.1234.abcd.1234|aa-bb-cc-dd-ee-ff|11:22:33:44:55:66
Author Rating: The rating for this expression. Brian Jack
Title Test Details MAC address
Expression
^([0-9A-F]{2}[:-]){5}([0-9A-F]{2})$
Description
This regular expression will validate against a valid MAC address. The 6 bytes are hexadecimal and separated by semi colon or dash caracters.
Matches
01:23:45:67:89:AB
Non-Matches
01:23:45:67:89:X9
Author Rating: The rating for this expression. Jeff Hervouet
Title Test Details Unit Address (digital Mac Address)
Expression
^(000-)(\\d{5}-){2}\\d{3}$
Description
When working w/ Moto STB, we need to sometimes use the unit address instead of the mac address. The format is always 000-12345-12345-123
Matches
000-00386-67627-142
Non-Matches
00-12345-12345-142, 001-12345-12345-123, 000-12345-12345-12
Author Rating: The rating for this expression. Kari
Title Test Details MAC Address
Expression
^(([\da-fA-F]{2}[-:]){5}[\da-fA-F]{2})$
Description
Easiest way to describe a MAC Address.
Matches
00-25-86-DC-FD-3B | 00:25:86:DC:FD:3B | 00-25-86-dc-fd-3b | 00:25:86:dc:fd:3b
Non-Matches
00 25 86 dc fd 3b | 002586dcfd3b | 00.25.86.dc.fd.3b
Author Rating: Not yet rated. Flx
Title Test Details MAC address matcher
Expression
^([\da-fA-f]{2}[:-]){5}[\da-fA-f]{2}$
Description
Matches mixed case, colon or hypen hexadecimal notation. Discards string too short or long, or with invalid characters. Needs extended grep.
Matches
98-CE-d0-a2-0a-68 | 98:cE:d0:a2:0a:68
Non-Matches
98-cE-d0-a2-0a | 98-cE-d0-a2-0a-68-f0
Author Rating: Not yet rated. manolo dantonio
   Displaying page 1 of 1 pages; Items 1 to 11

Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials