summaryrefslogtreecommitdiffstats
path: root/ldap-site-mngmt/webinterface/dhcp
diff options
context:
space:
mode:
Diffstat (limited to 'ldap-site-mngmt/webinterface/dhcp')
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/delete_confirm.php37
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp.dwt78
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp.php27
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_footer.inc.php18
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_header.inc.php21
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_menu.php199
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_start.dwt27
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt257
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice.php164
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice_add.php70
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice_change.php202
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice_delete.php37
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.dwt207
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.php126
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_add.php71
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_change.php292
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_delete.php34
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.dwt37
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.php65
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/menu.dwt29
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.dwt151
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.php79
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.dwt149
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.php84
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/no_dhcp.dwt25
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/no_dhcp.php27
26 files changed, 2513 insertions, 0 deletions
diff --git a/ldap-site-mngmt/webinterface/dhcp/delete_confirm.php b/ldap-site-mngmt/webinterface/dhcp/delete_confirm.php
new file mode 100644
index 00000000..62225afc
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/delete_confirm.php
@@ -0,0 +1,37 @@
+<?php
+include('../standard_header.inc.php');
+
+$dn = $_POST['dn'];
+$name = $_POST['name'];
+$delurl = $_POST['delurl'];
+$backurl = $_POST['backurl'];
+$successurl = $_POST['successurl'];
+
+echo "
+<html>
+<head>
+ <title>AU Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+ <tr>
+ <td>
+ Wollen Sie das Objekt <b>".$name."</b> wirklich l&ouml;schen?<br><br>
+ <form action='".$delurl."' method='post'>
+ Falls ja:<br><br>
+ <input type='hidden' name='dn' value='".$dn."'>
+ <input type='hidden' name='name' value='".$name."'>
+ <input type='hidden' name='successurl' value='".$successurl."'>
+ <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'><br><br>
+ </form>
+ <form action='".$backurl."' method='post'>
+ Falls, nein:<br><br>
+ <input type='Submit' name='apply' value='zur&uuml;ck' class='small_loginform_button'>
+ </form>
+ </td>
+ </tr>
+</table>
+</body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcp.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcp.dwt
new file mode 100644
index 00000000..4aadeba5
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcp.dwt
@@ -0,0 +1,78 @@
+<html>
+
+<head>
+ <title>{SEITENTITEL}</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'></head>
+<body>
+
+<table cellpadding='0' cellspacing='0' border='0' width='95%' height='8%'>
+ <tr>
+ <td width='35%'>
+ <table cellpadding='5' cellspacing='0' border='0' width='100%'>
+ <tr valign='top'>
+ <td width='1'></td>
+ <td><h2>Rechner und IP Management</h2></td>
+ </tr>
+ </table>
+ </td>
+
+ <td width='40%'>
+ <table cellpadding='5' cellspacing='0' border='0' width='100%'>
+ <tr valign='top' align='left'>
+ <td>
+ <h4><a href='../start.php' class='headerlink'>Startseite</a>
+ &nbsp;>>&nbsp; <a href='../au/au.php' class='headerlink'>{AU}</a> &nbsp;[ {DOMAIN} ]</h4>
+ </td>
+ </tr>
+ </table>
+ </td>
+ <td width='25%'>
+ <table cellpadding='5' cellspacing='0' border='0' width='100%' align='right'>
+ <tr valign='top' align='right'>
+ <td>
+ {LOGIN}
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellpadding='5' cellspacing='0' border='0' width='95%' height='7%'>
+<tr>
+ <td>{MAINMENU}</td>
+</tr>
+</table>
+
+<hr align='center' width='98%' noshade>
+
+
+
+<table cellpadding='5' cellspacing='0' border='0' width='100%' height='85%'>
+
+ <tr valign='top' height='100%'>
+ <td width='28%'>
+ <table cellpadding='5' cellspacing='0' border='0' width='100%'>
+ <tr><td>
+
+ {NAVIGATION}
+
+ </td></tr>
+ </table>
+ </td>
+
+ <td width='72%'>
+ <table cellpadding='5' cellspacing='0' border='0' width='100%'>
+ <tr><td>
+
+ {HAUPTFENSTER}
+
+ </td></tr>
+ </table>
+ </td>
+
+ </tr>
+</table>
+
+</body>
+
+</html>
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcp.php b/ldap-site-mngmt/webinterface/dhcp/dhcp.php
new file mode 100644
index 00000000..d757ba3b
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcp.php
@@ -0,0 +1,27 @@
+<?php
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 0;
+$sbmnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "dhcp_start.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcp_footer.inc.php b/ldap-site-mngmt/webinterface/dhcp/dhcp_footer.inc.php
new file mode 100644
index 00000000..311721c5
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcp_footer.inc.php
@@ -0,0 +1,18 @@
+<?php
+
+$template->assign(array("PFAD" => $START_PATH));
+
+# Daten in die Vorlage parsen
+$template->parse("LOGIN", "Login");
+$template->parse("MAINMENU", "Mmenu");
+$template->parse("NAVIGATION", "Menu");
+$template->parse("HAUPTFENSTER", "Webseite");
+$template->parse("PAGE", "Vorlage");
+
+# Fertige Seite an den Browser senden
+$template->FastPrint("PAGE");
+
+# Abmelden vom LDAP
+ldap_unbind($ds);
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcp_header.inc.php b/ldap-site-mngmt/webinterface/dhcp/dhcp_header.inc.php
new file mode 100644
index 00000000..9eaac019
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcp_header.inc.php
@@ -0,0 +1,21 @@
+<?php
+include("dhcp_menu.php");
+
+$template = new FastTemplate(".");
+
+# dem erstellten Template-Objekt eine Vorlage zuweisen
+$definedTemplates = array("Vorlage" => "dhcp.dwt",
+ "Login" => "../logout_form.inc.dwt",
+ "Mmenu" => "../hauptmenue.dwt",
+ "Menu" => "menu.dwt",
+ "Webseite" => $webseite);
+if (isset($additionalTemplates)) {
+ foreach ($additionalTemplates as $templateKey => $templateFile) {
+ $definedTemplates[$templateKey] = $templateFile;
+ }
+}
+$template->define($definedTemplates);
+
+$template->assign(array("SEITENTITEL" => $titel, "ROLLE" => "mainadmin", "AU" => $au_ou, "DOMAIN" => $assocdom, "USERCN" => $usercn));
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcp_menu.php b/ldap-site-mngmt/webinterface/dhcp/dhcp_menu.php
new file mode 100644
index 00000000..423c53c8
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcp_menu.php
@@ -0,0 +1,199 @@
+<?php
+
+function createDhcpMenu($rollen , $mnr, $auDN, $sbmnr) {
+ global $template;
+ global $START_PATH;
+
+ # falls keine kompletten Netze delegiert, dann keine DHCP Service und Subnet Links
+ if (!( check_if_max_networks() )){
+ $hauptmenu = array(array("link" => "no_dhcp.php",
+ "text" => "&Uuml;bersicht",
+ "zugriff" => "alle"));
+ $submenu = array(array(array()));
+ }else{
+ # DHCP Services (momentan nur für einen DHCP konzipiert)
+ $dhcpservice_array = get_dhcpservices($auDN,array("dn","cn"));
+ if (count($dhcpservice_array) == 0){
+ $dhcpsvlink = "new_dhcpservice.php?mnr=1";
+ }
+ else {
+ $dhcpsvlink = "dhcpservice.php?mnr=1";
+ }
+ $dhcpsubnet_array = get_dhcpsubnets($auDN,array("dn","cn"));
+
+ # Struktur der Registerkartenleiste
+ $hauptmenu = array(array("link" => "dhcp.php",
+ "text" => "&Uuml;bersicht",
+ "zugriff" => "alle"),
+ array("link" => $dhcpsvlink,
+ "text" => "DHCP Service",
+ "zugriff" => array("MainAdmin","DhcpAdmin")),
+ array("link" => "dhcpsubnets.php?mnr=2",
+ "text" => "DHCP Subnets",
+ "zugriff" => array("MainAdmin","DhcpAdmin")));
+
+ # DHCP Subnets
+ $subnets = array();
+ for ($i=0;$i<count($dhcpsubnet_array);$i++){
+ $subnets[] = array("link" => "dhcpsubnet.php?dn=".$dhcpsubnet_array[$i]['dn']."&mnr=2&sbmnr=".$i,
+ "text" => $dhcpsubnet_array[$i]['cn'],
+ "zugriff" => array("MainAdmin","DhcpAdmin"));
+ }
+
+ # falls komplette Netze verfügbar, link zum Neuanlegen
+ if ( check_if_free_networks() ){
+ $subnets[] = array("link" => "new_dhcpsubnet.php?mnr=2&sbmnr=".$i,
+ "text" => "Neues DHCP Subnet",
+ "zugriff" => array("MainAdmin","DhcpAdmin"));
+ }
+ $submenu = array(array(),
+ array(),
+ $subnets);
+
+ }
+ # $rollen = array_keys($roles);
+
+ # Zusammenstellen der Menuleiste
+ $template->define_dynamic("Hauptmenu", "Menu");
+ $template->define_dynamic("Submenu", "Menu");
+ $i=0;
+ $maxmenu = count($hauptmenu);
+
+ foreach($hauptmenu as $item) {
+ $template->clear_parse("SUBMENU_LIST");
+ if($item['zugriff'] === "alle" || vergleicheArrays($rollen , $item['zugriff'])) {
+
+ $subempty = 0;
+ $j=0;
+ $maxsub = count($submenu[$mnr]);
+ if($maxsub > 0){
+ foreach($submenu[$mnr] as $item2) {
+
+ if($item2['zugriff'] === "alle" || vergleicheArrays($rollen, $item2['zugriff'])) {
+ if($i != $mnr){
+ $template->assign(array("SUB" => ""));
+ # "LINK_S" => "",
+ # "TEXT_S" => ""));
+ $template->parse("SUBMENU_LIST", ".Submenu");
+ $template->clear_dynamic("Submenu");
+ }
+ else{
+ if ($j==0) {
+ if ($sbmnr==0) {
+ if($maxsub == 1){$zwisch="branchbottom2";}
+ else {$zwisch="branch2";}
+ $lastaktive=true;
+ $farb="#505050";
+ }
+ else{
+ if($maxsub == 1){$zwisch="branchbottom2";}
+ else {$zwisch="branch2";}
+ $farb="#A0A0A0";
+ $lastaktive=false;
+ }
+ }
+ else {
+ if ($sbmnr==$j) {
+ if($maxsub == $j+1){$zwisch="branchbottom2";}
+ else {$zwisch="branch2";}
+ $lastaktive=true;
+ $farb="#505050";
+ }
+ else {
+ $farb="#A0A0A0";
+ if($maxsub == $j+1){$zwisch="branchbottom2";}
+ else {$zwisch="branch2";}
+ # if ($lastaktive) {$zwisch="branch";}
+ # else {$zwisch="branch";}
+ $lastaktive=false;
+ }
+ }
+ $htmlcode= "
+ <tr height='4'>
+ <td></td><td align='right'><img src='../pics/line2.gif' height='4'></td><td></td><td></td>
+ </tr>
+ <tr>
+ <td width='8%'>&nbsp;</td>
+ <td width='8%' align='right'><img src='../pics/".$zwisch.".gif'></td>
+ <td width='74%' align='left' style='border-width:1 1 1 1;border-color:#000000;border-style:solid;padding:2;padding-left:30px;background-color:{FARBE_S}'>
+ <a href='".$item2['link']."' style='text-decoration:none'><b class='standard_schrift'>".$item2['text']."</b></a></td>
+ <td width='10%'>&nbsp;</td>
+ </tr>
+ ";
+ $template->assign(array("SUB" => $htmlcode));
+ $template->assign(array("FARBE_S" => $farb));
+ $template->parse("SUBMENU_LIST", ".Submenu");
+ $template->clear_dynamic("Submenu");
+ }
+ }
+ else {
+ $subempty++;
+ }
+ $j=$j+1;
+ }
+ }
+ if($subempty == count($submenu[$mnr])) {
+ $template->assign(array("SUB" => ""));
+ # "LINK_S" => "",
+ # "TEXT_S" => ""));
+ $template->parse("SUBMENU_LIST", ".Submenu");
+ $template->clear_dynamic("Submenu");
+ }
+
+ # weiter im Hauptmenü
+ if ($i==0) {
+ if ($mnr==0) {
+ if(count($submenu[$i][0]) != 0){
+ if($maxmenu == 1){$zwisch="";} # {$zwisch="<img style='border-width:0;border-style=none;' src='../pics/minus2.gif'>";}
+ else {$zwisch="";}
+ }else{$zwisch="";}
+ $lastaktive=true;
+ $farb="#505050";
+ }
+ else{
+ if(count($submenu[$i][0]) != 0){
+ if($maxmenu == 1){$zwisch="<a href='{LINK_M}' style='border-style=none;text-decoration:none'>
+ <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
+ else {$zwisch="<a href='{LINK_M}' style='border-style=none;text-decoration:none'>
+ <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
+ }else{$zwisch="";}
+ $farb="#A0A0A0";
+ $lastaktive=false;
+ }
+ }
+ else {
+ if ($mnr==$i) {
+ if(count($submenu[$mnr][0]) != 0){
+ if($maxmenu == $i+1){$zwisch="";}
+ else {$zwisch="";}
+ }else{$zwisch="";}
+ $lastaktive=true;
+ $farb="#505050";
+ }
+ else {
+ $farb="#A0A0A0";
+ if(count($submenu[$i][0]) != 0){
+ if($maxmenu == $i+1){$zwisch="<a href='{LINK_M}' style='border-style=none;text-decoration:none'>
+ <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
+ else {$zwisch="<a href='{LINK_M}' style='border-style=none;text-decoration:none'>
+ <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
+ }else{$zwisch="";}
+ #if ($lastaktive) {$zwisch="";}
+ #else {$zwisch="";}
+ $lastaktive=false;
+ }
+ }
+ $template->assign(array("ICON" => $zwisch,
+ "FARBE" => $farb,
+ "LINK_M" => $item["link"],
+ "TEXT_M" => $item["text"]));
+ $template->parse("HAUPTMENU_LIST", ".Hauptmenu");
+ $template->clear_dynamic("Hauptmenu");
+ }
+ $i=$i+1;
+ }
+ if ($lastaktive) {$template->assign(array("ENDE" => ""));}
+ else {$template->assign(array("ENDE" => ""));}
+}
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcp_start.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcp_start.dwt
new file mode 100644
index 00000000..2e1c0f02
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcp_start.dwt
@@ -0,0 +1,27 @@
+<table border='0' cellpadding='5' cellspacing='0' width='90%'>
+ <tr>
+ <td colspan='2'><h3>Modul - DHCP Management: </h3></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr>
+ <td>
+ <p>Dieses Modul dient der Verwaltung eines DHCP Dienstes und DHCP Subnets, Classes <br>
+ Benutzen Sie die Navigation links, um die einzelnen Verwaltungsbereiche anzusteuern:</p>
+ <ul>
+ <li><p><b>DHCP Service</b></p>
+ ...
+ </li>
+ <li><p><b>DHCP Subnets</b></p>
+ ...
+ </li>
+ <li><p><b>DHCP Classes</b></p>
+ ...
+ </li>
+ </ul>
+
+ </td>
+ </tr>
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt
new file mode 100644
index 00000000..2bfd0631
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt
@@ -0,0 +1,257 @@
+<table border='0' cellpadding='5' cellspacing='0' width='100%'>
+ <tr>
+ <td colspan='2'><h3>DHCP Service &nbsp;<code class='font_object'> {CN} </code> </h3></td>
+ </tr>
+ <tr>
+ <td height='20'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <form action='dhcpservice_change.php' method='post'>
+
+ <tr>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Eindeutiger DHCP Service Name (cn):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <font size='+2'><b>DHCP_</b></font><input type='Text' name='cn' value='{CN}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldcn' value='{CN}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Beschreibung:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[description]' value='{DESCRIPTION}' size='50' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[description]' value='{DESCRIPTION}'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Dienst kann momentan genutzt werden von:</b><br></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>Abteilung<b> {DHCPOFFERNOW}</b> &nbsp;(und allen Unterabteilungen)
+ </td>
+ </tr>
+ <tr height='50' valign='top'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>&Auml;ndern:</b><br>(W&auml;hlen Sie eine andere Abteilung)</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <select name='dhcpoffer' size='5' class='medium_form_selectbox'>
+ <option selected value='none'>----------</option>
+
+ <!-- BEGIN DYNAMIC BLOCK: Dhcpoffers -->
+ <option value='{DHCPOFFER}'>{DHCPOFFEROU}</option>
+ <!-- END DYNAMIC BLOCK: Dhcpoffers -->
+
+ <option value='off'>------ NIEMAND ------</option>
+
+ </select>
+ <input type='hidden' name='olddhcpoffer' value='{DHCPOFFERNOWDN}'> &nbsp;
+ </td>
+ </tr>
+ <!-- <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>PRIMARY DN:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[primary]' value='{PRIMARY}' size='50' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[primary]' value='{PRIMARY}'> &nbsp;
+ </td>
+ </tr> -->
+
+ </table></td>
+ </tr>
+
+ <tr>
+ <td height='40'></td>
+ </tr>
+ <tr>
+ <td colspan='2'><h4>DHCP Optionen des Dienstes (Globaler Scope):</h4></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <tr valign='top'>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert(e)</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Server Identifier:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptserver-identifier]' value='{SRVIDENT}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptserver-identifier]' value='{SRVIDENT}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Max Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptmax-lease-time]' value='{MAXLEASE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptmax-lease-time]' value='{MAXLEASE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Use Host DCL Names:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptuse-host-decl-names]' value='{USEHOSTDCL}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptuse-host-decl-names]' value='{USEHOSTDCL}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Max Message Size:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdhcp-max-message-size]' value='{MAXMESSIZE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdhcp-max-message-size]' value='{MAXMESSIZE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DDNS Update Style:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name]' value='{DOMAINNAME}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdomain-name]' value='{DOMAINNAME}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NTP Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptntp-servers]' value='{NTPSERVERS}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptntp-servers]' value='{NTPSERVERS}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Allow:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptallow]' value='{ALLOW}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptallow]' value='{ALLOW}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Deny:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdeny]' value='{DENY}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdeny]' value='{DENY}'> &nbsp;
+ </td>
+ </tr>
+
+ <input type='hidden' name='dhcpdn' value='{DHCPDN}'>
+ <input type='hidden' name='mnr' value='{MNR}'>
+ <input type='hidden' name='sbmnr' value='{SBMNR}'>
+
+ </table></td>
+ </tr>
+ <tr>
+ <td><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
+ </form></td>
+ </tr>
+
+ <tr>
+ <td height='40'></td>
+ </tr>
+ <tr>
+ <td colspan='2'><h4>Dem Dienst zugeordnete DHCP Subnets:</h4></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <tr valign='top'>
+ <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Subnet</b></td>
+ <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Netmask</b></td>
+ <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Abteilung (AU)</b></td>
+ </tr>
+ <!-- BEGIN DYNAMIC BLOCK: Dhcpsubnets -->
+ <tr>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{SUBNET} &nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{NETMASK}&nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{SUBNETAU}&nbsp</td>
+ </tr>
+ <!-- END DYNAMIC BLOCK: Dhcpsubnets -->
+
+ </table></td>
+ </tr>
+
+ <tr>
+ <td height='50'></td>
+ </tr>
+ <tr>
+ <td colspan='2'><h3>Config File f&uuml;r DHCP Generator Script</h3></td>
+ </tr>
+ <tr>
+ <td colspan='2'>Speichern Sie dieses als <b>dhcpgen.conf.pl</b> im gleichen Verzeichnis wie ihr DHCP Dienst Generator Skript <b>dhcp_generator.pl</b></td>
+ </tr>
+ <tr>
+ <td>
+ <table cellpadding='20' cellspacing='0' border='0' align='left' width='90%' style='border-color: black; border-style: solid; border-width: 2 2 2 2;'>
+
+ <tr>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
+ $ldaphost= "{DHCPGENLDAP}"; <br>
+ $basedn= "{DHCPGENBASE}"; <br>
+ $userdn= "{DHCPGENUDN}"; <br>
+ $passwd= "{DHCPGENPW}"; <br>
+ $dhcpservicedn= "{DHCPGENSVDN}";
+ </td>
+ </tr>
+
+
+ </table></td>
+ </tr>
+
+
+
+ <tr>
+ <td height='60'></td>
+ </tr>
+
+ <tr>
+ <td colspan='2'><h4>DHCP Service &nbsp;<code class='font_object'>{CN}</code>&nbsp; l&ouml;schen:</h4></td>
+ </tr>
+ <tr>
+ <td>
+ <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-width: 0 0 0 0;'>
+ <form action='delete_confirm.php' method='post'>
+
+ <tr>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
+ Der DHCP Dienst wird gel&ouml;scht, <br>
+ </tr>
+
+ <input type='hidden' name='dn' value='{DHCPDN}'>
+ <input type='hidden' name='name' value='{CN}'>
+ <input type='hidden' name='type' value='dhcp'>
+ <input type='hidden' name='delurl' value='dhcpservice_delete.php'>
+ <input type='hidden' name='backurl' value='dhcpservice.php?dn={DHCPDN}&mnr={MNR}'>
+ </table></td>
+ </tr>
+ <tr>
+ <td>
+ <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
+ </form></td>
+ </tr>
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpservice.php b/ldap-site-mngmt/webinterface/dhcp/dhcpservice.php
new file mode 100644
index 00000000..59d77bbe
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpservice.php
@@ -0,0 +1,164 @@
+<?php
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Service Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 0;
+$sbmnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "dhcpservice.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+$mnr = $_GET['mnr'];
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+$template->assign(array("DHCPDN" => "",
+ "CN" => "",
+ "PRIMARY" => "",
+ "SECONDARY" => "",
+ "DESCRIPTION" => "",
+ "STATEMENTS" => "",
+ "ALLOW" => "",
+ "DENY" => "",
+ "IGNORE" => "",
+ "DDNSUPDATE" => "",
+ "DEFAULTLEASE" => "",
+ "MAXLEASE" => "",
+ "USEHOSTDCL" => "",
+ "DOMAINNAME" => "",
+ "DOMAINNAMESERVERS" => "",
+ "MAXMESSIZE" => "",
+ "SRVIDENT" => "",
+ "NTPSERVERS" => "",
+ "OPTGENERIC" => "",
+ "DHCPOFFERNOWDN" => "",
+ "DHCPOFFERNOW" => ""));
+
+# DHCP Service Daten
+$dhcpsv_array = get_dhcpservices($auDN,array("dn","cn"));
+$dhcpserviceDN = $dhcpsv_array[0]['dn'];
+$attributes = array("dn","cn","dhcpprimarydn","dhcpsecondarydn","description","dhcpofferdn","dhcpstatements","dhcpoptallow",
+ "dhcpoptddns-update-style","dhcpoptdefault-lease-time","dhcpoptdeny","dhcpoptfilename",
+ "dhcpoptignore","dhcpoptmax-lease-time","dhcpoptnext-server","dhcpoptserver-identifier",
+ "dhcpoptuse-host-decl-names","dhcpoptbroadcast-address","dhcpoptdhcp-max-message-size",
+ "dhcpoptdomain-name","dhcpoptdomain-name-servers","dhcpoptgeneric","dhcpoptntp-servers",
+ "dhcpoptroot-path","dhcpoptrouters");
+$dhcpsv_data = get_node_data($dhcpserviceDN, $attributes);
+#print_r($dhcpsv_data);
+
+# RBS Anbieten
+# momentanes Offer
+# todo: falls dhcpofferDN leer dann standardwert AU teilbaum
+$offerexp = ldap_explode_dn($dhcpsv_data['dhcpofferdn'], 1);
+$dhcpoffernow = $offerexp[0];
+# alternative Offers
+$expdn = ldap_explode_dn($auDN, 0); # Mit Merkmalen
+$expdn = array_slice($expdn, 1);
+$expou = ldap_explode_dn($auDN, 1); # nur Werte
+$expou = array_slice($expou, 1, -3);
+#print_r($expou); echo "<br>";
+#print_r($expdn); echo "<br>";
+for ($i=0; $i<count($expou); $i++){
+ $dhcpoffers[$i]['ou'] = $expou[$i];
+ $dhcpoffers[$i]['dn'] = implode(',',$expdn);
+ $expdn = array_slice($expdn, 1);
+}
+#print_r($dhcpoffers);
+
+$expcn = explode('_',$dhcpsv_data['cn']);
+$name = array_slice($expcn,1);
+$dhcpcn = implode('_',$name);
+
+
+$template->assign(array("DHCPDN" => $dhcpsv_data['dn'],
+ "CN" => $dhcpcn,
+ "PRIMARY" => $dhcpsv_data['dhcpprimarydn'],
+ "SECONDARY" => $dhcpsv_data['dhcpsecondarydn'],
+ "DESCRIPTION" => $dhcpsv_data['description'],
+ "STATEMENTS" => $dhcpsv_data['dhcpstatements'],
+ "ALLOW" => $dhcpsv_data['dhcpoptallow'],
+ "DENY" => $dhcpsv_data['dhcpoptdeny'],
+ "IGNORE" => $dhcpsv_data['dhcpoptignore'],
+ "DDNSUPDATE" => $dhcpsv_data['dhcpoptddns-update-style'],
+ "DEFAULTLEASE" => $dhcpsv_data['dhcpoptdefault-lease-time'],
+ "MAXLEASE" => $dhcpsv_data['dhcpoptmax-lease-time'],
+ "USEHOSTDCL" => $dhcpsv_data['dhcpoptuse-host-decl-names'],
+ "MAXMESSIZE" => $dhcpsv_data['dhcpoptdhcp-max-message-size'],
+ "DOMAINNAME" => $dhcpsv_data['dhcpoptdomain-name'],
+ "DOMAINNAMESERVERS" => $dhcpsv_data['dhcpoptdomain-name-servers'],
+ "NEXTSERVER" => $dhcpsv_data['dhcpoptnext-server'],
+ "FILENAME" => $dhcpsv_data['dhcpoptfilename'],
+ "SRVIDENT" => $dhcpsv_data['dhcpoptserver-identifier'],
+ "NTPSERVERS" => $dhcpsv_data['dhcpoptntp-servers'],
+ "OPTGENERIC" => $dhcpsv_data['dhcpoptgeneric'],
+ "DHCPOFFERNOWDN" => $dhcpsv_data['dhcpofferdn'],
+ "DHCPOFFERNOW" => $dhcpoffernow,
+ "MNR" => $mnr,
+ "SBMNR" => $sbmnr));
+
+$template->define_dynamic("Dhcpoffers", "Webseite");
+foreach ($dhcpoffers as $offer){
+ $template->assign(array("DHCPOFFER" => $offer['dn'],
+ "DHCPOFFEROU" => $offer['ou'],));
+ $template->parse("DHCPOFFERS_LIST", ".Dhcpoffers");
+}
+
+# Subnetze und Hosts des Dienstes
+$dhcpobjects = get_service_subnets($dhcpserviceDN, array("dn","cn","dhcpoptnetmask"));
+#print_r($dhcpobjects);
+$template->define_dynamic("Dhcpsubnets", "Webseite");
+foreach ($dhcpobjects as $subnet){
+ $template->assign(array("SUBNET" => $subnet['cn'],
+ "NETMASK" => $subnet['dhcpoptnetmask'],
+ "SUBNETAU" => $subnet['auDN']));
+ $template->parse("DHCPSUBNETS_LIST", ".Dhcpsubnets");
+}
+
+### Rechner
+#$hostorgroup = $exp[0];
+#$hosts_array = get_hosts($auDN,array("dn","hostname","ipaddress"));
+#
+#$template->define_dynamic("TftpHosts", "Webseite");
+#$template->define_dynamic("NfsHosts", "Webseite");
+#$template->define_dynamic("NbdHosts", "Webseite");
+#foreach ($hosts_array as $item){
+# $template->assign(array("HDN" => $item['dn'],
+# "HN" => $item['hostname'],
+# "IP" => $item['ipaddress']));
+# $template->parse("TFTPHOSTS_LIST", ".TftpHosts");
+# $template->assign(array("HDN" => $item['dn'],
+# "HN" => $item['hostname'],
+# "IP" => $item['ipaddress']));
+# $template->parse("NFSHOSTS_LIST", ".NfsHosts");
+# $template->assign(array("HDN" => $item['dn'],
+# "HN" => $item['hostname'],
+# "IP" => $item['ipaddress']));
+# $template->parse("NBDHOSTS_LIST", ".NbdHosts");
+#}
+
+################################################
+# DHCP Generator Skript Config
+$template->assign(array("DHCPGENLDAP" => "ldap://".LDAP_HOST,
+ "DHCPGENBASE" => "ou=RIPM,".$suffix,
+ "DHCPGENUDN" => $userDN,
+ "DHCPGENPW" => $userPassword,
+ "DHCPGENSVDN" => $dhcpserviceDN));
+
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpservice_add.php b/ldap-site-mngmt/webinterface/dhcp/dhcpservice_add.php
new file mode 100644
index 00000000..bcb5899e
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpservice_add.php
@@ -0,0 +1,70 @@
+<?php
+include('../standard_header.inc.php');
+
+$cn = $_POST['cn'];
+$dhcpoffer = $_POST['dhcpoffer'];
+
+# sonstige Attribute
+$attribs = $_POST['attribs'];
+if (count($attribs) != 0){
+ foreach (array_keys($attribs) as $key){
+ $atts[$key] = htmlentities($attribs[$key]);
+ }
+}
+#print_r($atts); echo "<br><br>";
+
+$nodeDN = "cn=dhcp,".$auDN;
+$mnr = $_POST['mnr'];
+$sbmnr = $_POST['sbmnr'];
+$mcnr = $_POST['mcnr'];
+
+$get_dhcpcn = str_replace ( " ", "_", $cn );
+$seconds = 200;
+$url = "new_dhcpservice.php?&mnr=1";
+
+echo "
+<html>
+<head>
+ <title>Computers Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+<tr><td>";
+
+if ( $cn != "" && $cn != "Hier_DHCP_NAME_eintragen" ){
+
+ $dhcpcn = "DHCP_".$cn;
+
+ # Formulareingaben anpassen
+ $exp = explode(" ",$dhcpcn);
+ foreach ($exp as $word){$expuc[] = ucfirst($word);}
+ $dhcpcn = implode(" ",$expuc);
+ $dhcpcn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $dhcpcn);
+
+ #$dhcpDN = "cn=".$dhcpcn.",".$nodeDN;
+ #print_r($dhcpDN); echo "<br><br>";
+
+ if (add_dhcpservice ($dhcpcn,$dhcpoffer,$atts)){
+ $mesg .= "<br>DHCP Service erfolgreich angelegt<br>";
+ $url = "dhcpservice.php?mnr=1";
+ }else{
+ $mesg .= "<br>Fehler beim anlegen des DHCP Services!<br>";
+ }
+}
+
+elseif ( $cn == "" || $cn == "Hier_DHCP_NAME_eintragen" ){
+
+ $mesg = "Sie haben den Namen des neuen DHCP Service nicht angegeben. Dieser ist
+ aber ein notwendiges Attribut.<br>
+ Bitte geben Sie ihn an.<br><br>";
+ $url = "new_dhcpservice.php?dhcpcn=Hier_DHCP_NAME_eintragen&mnr=1";
+}
+
+$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
+ Falls nicht, klicken Sie hier <a href=".$url." style='publink'>back</a>";
+redirect($seconds, $url, $mesg, $addSessionId = TRUE);
+
+echo "</td></tr></table></body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpservice_change.php b/ldap-site-mngmt/webinterface/dhcp/dhcpservice_change.php
new file mode 100644
index 00000000..5096d355
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpservice_change.php
@@ -0,0 +1,202 @@
+<?php
+include('../standard_header.inc.php');
+
+$cn = "DHCP_".$_POST['cn'];
+$oldcn = "DHCP_".$_POST['oldcn'];
+$dhcpoffer = $_POST['dhcpoffer'];
+$olddhcpoffer = $_POST['olddhcpoffer'];
+
+$dhcpDN = $_POST['dhcpdn'];
+
+# sonstige Attribute
+$attribs = $_POST['attribs'];
+if (count($attribs) != 0){
+ foreach (array_keys($attribs) as $key){
+ $atts[$key] = htmlentities($attribs[$key]);
+ }
+}
+#print_r($atts); echo "<br><br>";
+$oldattribs = $_POST['oldattribs'];
+if (count($oldattribs) != 0){
+ foreach (array_keys($oldattribs) as $key){
+ $oldatts[$key] = htmlentities($oldattribs[$key]);
+ }
+}
+#print_r($oldatts); echo "<br><br>";
+
+
+$nodeDN = "cn=dhcp,".$auDN;
+$mnr = $_POST['mnr'];
+$sbmnr = $_POST['sbmnr'];
+$mcnr = $_POST['mcnr'];
+
+#$deltr = $_POST['deltr'];
+
+$seconds = 200;
+$url = "dhcpservice.php?dn=".$dhcpdn."&mnr=1";
+
+echo "
+<html>
+<head>
+ <title>Computers Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+<tr><td>";
+
+##############################################
+# DHCP Service CN (DN)
+
+if ( $oldcn == $cn ){
+ # $mesg = "keine Aenderung<br>";
+}
+
+if ( $oldcn != "" && $cn != "" && $oldcn != $cn ){
+ echo "DHCP Service Name aendern<br>";
+ # hier noch Syntaxcheck
+ # Formulareingaben anpassen
+ $exp = explode(" ",$cn);
+ foreach ($exp as $word){$expuc[] = ucfirst($word);}
+ $cn = implode(" ",$expuc);
+ $cn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $cn);
+
+ $newdhcpDN = "cn=".$cn.",".$nodeDN;
+ print_r($newdhcpDN); echo "<br><br>";
+
+ if(move_subtree($dhcpDN, $newdhcpDN)){
+ adjust_dhcpservice_dn($newdhcpDN, $dhcpDN);
+ $dhcpDN = $newdhcpDN;
+ $mesg = "DHCP Service Name erfolgreich ge&auml;ndert<br><br>";
+ }else{
+ $mesg = "Fehler beim &auml;ndern des DHCP Service Namen!<br><br>";
+ }
+}
+
+if ( $oldcn != "" && $cn == "" ){
+ echo "DHCP Service Name loeschen!<br>
+ Dieser ist Teil des DN, Sie werden den DHCP Service komplett l&ouml;schen<br><br>";
+ echo "Wollen Sie den DHCP Service <b>".$oldcn."</b> wirklich l&ouml;schen?<br><br>
+ <form action='dhcpservice_delete.php' method='post'>
+ Falls ja:<br><br>
+ <input type='hidden' name='dn' value='".$dhcpDN."'>
+ <input type='hidden' name='name' value='".$oldcn."'>
+ <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'><br><br>
+ </form>
+ <form action='".$url."' method='post'>
+ Falls, nein:<br><br>
+ <input type='Submit' name='apply' value='zur&uuml;ck' class='small_loginform_button'>
+ </form>";
+ $seconds = 600;
+}
+
+#####################################
+# Offer ändern
+
+if ( $dhcpoffer != "none" ){
+
+ if ( $dhcpoffer != "off" && $dhcpoffer == $olddhcpoffer ){
+ $mesg = "Sie haben die gleiche Abteilung ausgew&auml;hlt<br>
+ Keine &Auml;nderung!";
+ }
+
+ if ( $dhcpoffer != "off" && $dhcpoffer != $olddhcpoffer ){
+ $entryoffer ['dhcpofferdn'] = $dhcpoffer;
+ if(ldap_mod_replace($ds,$dhcpDN,$entryoffer)){
+ $mesg = "DHCP Service Offer erfolgreich ge&auml;ndert<br><br>";
+ }
+ else{
+ $mesg = "Fehler beim &auml;ndern des DHCP Service Offers!<br><br>";
+ }
+ }
+
+ /*if ( $dhcpoffer == "off" && $olddhcpoffer != "" ){
+ $entryoffer ['dhcpofferdn'] = array();
+ if(ldap_mod_del($ds,$dhcpDN,$entryoffer)){
+ $mesg = "DHCP Service Offer erfolgreich ge&auml;ndert<br><br>";
+ }
+ else{
+ $mesg = "Fehler beim &auml;ndern des DHCP Service Offers!<br><br>";
+ }
+ }*/
+
+}
+
+#####################################
+# Restliche Attribute
+
+$entryadd = array();
+$entrymod = array();
+$entrydel = array();
+
+foreach (array_keys($atts) as $key){
+
+ if ( $oldatts[$key] == $atts[$key] ){
+
+ }
+ if ( $oldatts[$key] == "" && $atts[$key] != "" ){
+ # hier noch Syntaxcheck
+ $entryadd[$key] = $atts[$key];
+ }
+ if ( $oldatts[$key] != "" && $atts[$key] != "" && $oldatts[$key] != $atts[$key] ){
+ # hier noch Syntaxcheck
+ $entrymod[$key] = $atts[$key];
+ }
+ if ( $oldatts[$key] != "" && $atts[$key] == "" ){
+ # hier noch Syntaxcheck
+ $entrydel[$key] = $oldatts[$key];
+ }
+}
+
+#print_r($entryadd); echo "<br>";
+#print_r($entrymod); echo "<br>";
+#print_r($entrydel); echo "<br>";
+
+
+if (count($entryadd) != 0 ){
+ #print_r($entryadd); echo "<br>";
+ #echo "neu anlegen<br>";
+ foreach (array_keys($entryadd) as $key){
+ $addatts .= "<b>".$key."</b>,";
+ }
+ if(ldap_mod_add($ds,$dhcpDN,$entryadd)){
+ $mesg = "Attribute ".$addatts." erfolgreich eingetragen<br><br>";
+ }else{
+ $mesg = "Fehler beim eintragen der Attribute ".$addatts."<br><br>";
+ }
+}
+
+if (count($entrymod) != 0 ){
+ #print_r($entrymod); echo "<br>";
+ #echo "&auml;ndern<br>";
+ foreach (array_keys($entrymod) as $key){
+ $modatts .= "<b>".$key."</b>,";
+ }
+ if(ldap_mod_replace($ds,$dhcpDN,$entrymod)){
+ $mesg = "Attribute ".$modatts." erfolgreich geaendert<br><br>";
+ }else{
+ $mesg = "Fehler beim aendern der Attribute ".$modatts."<br><br>";
+ }
+}
+
+if (count($entrydel) != 0 ){
+ #print_r($entrydel); echo "<br>";
+ #echo "l&ouml;schen<br>";
+ foreach (array_keys($entrydel) as $key){
+ $delatts .= "<b>".$key."</b>,";
+ }
+ if(ldap_mod_del($ds,$dhcpDN,$entrydel)){
+ $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
+ }else{
+ $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
+ }
+}
+
+
+$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
+ Falls nicht, klicken Sie hier <a href=".$url." style='publink'>back</a>";
+redirect($seconds, $url, $mesg, $addSessionId = TRUE);
+
+echo "</td></tr></table></body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpservice_delete.php b/ldap-site-mngmt/webinterface/dhcp/dhcpservice_delete.php
new file mode 100644
index 00000000..36260cd1
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpservice_delete.php
@@ -0,0 +1,37 @@
+<?php
+include('../standard_header.inc.php');
+
+$dhcpDN = $_POST['dn'];
+$dhcpcn = $_POST['name'];
+
+$seconds = 100;
+$url = "dhcpservice.php?mnr=1";
+
+echo "
+<html>
+<head>
+ <title>Computers Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+<tr><td>";
+
+if ( $dhcpDN != ""){
+ if ( dive_into_tree_del($dhcpDN,"") ){
+ cleanup_del_dhcpservice($dhcpDN);
+ $mesg = "DHCP Service <b>".$dhcpcn."</b> erfolgreich gel&ouml;scht!<br><br>";
+ }
+ else{
+ $mesg = "Fehler beim l&ouml;schen des DHCP Services <b>".$dhcpcn."</b> !<br><br>";
+ }
+}
+
+
+$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
+ Falls nicht, klicken Sie hier <a href=".$url." style='publink'>back</a>";
+redirect($seconds, $url, $mesg, $addSessionId = TRUE);
+
+echo "</td></tr></table></body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.dwt
new file mode 100644
index 00000000..394b63fc
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.dwt
@@ -0,0 +1,207 @@
+<table border='0' cellpadding='5' cellspacing='0' width='100%'>
+ <tr>
+ <td colspan='2'><h3>DHCP Subnet &nbsp;<code class='font_object'> {CN} </code> </h3></td>
+ </tr>
+ <tr>
+ <td height='20'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <form action='dhcpsubnet_change.php' method='post'>
+
+ <tr>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Subnet (cn):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='cn' value='{CN}' size='15' maxlength='15' class='medium_form_field'>
+ <input type='hidden' name='oldcn' value='{CN}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Netmask:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='netmask' value='{NETMASK}' size='15' maxlength='15' class='medium_form_field'>
+ <input type='hidden' name='oldnetmask' value='{NETMASK}'> &nbsp;
+ </td>
+ </tr>
+ <tr valign='top'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Eingebunden in DHCP Dienst: <b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>Service <b>{DHCPSVNOW}</b> / AU <b>{DHCPSVNOWAU}</b> &nbsp;
+ </td>
+ </tr>
+ <tr height='50' valign='top'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Dienst &auml;ndern:</b> </td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <select name='dhcpservice' size='5' class='medium_form_selectbox'>
+ <option selected value='none'>----------</option>
+
+ <!-- BEGIN DYNAMIC BLOCK: Dhcpservices -->
+ <option value='{DHCPSVDN}'>{DHCPSVCN}{DHCPSVAU}</option>
+ <!-- END DYNAMIC BLOCK: Dhcpservices -->
+
+ <option value='off'>-- keine DHCP Dienstzurordnung --</option>
+
+ </select>
+ <input type='hidden' name='olddhcpservice' value='{DHCPOFFERNOWDN}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Beschreibung:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[description]' value='{DESCRIPTION}' size='50' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[description]' value='{DESCRIPTION}'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>IP Range:</b><br>(Zur dynamischen Vergabe)</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='range1' value='{RANGE1}' size='15' maxlength='15' class='medium_form_field'>
+ &nbsp;&nbsp; - &nbsp;&nbsp;
+ <input type='Text' name='range2' value='{RANGE2}' size='15' maxlength='15' class='medium_form_field'>
+ <input type='hidden' name='oldrange1' value='{RANGE1}'>
+ <input type='hidden' name='oldrange2' value='{RANGE2}'>
+ </td>
+ </tr>
+
+ </table></td>
+ </tr>
+
+ <tr>
+ <td height='40'></td>
+ </tr>
+ <tr>
+ <td colspan='2'><h4>DHCP Optionen des Subnets (Subnet Scope):</h4></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <tr valign='top'>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert(e)</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Max Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptmax-lease-time]' value='{MAXLEASE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptmax-lease-time]' value='{MAXLEASE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DDNS Update Style:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name]' value='{DOMAINNAME}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdomain-name]' value='{DOMAINNAME}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Routers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptrouters]' value='{ROUTERS}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptrouters]' value='{ROUTERS}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Broadcast Address:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptbroadcast-address]' value='{BROADCAST}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptbroadcast-address]' value='{BROADCAST}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NTP Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptntp-servers]' value='{NTPSERVERS}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptntp-servers]' value='{NTPSERVERS}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Next Server:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptnext-server]' value='{NEXTSERVER}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptnext-server]' value='{NEXTSERVER}'> &nbsp;
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Filename:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptfilename]' value='{FILENAME}' size='40' class='medium_form_field'>
+ <input type='hidden' name='oldattribs[dhcpoptfilename]' value='{FILENAME}'> &nbsp;
+ </td>
+ </tr>
+
+ <input type='hidden' name='subnetdn' value='{SUBNETDN}'>
+ <input type='hidden' name='mnr' value='{MNR}'>
+ <input type='hidden' name='sbmnr' value='{SBMNR}'>
+
+ </table></td>
+ </tr>
+ <tr>
+ <td><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
+ </form></td>
+ </tr>
+
+
+ <tr>
+ <td height='60'></td>
+ </tr>
+
+ <tr>
+ <td colspan='2'><h4>DHCP Subnet &nbsp;<code class='font_object'>{CN}</code>&nbsp; l&ouml;schen:</h4></td>
+ </tr>
+ <tr>
+ <td>
+ <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-width: 0 0 0 0;'>
+ <form action='delete_confirm.php' method='post'>
+
+
+ <tr>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
+ Das DHCP Subnet wird gel&ouml;scht, <br>
+ </tr>
+
+ <input type='hidden' name='dn' value='{SUBNETDN}'>
+ <input type='hidden' name='name' value='{CN}'>
+ <input type='hidden' name='type' value='dhcp'>
+ <input type='hidden' name='delurl' value='dhcpsubnet_delete.php'>
+ <input type='hidden' name='backurl' value='dhcpsubnet.php?dn={SUBNETDN}&mnr={MNR}&sbmnr{SBMNR}'>
+
+ </table></td>
+ </tr>
+ <tr>
+ <td>
+ <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
+ </form></td>
+ </tr>
+
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.php b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.php
new file mode 100644
index 00000000..235667aa
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.php
@@ -0,0 +1,126 @@
+<?php
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Service Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 0;
+$sbmnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "dhcpsubnet.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+$mnr = $_GET['mnr'];
+$sbmnr = $_GET['sbmnr'];
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+$template->assign(array("SUBNETDN" => "",
+ "CN" => "",
+ "NETMASK" => "",
+ "RANGE1" => "",
+ "RANGE2" => "",
+ "DESCRIPTION" => "",
+ "STATEMENTS" => "",
+ "ALLOW" => "",
+ "DENY" => "",
+ "IGNORE" => "",
+ "DDNSUPDATE" => "",
+ "DEFAULTLEASE" => "",
+ "MAXLEASE" => "",
+ "USEHOSTDCL" => "",
+ "BROADCAST" => "",
+ "ROUTERS" => "",
+ "DOMAINNAME" => "",
+ "DOMAINNAMESERVERS" => "",
+ "NEXTSERVER" => "",
+ "FILENAME" => "",
+ "SRVIDENT" => "",
+ "NTPSERVERS" => "",
+ "OPTGENERIC" => "",
+ "DHCPOFFERNOWDN" => "",
+ "DHCPSVNOW" => "",
+ "DHCPSVNOWAU" => "",
+ "MNR" => $mnr,
+ "SBMNR" => $sbmnr,
+ "MCNR" => $mcnr));
+
+# DHCP Subnet Daten
+$dhcpsubnetDN = $_GET['dn'];
+$attributes = array("dn","cn","dhcpoptnetmask","dhcphlpcont","dhcprange","description","dhcpstatements","dhcpoptallow",
+ "dhcpoptddns-update-style","dhcpoptdefault-lease-time","dhcpoptdeny","dhcpoptfilename",
+ "dhcpoptignore","dhcpoptmax-lease-time","dhcpoptnext-server","dhcpoptserver-identifier",
+ "dhcpoptuse-host-decl-names","dhcpoptbroadcast-address","dhcpoptdhcp-max-message-size",
+ "dhcpoptdomain-name","dhcpoptdomain-name-servers","dhcpoptgeneric","dhcpoptntp-servers",
+ "dhcpoptroot-path","dhcpoptrouters");
+$subnet_data = get_node_data($dhcpsubnetDN, $attributes);
+#print_r($subnet_data);
+
+# momentane DHCP Service Zuordnung
+$dhcpsvnowdn = ldap_explode_dn($subnet_data['dhcphlpcont'], 1);
+
+# DHCP Range
+$iprange = explode('_',$subnet_data['dhcprange']);
+
+$template->assign(array("SUBNETDN" => $dhcpsubnetDN,
+ "CN" => $subnet_data['cn'],
+ "NETMASK" => $subnet_data['dhcpoptnetmask'],
+ "RANGE1" => $iprange[0],
+ "RANGE2" => $iprange[1],
+ "DESCRIPTION" => $subnet_data['description'],
+ "STATEMENTS" => $subnet_data['dhcpstatements'],
+ "ALLOW" => $subnet_data['dhcpoptallow'],
+ "DENY" => $subnet_data['dhcpoptdeny'],
+ "IGNORE" => $subnet_data['dhcpoptignore'],
+ "DDNSUPDATE" => $subnet_data['dhcpoptddns-update-style'],
+ "DEFAULTLEASE" => $subnet_data['dhcpoptdefault-lease-time'],
+ "MAXLEASE" => $subnet_data['dhcpoptmax-lease-time'],
+ "USEHOSTDCL" => $subnet_data['dhcpoptuse-host-decl-names'],
+ "BROADCAST" => $subnet_data['dhcpoptbroadcast-address'],
+ "ROUTERS" => $subnet_data['dhcpoptrouters'],
+ "DOMAINNAME" => $subnet_data['dhcpoptdomain-name'],
+ "DOMAINNAMESERVERS" => $subnet_data['dhcpoptdomain-name-servers'],
+ "NEXTSERVER" => $subnet_data['dhcpoptnext-server'],
+ "FILENAME" => $subnet_data['dhcpoptfilename'],
+ "SRVIDENT" => $subnet_data['dhcpoptserver-identifier'],
+ "NTPSERVERS" => $subnet_data['dhcpoptntp-servers'],
+ "OPTGENERIC" => $subnet_data['dhcpoptgeneric'],
+ "DHCPOFFERNOWDN" => $subnet_data['dhcphlpcont'],
+ "DHCPSVNOW" => $dhcpsvnowdn[0],
+ "DHCPSVNOWAU" => $dhcpsvnowdn[2],
+ "MNR" => $mnr,
+ "SBMNR" => $sbmnr,
+ "MCNR" => $mcnr));
+
+
+# alternative DHCP Services
+$altdhcp = alternative_dhcpservices($subnet_data['dhcphlpcont']);
+
+$template->assign(array("DHCPSVDN" => "",
+ "DHCPSVCN" => "",
+ "DHCPSVAU" => ""));
+if (count($altdhcp) != 0){
+$template->define_dynamic("Dhcpservices", "Webseite");
+ foreach ($altdhcp as $item){
+ $template->assign(array("DHCPSVDN" => $item['dn'],
+ "DHCPSVCN" => $item['cn'],
+ "DHCPSVAU" => $item['au']));
+ $template->parse("DHCPSERVICES_LIST", ".Dhcpservices");
+ }
+}
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_add.php b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_add.php
new file mode 100644
index 00000000..6939afe0
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_add.php
@@ -0,0 +1,71 @@
+<?php
+include('../standard_header.inc.php');
+
+$syntax = new Syntaxcheck;
+
+$cn = $_POST['cn'];
+$netmask = $_POST['netmask'];
+$dhcpservice = $_POST['dhcpservice'];
+$range1 = $_POST['range1'];
+$range2 = $_POST['range2'];
+
+# sonstige Attribute
+$attribs = $_POST['attribs'];
+if (count($attribs) != 0){
+ foreach (array_keys($attribs) as $key){
+ $atts[$key] = htmlentities($attribs[$key]);
+ }
+}
+#print_r($atts); echo "<br><br>";
+
+$nodeDN = "cn=dhcp,".$auDN;
+$mnr = $_POST['mnr'];
+$sbmnr = $_POST['sbmnr'];
+
+$get_dhcpcn = str_replace ( " ", "_", $cn );
+$seconds = 200;
+$url = "new_dhcpsubnet.php?&mnr=2";
+
+echo "
+<html>
+<head>
+ <title>Computers Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+<tr><td>";
+
+if ( $cn != "" && $cn != "Hier_Subnetz_eintragen" && $netmask != "" && $netmask != "Hier_Netzmaske_eintragen" ){
+
+ if ( $syntax->check_netip_syntax($cn) && $syntax->check_ip_syntax($netmask) ){
+
+ if (add_dhcpsubnet ($cn,$dhcpservice,$netmask,$range1,$range2,$atts)){
+ $mesg .= "<br>DHCP Subnet erfolgreich angelegt<br>";
+ $url = "dhcpsubnets.php?mnr=2";
+ }else{
+ $mesg .= "<br>Fehler beim anlegen des DHCP Subnets!<br>";
+ }
+
+ }else{
+ $mesg .= "Falsche IP Syntax! Geben Sie eine korrekte IP Adresse als Subnet Name oder Netzmaske ein.";
+ $url = "new_dhcpsubnet.php?subnetcn=Hier_Subnetz_eintragen&netmask=".$netmask."&mnr=2";
+ }
+}
+
+elseif ( $cn == "" || $cn == "Hier_Subnetz_eintragen" || $netmask == "" || $netmask == "Hier_Netzmaske_eintragen" ){
+
+ if ( $cn == ""){ $cn = "Hier_Subnetz_eintragen";}
+ if ( $netmask == ""){ $netmask = "Hier_Netzmaske_eintragen";}
+ $mesg = "Sie haben die notwendigen Attribute: Name (IP) und Netzmaske des neuen DHCP Subnets nicht angegeben.<br>
+ Bitte geben Sie fehlende ein.<br><br>";
+ $url = "new_dhcpsubnet.php?subnetcn=".$cn."&netmask=".$netmask."&mnr=2";
+}
+
+$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
+ Falls nicht, klicken Sie hier <a href=".$url." style='publink'>back</a>";
+redirect($seconds, $url, $mesg, $addSessionId = TRUE);
+
+echo "</td></tr></table></body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_change.php b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_change.php
new file mode 100644
index 00000000..b0dc13c7
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_change.php
@@ -0,0 +1,292 @@
+<?php
+include('../standard_header.inc.php');
+
+$syntax = new Syntaxcheck;
+
+$cn = $_POST['cn'];
+$oldcn = $_POST['oldcn'];
+$netmask = $_POST['netmask'];
+$oldnetmask = $_POST['oldnetmask'];
+$dhcpservice = $_POST['dhcpservice'];
+$olddhcpservice = $_POST['olddhcpservice'];
+$newrange1 = $_POST['range1'];
+$oldrange1 = $_POST['oldrange1'];
+$newrange2 = $_POST['range2'];
+$oldrange2 = $_POST['oldrange2'];
+
+$subnetDN = $_POST['subnetdn'];
+
+# sonstige Attribute
+$attribs = $_POST['attribs'];
+if (count($attribs) != 0){
+ foreach (array_keys($attribs) as $key){
+ $atts[$key] = htmlentities($attribs[$key]);
+ }
+}
+#print_r($atts); echo "<br><br>";
+$oldattribs = $_POST['oldattribs'];
+if (count($oldattribs) != 0){
+ foreach (array_keys($oldattribs) as $key){
+ $oldatts[$key] = htmlentities($oldattribs[$key]);
+ }
+}
+#print_r($oldatts); echo "<br><br>";
+
+$nodeDN = "cn=dhcp,".$auDN;
+$mnr = $_POST['mnr'];
+$sbmnr = $_POST['sbmnr'];
+$mcnr = $_POST['mcnr'];
+
+$seconds = 200;
+$url = "dhcpsubnet.php?dn=".$subnetDN."&mnr=".$mnr."&sbmnr=".$sbmnr;
+
+echo "
+<html>
+<head>
+ <title>Computers Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+<tr><td>";
+
+##############################################
+# DHCP Subnet CN (DN)
+
+if ( $oldcn == $cn ){
+ # $mesg = "keine Aenderung<br>";
+}
+
+if ( $oldcn != "" && $cn != "" && $oldcn != $cn ){
+
+ if ( $syntax->check_netip_syntax($cn) ){
+ echo "Subnetz aendern<br>";
+ $newsubnetDN = "cn=".$cn.",".$nodeDN;
+ print_r($newsubnetDN); echo "<br><br>";
+
+ if(modify_subnet_dn($subnetDN,$newsubnetDN)){
+ $subnetDN = $newsubnetDN;
+ $mesg = "DHCP Subnet erfolgreich ge&auml;ndert<br><br>";
+ $url = "dhcpsubnet.php?dn=".$subnetDN."&mnr=".$mnr."&sbmnr=".$sbmnr;
+ }else{
+ $mesg = "Fehler beim &auml;ndern des DHCP Subnets!<br><br>";
+ }
+
+ }else{
+ $mesg = "falsche IP Syntax<br>";
+ }
+}
+
+if ( $oldcn != "" && $cn == "" ){
+ echo "DHCP Subnet loeschen!<br>
+ Dieser ist Teil des DN, Sie werden den DHCP Subnet komplett l&ouml;schen<br><br>";
+ echo "Wollen Sie den DHCP Subnet <b>".$oldcn."</b> wirklich l&ouml;schen?<br><br>
+ <form action='dhcpsubnet_delete.php' method='post'>
+ Falls ja:<br><br>
+ <input type='hidden' name='dn' value='".$subnetDN."'>
+ <input type='hidden' name='name' value='".$oldcn."'>
+ <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'><br><br>
+ </form>
+ <form action='".$url."' method='post'>
+ Falls, nein:<br><br>
+ <input type='Submit' name='apply' value='zur&uuml;ck' class='small_loginform_button'>
+ </form>";
+ $seconds = 600;
+}
+
+
+#####################################
+# Netmask
+
+if ( $netmask != $oldnetmask ){
+
+ if ( $netmask == ""){
+ echo "Die Subnetzmaske ist ein notwendiges Attribut.<br>
+ Keine &Auml;nderung!<br>";
+ }
+
+ if ( $netmask != "" ){
+ if ( $syntax->check_ip_syntax($netmask) ){
+ $entry ['dhcpoptnetmask'] = $netmask;
+ if(ldap_mod_replace($ds,$subnetDN,$entry)){
+ $mesg = "Netzmaske erfolgreich ge&auml;ndert<br><br>";
+ }else{
+ $mesg = "Fehler beim &auml;ndern der Netzmaske!<br><br>";
+ }
+ }else{
+ $mesg = "falsche IP Syntax<br>";
+ }
+ }
+
+}
+
+
+#####################################
+# DHCP Dienstzuordnung ändern
+
+if ( $dhcpservice != "none" ){
+
+ if ( $dhcpservice != "off" && $dhcpservice == $olddhcpservice ){
+ $mesg = "Sie haben die gleiche Abteilung ausgew&auml;hlt<br>
+ Keine &Auml;nderung!";
+ }
+
+ if ( $dhcpservice != "off" && $dhcpservice != $olddhcpservice ){
+ $entrysv ['dhcphlpcont'] = $dhcpservice;
+ if(ldap_mod_replace($ds,$subnetDN,$entrysv)){
+ $mesg = "DHCP Dienstzuordnung erfolgreich ge&auml;ndert<br><br>";
+ }
+ else{
+ $mesg = "Fehler beim &auml;ndern der DHCP Dienstzuordnung!<br><br>";
+ }
+ }
+
+ if ( $dhcpservice == "off" && $olddhcpservice != "" ){
+ $entrysv ['dhcphlpcont'] = array();
+ if(ldap_mod_del($ds,$subnetDN,$entrysv)){
+ $mesg = "DHCP Dienstzuordnung erfolgreich ge&auml;ndert<br><br>";
+ }
+ else{
+ $mesg = "Fehler beim &auml;ndern der DHCP Dienstzuordnung!<br><br>";
+ }
+ }
+
+}
+
+
+#####################################
+# DHCP Range
+
+if ( $newrange1 == $oldrange1 && $newrange2 == $oldrange2 ){
+ # $mesg = "keine Aenderung<br>";
+}else{
+
+ if ( $newrange1 == "" xor $newrange2 == "" ){
+ $mesg = "Bitte beide DHCP Range Felder ausf&uuml;llen, keine Aenderung<br>";
+ }
+
+ if ( $oldrange1 == "" && $oldrange2 == "" && $newrange1 != "" && $newrange2 != "" ){
+ if ( $syntax->check_ip_syntax($newrange1) && $syntax->check_ip_syntax($newrange2) ){
+ if ( check_ip_in_subnet($newrange1,$cn) && check_ip_in_subnet($newrange2,$cn)){
+ $dhcprange = implode('_',array($newrange1,$newrange2));
+ if ( new_ip_dhcprange($dhcprange,$subnetDN,$auDN) ){
+ $mesg = "DHCP Range erfolgreich eingetragen";
+ }else{
+ $mesg = "Fehler beim eintragen der DHCP Range";
+ }
+ }else{
+ $mesg = "DHCP Range nicht in Subnetz ".$cn." enthalten";
+ }
+ }else{
+ $mesg = "falsche IP Syntax<br>";
+ }
+ }
+
+ if ( $oldrange1 != "" && $oldrange2 != "" && $newrange1 != "" && $newrange2 != "" ){
+ if ( $syntax->check_ip_syntax($newrange1) && $syntax->check_ip_syntax($newrange2) ){
+ if ( check_ip_in_subnet($newrange1,$cn) && check_ip_in_subnet($newrange2,$cn)){
+ $dhcprange = implode('_',array($newrange1,$newrange2));
+ $olddhcprange = implode('_',array($oldrange1,$oldrange2));
+ if ( modify_ip_dhcprange($dhcprange,$subnetDN,$auDN) ){
+ $mesg = "DHCP Range erfolgreich ge&auml;ndert";
+ }else{
+ $mesg = "Fehler beim &auml;ndern der DHCP Range";
+ # alte Range wiederherstellen
+ new_ip_dhcprange($olddhcprange,$subnetDN,$auDN);
+ }
+ }else{
+ $mesg = "DHCP Range nicht in Subnetz ".$cn." enthalten";
+ }
+ }else{
+ $mesg = "falsche IP Syntax<br>";
+ }
+ }
+
+ if ( $newrange1 == "" && $newrange2 == "" ){
+ if ( delete_ip_dhcprange($subnetDN,$auDN) ){
+ $mesg = "DHCP Range erfolgreich gel&ouml;scht";
+ }else{
+ $mesg = "Fehler beim l&ouml;schen der DHCP Range";
+ }
+ }
+
+}
+
+#####################################
+# Restliche Attribute (u.a. Description)
+
+$entryadd = array();
+$entrymod = array();
+$entrydel = array();
+
+foreach (array_keys($atts) as $key){
+
+ if ( $oldatts[$key] == $atts[$key] ){
+
+ }
+ if ( $oldatts[$key] == "" && $atts[$key] != "" ){
+ # hier noch Syntaxcheck
+ $entryadd[$key] = $atts[$key];
+ }
+ if ( $oldatts[$key] != "" && $atts[$key] != "" && $oldatts[$key] != $atts[$key] ){
+ # hier noch Syntaxcheck
+ $entrymod[$key] = $atts[$key];
+ }
+ if ( $oldatts[$key] != "" && $atts[$key] == "" ){
+ # hier noch Syntaxcheck
+ $entrydel[$key] = $oldatts[$key];
+ }
+}
+
+#print_r($entryadd); echo "<br>";
+#print_r($entrymod); echo "<br>";
+#print_r($entrydel); echo "<br>";
+
+
+if (count($entryadd) != 0 ){
+ #print_r($entryadd); echo "<br>";
+ #echo "neu anlegen<br>";
+ foreach (array_keys($entryadd) as $key){
+ $addatts .= "<b>".$key."</b>,";
+ }
+ if(ldap_mod_add($ds,$subnetDN,$entryadd)){
+ $mesg = "Attribute ".$addatts." erfolgreich eingetragen<br><br>";
+ }else{
+ $mesg = "Fehler beim eintragen der Attribute ".$addatts."<br><br>";
+ }
+}
+
+if (count($entrymod) != 0 ){
+ #print_r($entrymod); echo "<br>";
+ #echo "&auml;ndern<br>";
+ foreach (array_keys($entrymod) as $key){
+ $modatts .= "<b>".$key."</b>,";
+ }
+ if(ldap_mod_replace($ds,$subnetDN,$entrymod)){
+ $mesg = "Attribute ".$modatts." erfolgreich geaendert<br><br>";
+ }else{
+ $mesg = "Fehler beim aendern der Attribute ".$modatts."<br><br>";
+ }
+}
+
+if (count($entrydel) != 0 ){
+ #print_r($entrydel); echo "<br>";
+ #echo "l&ouml;schen<br>";
+ foreach (array_keys($entrydel) as $key){
+ $delatts .= "<b>".$key."</b>,";
+ }
+ if(ldap_mod_del($ds,$subnetDN,$entrydel)){
+ $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
+ }else{
+ $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
+ }
+}
+
+
+$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
+ Falls nicht, klicken Sie hier <a href=".$url." style='publink'>back</a>";
+redirect($seconds, $url, $mesg, $addSessionId = TRUE);
+
+echo "</td></tr></table></body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_delete.php b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_delete.php
new file mode 100644
index 00000000..eb5d66aa
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_delete.php
@@ -0,0 +1,34 @@
+<?php
+include('../standard_header.inc.php');
+
+$subnetDN = $_POST['dn'];
+$cn = $_POST['name'];
+
+$seconds = 100;
+$url = "dhcpsubnets.php?mnr=2";
+
+echo "
+<html>
+<head>
+ <title>Computers Management</title>
+ <link rel='stylesheet' href='../styles.css' type='text/css'>
+</head>
+<body>
+<table border='0' cellpadding='30' cellspacing='0'>
+<tr><td>";
+
+if ( $subnetDN != ""){
+ if( delete_dhcpsubnet($subnetDN,$cn)){
+ $mesg = "Subnet <b>".$cn."</b> erfolgreich gel&ouml;scht!<br><br>";
+ }else{
+ $mesg = "Fehler beim l&ouml;schen des Subnets <b>".$cn."</b> !<br><br>";
+ }
+}
+
+$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
+ Falls nicht, klicken Sie hier <a href=".$url." style='publink'>back</a>";
+redirect($seconds, $url, $mesg, $addSessionId = TRUE);
+
+echo "</td></tr></table></body>
+</html>";
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.dwt
new file mode 100644
index 00000000..e887509d
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.dwt
@@ -0,0 +1,37 @@
+<table border='0' cellpadding='5' cellspacing='0' width='100%'>
+ <tr>
+ <td colspan='2'><h3>DHCP Subnets</h3>
+ </td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+ <tr>
+ <td width='15%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Subnet</b></td>
+ <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Netmask</b></td>
+ <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP Dienst</b></td>
+ <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Range</b></td>
+ <td width='15%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Hostobjekte</b></td>
+ </tr>
+
+ <!-- BEGIN DYNAMIC BLOCK: Subnets -->
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{SUBNETCN} &nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{NETMASK}&nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{DHCP}&nbsp</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{RANGE}&nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <!-- BEGIN DYNAMIC BLOCK: Hosts -->
+ <b>{HOSTS}</b><br>
+ <!-- END DYNAMIC BLOCK: Hosts -->
+ </td>
+ </tr>
+ <!-- END DYNAMIC BLOCK: Subnets -->
+
+ </table></td>
+ </tr>
+
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.php b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.php
new file mode 100644
index 00000000..1104f496
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.php
@@ -0,0 +1,65 @@
+<?php
+
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Service Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 2;
+$sbmnr = -1;
+$mcnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "dhcpsubnets.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+$template->assign(array("SUBNETDN" => "",
+ "SUBNETCN" => "Noch keine Subnets angelegt",
+ "NETMASK" => "",
+ "DHCP" => "",
+ "RANGE" => "",
+ "HOSTS" => ""));
+
+# rbservice und pxe daten (voerst nur ein rbs)
+$subnet_array = get_dhcpsubnets($auDN,array("dn","cn","dhcpoptnetmask","dhcprange","dhcphlpcont"));
+
+$template->define_dynamic("Subnets", "Webseite");
+foreach ($subnet_array as $subnet){
+ $range = "";
+ if ($subnet['dhcprange'] != ""){
+ $exp = explode('_',$subnet['dhcprange']);
+ $range = $exp[0]." - ".$exp[1];
+ }
+ if ($subnet['dhcphlpcont'] != ""){
+ $exp = ldap_explode_dn($subnet['dhcphlpcont'],1);
+ $dhcpservice = $exp[0]." &nbsp;[".$exp[2]."]";
+ }else{
+ $dhcpservice = "";
+ }
+
+ $template->assign(array("SUBNETDN" => $subnet['dn'],
+ "SUBNETCN" => $subnet['cn'],
+ "NETMASK" => $subnet['dhcpoptnetmask'],
+ "DHCP" => $dhcpservice,
+ "RANGE" => $range,
+ "HOSTS" => ""));
+ $template->parse("SUBNETS_LIST", ".Subnets");
+}
+
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?>
diff --git a/ldap-site-mngmt/webinterface/dhcp/menu.dwt b/ldap-site-mngmt/webinterface/dhcp/menu.dwt
new file mode 100644
index 00000000..037bdf15
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/menu.dwt
@@ -0,0 +1,29 @@
+
+<table cellpadding='0' cellspacing='0' border='0' width='100%'>
+
+
+
+ <!-- BEGIN DYNAMIC BLOCK: Hauptmenu -->
+
+ <tr valign='middle' align='left'>
+
+ <td width='8%' align='right' style="border-style=none;">{ICON}</td>
+ <td width="8%" align="left" style="border-width:1 0 1 1;border-color:#000000;border-style:solid;padding:5;background-color:{FARBE}">&nbsp;</td>
+ <td width="74%" align="left" style="border-width:1 1 1 0;border-color:#000000;border-style:solid;padding:5;background-color:{FARBE}">
+ <a href="{LINK_M}" style="text-decoration:none"><b class="standard_schrift">{TEXT_M}</b></a></td>
+ <td width='10%'>&nbsp;</td>
+
+ </tr>
+
+ <!-- BEGIN DYNAMIC BLOCK: Submenu -->
+
+ {SUB}
+
+ <!-- END DYNAMIC BLOCK: Submenu -->
+
+ <tr height='5'></tr>
+ <!-- END DYNAMIC BLOCK: Hauptmenu -->
+
+
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.dwt b/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.dwt
new file mode 100644
index 00000000..7d964715
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.dwt
@@ -0,0 +1,151 @@
+<table border='0' cellpadding='5' cellspacing='0' width='100%'>
+ <tr>
+ <td colspan='2'><h3>DHCP Service anlegen</td>
+ </tr>
+ <tr>
+ <td height='20'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <form action='dhcpservice_add.php' method='post'>
+
+ <tr>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Eindeutiger DHCP Service Name (cn):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <font size='+2'><b>DHCP_</b></font><input type='Text' name='cn' value='{CN}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Beschreibung:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[description]' value='{DESCRIPTION}' size='50' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50' valign='top'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <b>Wer soll Dienst nutzen d&uuml;rfen:</b><br>(W&auml;hlen Sie eine Abteilung,<br>
+ impliziert alle Unterabteilungen)
+ </td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <select name='dhcpoffer' size='5' class='medium_form_selectbox'>
+ <option selected value='{OFFERSELF}'>{SELFOU}</option>
+
+ <!-- BEGIN DYNAMIC BLOCK: Dhcpoffers -->
+ <option value='{DHCPOFFER}'>{DHCPOFFEROU}</option>
+ <!-- END DYNAMIC BLOCK: Dhcpoffers -->
+
+ </select>
+ </td>
+ </tr>
+ <!-- <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>PRIMARY DN:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[primary]' value='{PRIMARY}' size='50' class='medium_form_field'>
+ </td>
+ </tr> -->
+
+ </table></td>
+ </tr>
+
+ <tr>
+ <td height='40'></td>
+ </tr>
+ <tr>
+ <td colspan='2'><h4>DHCP Optionen des Dienstes (Globaler Scope):</h4></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <tr valign='top'>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert(e)</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Server Identifier:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptserver-identifier]' value='{SRVIDENT}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Max Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptmax-lease-time]' value='{MAXLEASE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Use Host DCL Names:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptuse-host-decl-names]' value='{USEHOSTDCL}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Max Message Size:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdhcp-max-message-size]' value='{MAXMESSIZE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DDNS Update Style:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name]' value='{DOMAINNAME}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NTP Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptntp-servers]' value='{NTPSERVERS}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Allow:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptallow]' value='{ALLOW}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Deny:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdeny]' value='{DENY}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+
+ <input type='hidden' name='mnr' value='{MNR}'>
+ <input type='hidden' name='sbmnr' value='{SBMNR}'>
+
+ </table></td>
+ </tr>
+ <tr>
+ <td><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'>
+ </form></td>
+ </tr>
+
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.php b/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.php
new file mode 100644
index 00000000..83aa9cb5
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.php
@@ -0,0 +1,79 @@
+<?php
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Service Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 0;
+$sbmnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "new_dhcpservice.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+$mnr = $_GET['mnr'];
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+$dhcpcn = str_replace ( "_", " ", $_GET['dhcpcn']);
+$template->assign(array("CN" => $dhcpcn,
+ "PRIMARY" => "",
+ "SECONDARY" => "",
+ "DESCRIPTION" => "",
+ "STATEMENTS" => "",
+ "ALLOW" => "",
+ "DENY" => "",
+ "IGNORE" => "",
+ "DDNSUPDATE" => "",
+ "DEFAULTLEASE" => "",
+ "MAXLEASE" => "",
+ "USEHOSTDCL" => "",
+ "DOMAINNAME" => "",
+ "DOMAINNAMESERVERS" => "",
+ "MAXMESSIZE" => "",
+ "SRVIDENT" => "",
+ "NTPSERVERS" => "",
+ "OPTGENERIC" => "",
+ "OFFERSELF" => $auDN,
+ "SELFOU" => $au_ou,
+ "MNR" => $mnr,
+ "SBMNR" => $sbmnr));
+
+
+# DHCP Service Anbieten (ausser eigene AU)
+$expdn = ldap_explode_dn($auDN, 0); # Mit Merkmalen
+$expdn = array_slice($expdn, 2);
+$expou = ldap_explode_dn($auDN, 1); # nur Werte
+$expou = array_slice($expou, 2, -3);
+#print_r($expou); echo "<br>";
+#print_r($expdn); echo "<br>";
+for ($i=0; $i<count($expou); $i++){
+ $dhcpoffers[$i]['ou'] = $expou[$i];
+ $dhcpoffers[$i]['dn'] = implode(',',$expdn);
+ $expdn = array_slice($expdn, 1);
+}
+#print_r($dhcpoffers);
+
+$template->define_dynamic("Dhcpoffers", "Webseite");
+if ( count($dhcpoffers) != 0 ){
+ foreach ($dhcpoffers as $offer){
+ $template->assign(array("DHCPOFFER" => $offer['dn'],
+ "DHCPOFFEROU" => $offer['ou'],));
+ $template->parse("DHCPOFFERS_LIST", ".Dhcpoffers");
+ }
+}
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.dwt b/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.dwt
new file mode 100644
index 00000000..8b710fb8
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.dwt
@@ -0,0 +1,149 @@
+<table border='0' cellpadding='5' cellspacing='0' width='100%'>
+ <tr>
+ <td colspan='2'><h3>DHCP Subnet anlegen </h3></td>
+ </tr>
+ <tr>
+ <td height='20'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <form action='dhcpsubnet_add.php' method='post'>
+
+ <tr>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Subnet (cn):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='cn' value='{CN}' size='15' maxlength='15' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Netmask:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='netmask' value='{NETMASK}' size='15' maxlength='15' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50' valign='top'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Dienst w&auml;hlen:</b> </td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <select name='dhcpservice' size='5' class='medium_form_selectbox'>
+ <option selected value='none'>----------</option>
+
+ <!-- BEGIN DYNAMIC BLOCK: Dhcpservices -->
+ <option value='{DHCPSVDN}'>{DHCPSVCN} / {DHCPSVAU}</option>
+ <!-- END DYNAMIC BLOCK: Dhcpservices -->
+
+ </select>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Beschreibung:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[description]' value='{DESCRIPTION}' size='50' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>IP Range:</b><br>(Zur dynamischen Vergabe)</td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='range1' value='{RANGE1}' size='15' maxlength='15' class='medium_form_field'>
+ &nbsp;&nbsp; - &nbsp;&nbsp;
+ <input type='Text' name='range2' value='{RANGE2}' size='15' maxlength='15' class='medium_form_field'>
+ </td>
+ </tr>
+
+ </table></td>
+ </tr>
+
+ <tr>
+ <td height='40'></td>
+ </tr>
+ <tr>
+ <td colspan='2'><h4>DHCP Optionen des Subnets (Subnet Scope):</h4></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr><td>
+ <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
+
+ <tr valign='top'>
+ <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
+ <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert(e)</b></td>
+ </tr>
+
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Max Lease Time:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptmax-lease-time]' value='{MAXLEASE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DDNS Update Style:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name]' value='{DOMAINNAME}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Domain Name Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Routers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptrouters]' value='{ROUTERS}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Broadcast Address:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptbroadcast-address]' value='{BROADCAST}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <!-- <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Next Server:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptnext-server]' value='{NEXTSERVER}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Filename:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptfilename]' value='{FILENAME}' size='40' class='medium_form_field'>
+ </td>
+ </tr> -->
+ <tr height='50'>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NTP Servers:</b></td>
+ <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
+ <input type='Text' name='attribs[dhcpoptntp-servers]' value='{NTPSERVERS}' size='40' class='medium_form_field'>
+ </td>
+ </tr>
+
+ <input type='hidden' name='mnr' value='{MNR}'>
+ <input type='hidden' name='sbmnr' value='{SBMNR}'>
+
+ </table></td>
+ </tr>
+ <tr>
+ <td><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'>
+ </form></td>
+ </tr>
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.php b/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.php
new file mode 100644
index 00000000..a7697c14
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.php
@@ -0,0 +1,84 @@
+<?php
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Service Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 0;
+$sbmnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "new_dhcpsubnet.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+$mnr = $_GET['mnr'];
+$sbmnr = $_GET['sbmnr'];
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+$subnetcn = str_replace ( "_", " ", $_GET['subnetcn']);
+$netmask = str_replace ( "_", " ", $_GET['netmask']);
+$template->assign(array("CN" => $subnetcn,
+ "NETMASK" => $netmask,
+ "RANGE1" => "",
+ "RANGE2" => "",
+ "DESCRIPTION" => "",
+ "STATEMENTS" => "",
+ "ALLOW" => "",
+ "DENY" => "",
+ "IGNORE" => "",
+ "DDNSUPDATE" => "",
+ "DEFAULTLEASE" => "",
+ "MAXLEASE" => "",
+ "USEHOSTDCL" => "",
+ "BROADCAST" => "",
+ "ROUTERS" => "",
+ "DOMAINNAME" => "",
+ "DOMAINNAMESERVERS" => "",
+ "NEXTSERVER" => "",
+ "FILENAME" => "",
+ "SRVIDENT" => "",
+ "NTPSERVERS" => "",
+ "OPTGENERIC" => "",
+ "DHCPSVNOW" => "",
+ "DHCPSVNOWAU" => "",
+ "MNR" => $mnr,
+ "SBMNR" => $sbmnr,
+ "MCNR" => $mcnr));
+
+
+
+# DHCP Services
+$dhcpservices = get_dhcpoffers($auDN);
+#print_r($dhcpservices); echo "<br>";
+
+$template->assign(array("DHCPSVDN" => "",
+ "DHCPSVCN" => "",
+ "DHCPSVAU" => ""));
+if (count($dhcpservices) != 0){
+$template->define_dynamic("Dhcpservices", "Webseite");
+ foreach ($dhcpservices as $item){
+ $exp = ldap_explode_dn($item,1);
+
+ $template->assign(array("DHCPSVDN" => $item,
+ "DHCPSVCN" => $exp[0],
+ "DHCPSVAU" => $exp[2]));
+ $template->parse("DHCPSERVICES_LIST", ".Dhcpservices");
+ }
+}
+
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/no_dhcp.dwt b/ldap-site-mngmt/webinterface/dhcp/no_dhcp.dwt
new file mode 100644
index 00000000..5b8ffe4f
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/no_dhcp.dwt
@@ -0,0 +1,25 @@
+<table border='0' cellpadding='5' cellspacing='0' width='90%'>
+ <tr>
+ <td colspan='2'><h3>Modul - DHCP Management: </h3></td>
+ </tr>
+ <tr>
+ <td height='10'></td>
+ </tr>
+ <tr>
+ <td>
+ <p>Dieses Modul dient der Verwaltung des DHCP Dienstes und DHCP Subnetzen.<br>
+ <br>
+ <b>Sie verf&uuml;gen &uuml;ber keine kompletten Netzwerke!</b> <br>
+ x.x.x.0/24<br>
+ x.x.0.0/16<br>
+ x.0.0.0/8<br>
+ <br>
+ Sie k&ouml;nnen daher keine DHCP Dienst- bzw. DHCP Subnetz-Objekte anlegen. <br>
+ <br>
+ Jedoch k&ouml;nnen Sie ihre Rechner in DHCP Diensten (Subnetzen) anderer AUs
+ anmelden (Modul Rechner Management).
+
+ </td>
+ </tr>
+
+</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/no_dhcp.php b/ldap-site-mngmt/webinterface/dhcp/no_dhcp.php
new file mode 100644
index 00000000..57653255
--- /dev/null
+++ b/ldap-site-mngmt/webinterface/dhcp/no_dhcp.php
@@ -0,0 +1,27 @@
+<?php
+include('../standard_header.inc.php');
+
+# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
+$titel = "DHCP Management";
+# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
+$mainnr = 5;
+$mnr = 0;
+$sbmnr = -1;
+# 3. Dateiname und evtl. Pfad des Templates für die Webseite
+$webseite = "no_dhcp.dwt";
+
+include("../class.FastTemplate.php");
+
+include('dhcp_header.inc.php');
+
+###################################################################################
+
+# Menuleisten erstellen
+createMainMenu($rollen, $mainnr);
+createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
+
+###################################################################################
+
+include("dhcp_footer.inc.php");
+
+?> \ No newline at end of file