File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ Integrated the Tracker Core (#255)
2727Removed deprecated trackImpression method (#256)
2828Added forceSecureTracker boolean option to the argmap, thanks @kujo4pmZ! (#247)
2929Moved link click tracking into its own file (#266)
30+ Made IP address regex more strict (#267)
3031
3132Version 2.0.2 (2014-10-20)
3233--------------------------
Original file line number Diff line number Diff line change 4242 * Test whether a string is an IP address
4343 */
4444 function isIpAddress ( string ) {
45- var IPRegExp = new RegExp ( '^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$' ) ;
45+ var IPRegExp = new RegExp ( '^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\ .(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\ .(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\ \.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$' ) ;
4646 return IPRegExp . test ( string ) ;
4747 }
4848
9696 hostName = helpers . getHostName ( href ) ;
9797 }
9898 return [ hostName , href , referrer ] ;
99- }
99+ } ;
100100
101101} ( ) ) ;
You can’t perform that action at this time.
0 commit comments