|
|
|
@@ -67,12 +67,19 @@ |
|
|
|
"source":"https://projects.lukehaas.me/regexhub" |
|
|
|
}, |
|
|
|
{ |
|
|
|
"name":"Web, URL", |
|
|
|
"name":"Web, URL Simple", |
|
|
|
"regex":"((https?|ftp|file)://)?([\\w\\d.-]+)\\.([a-zA-Z.]{2,6})([-/.a-zA-Z0-9]+)*/?", |
|
|
|
"description":"Match URL with optional protocol, e.g. <code>yahoo.com</code> or <code>https://yahoo.com/finance</code>. (Validation only, may have high false positives.)", |
|
|
|
"tags":"url,address,http", |
|
|
|
"source":"https://projects.lukehaas.me/regexhub" |
|
|
|
}, |
|
|
|
{ |
|
|
|
"name":"Web, URL Extended", |
|
|
|
"regex":"(?:(?:http(?:s)?|ftp)://)(?:\\S+(?::(?:\\S)*)?@)?(?:(?:[a-z0-9\u00a1-\uffff](?:-)*)*(?:[a-z0-9\u00a1-\uffff])+)(?:\\.(?:[a-z0-9\u00a1-\uffff](?:-)*)*(?:[a-z0-9\u00a1-\uffff])+)*(?:\\.(?:[a-z0-9\u00a1-\uffff]){2,})(?::(?:\\d){2,5})?(?:/(?:\\S)*)?", |
|
|
|
"description":"More complicated URL validation that handles URLs such as <code>http://www.example.com/wpstyle/?p=364</code>, <code>http://foo.com/blah_blah_(wikipedia)_(again)</code>, or even <code>http://userid:password@example.com:8080/</code>.", |
|
|
|
"tags":"url,address,http", |
|
|
|
"source":"http://rpubs.com/jimhester/rex-url_parsing" |
|
|
|
}, |
|
|
|
{ |
|
|
|
"name":"Network, IPv4 Address", |
|
|
|
"regex":"(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)", |