04d6095d065869f5b40d5977d56d78e779126605
[freeside.git] / httemplate / misc / process / nms-add_iface.html
1 <% header('Interface added') %>
2 </BODY></HTML>
3 <%init>
4
5 # XXX: access rights
6
7 my $host = $cgi->param('host'); 
8 die 'invalid host' unless $host =~ /^[0-9.a-zA-Z\-]+$/;
9
10 my $iface = $cgi->param('iface');
11 die 'invalid iface' unless $iface =~ /^[0-9A-Za-z_\-.\\\/ ]+$/;
12
13 my $serviceid = $cgi->param('serviceid');
14 die 'invalid serviceid' unless $serviceid =~ /^[0-9A-Za-z_\-.\\\/ ]+$/;
15   
16 my $nms = new FS::NetworkMonitoringSystem;
17 $nms->add_interface($host,$iface,$serviceid);
18
19 </%init>