diff options
author | Mark Wells <mark@freeside.biz> | 2014-01-15 12:18:30 -0800 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2014-01-15 12:18:30 -0800 |
commit | b527719318878e876971e02e4ac3bfb892a68dec (patch) | |
tree | af07b99c0b45f473818a12e87814d059fa3e2ca5 /httemplate/edit/process/addr_range.html | |
parent | 748fb30c036addb30e6d401ebc1bb650311284ec (diff) |
fix address ranges for sites with old NetAddr::IP versions, #26868
Diffstat (limited to 'httemplate/edit/process/addr_range.html')
-rw-r--r-- | httemplate/edit/process/addr_range.html | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/httemplate/edit/process/addr_range.html b/httemplate/edit/process/addr_range.html index 6b05d23a5..5df05596e 100644 --- a/httemplate/edit/process/addr_range.html +++ b/httemplate/edit/process/addr_range.html @@ -13,6 +13,11 @@ $cgi->param('end', $end->addr); $cgi->param('start', $start->addr); } + if ( $start + 0x7FFFFFFF <= $end ) { + # then this is going to overflow + return "Address ranges must be < 2^31 - 1 addresses long." + } + $cgi->param('length', $end - $start + 1); } else { $cgi->param('length', 1); |