summaryrefslogtreecommitdiffstats
path: root/ldap-site-mngmt
diff options
context:
space:
mode:
authorLars Müller2008-03-01 19:04:26 +0100
committerLars Müller2008-03-01 19:04:26 +0100
commitcd46d68991f7ae0cf319f915c5fecdd71b78ee34 (patch)
treee9a48065f3203c8e16b14f82216452810d0f53ee /ldap-site-mngmt
parentOptimizations, improvements ... (diff)
downloadcore-cd46d68991f7ae0cf319f915c5fecdd71b78ee34.tar.gz
core-cd46d68991f7ae0cf319f915c5fecdd71b78ee34.tar.xz
core-cd46d68991f7ae0cf319f915c5fecdd71b78ee34.zip
Reorganisation of the repo structure as discussed on the devel list.
- Move the majority of trunk and all branches to the new openslx/ dir. - Move ldap-site-mngmt to contrib/. - Move openslx/trunk/os-plugins/plugins/vmchooser/src/ to openslx-src-tools/trunk/os-plugins/plugins/vmchooser/ git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@1591 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'ldap-site-mngmt')
-rw-r--r--ldap-site-mngmt/generation-scripts/dhcp_generate.pl410
-rwxr-xr-xldap-site-mngmt/generation-scripts/pxelink84
-rwxr-xr-xldap-site-mngmt/webinterface/au/au.dwt85
-rw-r--r--ldap-site-mngmt/webinterface/au/au.php26
-rw-r--r--ldap-site-mngmt/webinterface/au/au_change.php121
-rwxr-xr-xldap-site-mngmt/webinterface/au/au_childs.dwt46
-rw-r--r--ldap-site-mngmt/webinterface/au/au_childs.php50
-rw-r--r--ldap-site-mngmt/webinterface/au/au_footer.inc.php21
-rw-r--r--ldap-site-mngmt/webinterface/au/au_header.inc.php38
-rw-r--r--ldap-site-mngmt/webinterface/au/au_menu.php236
-rwxr-xr-xldap-site-mngmt/webinterface/au/au_show.dwt88
-rw-r--r--ldap-site-mngmt/webinterface/au/au_show.php70
-rwxr-xr-xldap-site-mngmt/webinterface/au/au_start.dwt31
-rwxr-xr-xldap-site-mngmt/webinterface/au/child_au.dwt131
-rw-r--r--ldap-site-mngmt/webinterface/au/child_au.php74
-rw-r--r--ldap-site-mngmt/webinterface/au/childau_add.php146
-rw-r--r--ldap-site-mngmt/webinterface/au/childau_change.php157
-rw-r--r--ldap-site-mngmt/webinterface/au/childau_delete.php34
-rw-r--r--ldap-site-mngmt/webinterface/au/dom_delete.php31
-rw-r--r--ldap-site-mngmt/webinterface/au/ip_deleg_change.php194
-rwxr-xr-xldap-site-mngmt/webinterface/au/menu.dwt29
-rwxr-xr-xldap-site-mngmt/webinterface/au/new_child.dwt123
-rw-r--r--ldap-site-mngmt/webinterface/au/new_child.php74
-rw-r--r--ldap-site-mngmt/webinterface/au/role_add.php53
-rw-r--r--ldap-site-mngmt/webinterface/au/role_delete.php57
-rw-r--r--ldap-site-mngmt/webinterface/au/role_show.dwt70
-rw-r--r--ldap-site-mngmt/webinterface/au/role_show.php114
-rw-r--r--ldap-site-mngmt/webinterface/au/roles.php24
-rw-r--r--ldap-site-mngmt/webinterface/au/roles_start.dwt41
-rw-r--r--ldap-site-mngmt/webinterface/class.FastTemplate.php768
-rw-r--r--ldap-site-mngmt/webinterface/common/ip_blocks.inc.php74
-rw-r--r--ldap-site-mngmt/webinterface/common/ipblocks.dwt11
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers.dwt85
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers.php23
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers_footer.inc.php19
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers_header.inc.php29
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers_menu.php250
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers_menu.save.php188
-rw-r--r--ldap-site-mngmt/webinterface/computers/computers_start.dwt42
-rw-r--r--ldap-site-mngmt/webinterface/computers/delete_confirm.php41
-rw-r--r--ldap-site-mngmt/webinterface/computers/dhcphost.dwt69
-rw-r--r--ldap-site-mngmt/webinterface/computers/dhcphost.php185
-rw-r--r--ldap-site-mngmt/webinterface/computers/dhcphost_change.php236
-rw-r--r--ldap-site-mngmt/webinterface/computers/group.dwt397
-rw-r--r--ldap-site-mngmt/webinterface/computers/group.php115
-rw-r--r--ldap-site-mngmt/webinterface/computers/group_add.php84
-rw-r--r--ldap-site-mngmt/webinterface/computers/group_change.php252
-rw-r--r--ldap-site-mngmt/webinterface/computers/group_delete.php47
-rw-r--r--ldap-site-mngmt/webinterface/computers/groupoverview.dwt38
-rw-r--r--ldap-site-mngmt/webinterface/computers/groupoverview.php59
-rw-r--r--ldap-site-mngmt/webinterface/computers/host.dwt126
-rw-r--r--ldap-site-mngmt/webinterface/computers/host.php92
-rw-r--r--ldap-site-mngmt/webinterface/computers/host_add.php103
-rw-r--r--ldap-site-mngmt/webinterface/computers/host_change.php427
-rw-r--r--ldap-site-mngmt/webinterface/computers/host_delete.php51
-rw-r--r--ldap-site-mngmt/webinterface/computers/hostoverview.dwt40
-rw-r--r--ldap-site-mngmt/webinterface/computers/hostoverview.php102
-rw-r--r--ldap-site-mngmt/webinterface/computers/hwhost.dwt74
-rw-r--r--ldap-site-mngmt/webinterface/computers/hwhost.php76
-rw-r--r--ldap-site-mngmt/webinterface/computers/hwhost_change.php116
-rw-r--r--ldap-site-mngmt/webinterface/computers/ip_rechner.dwt40
-rw-r--r--ldap-site-mngmt/webinterface/computers/ip_rechner.php76
-rw-r--r--ldap-site-mngmt/webinterface/computers/ip_rechner_change.php122
-rw-r--r--ldap-site-mngmt/webinterface/computers/machineconfig_default.dwt323
-rw-r--r--ldap-site-mngmt/webinterface/computers/machineconfig_default.php70
-rw-r--r--ldap-site-mngmt/webinterface/computers/mc_wochenplan.php154
-rw-r--r--ldap-site-mngmt/webinterface/computers/mcdef.dwt293
-rw-r--r--ldap-site-mngmt/webinterface/computers/mcdef.php132
-rw-r--r--ldap-site-mngmt/webinterface/computers/mcdef_add.php160
-rw-r--r--ldap-site-mngmt/webinterface/computers/mcdef_change.php402
-rw-r--r--ldap-site-mngmt/webinterface/computers/mcdef_copy.php111
-rw-r--r--ldap-site-mngmt/webinterface/computers/mcdef_delete.php40
-rw-r--r--ldap-site-mngmt/webinterface/computers/menu.dwt32
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuentry.dwt249
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuentry.php165
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuentry_add.php263
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuentry_change.php208
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuentry_delete.php41
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuposition_down.php42
-rw-r--r--ldap-site-mngmt/webinterface/computers/menuposition_up.php40
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_group.dwt101
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_group.php71
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_host.dwt112
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_host.php58
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_mcdef.dwt184
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_mcdef.php69
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_menuentry.dwt191
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_menuentry.php145
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_pxe.dwt165
-rw-r--r--ldap-site-mngmt/webinterface/computers/new_pxe.php115
-rw-r--r--ldap-site-mngmt/webinterface/computers/no_ip.dwt11
-rw-r--r--ldap-site-mngmt/webinterface/computers/no_ip.php28
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe.dwt171
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe.php129
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_add.php228
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_bootmenue.dwt176
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_bootmenue.php151
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_change.php348
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_copy.php182
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_delete.php42
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_globals.dwt128
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_globals.php96
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_globals_change.php126
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxe_wochenplan.php262
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxeconfigs.dwt318
-rw-r--r--ldap-site-mngmt/webinterface/computers/pxeconfigs.php92
-rw-r--r--ldap-site-mngmt/webinterface/computers/rbshost.dwt385
-rw-r--r--ldap-site-mngmt/webinterface/computers/rbshost.php250
-rw-r--r--ldap-site-mngmt/webinterface/computers/rbshost_change.php98
-rw-r--r--ldap-site-mngmt/webinterface/computers/showpxe.dwt57
-rw-r--r--ldap-site-mngmt/webinterface/computers/showpxe.php89
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/delete_confirm.php39
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp.dwt85
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp.php24
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_footer.inc.php19
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_header.inc.php29
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_menu.php215
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcp_start.dwt32
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpnopool.dwt53
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpnopool.php128
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcppool.dwt123
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcppool.php166
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcppool_add.php106
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcppool_new.dwt49
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcppool_new.php201
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcppools_change.php336
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt262
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice.php182
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice_add.php70
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice_change.php229
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpservice_delete.php37
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.dwt219
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.php125
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_add.php76
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_change.php294
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_delete.php36
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.dwt36
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.php89
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/menu.dwt32
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.dwt151
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.php75
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.dwt144
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.php109
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/no_dhcp.dwt27
-rw-r--r--ldap-site-mngmt/webinterface/dhcp/no_dhcp.php23
-rw-r--r--ldap-site-mngmt/webinterface/dns/dns.dwt76
-rw-r--r--ldap-site-mngmt/webinterface/dns/dns.php21
-rw-r--r--ldap-site-mngmt/webinterface/dns/dns_footer.inc.php18
-rw-r--r--ldap-site-mngmt/webinterface/dns/dns_header.inc.php27
-rwxr-xr-xldap-site-mngmt/webinterface/dns/dns_inwork.dwt15
-rw-r--r--ldap-site-mngmt/webinterface/dns/dns_menu.php73
-rw-r--r--ldap-site-mngmt/webinterface/dns/dns_start.dwt30
-rw-r--r--ldap-site-mngmt/webinterface/dns/menu.dwt22
-rw-r--r--ldap-site-mngmt/webinterface/hauptmenue.dwt16
-rw-r--r--ldap-site-mngmt/webinterface/home.dwt72
-rw-r--r--ldap-site-mngmt/webinterface/index.dwt27
-rw-r--r--ldap-site-mngmt/webinterface/index.php46
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip.dwt88
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip.php22
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_blocks.inc.php68
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_deleg.dwt40
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_deleg.php102
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_deleg_change.php194
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_dhcp.dwt39
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_dhcp.php54
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_dhcp_change.php146
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_footer.inc.php19
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_header.inc.php31
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_menu.php82
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_rechner.dwt40
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_rechner.php79
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_rechner_change.php122
-rw-r--r--ldap-site-mngmt/webinterface/ip/ip_start.dwt36
-rw-r--r--ldap-site-mngmt/webinterface/ip/ipblocks.dwt11
-rw-r--r--ldap-site-mngmt/webinterface/ip/menu.dwt22
-rw-r--r--ldap-site-mngmt/webinterface/ip/no_ip.dwt11
-rw-r--r--ldap-site-mngmt/webinterface/ip/no_ip.php26
-rw-r--r--ldap-site-mngmt/webinterface/lib/au_management_functions.php1333
-rw-r--r--ldap-site-mngmt/webinterface/lib/commonlib.inc.php554
-rw-r--r--ldap-site-mngmt/webinterface/lib/config.inc.php36
-rw-r--r--ldap-site-mngmt/webinterface/lib/dhcp_management_functions.php727
-rw-r--r--ldap-site-mngmt/webinterface/lib/host_management_functions.php474
-rw-r--r--ldap-site-mngmt/webinterface/lib/ip_management_functions.php1553
-rw-r--r--ldap-site-mngmt/webinterface/lib/ldap.inc.php1117
-rw-r--r--ldap-site-mngmt/webinterface/lib/ldap2.inc.php350
-rw-r--r--ldap-site-mngmt/webinterface/lib/rbs_management_functions.php685
-rw-r--r--ldap-site-mngmt/webinterface/lib/syntax_check.php302
-rw-r--r--ldap-site-mngmt/webinterface/login_form.inc.html29
-rw-r--r--ldap-site-mngmt/webinterface/login_sicher.php365
-rw-r--r--ldap-site-mngmt/webinterface/logout_form.inc.dwt9
-rw-r--r--ldap-site-mngmt/webinterface/pics/arrow.pngbin866 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/branch.gifbin70 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/branch2.gifbin77 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/branchbottom.gifbin72 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/branchbottom2.gifbin72 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/branchtop.gifbin67 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/down.gifbin164 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/down2.gifbin132 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/folder-expanded.gifbin923 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/folder.gifbin922 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/header.pngbin25739 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/header1.pngbin6433 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/headerlayer.xcfbin44417 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/host.pngbin816 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/host1.pngbin802 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/hostfaulty.pngbin712 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/hostfaulty1.pngbin696 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/hostnoboot.pngbin805 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/hostnoboot1.pngbin792 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/line.gifbin63 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/line2.gifbin851 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/linebottom.gifbin58 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/minus.gifbin91 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/minus2.gifbin921 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/minusbottom.gifbin90 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/minustop.gifbin88 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/plus.gifbin94 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/plus2.gifbin890 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/plusbottom.gifbin93 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/plustop.gifbin93 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/up.gifbin162 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/pics/up2.gifbin151 -> 0 bytes
-rw-r--r--ldap-site-mngmt/webinterface/rbs/delete_confirm.php90
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm.dwt189
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm.php134
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm_add.php68
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm_change.php236
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm_delete.php40
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm_overview.dwt29
-rw-r--r--ldap-site-mngmt/webinterface/rbs/gbm_overview.php59
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menu.dwt31
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuentry.dwt247
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuentry.php153
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuentry_add.php258
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuentry_change.php207
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuentry_delete.php41
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuposition_down.php41
-rw-r--r--ldap-site-mngmt/webinterface/rbs/menuposition_up.php39
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_gbm.dwt91
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_gbm.php59
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_menuentry.dwt188
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_menuentry.php161
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_pxe.dwt144
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_pxe.php72
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_rbservice.dwt117
-rw-r--r--ldap-site-mngmt/webinterface/rbs/new_rbservice.php94
-rw-r--r--ldap-site-mngmt/webinterface/rbs/no_rbservice.dwt22
-rw-r--r--ldap-site-mngmt/webinterface/rbs/no_rbservice.php27
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe.dwt461
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe.php219
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe_add.php118
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe_change.php434
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe_copy.php189
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe_delete.php42
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxe_wochenplan.php154
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxeconfig_default.dwt323
-rw-r--r--ldap-site-mngmt/webinterface/rbs/pxeconfig_default.php77
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbs.dwt76
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbs.php25
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbs_footer.inc.php18
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbs_header.inc.php27
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbs_menu.php194
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbs_start.dwt41
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbservice.dwt228
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbservice.php152
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbservice_add.php141
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbservice_change.php394
-rw-r--r--ldap-site-mngmt/webinterface/rbs/rbservice_delete.php41
-rw-r--r--ldap-site-mngmt/webinterface/roles/menu.dwt22
-rw-r--r--ldap-site-mngmt/webinterface/roles/role_add.php53
-rw-r--r--ldap-site-mngmt/webinterface/roles/role_delete.php57
-rw-r--r--ldap-site-mngmt/webinterface/roles/role_show.dwt70
-rw-r--r--ldap-site-mngmt/webinterface/roles/role_show.php123
-rw-r--r--ldap-site-mngmt/webinterface/roles/roles.dwt79
-rw-r--r--ldap-site-mngmt/webinterface/roles/roles.php30
-rw-r--r--ldap-site-mngmt/webinterface/roles/roles_footer.inc.php18
-rw-r--r--ldap-site-mngmt/webinterface/roles/roles_header.inc.php19
-rw-r--r--ldap-site-mngmt/webinterface/roles/roles_menu.php95
-rw-r--r--ldap-site-mngmt/webinterface/roles/roles_start.dwt37
-rw-r--r--ldap-site-mngmt/webinterface/standard_footer.inc.php19
-rw-r--r--ldap-site-mngmt/webinterface/standard_header.inc.php86
-rw-r--r--ldap-site-mngmt/webinterface/start.dwt57
-rw-r--r--ldap-site-mngmt/webinterface/start.php83
-rw-r--r--ldap-site-mngmt/webinterface/styles.css369
-rw-r--r--ldap-site-mngmt/webinterface/syntax_check.php304
-rw-r--r--ldap-site-mngmt/webinterface/zwischen.php16
286 files changed, 0 insertions, 35176 deletions
diff --git a/ldap-site-mngmt/generation-scripts/dhcp_generate.pl b/ldap-site-mngmt/generation-scripts/dhcp_generate.pl
deleted file mode 100644
index 5623cc96..00000000
--- a/ldap-site-mngmt/generation-scripts/dhcp_generate.pl
+++ /dev/null
@@ -1,410 +0,0 @@
-#!/usr/bin/perl
-
-# Generate ISC DHCP Configuration File
-#
-# Reads DHCP Config Data form LDAP Directory and generates an
-# include file "dhcp.master.inc" included in dhcpd.conf with:
-# - Definitions of User-defined DHCP Options
-# - DHCP Service Global Options
-# - DHCP Subnet Declarations, Options and Dynamic Pools
-# - DHCP Host Declarations and Options
-
-
-use strict;
-use warnings;
-#use diagnostics;
-
-#use LSM::dhcpgen;
-use Net::LDAP;
-use Net::LDAP::LDIF;
-use Getopt::Std;
-
-#$Getopt::Std::STANDARD_HELP_VERSION;
-our $VERSION = "1.10";
-
-
-# Configuration Variables for Perl-Script
-our ( $ldaphost, $basedn, $userdn, $passwd, $dhcpdn, $dhcpdconfpath, $dhcpdconffile, $opt_a, $opt_h, $opt_v );
-# Read Configuration Variables ...
-require "dhcpgen.conf.pl";
-
-my ( $ldap, $mesg, $failoverpeer, @searchbases );
-
-#use LSM::dhcpgen;
-my $acteptime = time();
-my $acttime = localtime();
-getopts('ahv');
-
-
-if ($opt_h){ print "HILFE Text\n"; exit (1); }
-if ($opt_a){ print "Generate all Include Files:\n\n";}
-
-
-# Bind with LDAP Server
-$ldap = Net::LDAP->new( $ldaphost, debug => 0 ) or die "$@";
-$mesg = $ldap->bind( $userdn, password => $passwd );
-$mesg->code && die $mesg->error;
-
-my @dhcpunits = get_dhcpunits();
-@searchbases = searchbases($acteptime);
-#print @searchbases;
-
-mkdir "$dhcpdconfpath/includes";
-
-
-#################################################
-# DHCP MASTER INCLUDE FILE
-my $writemaster;
-my @dhcpdnarray = split /,/,$dhcpdn;
-my $aurdn = $dhcpdnarray[2];
-my @auarray = split /=/,$aurdn;
-my $au = $auarray[1];
-my $srvrdn = $dhcpdnarray[0];
-my @srvarray = split /=/,$srvrdn;
-my $srv = $srvarray[1];
-
-# File Header
-$writemaster .= "# DHCP Config Master Include File \"dhcp.master.inc\"\n# DHCP Service: $srv\n# AU: $au\n# (DN: $dhcpdn)\n# generated: $acttime\n# Unix: $acteptime\n\n";
-
-# LDAP Search: DHCP Service Object
-my $dhcpsrventry = get_dhcpservice_object($ldap,$dhcpdn);
-
-# Definitions for user/self-defined DHCP Options
-$writemaster .= "\n######################\n# Option Definitions\n######################\n\n";
-if ($dhcpsrventry->exists('OptionDefinition')) {
- my @optdefinitions = $dhcpsrventry->get_value('OptionDefinition');
- foreach my $optdef (@optdefinitions) {
- $writemaster .= "$optdef\n";
- }
-}
-
-# Failover Information of DHCP Service, needed for DHCP Pool Declarations later
-#my $failoverpeer;
-if ($dhcpsrventry->exists( 'dhcpFailoverPeer' )) {
- $failoverpeer = $dhcpsrventry->get_value( 'dhcpFailoverPeer' );
-}
-
-# Global DHCP Options (global Scope)
-$writemaster .= "\n\n######################\n# Global Options\n######################\n\n";
-my $indent = "";
-$writemaster .= dhcpoptions( $dhcpsrventry, $indent );
-
-# Include Directives (one for each DHCP Unit in LDAP Database)
-$writemaster .= "\n\n######################\n# Includes\n######################\n\n";
-foreach my $dhcpunit ( @dhcpunits ){
- $writemaster .= "include \"$dhcpdconfpath/includes/dhcp.".lc $dhcpunit->get_value('ou').".inc\";\n";
- #$writemaster .= "include \"includes/dhcp.".lc $dhcpunit->get_value('ou').".inc\";\n";
-}
-
-# Write File
-print "Generate DHCP Master Include File\n";
-open DATEI, "> $dhcpdconfpath/includes/dhcp.master.inc";
-print DATEI $writemaster;
-close DATEI;
-# Writing DHCP MASTER INCLUDE FILE Completed
-#################################################
-
-
-#################################################
-# DHCP INCLUDE FILES, one for each AdministrativeUnit
-foreach my $searchbase ( @searchbases ){
-
- my $writeinc;
- my $lastchange;
- my $includedatei = lc "dhcp.$searchbase->{ou}.inc";
- my $audn = $searchbase->{dn};
- my $dhcpmtime = $searchbase->{dhcpmtime};
- #print "$includedatei\n";
- #print "$audn\n";
-
- # Include File Header
- $writeinc .= "# DHCP Config Include File \"$includedatei\"\n# AU: $searchbase->{ou}\n# (DN: $audn)\n# generated: $acttime\n# Unix: $acteptime\n\n";
-
- ###########################
- # DHCP SUBNETS (and POOLS)
- # LDAP Search: DHCP Subnet Objects referencing to DHCP Service Object
- my @subnets = get_dhcpsubnet_objects($ldap,$audn,$dhcpdn);
- # write Subnet declarations
- $writeinc .= "\n\n######################\n# DHCP Subnets\n######################\n\n";
- foreach my $subnetentry ( @subnets ) {
- $writeinc .= dhcpsubnet($subnetentry);
- }
-
- ###########################
- # DHCP HOSTS
- # LDAP Search: DHCP Host Objects referencing to DHCP Service Object
- my @hosts = get_dhcphost_objects($ldap,$audn,$dhcpdn);
- # write Host Declarations
- $writeinc .= "\n\n######################\n# DHCP Hosts\n######################\n";
- foreach my $hostentry ( @hosts ) {
- $writeinc .= dhcphost($hostentry);
- }
-
- # Write File
- if ($dhcpmtime == 0){ $lastchange = "not changed yet!"; }
- else{ $lastchange = "last change: ".localtime($dhcpmtime); }
- print "Generate Include-File $includedatei ($lastchange)\n";
- open DATEI, "> $dhcpdconfpath/includes/$includedatei";
- print DATEI $writeinc;
- close DATEI;
-}
-# Writing DHCP INCLUDE FILES Completed
-#######################################
-
-
-# LDAP unbind
-$mesg = $ldap->unbind;
-
-
-exit (0);
-
-
-
-###################################################################################################
-# Subroutines
-###############
-
-# write DHCP Options, Parameter: DHCP Object LDAP Entry
-sub dhcpoptions {
- my $entry = shift;
- my $indent = shift;
- my @atts = $entry->attributes;
- my $output = "";
-
- # DHCP Option beginning with with 'option'
- my @options1 = grep /dhcpopt/, @atts;
- #printf "options: @options1\n";
- foreach my $option ( @options1 ){
- if ( $option ne "dhcpoptNetmask" ){
- my $value = $entry->get_value( $option );
- $option =~ s/dhcpopt//;
- if ( $option eq "Domain-name"){
- $output .= $indent."option ".lc($option)." \"$value\";\n";
- }else{
- $output .= $indent."option ".lc($option)." $value;\n";
- }
- }
- }
- # DHCP Options without 'option'
- my @options2 = grep /dhcpOpt/, @atts;
- #printf "Options: @options2\n";
- foreach my $option ( @options2 ){
- if ( $option ne "dhcpOptFixed-address" ){
- my $value = $entry->get_value( $option );
- $option =~ s/dhcpOpt//;
- if ( $option eq "Filename"){
- $output .= $indent.lc($option)." \"$value\";\n";
- }else{
- $output .= $indent.lc($option)." $value;\n";
- }
- }
- }
-
- return $output;
-}
-
-
-# write DHCP Pool declaration (+ specific Options), Parameter: DHCP Object LDAP Entry
-sub dhcppool {
- my $entry = shift;
- my $indent = shift;
- my @atts = $entry->attributes;
- my $output = "";
- # open Pool Declaration
- $output .= $indent."pool {\n";
- # write DHCP Options in Pool Scope
- my $poolindent = $indent." ";
- if ( $failoverpeer ){
- $output .= $poolindent."failover peer \"$failoverpeer\";\n";
- $output .= $poolindent."deny dynamic bootp clients;\n";
- }
- if ($entry->exists( 'dhcpRange' )) {
- #foreach my $ranges ( @) {
- my @range = split /_/,$entry->get_value( 'dhcpRange' );
- $output .= $poolindent."range $range[0] $range[1];\n";
- }
- $output .= dhcpoptions($entry,$poolindent);
- # close Pool Declaration
- $output .= "$indent}\n";
-
- return $output;
-}
-
-
-# write DHCP Subnet declaration (specific Options), Parameter: DHCP Object LDAP Entry
-sub dhcpsubnet {
- my $entry = shift;
- my @atts = $entry->attributes;
- my $output = "";
-
- my $subnetdn = $entry->dn;
- my $subnet = $entry->get_value( 'cn' );
- my $netmask = $entry->get_value( 'dhcpoptnetmask' );
- # open Subnet Declaration
- $output .= "subnet $subnet netmask $netmask {\n";
- # write DHCP Options in Subnet Scope
- my $optindent = " ";
- $output .= dhcpoptions($entry,$optindent);
- # write Pool Declarations in Subnet Declaration
- # ldapsearch on Pool Objects referencing to DHCP Subnet Object
- $mesg = $ldap->search(base=>$basedn,
- scope => 'sub',
- filter => '(&(objectclass=dhcpPool)(dhcphlpcont:dn:='.$subnetdn.'))');
- #Net::LDAP::LDIF->new( \*STDOUT,"w" )->write( $mesg->entries );
- $mesg->code && die $mesg->error;
- my @pools = $mesg->sorted('cn');
- foreach my $poolentry ( @pools ) {
- $output .= dhcppool($poolentry,$optindent);
- }
- # close Subnet Declaration
- $output .= "}\n\n";
-
- return $output;
-}
-
-
-# write DHCP Host declaration (specific Options), Parameter: DHCP Object LDAP Entry
-sub dhcphost {
- my $entry = shift;
- my @atts = $entry->attributes;
- my $output = "";
-
- $output .= "\nhost ".lc $entry->get_value('hostname')." {\n";
- #printf DATEI "\nhost %s {\n", lc $entry->get_value( 'hostname' );
- # Host specific DHCP Options
- if ($entry->exists('hwaddress')) {
- $output .= " hardware ethernet ".$entry->get_value('hwaddress').";\n";
- }
- if ($entry->exists('dhcpoptfixed-address')) {
- if ( $entry->get_value('dhcpoptfixed-address') eq "ip" ){
- my @ip = split /_/, $entry->get_value('ipaddress');
- $output .= " fixed-address ".lc $ip[0].";\n";
- }
- if ( $entry->get_value('dhcpoptfixed-address') eq "hostname" ){
- $output .= " fixed-address ".lc $entry->get_value('hostname').".".lc $entry->get_value('domainname').";\n";
- }
- }
- my @hwoptions = grep /Hw-/, @atts;
- foreach my $hwoption ( @hwoptions ){
- $output .= " option ".lc($hwoption)." \"".$entry->get_value($hwoption)."\";\n";
- }
- # remaining DHCP Options
- my $optindent = " ";
- $output .= dhcpoptions ($entry, $optindent);
- $output .= "}\n";
-
- return $output;
-}
-
-sub get_dhcpservice_object {
- my $ldap = shift;
- my $basedn = shift;
- # Ldapsearch on DHCP Service Object
-
- my $mesg = $ldap->search(base => $basedn,
- scope => 'base',
- filter => '(objectclass=dhcpService)');
- #Net::LDAP::LDIF->new( \*STDOUT,"w" )->write( $mesg->entries );
- $mesg->code && die $mesg->error;
- my $dhcpservice = $mesg->count or die "DHCP Service Object does not exist in the System";
- my $dhcpsrventry = $mesg->entry(0);
-
- return $dhcpsrventry;
-}
-
-# all Subnet Objects of one AU Container
-sub get_dhcpsubnet_objects {
- my $ldap = shift;
- my $audn = shift;
- my $dhcpdn = shift;
-
- # ldapsearch on Subnet Objects referencing to DHCP Service Object
- $mesg = $ldap->search(base=>"cn=dhcp,".$audn,
- scope => 'sub',
- filter => '(&(objectclass=dhcpSubnet)(dhcphlpcont:dn:='.$dhcpdn.'))');
- #Net::LDAP::LDIF->new( \*STDOUT,"w" )->write( $mesg->entries );
- $mesg->code && die $mesg->error;
- my @dhcpsubnets = $mesg->sorted('cn');
-
- return @dhcpsubnets;
-}
-
-# all Host Objects of one AU Container
-sub get_dhcphost_objects {
- my $ldap = shift;
- my $audn = shift;
- my $dhcpdn = shift;
-
- # ldapsearch on DHCP Host Objects referencing to DHCP Service Object
- $mesg = $ldap->search(base=>"cn=computers,".$audn,
- scope => 'sub',
- filter => '(&(objectclass=dhcpHost)(dhcphlpcont:dn:='.$dhcpdn.'))');
- #Net::LDAP::LDIF->new( \*STDOUT,"w" )->write( $mesg->entries );
- $mesg->code && die $mesg->error;
- my @dhcphosts = $mesg->sorted('dn');
-
- return @dhcphosts;
-}
-
-# all AU containers
-sub get_dhcpunits {
- #my $ldap = shift;
- #my $basedn = shift;
-
- # ldapsearch on Subnet Objects referencing to DHCP Service Object
- $mesg = $ldap->search(base=>$basedn,
- scope => 'sub',
- filter => '(objectclass=administrativeUnit)',
- #filter => '(&(objectclass=administrativeUnit)(dhcpMTime>='.$yday.'))',
- attrs => [ 'ou','dhcpMTime' ] );
- #Net::LDAP::LDIF->new( \*STDOUT,"w" )->write( $mesg->entries );
- $mesg->code && die $mesg->error;
- my @adminunits = $mesg->entries;
-
- return @adminunits;
-}
-
-
-# Generate Searchbases-Array for AdminUnit-specific LDAP Search on DHCP Objects
-sub searchbases {
- my $acteptime = shift; ### falls noch plausibiltäts-test: acteptime > dhcpmtime
- my $opta = $opt_a;
- #print "opt_a: $opta \n";
- my @adunits = get_dhcpunits();
- if ( $opta ){
- # All Admin Units
- foreach my $adunit (@adunits){
- push @searchbases, { dn => $adunit->dn, ou => $adunit->get_value('ou'), dhcpmtime => $adunit->get_value('dhcpMTime') };
- }
- }else{
- # Only Admin Units which DHCP Data changed since last generation
- foreach my $adunit (@adunits){
- my $changetime = "1";
- my $dhandle = 1;
- open DAT, "< $dhcpdconfpath/includes/dhcp.".lc $adunit->get_value('ou').".inc" #or open DAT and my $incgen = 1; #or die "Can't open/generate Include File";
- #print $incgen;
- or $dhandle = 0;
- if ($dhandle){
- while (<DAT>){
- chomp;
- if (/^# Unix: (\S+)/){ $changetime = $1; }
- }
- close DAT;
- }
- my $actualize = "";
- if ($adunit->exists( 'dhcpMTime' ) && $adunit->get_value('dhcpMTime') >= $changetime ) {
- #printf "%s - %s\n", $adunit->dn, $adunit->get_value('dhcpMTime');
- $actualize = "needs to be actualized\n";
- push @searchbases, { dn => $adunit->dn, ou => $adunit->get_value('ou'), dhcpmtime => $adunit->get_value('dhcpMTime') };
- }
- if ($opt_v){
- print $adunit->get_value('ou')."\n";
- print "dhcpmodify: ".$adunit->get_value('dhcpMTime')."\n";
- print "lastchange: $changetime\n";
- print $actualize;
- print "------------------------\n";
- }
- }
- }
- return @searchbases;
-} \ No newline at end of file
diff --git a/ldap-site-mngmt/generation-scripts/pxelink b/ldap-site-mngmt/generation-scripts/pxelink
deleted file mode 100755
index 7e9df8af..00000000
--- a/ldap-site-mngmt/generation-scripts/pxelink
+++ /dev/null
@@ -1,84 +0,0 @@
-#!/bin/sh
-# the pxe-linking skript should be executed every new hour
-# crontab entry: 0 * * * * root <absolute-path>/pxelink.sh
-
-pxedir='tftpboot/pxe/pxelinux.cfg/'
-cd $pxedir
-# delete all symbolic links (they are obsolete)
-rm 01-*
-if [ -e default ] ; then rm default ; fi
-
-# get actual time parameters (weekday and hour)
-datum=`date +%a:%-k |sed 's/[a-z]/\U&/g'`
-wday=`echo $datum | cut -d ":" -f 1`
-time=`echo $datum | cut -d ":" -f 2`
-echo "actual time: " $wday $time
-
-# get all PXE files (unique) under <timerange>/<pxefile>
-pxenumber=`find -type f | cut -d "/" -f 3 | sort | sed '$!N; /^\(.*\)
- \n\1$/!P; D' | wc -l`
-pxe=`find -type f | cut -d "/" -f 3 | sort | sed '$!N; /^\(.*\)\n\1$
- /!P; D' `
-for ((j=0;j<$pxenumber;j++)) ; do
- pxe_array[$j]=`echo $pxe | cut -d " " -f $[$j+1] `
- echo "pxe file: " ${pxe_array[j]}
- lines=`find */${pxe_array[j]} | cut -d "/" -f 1 | wc -l`
- ranges=`find */${pxe_array[j]} | cut -d "/" -f 1`
- for ((i=0;i<$lines;i++)) ; do
- timerange[$i]=`echo $ranges | cut -d " " -f $[$i+1] `
- #echo ${timerange[i]}
- done
- match=0
-
- # get timerange corresponding to actual time parameters
- while true; do
- for ((i=0;i<$lines;i++)) ; do
- trday=`echo ${timerange[i]} | cut -d "_" -f 1`
- trbegin=`echo ${timerange[i]} | cut -d "_" -f 2`
- trend=`echo ${timerange[i]} | cut -d "_" -f 3`
- if [ $trday != "X" ] && [ $trbegin != "X" ] && [ $trday == $wday ] \
- && [ $trbegin -le $time ] && [ $time -le $trend ]; then
- echo $wday $time "[D H H]match ->" ${timerange[i]}
- ln -s ${timerange[i]}'/'${pxe_array[j]} ${pxe_array[j]}
- echo "symlink: " ${pxe_array[j]} "->" ${timerange[i]}"/"${pxe_array[j]}
- match=1 && break
- fi
- done
- if [ $match == 1 ] ; then break ; fi
-
- for ((i=0;i<$lines;i++)) ; do
- trday=`echo ${timerange[i]} | cut -d "_" -f 1`
- trbegin=`echo ${timerange[i]} | cut -d "_" -f 2`
- trend=`echo ${timerange[i]} | cut -d "_" -f 3`
- if [ $trday == $wday ] && [ $trbegin == "X" ] && [ $trend == "X" ]; then
- echo $wday $time "[D _ _]match ->" ${timerange[i]}
- ln -s ${timerange[i]}"/"${pxe_array[j]} ${pxe_array[j]}
- echo "symlink: " ${pxe_array[j]} "->" ${timerange[i]}"/"${pxe_array[j]}
- match=1 && break
- fi
- done
- if [ $match == 1 ] ; then break ; fi
-
- for ((i=0;i<$lines;i++)) ; do
- trday=`echo ${timerange[i]} | cut -d "_" -f 1`
- trbegin=`echo ${timerange[i]} | cut -d "_" -f 2`
- trend=`echo ${timerange[i]} | cut -d "_" -f 3`
- if [ $trday == "X" ] && [ $trbegin != "X" ] && [ $trend != "X" ] && \
- [ $trbegin -le $time ] && [ $time -le $trend ]; then
- echo $wday $time "[_ H H]match ->" ${timerange[i]}
- ln -s ${timerange[i]}"/"${pxe_array[j]} ${pxe_array[j]}
- echo "symlink: " ${pxe_array[j]} "->" ${timerange[i]}"/"${pxe_array[j]}
- match=1 && break
- else
- if [ ${timerange[i]} == "X_X_X" ]; then
- echo $wday $time "[_ _ _]match ->" ${timerange[i]}
- ln -s ${timerange[i]}"/"${pxe_array[j]} ${pxe_array[j]}
- echo "symlink: " ${pxe_array[j]} "->" ${timerange[i]}"/"${pxe_array[j]}
- fi
- match=1
- fi
- done
- if [ $match == 1 ] ; then break ; fi
- done
-done
-exit 0
diff --git a/ldap-site-mngmt/webinterface/au/au.dwt b/ldap-site-mngmt/webinterface/au/au.dwt
deleted file mode 100755
index 16f0302c..00000000
--- a/ldap-site-mngmt/webinterface/au/au.dwt
+++ /dev/null
@@ -1,85 +0,0 @@
-<html>
-
-<head>
- <title>{SEITENTITEL}</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'></head>
-<body>
-
-<table cellpadding='0' cellspacing='0' border='0' width='100%' style='background-color: #F0F0F0;border-color: #505050; border-style: solid; border-width: 0 0 1 0;'>
- <tr>
- <td width='30%'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr valign='top'>
- <td width='1'></td>
- <td><h2>Client / IP Management</h2></td>
- </tr>
- </table>
- </td>
-
- <td width='45%'>
- <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.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>
- <tr>
- <td colspan='3'>{MAINMENU}</td>
- </tr>
-</table>
-
-<!--<hr align='center' width='98%' noshade>-->
-<br>
-
-
-<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>
- <tr>
- <td>
-
- {IPBLOCKS}
-
- </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/au/au.php b/ldap-site-mngmt/webinterface/au/au.php
deleted file mode 100644
index c66784b1..00000000
--- a/ldap-site-mngmt/webinterface/au/au.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Filename of Template
-$webseite = "au_start.dwt";
-
-include('au_header.inc.php');
-
-###############################################################################
-# Menus
-
-$mnr = 0;
-$sbmnr = -1;
-
-$childauDN = $_GET['dn'];
-
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###############################################################################
-# Footer
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_change.php b/ldap-site-mngmt/webinterface/au/au_change.php
deleted file mode 100644
index 990d2155..00000000
--- a/ldap-site-mngmt/webinterface/au/au_change.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# $_POST form variables
-$cn = $_POST['commonname'];
-$oldcn = $_POST['oldcn'];
-$description = $_POST['description'];
-$olddesc = $_POST['olddesc'];
-
-$cn = htmlentities($cn);
-$oldcn = htmlentities($oldcn);
-$description = htmlentities($description);
-$olddesc = htmlentities($olddesc);
-
-#echo "new cn:"; print_r($cn); echo "<br>";
-#echo "old cn:"; print_r($oldcn); echo "<br>";
-#echo "new desc:"; print_r($description); echo "<br>";
-#echo "old desc:"; print_r($olddesc); echo "<br><br>";
-
-$url = 'au_show.php';
-
-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>";
-
-if ( $oldcn == "" && $cn != "" ){
- echo "CN neu anlegen<br>";
- # hier noch Syntaxcheck
- $entry['cn'] = $cn;
- $result = ldap_mod_add($ds,$auDN,$entry);
- if($result){
- $mesg = "AU Name erfolgreich eingetragen<br><br>";
- }
- else{
- $mesg = "Fehler beim eintragen des AU Namen<br><br>";
- }
-}
-
-if ( $oldcn != "" && $cn != "" && $oldcn != $cn ){
- echo "CN aendern<br>";
- # hier noch Syntaxcheck
- $entry['cn'] = $cn;
- $result = ldap_mod_replace($ds,$auDN,$entry);
- if($result){
- $mesg = "AU Name erfolgreich geaendert<br><br>";
- }
- else{
- $mesg = "Fehler beim aendern des AU Namen<br><br>";
- }
-}
-
-if ( $oldcn != "" && $cn == "" ){
- echo "CN loeschen<br>";
- # hier noch Syntaxcheck
- $entry['cn'] = $oldcn;
- $result = ldap_mod_del($ds,$auDN,$entry);
- if($result){
- $mesg = "AU Name erfolgreich geloescht<br><br>";
- }
- else{
- $mesg = "Fehler beim loeschen des AU Namen<br><br>";
- }
-}
-
-if ( $olddesc == "" && $description != "" ){
- echo "DESCR neu anlegen<br>";
- # hier noch Syntaxcheck
- $entry2['description'] = $description;
- $result = ldap_mod_add($ds,$auDN,$entry2);
- if($result){
- $mesg = "AU Beschreibung erfolgreich eingetragen<br><br>";
- }
- else{
- $mesg = "Fehler beim eintragen der AU Beschreibung<br><br>";
- }
-}
-
-if ( $olddesc != "" && $description != "" && $olddesc != $description ){
- echo "DESCR aendern<br>";
- # hier noch Syntaxcheck
- $entry2['description'] = $description;
- $result = ldap_mod_replace($ds,$auDN,$entry2);
- if($result){
- $mesg = "AU Beschreibung erfolgreich geandert<br><br>";
- }
- else{
- $mesg = "Fehler beim aendern der AU Beschreibung<br><br>";
- }
-}
-
-if ( $olddesc != "" && $description == "" ){
- echo "DESCR loeschen<br>";
- # hier noch Syntaxcheck
- $entry2['description'] = $olddesc;
- $result = ldap_mod_del($ds,$auDN,$entry2);
- if($result){
- $mesg = "AU Beschreibung erfolgreich geloescht<br><br>";
- }
- else{
- $mesg = "Fehler beim loeschen der AU Beschreibung<br><br>";
- }
-}
-
-else{
- $mesg = "keine Aenderung<br>";
-}
-
-$mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='au_show.php' style='publink'>back</a>";
-redirect(2, $url, $mesg, $addSessionId = TRUE);
-
-echo "</td></tr></table></body></html>";
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_childs.dwt b/ldap-site-mngmt/webinterface/au/au_childs.dwt
deleted file mode 100755
index 0d37b5c7..00000000
--- a/ldap-site-mngmt/webinterface/au/au_childs.dwt
+++ /dev/null
@@ -1,46 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Untergeordnete AUs von - &nbsp;<code class='font_object'>{AU}</code></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='55%' class='tab_h'><b>Untergeordnete AU</b></td>
- <td width='45%' class='tab_h'><b>Domain</b></td>
- </tr>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Childaus -->
- <tr>
- <td class='tab_d' height='40'>{CHILDOU} &nbsp;</td>
- <td class='tab_d' height='40'>{CHILDDOMAIN} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Childaus -->
-
- </table></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- Zum Verwalten oder L&ouml;schen einer untergeordneten AU, w&auml;hlen Sie links entsprechenden Submen&uuml;-Eintrag.<br>
- Dort k&ouml;nnen Sie auch den DNS Domainnamen der untergeordneten AU bearbeiten bzw. neu zuordnen (d.h. im <br>
- DNS der Organisation aufnehmen).
- </td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Neue untergeordnete AU anlegen</h4> >>
- <a href='new_child.php?sbmnr=0' style='color:#FFFFFF;' class='small_loginform_button'>&nbsp; zur Eingabemaske &nbsp;</a>
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_childs.php b/ldap-site-mngmt/webinterface/au/au_childs.php
deleted file mode 100644
index 7aa5dcb3..00000000
--- a/ldap-site-mngmt/webinterface/au/au_childs.php
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Filename of Template
-$webseite = "au_childs.dwt";
-
-include('au_header.inc.php');
-
-###############################################################################
-# Menus
-
-$mnr = 2;
-$sbmnr = -1;
-
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###############################################################################
-# Mainpage Data
-
-$template->assign(array("CHILDOU" => "Noch keine untergordnete AU angelegt",
- "CHILDCN" => "",
- "CHILDDN" => "",
- "CHILDDOMAIN" => "",
- "CHILDDESC" => ""));
-
-$childau_array = get_childau($auDN,array("dn","cn","ou","associateddomain","description","maxipblock"));
-
-$template->define_dynamic("Childaus", "Webseite");
-
-foreach ($childau_array as $childau){
- $auname = "<a href='child_au.php?dn=".$childau['dn']."' class='headerlink'>".$childau['ou']."</a>";
-
- $template->assign(array("CHILDOU" => $auname,
- "CHILDCN" => $childau['cn'],
- "CHILDDN" => $childau['dn'],
- "CHILDDOMAIN" => $childau['associateddomain'],
- "CHILDDESC" => $childau['description'],
- "AUDN" => $auDN));
- $template->parse("CHILDAUS_LIST", ".Childaus");
-}
-
-
-###################################################################################
-# Footer
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_footer.inc.php b/ldap-site-mngmt/webinterface/au/au_footer.inc.php
deleted file mode 100644
index 37fa7808..00000000
--- a/ldap-site-mngmt/webinterface/au/au_footer.inc.php
+++ /dev/null
@@ -1,21 +0,0 @@
-<?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("IPBLOCKS", "IPBlocks");
-$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/au/au_header.inc.php b/ldap-site-mngmt/webinterface/au/au_header.inc.php
deleted file mode 100644
index 57e85f84..00000000
--- a/ldap-site-mngmt/webinterface/au/au_header.inc.php
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-
-#################
-
-# 1. Title
-$titel = "Administrative Unit Management";
-# 2. Mainmenu Number (starting with 0)
-$mainnr = 0;
-
-
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$definedTemplates = array("Vorlage" => "au.dwt",
- "Login" => "../logout_form.inc.dwt",
- "Mmenu" => "../hauptmenue.dwt",
- "Menu" => "menu.dwt",
- "IPBlocks" => "../common/ipblocks.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));
-
-
-include("au_menu.php");
-include("../common/ip_blocks.inc.php");
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_menu.php b/ldap-site-mngmt/webinterface/au/au_menu.php
deleted file mode 100644
index d912c7a5..00000000
--- a/ldap-site-mngmt/webinterface/au/au_menu.php
+++ /dev/null
@@ -1,236 +0,0 @@
-<?php
-
-function createAUMenu($rollen, $mnr, $auDN,$sbmnr) {
-
- global $template, $ds, $suffix, $START_PATH;
-
- # Mainmenu
- $hauptmenu = array(array("link" => "au.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => "alle"),
- array("link" => "au_show.php",
- "text" => "Eigene AU",
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin")),
- array("link" => "au_childs.php",
- "text" => "Untergeordnete AUs",
- "zugriff" => array("MainAdmin")),
- array("link" => "roles.php",
- "text" => "Admin Rollen Management",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- #array("link" => "new_child.php",
- # "text" => "Neue untergeordnete AU",
- # "zugriff" => array("MainAdmin"))
- );
- #echo "hauptmenu: ";print_r($hauptmenu);echo "<br><br>";
-
- # Submenu
- $childaus = array();
- $n = 0;
- #$childau_array = get_childau($auDN,array("dn","cn","ou"));
- #echo "childau_array: ";print_r($childau_array);echo "<br><br>";
- #if (count($childau_array)!= 0){
- # for ($n=0;$n<count($childau_array);$n++) {
- # $childaus[] = array("link" => "child_au.php?dn=".$childau_array[$n]['dn']."&sbmnr=".$n,
- # "text" => $childau_array[$n]['ou'],
- # "zugriff" => array("MainAdmin"));
- # }
- # #$c=0+$n;
- #}
- #$c = $n;
- $childaus[] = array("link" => "new_child.php?sbmnr=".$n,
- "text" => "Neue untergeordnete AU",
- "zugriff" => array("MainAdmin"));
-
- $adminroles = array(array("link" => "role_show.php?role=MainAdmin&sbmnr=0",
- "text" => "Main Admins",
- "zugriff" => array("MainAdmin")),
- array("link" => "role_show.php?role=DhcpAdmin&sbmnr=1",
- "text" => "DHCP Admins",
- "zugriff" => array("MainAdmin")),
- array("link" => "role_show.php?role=HostAdmin&sbmnr=2",
- "text" => "Host Admins",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- array("link" => "role_show.php?role=RbsAdmin&sbmnr=3",
- "text" => "RBS Admins",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- #array("link" => "role_show.php?role=ZoneAdmin&mnr=4",
- # "text" => "DNS Admins",
- # "zugriff" => array("MainAdmin"))
- );
-
-
- $submenu = array(array(),
- array(),
- $childaus,
- $adminroles
- );
- #echo "submenu: ";print_r($submenu);echo "<br><br>";
- # 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");
- #echo "item: "; print_r($item); echo "<br>";
- if ($item['zugriff'] === "alle" || vergleicheArrays($rollen , $item['zugriff'])) {
-
- #########################################################################
- # SUBMENU
-
- $subempty = 0;
- $j=0;
- $maxsub = count($submenu[$mnr]);
- #echo "maxsub: "; print_r($maxsub); echo "<br>";
- if ($maxsub > 0) {
- foreach ($submenu[$mnr] as $item2) {
- #echo "item2: "; print_r($item2); echo "<br>";
- 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:4;padding-left:25px;background-color:{FARBE_S}'>
- <a href='".$item2['link']."' style='text-decoration:none'><code class='submenue_schrift'>".$item2['text']."</code></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");
- }
- # SUBMENU
- #####################################################################
-
-
- 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/au/au_show.dwt b/ldap-site-mngmt/webinterface/au/au_show.dwt
deleted file mode 100755
index f6bfe663..00000000
--- a/ldap-site-mngmt/webinterface/au/au_show.dwt
+++ /dev/null
@@ -1,88 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Administrative Unit - &nbsp;<code class='font_object'>{AU}</code></h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- Sie k&ouml;nnen den Namen und die Beschreibung bearbeiten. Zur Verwaltung, der ihnen
- zugeordneten IP Adressbereiche benutzen Sie bitte das Modul <b>IP Management</b>.<br>
- Wollen Sie ihren DNS Domainnamen &auml;ndern so wenden Sie sich an den Haupt-Administrator
- ihrer &uuml;bergeordneten AU &nbsp;- &nbsp;<b>{PARENTAU}</b> &nbsp;
- (Email: &nbsp;<b>{EMAILMA}</b> )
-
- </td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='au_change.php' method='post'>
-
- <tr height='45'>
- <td width='45%' class='tab_h'><b>Attribut</b></td>
- <td width='55%' class='tab_h'><b>Wert</b></td>
- </tr>
- <tr height='45'>
- <td width='45%' class='tab_d'><b>Name: </b></td>
- <td width='55%' class='tab_d'>
- <input type='Text' name='commonname' value='{CN}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldcn' value='{CN}'>
- <input type='hidden' name='audn' value='{AUDN}'> &nbsp;
- </td>
- </tr>
- <tr height='45'>
- <td width='45%' class='tab_d'><b>Bechreibung:</b></td>
- <td width='55%' class='tab_d'>
- <input type='Text' name='description' value='{DSC}' size='40' class='medium_form_field'>
- <input type='hidden' name='olddesc' value='{DSC}'>
- <input type='hidden' name='audn' value='{AUDN}'> &nbsp;
- </td>
- </tr>
- <tr height='45'>
- <td width='45%' class='tab_d'><b>DNS Domain:</b></td>
- <td width='55%' class='tab_d'>{DOMAIN} &nbsp;</td>
- </tr>
- <tr height='45' valign='top'>
- <td width='45%' class='tab_d'><b>IP Bereiche:</b></td>
- <td width='55%' class='tab_d'>{MIPBS} &nbsp;</td>
- </tr>
-
- </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><h4>Weitere Statistiken zu Ihrer AU:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr height='1'>
- <td width='45%' class='tab_h'>&nbsp;</td>
- <td width='55%' class='tab_h'>&nbsp;</td>
- </tr>
- <tr height='45'>
- <td width='45%' class='tab_d'><b>Hauptadministratoren:</b></td>
- <td width='55%' class='tab_d'>...</td>
- </tr>
- <tr height='45'>
- <td width='45%' class='tab_d'><b>Anzahl Rechner:</b></td>
- <td width='55%' class='tab_d'>...</td>
- </tr>
- <tr height='45'>
- <td width='45%' class='tab_d'><b>.... :</b></td>
- <td width='55%' class='tab_d'>...</td>
- </tr>
- </table></td>
- </tr>
- -->
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_show.php b/ldap-site-mngmt/webinterface/au/au_show.php
deleted file mode 100644
index f29c1ef7..00000000
--- a/ldap-site-mngmt/webinterface/au/au_show.php
+++ /dev/null
@@ -1,70 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-# Filename of Template
-$webseite = "au_show.dwt";
-
-include('au_header.inc.php');
-
-###############################################################################
-# Menus
-
-$mnr = 1;
-$sbmnr = -1;
-
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###############################################################################
-# MainpageData
-
-# Parent AU, Email MainAdmin
-$exp = explode(',',$auDN);
-$parentau = array_slice($exp, 1, 1);
-$parentau = substr($parentau[0],3);
-
-if ( $parentau != "RIPM"){
- $length = count($exp);
- $out = array_slice($exp, 1, $length -1);
- $parentauDN = implode(',',$out);
- $rol = get_roles($parentauDN);
- $mainadminDN = $rol['MainAdmin'][0];
- $emailMA = get_user_data($mainadminDN, array("mail"));
- $emailCODE = "<a href'mailto:".$emailMA['mail']."' class='maillink' style='text-decoration:none'>".$emailMA['mail']."</a>";
-}
-
-$template->assign(array("OU" => $au_ou,
- "CN" => $au_cn,
- "DSC" => $au_desc,
- "AUDN" => $auDN,
- "PARENTAU" => $parentau,
- "EMAILMA" => $emailCODE));
-
-# MaxIPBlocks
-$mipb = $au_mipb;
-$mipbs = "";
-if (count($mipb) > 1) {
- for ($i=0; $i < count($mipb) - 1; $i++) {
- $exp = explode('_',$mipb[$i]);
- $mipbs .= "$exp[0]&nbsp; - &nbsp;$exp[1]<br>";
- }
- $exp = explode('_',$mipb[$i]);
- $mipbs .= "$exp[0]&nbsp; - &nbsp;$exp[1]";
- $template->assign(array("MIPBS" => $mipbs));
-}
-elseif (count($mipb) == 1) {
- $exp = explode('_',$mipb);
- $mipbs .= "$exp[0]&nbsp; - &nbsp;$exp[1]";
- $template->assign(array("MIPBS" => $mipbs));
-}
-else {
- $template->assign(array("MIPBS" => $mipbs));
-}
-
-
-###############################################################################
-# Footer
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/au_start.dwt b/ldap-site-mngmt/webinterface/au/au_start.dwt
deleted file mode 100755
index aeee690f..00000000
--- a/ldap-site-mngmt/webinterface/au/au_start.dwt
+++ /dev/null
@@ -1,31 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - AU Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung ihrer Abteilung oder Administrativen Einheit
- (Administrative Unit - AU).<br>
- Benutzen Sie die Navigation links, um die einzelnen Verwaltungsbereiche anzusteuern:</p>
- <ul>
- <li><p><b>Eigene AU</b></p>
- Hier erhalten Sie eine &Uuml;bersicht &uuml;ber Ihre Administrative Unit. Sie k&ouml;nnen bestimmte
- Daten bearbeiten, z.B. den Name(cn) oder die Beschreibung. Zudem k&ouml;nnen Sie Statistiken
- zu Ihrer AU einsehen.
-
- </li>
- <li><p><b>Untergeordnete AUs</b></p>
- Hier erhalten Sie eine &Uuml;bersicht Ihrer untergeordneten eigenst&auml;ndigen Administrativen Einheiten. Sie k&ouml;nnen diese bearbeiten und l&ouml;schen. Hier k&ouml;nnen Sie auch neue untergeordnete AUs anlegen.
- </li>
- <li><p><b>Admin Rollen Management</b></p>
- Hier k&ouml;nnen Sie den Administratoren Rollen ihrer AU Benutzer zuweisen.
- </li>
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/child_au.dwt b/ldap-site-mngmt/webinterface/au/child_au.dwt
deleted file mode 100755
index 561d0b09..00000000
--- a/ldap-site-mngmt/webinterface/au/child_au.dwt
+++ /dev/null
@@ -1,131 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td colspan='4' height='20'><h4><a href='au_childs.php?' class='headerlink'><< Zur&uuml;ck zur &Uuml;bersicht </a></h4></td>
- </tr>
-
- <tr>
- <td colspan='2'><h3>AU &nbsp;- &nbsp;<code class='font_object'>{CHILDCN}</code>&nbsp; &nbsp;verwalten:</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;'>
-
- <form action='childau_change.php' method='post'>
-
- <tr>
- <td width='45%' class='tab_h'><b>Attribut</b></td>
- <td width='55%' class='tab_h'><b>Wert</b></td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>Eindeutiger Name (ou):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childou' value='{CHILDOU}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldchildou' value='{CHILDOU}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>Name der Abteilung (cn): </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childcn' value='{CHILDCN}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldchildcn' value='{CHILDCN}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>DNS Domain :</b> &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childdomain' value='{CHILDDOMAIN}' size='25' class='medium_form_field'>
- <input type='hidden' name='oldchilddomain' value='{CHILDDOMAIN}'>
- <b><font size="+1">.uni-freiburg.de</font></b>
- </td>
- </tr>
-
- <input type='hidden' name='childdn' value='{CHILDDN}'>
- <input type='hidden' name='submenu' value='{SBMNR}'>
-
- </table></td>
- </tr>
- <tr>
- <td><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></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='ip_deleg_change.php' method='post'>
- <tr>
- <td class='tab_h'><b>Delegierte IP Bereiche</b></td>
- </tr>
- <tr>
- <td class='tab_d'>
-
- <!-- BEGIN DYNAMIC BLOCK: Delegs -->
-
- <input type='Text' name='range1[]' value='{RANGE1}' size='15' class='medium_form_field'>
- &nbsp;&nbsp;- &nbsp;&nbsp;
- <input type='Text' name='range2[]' value='{RANGE2}' size='15' class='medium_form_field'><br>
- <input type='hidden' name='oldrange1[]' value='{RANGE1}'>
- <input type='hidden' name='oldrange2[]' value='{RANGE2}'>
-
- <!-- END DYNAMIC BLOCK: Delegs -->
-
- <input type='hidden' name='childdn' value='{CHILDDN}'>
- <input type='hidden' name='submenu' value='{SBMNR}'>
-
- </td>
- </tr>
- </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>Untergeordnete AU &nbsp;<code class='font_object'>{CHILDCN}</code>&nbsp; l&ouml;schen:</h4></td>
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <form action='childau_delete.php' method='post'>
-
- <tr>
- <td colspan='2' class='tab_h'>W&auml;hlen Sie einen Modus:<br></td>
-
- </tr>
- <tr>
- <td class='tab_d'>
- <input type='radio' name='delmodus' value='integrate' checked></td>
- <td class='tab_d'>
- Nur die untergeordnete AU l&ouml;schen (nur eine Ebene). <br>
- Rechner und DHCP Objekte werden aus dieser in eigene AU integrieren</td>
- </tr>
- <tr>
- <td class='tab_d'>
- <input type='radio' name='delmodus' value='complete'></td>
- <td class='tab_d'>
- Komplett l&ouml;schen: untergeordnete AU und alle darunter angelegten AUs</td>
- </tr>
- <input type='hidden' name='childdn' value='{CHILDDN}'>
- <input type='hidden' name='oldchilddomain' value='{CHILDDOMAIN}'>
- <input type='hidden' name='childou' value='{CHILDOU}'>
-
- </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/au/child_au.php b/ldap-site-mngmt/webinterface/au/child_au.php
deleted file mode 100644
index 665f1da2..00000000
--- a/ldap-site-mngmt/webinterface/au/child_au.php
+++ /dev/null
@@ -1,74 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Filename of Template
-$webseite = "child_au.dwt";
-
-include('au_header.inc.php');
-
-###############################################################################
-# Menus
-
-$mnr = 2;
-$sbmnr = -1;
-
-#$sbmnr = $_GET['sbmnr'];
-
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###############################################################################
-# MainPage Data
-
-$childauDN = $_GET['dn'];
-
-$childau = get_au_data($childauDN,array("dn","cn","ou","associateddomain","description","maxipblock"));
-#print_r($childau);
-
-$domprefix = str_replace('.uni-freiburg.de','',$childau[0]['associateddomain']);
-#print_r($domprefix);
-
-$template->assign(array("CHILDOU" => $childau[0]['ou'],
- "CHILDCN" => $childau[0]['cn'],
- "CHILDDN" => $childauDN,
- "CHILDDOMAIN" => $domprefix,
- "CHILDDESC" => $childau[0]['description'],
- "RANGE1" => "",
- "RANGE2" => "",
- "AUDN" => $auDN,
- "SBMNR" => $sbmnr));
-
-# MaxIPBlocks
-$mipb = $childau[0]['maxipblock'];
-
-# IP Delegs
-$template->define_dynamic("Delegs", "Webseite");
-#print_r($mipb);
-if (count($mipb) > 1){
- foreach ($mipb as $block){
- $exp = explode('_',$block);
- $template->assign(array("RANGE1" => $exp[0],
- "RANGE2" => $exp[1]));
- $template->parse("DELEGS_LIST", ".Delegs");
- }
- $template->clear_dynamic("Delegs");
-}elseif(count($mipb) == 1){
- $exp = explode('_',$mipb);
- $template->assign(array("RANGE1" => $exp[0],
- "RANGE2" => $exp[1]));
- $template->parse("DELEGS_LIST", ".Delegs");
- $template->clear_dynamic("Delegs");
-}
-$template->assign(array("RANGE1" => "",
- "RANGE2" => ""));
-$template->parse("DELEGS_LIST", ".Delegs");
-#$template->clear_dynamic("Delegs");
-
-
-###############################################################################
-# Footer
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/childau_add.php b/ldap-site-mngmt/webinterface/au/childau_add.php
deleted file mode 100644
index 47fb9b55..00000000
--- a/ldap-site-mngmt/webinterface/au/childau_add.php
+++ /dev/null
@@ -1,146 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# $_POST form variables
-$childou = $_POST['childou'];
-$childcn = $_POST['childcn'];
-$childdesc = $_POST['childdesc'];
-$childdomain = $_POST['childdomain'];
-$mainadmin = $_POST['adduser'];
-$hosts = $_POST['addhost'];
-
-$childou = htmlentities($childou);
-$childcn = htmlentities($childcn);
-$childdesc = htmlentities($childdesc);
-$childdomainfull = htmlentities($childdomain).".".$domsuffix ;
-
-/*
-echo "AU dn:"; print_r($auDN); echo "<br>";
-echo "ou:"; print_r($childou); echo "<br>";
-echo "cn:"; print_r($childcn); echo "<br>";
-echo "desc:"; print_r($childdesc); echo "<br>";
-echo "domain:"; print_r($childdomainfull); echo "<br>";
-echo "mainadmin:"; print_r($mainadmin); echo "<br><br>";
-echo "hosts:"; print_r($hosts); echo "<br><br>";
-*/
-
-$seconds = 2;
-# $url = 'new_child.php?ou='.$childou.'&cn='.$get_childcn.'&desc='.$get_childdesc.'&childdomain='.$childdomain;
-
-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>";
-
-if ( $childou != "" && $mainadmin != none && $mainadmin != "") {
-
- # Formulareingaben anpassen
- $expou = explode(" ",$childou);
- foreach ($expou as $word) {$expuc[] = ucfirst($word);}
- $childou = implode(" ",$expuc);
- $childou = preg_replace ( '/\s+([0-9A-Z])/', '$1', $childou);
-
- # AU Objekt anlegen
- # Test auf gleichnamige Geschwister-AUs
- #$sisters = get_childau($auDN,array("ou"));
- $sisters = get_all_aus(array("ou"));
- $sister = 0;
- foreach ($sisters as $item) {
- if ( strtolower($item['ou']) == strtolower($childou) ) {
- $mesg = "Es existiert bereits eine AU mit dem eingegebenen 'ou' Namen!<br>
- Bitte geben Sie einen anderen 'ou' Namen ein.<br><br>";
- $get_childcn = str_replace ( " ", "_", $childcn );
- $get_childdesc = str_replace ( " ", "_", $childdesc );
- $url = "new_child.php?ou=Hier_andere_OU_eingeben&cn=".$get_childcn."&desc=".$get_childdesc."&childdomain=".$childdomain;
- $sister = 1;
- break;
- }
- }
- if ($sister == 0) {
-
- $childDN = "ou=".$childou.",".$auDN;
- if (new_childau($childDN,$childou,$childcn,$childdesc,$mainadmin)) {
-
- # Objekete verschieben
- $i = array_search('none',$hosts);
- #print_r($i); echo "<br>";
- if ($i === 0 ) {array_splice($hosts, $i, 1);}
- #print_r($hosts ); echo "<br>";
-
- if (count($hosts) != 0) {
- foreach ($hosts as $host) {
- $exp = explode('_',$host);
- $hostDN = $exp[0];
- $hostname = $exp[1];
- print_r($hostDN); echo "<br>";
- print_r($hostname); echo "<br><br>";
- # IP Adresse nicht verschieben (IPs werden später delegiert)
- $hoip = get_node_data($hostDN, array("ipaddress"));
- # print_r($hoip); echo "<br>";
- if ($hoip['ipaddress'] != "") {
- delete_ip_host($hostDN,$auDN);
- }
- if (move_subtree($hostDN, "hostname=".$hostname.",cn=computers,".$childDN)) {
- # bestimmte Attribute loeschen ...
- $newhostDN = "hostname=".$hostname.",cn=computers,".$childDN;
- $dhcp = get_node_data($newhostDN, array("dhcphlpcont"));
- # print_r($dhcp); echo "<br>";
- if ($dhcp['dhcphlpcont'] != "") {
- $entrydel ['dhcphlpcont'] = array();
- #$entrydel ['objectclass'] = "dhcpHost";
- # print_r($dhcphlpcont);
- ldap_mod_del($ds, "hostname=".$hostname.",cn=computers,".$childDN, $entrydel);
- }
- }
- }
- }
-
- # Domain anlegen falls erforderlich
- if (new_child_domain($childdomain, $childDN, $assocdom, $domDN)) {
- $mesg .= "<br>AU Domain erfolgreich eingetragen<br>";
- }
- else {
- $mesg .= "<br>Fehler beim eintragen der AU Domain<br>";
- }
-
- $mesg .= "<br>Untergeordnete AU erfolgreich angelegt<br>";
- }
- else {
- $mesg .= "<br>Fehler beim anlegen der untergeordneten AU<br>";
- }
-
- $url = 'au_childs.php';
- }
-}
-
-
-elseif ( $childou == "") {
- $get_childcn = str_replace ( " ", "_", $childcn );
- $get_childdesc = str_replace ( " ", "_", $childdesc );
- $mesg = "Sie haben den OU der neuen AU nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "new_child.php?ou=Hier_OU_eingeben&cn=".$get_childcn."&desc=".$get_childdesc."&childdomain=".$childdomain;
-}
-
-elseif ($mainadmin == "none" || $mainadmin == "") {
- $get_childcn = str_replace ( " ", "_", $childcn );
- $get_childdesc = str_replace ( " ", "_", $childdesc );
- $mesg = "Sie haben keinen MainAdmin f&uuml;r die neue AU gew&auml;hlt.<br>
- Bitte w&auml;hlen Sie einen MainAdmin.<br><br>";
- $url = 'new_child.php?ou='.$childou.'&cn='.$get_childcn.'&desc='.$get_childdesc.'&childdomain='.$childdomain;
-}
-
-
-$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/au/childau_change.php b/ldap-site-mngmt/webinterface/au/childau_change.php
deleted file mode 100644
index 2406b4c2..00000000
--- a/ldap-site-mngmt/webinterface/au/childau_change.php
+++ /dev/null
@@ -1,157 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-$childcn = $_POST['childcn'];
-$oldchildcn = $_POST['oldchildcn'];
-$childou = $_POST['childou'];
-$oldchildou = $_POST['oldchildou'];
-$childdomain = $_POST['childdomain'];
-$oldchilddomain = $_POST['oldchilddomain'];
-$childDN = $_POST['childdn'];
-$submenu = $_POST['submenu'];
-
-$childcn = htmlentities($childcn);
-$oldchildcn = htmlentities($oldchildcn);
-$childou = htmlentities($childou);
-$oldchildou = htmlentities($oldchildou);
-$childdomainfull = htmlentities($childdomain).".".$domsuffix ;
-$oldchilddomainfull = htmlentities($oldchilddomain).".".$domsuffix;
-
-/*
-echo "new ou:"; print_r($childou); echo "<br>";
-echo "old ou:"; print_r($oldchildou); echo "<br>";
-echo "new cn:"; print_r($childcn); echo "<br>";
-echo "old cn:"; print_r($oldchildcn); echo "<br>";
-echo "new domain:"; print_r($childdomain); echo "<br>";
-echo "old domain:"; print_r($oldchilddomain); echo "<br><br>";
-echo "child DN:"; print_r($childDN); echo "<br>";
-echo "new child DN:"; print_r($newchildDN); echo "<br>";
-echo "submenuNR:"; print_r($submenu); echo "<br><br>";
-*/
-
-$seconds = 2;
-$url = 'child_au.php?dn='.$childDN.'&sbmnr='.$submenu;
-
-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>";
-
-#######################################
-# CN
-
-if ($oldchildcn == $childcn) {
- #$mesg = "keine Aenderung<br>";
-}
-
-if ($oldchildcn == "" && $childcn != "") {
- echo "CN neu anlegen<br>";
- # hier noch Syntaxcheck
- $entry['cn'] = $childcn;
- $result = ldap_mod_add($ds,$childDN,$entry);
- if ($result) {
- $mesg = "AU Name erfolgreich eingetragen<br><br>";
- }
- else {
- $mesg = "Fehler beim eintragen des AU Namen<br><br>";
- }
-}
-
-if ($oldchildcn != "" && $childcn != "" && $oldchildcn != $childcn) {
- echo "CN aendern<br>";
- # hier noch Syntaxcheck
- $entry['cn'] = $childcn;
- $result = ldap_mod_replace($ds,$childDN,$entry);
- if ($result) {
- $mesg = "AU Name erfolgreich geaendert<br><br>";
- }
- else {
- $mesg = "Fehler beim aendern des AU Namen<br><br>";
- }
-}
-
-if ($oldchildcn != "" && $childcn == "") {
- echo "CN loeschen<br>";
- # hier noch Syntaxcheck
- $entry['cn'] = $oldchildcn;
- $result = ldap_mod_del($ds,$childDN,$entry);
- if ($result) {
- $mesg = "AU Name erfolgreich geloescht<br><br>";
- }
- else {
- $mesg = "Fehler beim loeschen des AU Namen<br><br>";
- }
-}
-
-#######################################
-# OU
-
-if ($oldchildou == $childou) {
- #$mesg = "keine Aenderung<br>";
-}
-
-if ($oldchildou != "" && $childou != "" && $oldchildou != $childou) {
- echo "OU aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $expou = explode(" ",$childou);
- foreach ($expou as $word) {$expuc[] = ucfirst($word);}
- $childou = implode(" ",$expuc);
- $childou = preg_replace ( '/\s+([0-9A-Z])/', '$1', $childou);
-
- $newchildDN = "ou=".$childou.",".$auDN;
- modify_au_dn($childDN, $newchildDN);
-
- $url = 'au_childs.php';
-}
-
-if ($oldchildou != "" && $childou == "") {
- echo "OU loeschen<br>";
- echo "Sie sind dabei einen Teil des DN zu loeschen.<br>
- Dies geht nur, wenn Sie den gesamten Eintrag loeschen. <br>
- Verwenden Sie dazu das Formular unten";
-}
-
-########################################
-# DOMAIN
-if ($oldchilddomain == $domprefix && ($childdomain == "" || $childdomain == $domprefix)) {
- #$mesg = "keine Aenderung<br>";
-}
-if ($oldchilddomain == $childdomain) {
- #$mesg = "keine Aenderung<br>";
-}
-
-
-if ($oldchilddomain != "" && $childdomain != "" && $oldchilddomain != $childdomain && $childdomain != $domprefix) {
- echo "Domain aendern<br>";
- # hier noch Syntaxcheck
- if (change_child_domain($childdomain, $oldchilddomain, $childDN, $assocdom, $domDN, $domprefix)) {
- $mesg = "Domain erfolgreich geandert<br><br>";
- }
- else {
- $mesg = "Fehler beim aendern der Domain<br><br>";
- }
-}
-
-
-if ($oldchilddomain != "" && $oldchilddomain != $domprefix && ($childdomain == "" || $childdomain == $domprefix)) {
- echo "Domain loeschen bzw. integrieren<br><br>";
- $delmodus = "integrate";
- delete_child_domain($oldchilddomain,$assocdom,$childDN, $domDN, $delmodus);
- $seconds = 5;
-}
-
-
-$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/au/childau_delete.php b/ldap-site-mngmt/webinterface/au/childau_delete.php
deleted file mode 100644
index f9bd75d7..00000000
--- a/ldap-site-mngmt/webinterface/au/childau_delete.php
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# $_POST form variables
-$delmodus = $_POST['delmodus'];
-$childDN = $_POST['childdn'];
-$childou = $_POST['childou'];
-$oldchilddomain = $_POST['oldchilddomain'];
-#print_r($childDN); echo "<br>";
-#print_r($oldchilddomain); echo "<br>";
-#print_r($entrydel); echo "<br>";
-
-$url = 'au_childs.php';
-
-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>";
-
-$mesg = delete_childau($childDN,$childou,$delmodus);
-
-$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(2, $url, $mesg, $addSessionId = TRUE);
-
-echo "</td></tr></table></body></html>";
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/dom_delete.php b/ldap-site-mngmt/webinterface/au/dom_delete.php
deleted file mode 100644
index b8c664b4..00000000
--- a/ldap-site-mngmt/webinterface/au/dom_delete.php
+++ /dev/null
@@ -1,31 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# $_POST form variables
-$delmodus = $_POST['delmodus'];
-$oldchilddomain = $_POST['oldchilddomain'];
-$childDN = $_POST['childdn'];
-$submenu = $_POST['submenu'];
-
-$url = 'child_au.php?dn='.$childDN.'&sbmnr='.$submenu;
-
-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>";
-
-$mesg = delete_childau_domain($oldchilddomain,$childDN,$delmodus);
-
-$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(2, $url, $mesg, $addSessionId = TRUE);
-
-echo "</td></tr></table></body></html>";
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/ip_deleg_change.php b/ldap-site-mngmt/webinterface/au/ip_deleg_change.php
deleted file mode 100644
index 19131837..00000000
--- a/ldap-site-mngmt/webinterface/au/ip_deleg_change.php
+++ /dev/null
@@ -1,194 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-#$auDN = $_POST['audn'];
-$childauDN = $_POST['childdn'];
-$oldrange1 = $_POST['oldrange1'];
-$oldrange2 = $_POST['oldrange2'];
-$newrange1 = $_POST['range1'];
-$newrange2 = $_POST['range2'];
-
-/*
-print_r($oldrange1);echo "<br>";
-print_r($newrange1);echo "<br><br>";
-print_r($oldrange2);echo "<br>";
-print_r($newrange2);echo "<br>";
-print_r($childauDN);echo "<br>";
-print_r($auDN);echo "<br><br>";
-*/
-
-$syntax = new Syntaxcheck;
-$url = "child_au.php?dn=".$childauDN."&sbmnr=".$sbmnr;
-$seconds = 200;
-
-echo "
-<html>
-<head>
- <title>IP Address Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-
-$diff1 = array_keys(array_diff_assoc($oldrange1,$newrange1));
-$diff2 = array_keys(array_diff_assoc($newrange1,$oldrange1));
-$tochange1 = array_unique(array_merge($diff1,$diff2));
-
-$diff3 = array_keys(array_diff_assoc($oldrange2,$newrange2));
-$diff4 = array_keys(array_diff_assoc($newrange2,$oldrange2));
-$tochange2 = array_unique(array_merge($diff3,$diff4));
-
-# print_r($tochange1);echo "<br><br>";
-# print_r($tochange2);echo "<br><br>";
-
-$tochange = array_unique(array_merge($tochange1,$tochange2));
-#print_r($tochange);echo "<br><br>";
-
-
-foreach ($tochange as $i){
-
- $childaudnexp = ldap_explode_dn($childauDN, 1);
- $childau = $childaudnexp[0];
- #print_r($childau);
-
- if ( $oldrange1[$i] == "" && $oldrange2[$i] == "" && $newrange1[$i] != "" && $newrange2[$i] != "" ){
-
- echo "Neuen IP Bereich an <b>$childau</b> delegieren:";echo "<br>";echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- #echo "korrekte IP Syntax<br>";
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- #print_r($newrange_array);
- $newrange = implode('_',$newrange_array);
- #print_r($newrange);
- # $oldip[$i] = htmlentities($oldip[$i]);
- if (new_ip_delegation($newrange,$childauDN,$auDN)){
- echo "<br>Neuer IP Bereich erfolgreich delegiert<br>";
- }else{echo "<br>Fehler beim delegieren des neuen IP Bereichs<br>";}
- }else{echo "falsche IP Syntax<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);
- }
-
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $newrange1[$i] == "" && $newrange2[$i] == "" ){
-
- echo "IP Delegierung von <b>$childau</b> l&ouml;schen:";echo "<br>";echo "<br>";
- echo "zu l&ouml;schende IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
-
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldip_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldip_array);
- if (delete_ip_delegation($oldrange,$childauDN,$auDN)){
- $mesg = "<br>IP Delegierung geloescht<br>";
- }else{
- $mesg = "<br>Fehler beim loeschen der IP Delegierung<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);
- }
-
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $newrange1[$i] != "" && $newrange2[$i] != "" ){
- $or1 = ip2long($oldrange1[$i]);
- $or2 = ip2long($oldrange2[$i]);
- $nr1 = ip2long($newrange1[$i]);
- $nr2 = ip2long($newrange2[$i]);
-
- if ( ($nr1 > $or1 || $nr2 < $or2) && !($nr1 < $or1 || $nr2 > $or2) ){
-
- echo "IP Delegierung von <b>$childau</b> reduzieren:";echo "<br>";echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- #echo "korrekte IP Syntax<br>";
-
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- $newrange = implode('_',$newrange_array);
- #print_r($newrange);
-
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldip_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldip_array);
- #print_r($oldrange);
-
- if (reduce_ip_delegation($oldrange,$newrange,$childauDN,$auDN)){
- $mesg = "<br>IP Range verkleinert<br>";
- }else{
- $mesg = "<br>Fehler beim verkleinern der IP Range<br>";
- }
- }else{echo "falsche IP Syntax<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);
-
-
- }elseif( ($nr1 < $or1 || $nr2 > $or2) && !($nr1 > $or1 || $nr2 < $or2) ){
-
- echo "IP Delegierung von <b>$childau</b> erweitern:";echo "<br>";echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- #echo "korrekte IP Syntax<br>";
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- $newrange = implode('_',$newrange_array);
- #print_r($newrange);
-
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldip_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldip_array);
- #print_r($oldrange);
-
- if (expand_ip_delegation($oldrange,$newrange,$childauDN,$auDN)){
- $mesg = "<br>IP Range erweitert<br>";
- }else{
- $mesg = "<br>Fehler beim erweitern der IP Range<br>";
- }
- }else{
- echo "falsche IP Syntax<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);
- }
- else{
- $mesg = "<br>Verschieben (Shiften) der Delegierung nicht moeglich!<br>
- Nur Vergroessern und Verkleinern moeglich!<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);
- }
- }
- else{
- $mesg = "keine Aenderung<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 "<br><br>";
-}
-
-echo "
-</td></tr></table>
-</head>
-</html>";
-?>
diff --git a/ldap-site-mngmt/webinterface/au/menu.dwt b/ldap-site-mngmt/webinterface/au/menu.dwt
deleted file mode 100755
index 20631be8..00000000
--- a/ldap-site-mngmt/webinterface/au/menu.dwt
+++ /dev/null
@@ -1,29 +0,0 @@
-
-<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">
- <code class="submenue_schrift">{TEXT_M}</code>
- </a></td>
- <td width='10%'>&nbsp;</td>
-
- </tr>
- <!-- BEGIN DYNAMIC BLOCK: Submenu -->
-
- {SUB}
-
- <!-- END DYNAMIC BLOCK: Submenu -->
-
- <tr height='4'>
- </tr>
-
- <!-- END DYNAMIC BLOCK: Hauptmenu -->
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/au/new_child.dwt b/ldap-site-mngmt/webinterface/au/new_child.dwt
deleted file mode 100755
index 309737cc..00000000
--- a/ldap-site-mngmt/webinterface/au/new_child.dwt
+++ /dev/null
@@ -1,123 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Neue untergeordnete AU anlegen:</h3></td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Notwendige Attribute (m&uuml;ssen angegeben werden):</h3></td>
- </tr>
-
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='childau_add.php' method='post'>
-
- <tr>
- <td width='45%' class='tab_h'><b>Attribut</b></td>
- <td width='55%' class='tab_h'><b>Wert</b></td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>Eindeutiger Name (ou):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childou' value='{CHILDOU}' size='40' class='medium_form_field'> &nbsp;
- </td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>MainAdmin neue AU:</b><br>(W&auml;hlen Sie einen Benutzer aus)</td>
- <td class='tab_d'>
- <select name='adduser' size='1' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Users -->
- <option value='{UDN}'>{USER}</option>
- <!-- END DYNAMIC BLOCK: Users -->
-
- </select>
- <input type='hidden' name='role' value='MainAdmin'> &nbsp;
- </td>
- </tr>
- </table></td>
- </tr>
- <tr>
- <td height='25'></td>
- </tr>
- <tr>
- <td><h4>Optionale Attribute:</h3></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='45%' class='tab_h'><b>Attribut</b></td>
- <td width='55%' class='tab_h'><b>Wert</b></td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>Name der Abteilung (cn): </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childcn' value='{CHILDCN}' size='40' class='medium_form_field'>
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>DNS Domain :</b> &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childdomain' value='{CHILDDOMAIN}' size='24' class='medium_form_field'>
- <b><font size="+1">.uni-freiburg.de</font></b>&nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>Beschreibung der AU:</b> &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='childdesc' value='{CHILDDESC}' size='40' class='medium_form_field'>
- </td>
-
-
- </tr>
- </table></td>
- </tr>
-
- <tr>
- <td height='25'></td>
- </tr>
- <tr>
- <td><h4>Objekte, die Sie in die neue untergeordnete AU verschieben m&ouml;chten :</h3></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='45%' class='tab_h'><b>Objekt</b></td>
- <td width='55%' class='tab_h'><b>Auswahl</b></td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>Rechner:</b><br>
- (W&auml;hlen Sie die zu verschiebenden Rechner aus, <br>Mehrfachauswahl m&ouml;glich)</td>
- <td class='tab_d'>
- <select name='addhost[]' size='{HOSTNUMBER}' class='medium_form_selectbox' multiple>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}_{HOSTNAME}'>{HOSTNAME}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- </select>
- </td>
- </tr>
- </table></td>
- </tr>
-
- <tr>
- <td height='5'></td>
- </tr>
- <tr>
- <td style='border-width: 0 0 0 0;'><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/au/new_child.php b/ldap-site-mngmt/webinterface/au/new_child.php
deleted file mode 100644
index f083050d..00000000
--- a/ldap-site-mngmt/webinterface/au/new_child.php
+++ /dev/null
@@ -1,74 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Filename of Template
-$webseite = "new_child.dwt";
-
-include('au_header.inc.php');
-
-###############################################################################
-# Menus
-
-$mnr = 2;
-$sbmnr = -1;
-
-$sbmnr = $_GET['sbmnr'];
-
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-################################################################################
-# Mainpage Data
-
-$childou = str_replace ( "_", " ", $_GET['ou']);
-$childcn = str_replace ( "_", " ", $_GET['cn']);
-$childdesc = str_replace ( "_", " ", $_GET['desc']);
-$childdomain = $_GET['childdomain'];
-
-$domprefix = str_replace('.uni-freiburg.de','',$childau[0]['associateddomain']);
-
-$template->assign(array("CHILDOU" => $childou,
- "CHILDCN" => $childcn,
- "CHILDDOMAIN" => $childdomain,
- "CHILDDESC" => $childdesc,
- "AUDN" => $auDN));
-
-
-#######################################
-# Admin anlegen
-
-$users_array = get_users();
-#print_r($users_array); echo "<br><br>";
-
-if (count($users_array) != 0) {
- $template->define_dynamic("Users", "Webseite");
- foreach ($users_array as $item) {
- $template->assign(array("UDN" => $item['dn'],
- "USER" => $item['uid']));
- $template->parse("USERS_LIST", ".Users");
- }
-}
-else {
- $template->assign(array("UDN" => "","USER" => ""));
-}
-
-#######################################
-# Objekte zum verschieben
-
-$host_array = get_hosts($auDN,array("dn","hostname"));
-#print_r($host_array);
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($host_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HOSTNAME" => $item['hostname'],
- "HOSTNUMBER" => 5));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-
-###############################################################################
-# Footer
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/role_add.php b/ldap-site-mngmt/webinterface/au/role_add.php
deleted file mode 100644
index c1729ed1..00000000
--- a/ldap-site-mngmt/webinterface/au/role_add.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-
-$adduser = $_POST['adduser'];
-$role = $_POST['role'];
-$menr = $_POST['menr'];
-
-$exp = explode('_',$adduser);
-$adduserDN = $exp[0];
-$adduserUID = $exp[1];
-
-echo "
-<html>
-<head>
- <title>Administrative Unit Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-# print_r($adduser);echo "<br>";
-# print_r($adduserDN);echo "<br>";
-# print_r($adduserUID);echo "<br>";
-# print_r($role);echo "<br>";
-# print_r($menr);echo "<br><br>";
-
-$url = 'role_show.php?role='.$role.'&sbmnr='.$menr;
-
-if ($adduser != 'none'){
- $res = new_role_member($adduserDN,$role,$auDN,$domDN);
- if ($res == 1){
- $mesg = "Der Benutzer <b>".$adduserUID."</b> wurde erfolgreich als neuer <b>".$role."</b> aufgenommen.<br><br>";
- }else{
- $mesg = "Fehler! Der Benutzer <b>".$adduserUID."</b> konnte nicht aufgenommen werden<br><br>";
- }
- $mesg .= "Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-}
-
-else {
- $mesg = "Sie haben keinen Benutzer ausgew&auml;hlt<br><br>
- Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-}
-
-echo "</td></tr></table></body>
-</html>";
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/role_delete.php b/ldap-site-mngmt/webinterface/au/role_delete.php
deleted file mode 100644
index eccd4ce4..00000000
--- a/ldap-site-mngmt/webinterface/au/role_delete.php
+++ /dev/null
@@ -1,57 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-
-$deluser = $_POST['deluser'];
-$role = $_POST['role'];
-$menr = $_POST['menr'];
-
-echo "
-<html>
-<head>
- <title>Administrative Unit Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-if (isset($_POST['deluser'])){
-
- # print_r($deluser);echo "<br>";
- # print_r($role);echo "<br>";
- # print_r($menr);echo "<br>";
-
- $url = 'role_show.php?role='.$role.'&sbmnr='.$menr;
- $mesg = "";
-
- foreach ($deluser as $item){
- $exp = explode('_',$item);
- $deluserDN = $exp[0];
- $deluserUID = $exp[1];
- # print_r($deluserDN);echo "<br>";
- # print_r($deluserUID);echo "<br>";
- $res = delete_role_member($deluserDN,$role,$auDN,$domDN);
- if ($res == 1){
- $mesg .= "Der Benutzer <b>".$deluserUID."</b> wurde erfolgreich aus der Rolle <b>".$role."</b> entfernt.<br>";
- }else{
- $mesg .= "<br><b>Fehler!</b> Der Benutzer <b>".$deluserUID."</b> konnte nicht entfernt werden<br>";
- }
- }
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a><br><br>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-
-}
-
-else {
- $mesg .= "<br>Sie haben keinen Benutzer ausgew&auml;hlt<br><br>
- Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-}
-
-echo "</td></tr></table></body>
-</html>";
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/role_show.dwt b/ldap-site-mngmt/webinterface/au/role_show.dwt
deleted file mode 100644
index 39c618c0..00000000
--- a/ldap-site-mngmt/webinterface/au/role_show.dwt
+++ /dev/null
@@ -1,70 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>{ROLE_DESC}</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;'>
- <tr>
- <td width='5%' class='tab_h'>&nbsp;</td>
- <td width='25%' class='tab_h'><b>Benutzer</b></td>
- <td width='25%' class='tab_h'><b>UID</b></td>
- <td width='45%' class='tab_h'><b>Email</b></td>
- </tr>
-
- <form action='role_delete.php' method='post'>
-
- <!-- BEGIN DYNAMIC BLOCK: Members -->
- <tr>
- <td class='tab_d'>
- <input type='checkbox' name='deluser[]' value='{VALUE}_{UID}' size='15' class='medium_form_checkbox'></td>
- <td class='tab_d'>{USERNAME} &nbsp;</td>
- <td class='tab_d'>{UID} &nbsp;</td>
- <td class='tab_d'><a href'mailto:{MAIL}' style='publink'>{MAIL}</a> &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Members -->
- <input type='hidden' name='role' value='{ROLE}'>
- <input type='hidden' name='menr' value='{MENR}'>
-
-
- <tr>
- <td colspan='3' style='border-width: 0 0 0 0;'><input type='Submit' name='delete' value='entfernen' class='small_loginform_button'></td>
-
- </form>
- </tr>
- </table></td>
- </tr>
-
- <tr height='30'></tr>
- <tr>
- <td colspan='2'><h4>Neuen Administrator anlegen:</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>
-
- <form action='role_add.php' method='post'>
-
- <td width='60%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- W&auml;hlen Sie einen Benutzer aus <br>
- <select name='adduser' size='1' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Users -->
- <option value='{UDN}_{USER}'>{USER}</option>
- <!-- END DYNAMIC BLOCK: Users -->
-
- </select>
- <input type='hidden' name='role' value='{ROLE}'>
- <input type='hidden' name='menr' value='{MENR}'>
- </td>
- </tr>
- <tr>
- <td style='border-width: 0 0 0 0;'><input type='Submit' name='add' value='anlegen' class='small_loginform_button'></td>
-
- </form>
- </tr>
- </table></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/role_show.php b/ldap-site-mngmt/webinterface/au/role_show.php
deleted file mode 100644
index 8e94d7ed..00000000
--- a/ldap-site-mngmt/webinterface/au/role_show.php
+++ /dev/null
@@ -1,114 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "role_show.dwt";
-
-include("au_header.inc.php");
-
-###############################################################################
-
-#$mnr = $_GET['mnr'];
-$mnr = 3;
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###############################################################################
-# Admins anzeigen und loeschen
-
-$role = $_GET['role'];
-$roles_array = get_roles($auDN);
-# print_r($roles_array);
-
-# jeder Rolle entsprechend Members holen und Ãœberschrift setzen
-switch ($role){
-case 'MainAdmin':
- $template->assign(array("ROLE" => "MainAdmin","ROLE_DESC" => "Haupt Administratoren","MENR" => $sbmnr));
- $members = $roles_array['MainAdmin'];
- break;
-case 'HostAdmin':
- $template->assign(array("ROLE" => "HostAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;Rechner","MENR" => $sbmnr));
- $members = $roles_array['HostAdmin'];
- break;
-case 'DhcpAdmin':
- $template->assign(array("ROLE" => "DhcpAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;DHCP","MENR" => $sbmnr));
- $members = $roles_array['DhcpAdmin'];
- break;
-case 'RbsAdmin':
- $template->assign(array("ROLE" => "RbsAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;Remote Boot Services","MENR" => $sbmnr));
- $members = $roles_array['RbsAdmin'];
- break;
-case 'ZoneAdmin':
- $template->assign(array("ROLE" => "ZoneAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;DNS Zone &nbsp;[ {DOM} ]","MENR" => $sbmnr));
- $members = $roles_array['ZoneAdmin'];
- break;
-}
-
-# print_r($members); echo "<br><br>";
-
-# für jedes Member Daten holen (Benutzername, UID)
-if ( count($members) != 0 ){
- $members_data = array();
- foreach ($members as $item){
- $members_data[] = get_user_data($item,array("dn","cn","uid","mail"));
- # print_r(get_user_data($item,array("dn","cn","uid"))); echo "<br>";
- }
-}
-# echo "<br>";
-# print_r($members_data); echo "<br><br>";
-
-if (count($members_data) != 0){
- $template->define_dynamic("Members", "Webseite");
- foreach ($members_data as $item){
- $template->assign(array("VALUE" => $item['dn'],
- "USERNAME" => $item['cn'],
- "UID" => $item['uid'],
- "MAIL" => $item['mail']));
- $template->parse("MEMBERS_LIST", ".Members");
- }
-}else{
- $template->assign(array("VALUE" => "","USERNAME" => "","UID" => "","MAIL" => ""));
-}
-
-
-##############################################
-# Admin anlegen ...
-$users_array = get_users();
-# print_r($users_array); echo "<br><br>";
-
-if (count($members_data) != 0){
-for ($i=0; $i < count($users_array); $i++){
- foreach ($members_data as $item){
- if ($users_array[$i]['uid'] == $item['uid']){
- array_splice($users_array, $i, 1);
- # break;
- }
- }
-}
-# print_r($users_array); echo "<br><br>";
-}
-
-# if (count($users_array) != 0){
- $template->define_dynamic("Users", "Webseite");
- foreach ($users_array as $item){
- $template->assign(array("UDN" => $item['dn'],
- "USER" => $item['uid']));
- $template->parse("USERS_LIST", ".Users");
- }
-#}else{
-# $template->assign(array("UDN" => "","USER" => ""));
-# }
-
-
-
-
-
-###############################################################################
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/roles.php b/ldap-site-mngmt/webinterface/au/roles.php
deleted file mode 100644
index 608b7e30..00000000
--- a/ldap-site-mngmt/webinterface/au/roles.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mnr = 0;
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "roles_start.dwt";
-
-#include("roles_header.inc.php");
-include("au_header.inc.php");
-
-###################################################################################
-
-$mnr = 3;
-$sbmnr = -1;
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/au/roles_start.dwt b/ldap-site-mngmt/webinterface/au/roles_start.dwt
deleted file mode 100644
index 27f55a2f..00000000
--- a/ldap-site-mngmt/webinterface/au/roles_start.dwt
+++ /dev/null
@@ -1,41 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - Administratoren Rollen Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung von Administratoren Rollen in ihrer Abteilung.
- Benutzen Sie die Navigation links, um die Verwaltungsbereiche der einzelnen Rollen anzusteuern.
- Dort koennen Sie dann Benutzer den Rollen zuweisen oder wieder entziehen.</p>
- <p>Folgende administrative Rollen stehen zur Verfuegung:</p>
- <ul>
- <li><p><b>Main Admins</b></p>
- Hauptadministratoren, der AU mit uneingeschraenkten Rechten. Sie verwalten: u.a.
- untergeordnete AUs (anlegen/loeschen/im DNS anmelden),
- Rollen, IP Adressen und deren Delegierung, Rechner (Gruppen), deren Hardware-Profile und
- PXE Boot Konfigurationen, sowie die Dienste DHCP und DNS.
- </li>
- <li><p><b>DHCP Admins</b></p>
- Verwalten den DHCP Dienst, d.h. Subnetz-, Pool-, Class-Objekte.
- </li>
- <li><p><b>Host Admins</b></p>
- Diese verwalten Rechner (Gruppen), deren Hardware-Profile und PXE Boot Konfigurationen,
- und koennen diese im DHCP und DNS anmelden (verwalten im DNS nur deren Namenseintraege).
- </li>
- <li><p><b>RBS Admins</b></p>
- Diese verwalten Remote Boot Services: TFTP/PXE Konfiguration der Dienste, Default PXE Boot Konfigurationen und Generische Bootmen&uuml;eintr&auml;ge.
- </li>
- <!--
- <li><p><b>DNS Admins</b></p>
- Sind die Administratoren der mit der AU assozierten DNS Zone. D.h. sie verwalten SOA,
- Include Direktiven untergeordneter Include Files, sowie alle Nameneintraege der Zone.
- </li> -->
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/class.FastTemplate.php b/ldap-site-mngmt/webinterface/class.FastTemplate.php
deleted file mode 100644
index d048ee5c..00000000
--- a/ldap-site-mngmt/webinterface/class.FastTemplate.php
+++ /dev/null
@@ -1,768 +0,0 @@
-<?
-################################################
-#### Angepasst an PHP4 von ####
-#### Timothy Burk - Webdesign & PC-Service ####
-#### info@tburk.com ####
-################################################
-/*
- CVS Revision. 1.1.0
-*/
-
-/*
- eine weitere kleine Anpassung von Thomas Nunninger betrifft das append in der
- parse-Funktion. Bei error_reporting(E_ALL) erschien sonst beim ersten Anhängen
- an eine noch nicht vorhandene Variable eine Fehlermeldung.
-*/
-
-class FastTemplate {
-
- var $FILELIST = array(); // Holds the array of filehandles
- // FILELIST[HANDLE] == "fileName"
-
- var $DYNAMIC = array(); // Holds the array of dynamic
- // blocks, and the fileHandles they
- // live in.
-
- var $PARSEVARS = array(); // Holds the array of Variable
- // handles.
- // PARSEVARS[HANDLE] == "value"
-
- var $LOADED = array(); // We only want to load a template
- // once - when it's used.
- // LOADED[FILEHANDLE] == 1 if loaded
- // undefined if not loaded yet.
-
- var $HANDLE = array(); // Holds the handle names assigned
- // by a call to parse()
-
- var $ROOT = ""; // Holds path-to-templates
-
- var $WIN32 = false; // Set to true if this is a WIN32 server
-
- var $ERROR = ""; // Holds the last error message
-
- var $LAST = ""; // Holds the HANDLE to the last
- // template parsed by parse()
-
- var $STRICT = true; // Strict template checking.
- // Unresolved vars in templates will
- // generate a warning when found.
-
-// ************************************************************
-
- function FastTemplate ($pathToTemplates = "")
- {
- global $php_errormsg;
-
- if(!empty($pathToTemplates))
- {
- $this->set_root($pathToTemplates);
- }
-
- } // end (new) FastTemplate ()
-
-
-// ************************************************************
-// All templates will be loaded from this "root" directory
-// Can be changed in mid-process by re-calling with a new
-// value.
-
- function set_root ($root)
- {
- $trailer = substr($root,-1);
-
- if(!$this->WIN32)
- {
- if( (ord($trailer)) != 47 )
- {
- $root = "$root".chr(47);
- }
-
- if(is_dir($root))
- {
- $this->ROOT = $root;
- }
- else
- {
- $this->ROOT = "";
- $this->error("Specified ROOT dir [$root] is not a directory");
- }
- }
- else
- {
- // WIN32 box - no testing
- if( (ord($trailer)) != 92 )
- {
- $root = "$root".chr(92);
- }
- $this->ROOT = $root;
- }
-
- } // End set_root()
-
-
-// **************************************************************
-// Calculates current microtime
-// I throw this into all my classes for benchmarking purposes
-// It's not used by anything in this class and can be removed
-// if you don't need it.
-
-
- function utime ()
- {
- $time = explode( " ", microtime());
- $usec = (double)$time[0];
- $sec = (double)$time[1];
- return $sec + $usec;
- }
-
-// **************************************************************
-// Strict template checking, if true sends warnings to STDOUT when
-// parsing a template with undefined variable references
-// Used for tracking down bugs-n-such. Use no_strict() to disable.
-
- function strict ()
- {
- $this->STRICT = true;
- }
-
-// ************************************************************
-// Silently discards (removes) undefined variable references
-// found in templates
-
- function no_strict ()
- {
- $this->STRICT = false;
- }
-
-// ************************************************************
-// A quick check of the template file before reading it.
-// This is -not- a reliable check, mostly due to inconsistencies
-// in the way PHP determines if a file is readable.
-
- function is_safe ($filename)
- {
- if(!file_exists($filename))
- {
- $this->error("[$filename] does not exist",0);
- return false;
- }
- return true;
- }
-
-// ************************************************************
-// Grabs a template from the root dir and
-// reads it into a (potentially REALLY) big string
-
- function get_template ($template)
- {
- if(empty($this->ROOT))
- {
- $this->error("Cannot open template. Root not valid.",1);
- return false;
- }
-
- $filename = "$this->ROOT"."$template";
-
- $contents = implode("",(@file($filename)));
- if( (!$contents) or (empty($contents)) )
- {
- $this->error("get_template() failure: [$filename] $php_errormsg",1);
- }
-
- return $contents;
-
- } // end get_template
-
-// ************************************************************
-// Prints the warnings for unresolved variable references
-// in template files. Used if STRICT is true
-
- function show_unknowns ($Line)
- {
- $unknown = array();
- if (ereg("({[A-Z0-9_]+})",$Line,$unknown))
- {
- $UnkVar = $unknown[1];
- if(!(empty($UnkVar)))
- {
- @error_log("[FastTemplate] Warning: no value found for variable: $UnkVar ",0);
- }
- }
- } // end show_unknowns()
-
-// ************************************************************
-// This routine get's called by parse() and does the actual
-// {VAR} to VALUE conversion within the template.
-
- function parse_template ($template, $tpl_array)
- {
- while ( list ($key,$val) = each ($tpl_array) )
- {
- if (!(empty($key)))
- {
- if(gettype($val) != "string")
- {
- settype($val,"string");
- }
-
- $template = ereg_replace("\{$key}","$val","$template");
- //$template = str_replace("\{$key}","$val","$template");
- }
- }
-
- if(!$this->STRICT)
- {
- // Silently remove anything not already found
-
- $template = ereg_replace("\{([A-Z0-9_]+)}","",$template);
- }
- else
- {
- // Warn about unresolved template variables
- if (ereg("(\{[A-Z0-9_]+})",$template))
- {
- $unknown = split("\n",$template);
- while (list ($Element,$Line) = each($unknown) )
- {
- $UnkVar = $Line;
- if(!(empty($UnkVar)))
- {
- $this->show_unknowns($UnkVar);
- }
- }
- }
- }
- return $template;
-
- } // end parse_template();
-
-// ************************************************************
-// The meat of the whole class. The magic happens here.
-
- function parse ( $ReturnVar, $FileTags )
- {
- $append = false;
- $this->LAST = $ReturnVar;
- $this->HANDLE[$ReturnVar] = 1;
-
- if (gettype($FileTags) == "array")
- {
- unset($this->$ReturnVar); // Clear any previous data
-
- while ( list ( $key , $val ) = each ( $FileTags ) )
- {
- if ( (!isset($this->$val)) || (empty($this->$val)) )
- {
- $this->LOADED["$val"] = 1;
- if(isset($this->DYNAMIC["$val"]))
- {
- $this->parse_dynamic($val,$ReturnVar);
- }
- else
- {
- $fileName = $this->FILELIST["$val"];
- $this->$val = $this->get_template($fileName);
- }
- }
-
- // Array context implies overwrite
-
- $this->$ReturnVar = $this->parse_template($this->$val,$this->PARSEVARS);
-
- // For recursive calls.
-
- $this->assign( array( $ReturnVar => $this->$ReturnVar ) );
-
- }
- } // end if FileTags is array()
- else
- {
- // FileTags is not an array
-
- $val = $FileTags;
-
- if( (substr($val,0,1)) == '.' )
- {
- // Append this template to a previous ReturnVar
-
- $append = true;
- $val = substr($val,1);
- }
-
- if ( (!isset($this->$val)) || (empty($this->$val)) )
- {
- $this->LOADED["$val"] = 1;
- if(isset($this->DYNAMIC["$val"]))
- {
- $this->parse_dynamic($val,$ReturnVar);
- }
- else
- {
- $fileName = $this->FILELIST["$val"];
- $this->$val = $this->get_template($fileName);
- }
- }
-
- if($append)
- {
- // Thomas> auch hier append korrigiert
- if (isset($this->$ReturnVar)) {
- $this->$ReturnVar .= $this->parse_template($this->$val,$this->PARSEVARS);
- } else {
- $this->$ReturnVar = $this->parse_template($this->$val,$this->PARSEVARS);
- }
- }
- else
- {
- $this->$ReturnVar = $this->parse_template($this->$val,$this->PARSEVARS);
- }
-
- // For recursive calls.
-
- $this->assign(array( $ReturnVar => $this->$ReturnVar) );
-
- }
- return;
- } // End parse()
-
-
-// ************************************************************
-
- function FastPrint ( $template = "" )
- {
- if(empty($template))
- {
- $template = $this->LAST;
- }
-
- if( (!(isset($this->$template))) || (empty($this->$template)) )
- {
- $this->error("Nothing parsed, nothing printed",0);
- return;
- }
- else
- {
- print $this->$template;
- }
- return;
- }
-
-// ************************************************************
-
- function fetch ( $template = "" )
- {
- if(empty($template))
- {
- $template = $this->LAST;
- }
- if( (!(isset($this->$template))) || (empty($this->$template)) )
- {
- $this->error("Nothing parsed, nothing printed",0);
- return "";
- }
-
- return($this->$template);
- }
-
-
-// ************************************************************
-
- function define_dynamic ($Macro, $ParentName)
- {
- // A dynamic block lives inside another template file.
- // It will be stripped from the template when parsed
- // and replaced with the {$Tag}.
-
- $this->DYNAMIC["$Macro"] = $ParentName;
- return true;
- }
-
-// ************************************************************
-
- function parse_dynamic ($Macro,$MacroName)
- {
- // The file must already be in memory.
-
- $ParentTag = $this->DYNAMIC["$Macro"];
- // Thomas> in Folgezeile !isset($this->$ParentTag eingefügt
- if( (!isset($this->$ParentTag) || !$this->$ParentTag) or (empty($this->$ParentTag)) )
- {
- $fileName = $this->FILELIST[$ParentTag];
- $this->$ParentTag = $this->get_template($fileName);
- $this->LOADED[$ParentTag] = 1;
- }
- if($this->$ParentTag)
- {
- $template = $this->$ParentTag;
- $DataArray = split("\n",$template);
- $newMacro = "";
- $newParent = "";
- $outside = true;
- $start = false;
- $end = false;
- while ( list ($lineNum,$lineData) = each ($DataArray) )
- {
- $lineTest = trim($lineData);
- if("<!-- BEGIN DYNAMIC BLOCK: $Macro -->" == "$lineTest" )
- {
- $start = true;
- $end = false;
- $outside = false;
- }
- if("<!-- END DYNAMIC BLOCK: $Macro -->" == "$lineTest" )
- {
- $start = false;
- $end = true;
- $outside = true;
- }
- if( (!$outside) and (!$start) and (!$end) )
- {
- $newMacro .= "$lineData\n"; // Restore linebreaks
- }
- if( ($outside) and (!$start) and (!$end) )
- {
- $newParent .= "$lineData\n"; // Restore linebreaks
- }
- if($end)
- {
- $newParent .= "\{$MacroName}\n";
- }
- // Next line please
- if($end) { $end = false; }
- if($start) { $start = false; }
- } // end While
-
- $this->$Macro = $newMacro;
- $this->$ParentTag = $newParent;
- return true;
-
- } // $ParentTag NOT loaded - MAJOR oopsie
- else
- {
- @error_log("ParentTag: [$ParentTag] not loaded!",0);
- $this->error("ParentTag: [$ParentTag] not loaded!",0);
- }
- return false;
- }
-
-// ************************************************************
-// Strips a DYNAMIC BLOCK from a template.
-
- function clear_dynamic ($Macro="")
- {
- if(empty($Macro)) { return false; }
-
- // The file must already be in memory.
-
- $ParentTag = $this->DYNAMIC["$Macro"];
-
- if( (!$this->$ParentTag) or (empty($this->$ParentTag)) )
- {
- $fileName = $this->FILELIST[$ParentTag];
- $this->$ParentTag = $this->get_template($fileName);
- $this->LOADED[$ParentTag] = 1;
- }
-
- if($this->$ParentTag)
- {
- $template = $this->$ParentTag;
- $DataArray = split("\n",$template);
- $newParent = "";
- $outside = true;
- $start = false;
- $end = false;
- while ( list ($lineNum,$lineData) = each ($DataArray) )
- {
- $lineTest = trim($lineData);
- if("<!-- BEGIN DYNAMIC BLOCK: $Macro -->" == "$lineTest" )
- {
- $start = true;
- $end = false;
- $outside = false;
- }
- if("<!-- END DYNAMIC BLOCK: $Macro -->" == "$lineTest" )
- {
- $start = false;
- $end = true;
- $outside = true;
- }
- if( ($outside) and (!$start) and (!$end) )
- {
- $newParent .= "$lineData\n"; // Restore linebreaks
- }
- // Next line please
- if($end) { $end = false; }
- if($start) { $start = false; }
- } // end While
-
- $this->$ParentTag = $newParent;
- return true;
-
- } // $ParentTag NOT loaded - MAJOR oopsie
- else
- {
- @error_log("ParentTag: [$ParentTag] not loaded!",0);
- $this->error("ParentTag: [$ParentTag] not loaded!",0);
- }
- return false;
- }
-
-
-// ************************************************************
-
- function define ($fileList)
- {
- while ( list ($FileTag,$FileName) = each ($fileList) )
- {
- $this->FILELIST["$FileTag"] = $FileName;
- }
- return true;
- }
-
-// ************************************************************
-
- function clear_parse ( $ReturnVar = "")
- {
- $this->clear($ReturnVar);
- }
-
-// ************************************************************
-
- function clear ( $ReturnVar = "" )
- {
- // Clears out hash created by call to parse()
-
- if(!empty($ReturnVar))
- {
- if( (gettype($ReturnVar)) != "array")
- {
- unset($this->$ReturnVar);
- return;
- }
- else
- {
- while ( list ($key,$val) = each ($ReturnVar) )
- {
- unset($this->$val);
- }
- return;
- }
- }
-
- // Empty - clear all of them
-
- while ( list ( $key,$val) = each ($this->HANDLE) )
- {
- $KEY = $key;
- unset($this->$KEY);
- }
- return;
-
- } // end clear()
-
-// ************************************************************
-
- function clear_all ()
- {
- $this->clear();
- $this->clear_assign();
- $this->clear_define();
- $this->clear_tpl();
-
- return;
-
- } // end clear_all
-
-// ************************************************************
-
- function clear_tpl ($fileHandle = "")
- {
- if(empty($this->LOADED))
- {
- // Nothing loaded, nothing to clear
-
- return true;
- }
- if(empty($fileHandle))
- {
- // Clear ALL fileHandles
-
- while ( list ($key, $val) = each ($this->LOADED) )
- {
- unset($this->$key);
- }
- unset($this->LOADED);
-
- return true;
- }
- else
- {
- if( (gettype($fileHandle)) != "array")
- {
- if( (isset($this->$fileHandle)) || (!empty($this->$fileHandle)) )
- {
- unset($this->LOADED[$fileHandle]);
- unset($this->$fileHandle);
- return true;
- }
- }
- else
- {
- while ( list ($Key, $Val) = each ($fileHandle) )
- {
- unset($this->LOADED[$Key]);
- unset($this->$Key);
- }
- return true;
- }
- }
-
- return false;
-
- } // end clear_tpl
-
-// ************************************************************
-
- function clear_define ( $FileTag = "" )
- {
- if(empty($FileTag))
- {
- unset($this->FILELIST);
- return;
- }
-
- if( (gettype($Files)) != "array")
- {
- unset($this->FILELIST[$FileTag]);
- return;
- }
- else
- {
- while ( list ( $Tag, $Val) = each ($FileTag) )
- {
- unset($this->FILELIST[$Tag]);
- }
- return;
- }
- }
-
-// ************************************************************
-// Aliased function - used for compatibility with CGI::FastTemplate
- /* function clear_parse ()
- {
- $this->clear_assign();
- } */
-
-// ************************************************************
-// Clears all variables set by assign()
-
- function clear_assign ()
- {
- if(!(empty($this->PARSEVARS)))
- {
- while(list($Ref,$Val) = each ($this->PARSEVARS) )
- {
- unset($this->PARSEVARS["$Ref"]);
- }
- }
- }
-
-// ************************************************************
-
- function clear_href ($href)
- {
- if(!empty($href))
- {
- if( (gettype($href)) != "array")
- {
- unset($this->PARSEVARS[$href]);
- return;
- }
- else
- {
- while (list ($Ref,$val) = each ($href) )
- {
- unset($this->PARSEVARS[$Ref]);
- }
- return;
- }
- }
- else
- {
- // Empty - clear them all
-
- $this->clear_assign();
- }
- return;
- }
-
-// ************************************************************
-
- function assign ($tpl_array, $trailer="")
- {
- if(gettype($tpl_array) == "array")
- {
- while ( list ($key,$val) = each ($tpl_array) )
- {
- if (!(empty($key)))
- {
- // Empty values are allowed
- // Empty Keys are NOT
-
- $this->PARSEVARS["$key"] = $val;
- }
- }
- }
- else
- {
- // Empty values are allowed in non-array context now.
- if (!empty($tpl_array))
- {
- $this->PARSEVARS["$tpl_array"] = $trailer;
- }
- }
- }
-
-// ************************************************************
-// Return the value of an assigned variable.
-// Christian Brandel cbrandel@gmx.de
-
- function get_assigned($tpl_name = "")
- {
- if(empty($tpl_name)) { return false; }
- if(isset($this->PARSEVARS["$tpl_name"]))
- {
- return ($this->PARSEVARS["$tpl_name"]);
- }
- else
- {
- return false;
- }
- }
-
-// ************************************************************
-
- function error ($errorMsg, $die = 0)
- {
- $this->ERROR = $errorMsg;
- echo "ERROR: $this->ERROR <BR> \n";
- if ($die == 1)
- {
- exit;
- }
-
- return;
-
- } // end error()
-
-
-// ************************************************************
-
-
-
-// ************************************************************
-
-} // End class.FastTemplate.php3
-
-?>
diff --git a/ldap-site-mngmt/webinterface/common/ip_blocks.inc.php b/ldap-site-mngmt/webinterface/common/ip_blocks.inc.php
deleted file mode 100644
index 17795671..00000000
--- a/ldap-site-mngmt/webinterface/common/ip_blocks.inc.php
+++ /dev/null
@@ -1,74 +0,0 @@
-<?php
-
-# Max und Free IP Blocks
-$mipb_array = get_maxipblocks_au($auDN);
-$fipb_array = get_freeipblocks_au($auDN);
-#print_r($fipb_array); echo "<br>";
-natsort($mipb_array);
-natsort($fipb_array);
-#print_r($fipb_array); echo "<br>";
-#print_r(count($mipb_array)); echo "<br>";
-#print_r(count($fipb_array)); echo "<br>";
-$ipblocks = "";
-
-# print_r($mipb_array);
-if ($mipb_array[0] != "" ){
- if (count($mipb_array) > 1 ){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <b>Zugewiesene IP Bereiche:</b></td></tr>";
- foreach ($mipb_array as $mipb){
- $exp = explode('_',$mipb);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></td></tr>";
- }
- }
- elseif (count($mipb_array) == 1){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <b>Zugewiesener IP Bereich:</b></td></tr>";
- $exp = explode('_',$mipb_array[0]);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></tr>";
- }
- elseif( $fipb_array[0] == "" ){
- $ipblocks .= "<table border='0' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td><b>Keine IP Adressen mehr verf&uuml;gbar</b></td></tr>";
- }
- if (count($fipb_array) > 1 ){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr valign='bottom' height='40'>
- <td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <b>Davon noch frei verf&uuml;gbar:</b></td></tr>";
- foreach ($fipb_array as $fipb){
- $exp = explode('_',$fipb);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></tr>";
- }
- }
- elseif (count($fipb_array) == 1){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr valign='bottom' height='40'>
- <td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <b>Davon noch frei verf&uuml;gbar:</b></td></tr>";
- $exp = explode('_',$fipb_array[0]);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></tr>";
- }
-
-}
-
-if( $mipb_array[0] == "" ){
- $ipblocks .= "<table border='0' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr valign='bottom' height='40'>
- <td><b>Ihnen wurden keine IP Adressen zugewiesen</b></td></tr>";
-}
-$ipblocks .= "</table>";
-
-$template->assign(array("IPBLOCKS" => $ipblocks));
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/common/ipblocks.dwt b/ldap-site-mngmt/webinterface/common/ipblocks.dwt
deleted file mode 100644
index b77f53b3..00000000
--- a/ldap-site-mngmt/webinterface/common/ipblocks.dwt
+++ /dev/null
@@ -1,11 +0,0 @@
-<table cellpadding='5' cellspacing='0' border='1' width='100%' style='border-width: 0 0 0 0;'>
-
- <tr align='left'>
- <td width='8%'></td>
- <td width='82%' style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>{IPBLOCKS}</td>
- <td width='10%'></td>
-
- </tr>
- <tr height='5'></tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/computers.dwt b/ldap-site-mngmt/webinterface/computers/computers.dwt
deleted file mode 100644
index 933ab60d..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers.dwt
+++ /dev/null
@@ -1,85 +0,0 @@
-<html>
-
-<head>
- <title>{SEITENTITEL}</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'></head>
-<body>
-
-<table cellpadding='0' cellspacing='0' border='0' width='100%' style='background-color: #F0F0F0;border-color: #505050; border-style: solid; border-width: 0 0 1 0;'>
- <tr>
- <td width='30%'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr valign='top'>
- <td width='1'></td>
- <td><h2>Client / IP Management</h2></td>
- </tr>
- </table>
- </td>
-
- <td width='45%'>
- <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>
- <tr>
- <td colspan='3'>{MAINMENU}</td>
- </tr>
-</table>
-
-<!--<hr align='center' width='98%' noshade>-->
-<br>
-
-
-<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>
- <tr>
- <td>
-
- {IPBLOCKS}
-
- </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/computers/computers.php b/ldap-site-mngmt/webinterface/computers/computers.php
deleted file mode 100644
index ea365d76..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers.php
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "computers_start.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/computers_footer.inc.php b/ldap-site-mngmt/webinterface/computers/computers_footer.inc.php
deleted file mode 100644
index 7849823e..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers_footer.inc.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?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("IPBLOCKS", "IPBlocks");
-$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/computers/computers_header.inc.php b/ldap-site-mngmt/webinterface/computers/computers_header.inc.php
deleted file mode 100644
index d6bc3746..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers_header.inc.php
+++ /dev/null
@@ -1,29 +0,0 @@
-<?php
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "Computers Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-
-
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$definedTemplates = array("Vorlage" => "computers.dwt",
- "Login" => "../logout_form.inc.dwt",
- "Mmenu" => "../hauptmenue.dwt",
- "Menu" => "menu.dwt",
- "IPBlocks" => "../common/ipblocks.dwt",
- "Webseite" => $webseite);
-if (isset($additionalTemplates)) {
- foreach ($additionalTemplates as $templateKey => $templateFile) {
- $definedTemplates[$templateKey] = $templateFile;
- }
-}
-$template->define($definedTemplates);
-$template->assign(array("SEITENTITEL" => $titel, "AU" => $au_ou, "DOMAIN" => $assocdom, "USERCN" => $usercn));
-
-
-include("computers_menu.php");
-include("../common/ip_blocks.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/computers_menu.php b/ldap-site-mngmt/webinterface/computers/computers_menu.php
deleted file mode 100644
index 1ab98526..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers_menu.php
+++ /dev/null
@@ -1,250 +0,0 @@
-<?php
-
-function createComputersMenu($rollen , $mnr, $auDN, $sbmnr, $mcnr) {
-
- global $template, $ds, $suffix, $START_PATH;
-
- $mipb_array = get_maxipblocks_au($auDN);
- #print_r($mipb_array);
- if ( $mipb_array[0] == "" ){
- $iprechnerlink = "no_ip.php?mnr=2";
- }else{
- $iprechnerlink = "ip_rechner.php?sort=ipaddress";
- }
-
- # Struktur der Registerkartenleiste
- # Hauptmenu
- $hauptmenu = array( #array("link" => "computers.php",
- # "text" => "&Uuml;bersicht",
- # "zugriff" => array("MainAdmin","HostAdmin","DhcpAdmin")),
- array("link" => "hostoverview.php?sort=hostname",
- "text" => "&Uuml;bersicht Rechner",
- "zugriff" => array("MainAdmin","HostAdmin","DhcpAdmin")),
- array("link" => $iprechnerlink,
- "text" => "IP Adressen Rechner",
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin")),
- #array("link" => "groupoverview.php",
- # "text" => "Rechnergruppen",
- # "zugriff" => array("MainAdmin")),
- #array("link" => "machineconfig_default.php",
- # "text" => "Default MachineConfigs",
- # "zugriff" => array("MainAdmin","HostAdmin")),
- #array("link" => "new_mcdef.php",
- # "text" => "Neue MachineConfig",
- # "zugriff" => array("MainAdmin","HostAdmin")),
- array("link" => "pxeconfigs.php",
- "text" => "PXE Configs",
- "zugriff" => array("MainAdmin","DhcpAdmin")));
-
- # Submenus
- /*$computers_array = get_hosts($auDN,array("dn","hostname","ou"));
- for($n=0;$n<count($computers_array);$n++){
-
- $comps[] = array("link" => "host.php?dn=".$computers_array[$n]['dn']."&sbmnr=".$n,
- "text" => $computers_array[$n]['hostname'],
- "zugriff" => array("MainAdmin","HostAdmin","DhcpAdmin"));
- # print_r($comps); echo "<br>";
- }*/
- $comps[] = array("link" => "new_host.php?sbmnr=0", #.$n,
- "text" => "Neuen Rechner anlegen",
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin"));
-
- $groups_array = get_groups($auDN,array("dn","cn"));
- for($n=0;$n<count($groups_array);$n++){
-
- $groups = array();
- $groups[] = array("link" => "group.php?dn=".$groups_array[$n]['dn']."&sbmnr=".$n,
- "text" => $groups_array[$n]['cn'],
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin"));
-
- }
- $groups[] = array("link" => "new_group.php?sbmnr=".$n,
- "text" => "Neue Gruppe anlegen",
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin"));
-
- # default machine-configs
- $mcdef_array = get_machineconfigs("cn=computers,".$auDN,array("dn","cn","timerange"));
- for($n=0;$n<count($mcdef_array);$n++){
- $defmc [] = array("link" => "mcdef.php?dn=".$mcdef_array[$n]['dn']."&mnr=3&sbmnr=".$n,
- "text" => $mcdef_array[$n]['cn'],
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin"));
- }
-
- $newpxe[] = array("link" => "new_pxe.php",
- "text" => "Neue PXE Config anlegen",
- "zugriff" => array("MainAdmin","DhcpAdmin"));
-
- $submenu = array(#array(),
- $comps,
- array(),
- #$groups,
- #$defmc,
- $newpxe);
- #echo "submenu: ";print_r($submenu);echo "<br><br>";
-
- # 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'])) {
-
- #########################################################################
- # SUBMENU
-
- $subempty = 0;
- $j=0;
- $maxsub = count($submenu[$mnr]);
- #echo "_"; print_r($maxsub); echo "_";
- 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){$zwisch2="branchbottom2";}
- else {$zwisch2="branch2";}
- $lastaktive=true;
- $farb="#505050";
- }
- else{
- if ($maxsub == 1) {$zwisch2="branchbottom2";}
- # Wenn Unter-Unter-Menu ...
- #if(count($subsubmenu[$i][$j][0]) != 0){
- #if($maxsub == 1){$zwisch2="<a href='".$item2['link']."' style='border-style=none;text-decoration:none'>
- # <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
- #else {$zwisch2="<a href='".$item2['link']."' style='border-style=none;text-decoration:none'>
- # <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
- #}
- else{$zwisch2="branch2";}
- $farb="#A0A0A0";
- $lastaktive=false;
- }
- }
- else {
- if ($sbmnr==$j) {
- if($maxsub == $j+1){$zwisch2="branchbottom2";}
- else {$zwisch2="branch2";}
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- if ($maxsub == $j+1) {$zwisch2="branchbottom2";}
- # Wenn Unter-Unter-Menu ...
- #if(count($subsubmenu[$i][$j][0]) != 0){
- # if($maxsub == $i+1){$zwisch2="<a href='".$item2['link']."' style='border-style=none;text-decoration:none'>
- # <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
- # else {$zwisch2="<a href='".$item2['link']."' style='border-style=none;text-decoration:none'>
- # <img style='border-width:0;border-style=none;' src='../pics/plus2.gif'></a>";}
- #}
- else{$zwisch2="branch2";}
- $farb="#A0A0A0";
- $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/".$zwisch2.".gif'></td>
- <td width='5%' align='left' style='border-width:1 0 1 1;border-color:#000000;border-style:solid;padding:4;background-color:{FARBE_S}'>&nbsp;</td>
- <td width='69%' align='left' style='border-width:1 1 1 0;border-color:#000000;border-style:solid;padding:4;padding-left:12px;background-color:{FARBE_S}'>
- <a href='".$item2['link']."' style='text-decoration:none'><code class='submenue_schrift'>".$item2['text']."</code></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");
-
- }
- # SUBMENU
- #####################################################################
-
- 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 {
-
- 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="";}
- $farb="#A0A0A0";
- $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/computers/computers_menu.save.php b/ldap-site-mngmt/webinterface/computers/computers_menu.save.php
deleted file mode 100644
index 183d9309..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers_menu.save.php
+++ /dev/null
@@ -1,188 +0,0 @@
-<?php
-
-function createComputersMenu($roles , $mnr, $auDN, $sbmnr) {
-
- global $template, $ds, $suffix, $START_PATH;
-
- # Struktur der Registerkartenleiste
- # Hauptmenu
- $hauptmenu = array(array("link" => "computers.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => "alle"),
- array("link" => "hostoverview.php",
- "text" => "Rechner",
- "zugriff" => array("MainAdmin")),
- array("link" => "computers.php",
- "text" => "Neuen Rechner anlegen",
- "zugriff" => array("MainAdmin")),
- array("link" => "groupoverview.php",
- "text" => "Rechnergruppen",
- "zugriff" => array("MainAdmin")),
- array("link" => "computers.php",
- "text" => "Neue Gruppe anlegen",
- "zugriff" => array("MainAdmin")));
-
- # Submenu
- $computers_array = get_hosts($auDN,array("dn","hostname","ou"));
- for($n=0;$n<count($computers_array);$n++){
- $comps[] = array("link" => "host.php?dn=".$computers_array[$n]['dn']."&sbmnr=".$n,
- "text" => $computers_array[$n]['hostname'],
- "zugriff" => array("MainAdmin"));
- }
- $groups_array = get_groups($auDN,array("dn","cn"));
- for($n=0;$n<count($groups_array);$n++){
- $groups[] = array("link" => "group.php?dn=".$groups_array[$n]['dn']."&sbmnr=".$n,
- "text" => $groups_array[$n]['cn'],
- "zugriff" => array("MainAdmin"));
- }
- $submenu = array(array(array()),
- $comps,
- array(array()),
- $groups,
- array(array()));
-
- $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]);
- 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='10%'>&nbsp;</td>
- <td width='15%' align='right'><img src='../pics/".$zwisch.".gif'></td>
- <td width='65%' align='left' style='border-width:1 1 1 1;border-color:#000000;border-style:solid;padding:5;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");
- }
-
- 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/computers/computers_start.dwt b/ldap-site-mngmt/webinterface/computers/computers_start.dwt
deleted file mode 100644
index 378e5d76..00000000
--- a/ldap-site-mngmt/webinterface/computers/computers_start.dwt
+++ /dev/null
@@ -1,42 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - Rechner und Rechnergruppen Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung der Rechner und Rechnergruppen in ihrer Abteilung
- (AU), inklusive ihrer spezifischen Rechner- und PXE Boot Konfigurationen<br>
- Benutzen Sie die Navigation links, um die einzelnen Verwaltungsbereiche anzusteuern:</p>
- <ul>
- <li><p><b>Rechner</b></p>
- Hier verwalten Sie ihre Rechner (anlegen, bearbeiten, l&ouml;schen), und k&ouml;nnen zu dem
- einige Hardware-Parameter festlegen. Daneben verwalten Sie hier rechner-spezifische
- Computer-Profile (MachineConfig) und PXE Boot Konfigurationen.
- </li>
- <li><p><b>Rechnergruppen</b></p>
- Hier verwalten Sie die Rechnergruppen (anlegen, bearbeiten, l&ouml;schen), sowie
- ihre gemeinsamen Hardware-Parameter. Daneben verwalten Sie hier gruppen-spezifische
- Computer-Profile (MachineConfig) und PXE Boot Konfigurationen.
- </li>
- <!-- <li><p><b>Default MachineConfig</b></p>
- Hier verwalten Sie ihre Default Computer-Profile (bearbeiten, l&ouml;schen, kopieren),
- d.h. Computer-Profile, die beim booten von Rechnern verwendet werden, f&uuml;r die
- keine rechner- oder gruppen-spezifischen MachineConfigs angelegt sind.
- </li>
- <li><p><b>Neue MachineConfig</b></p>
- Hier k&ouml;ennen Sie neue Computer-Profile (MachineConfigs) als rechner-, gruppen-
- spezifische, oder Default MachineConfigs anlegen.
- </li> -->
- <li><p><b>Neues PXE Bootmen&uuml;</b></p>
- Hier k&ouml;nnen Sie neue PXE Bootmen&uuml;s (PXEConfigs) f&uuml;r ihre Rechner oder
- Rechnergruppen anlegen.
- </li>
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/delete_confirm.php b/ldap-site-mngmt/webinterface/computers/delete_confirm.php
deleted file mode 100644
index 32eb4cf4..00000000
--- a/ldap-site-mngmt/webinterface/computers/delete_confirm.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$dn = $_POST['dn'];
-$name = $_POST['name'];
-$dhcphlpcont = $_POST['dhcphlpcont'];
-$delurl = $_POST['delurl'];
-$backurl = $_POST['backurl'];
-$successurl = $_POST['successurl'];
-
-$pxedn = $_POST['pxedn'];
-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='dhcphlpcont' value='".$dhcphlpcont."'>
- <input type='hidden' name='successurl' value='".$successurl."'>
- <input type='hidden' name='pxedn' value='".$pxedn."'>
- <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/computers/dhcphost.dwt b/ldap-site-mngmt/webinterface/computers/dhcphost.dwt
deleted file mode 100644
index 3bb5e756..00000000
--- a/ldap-site-mngmt/webinterface/computers/dhcphost.dwt
+++ /dev/null
@@ -1,69 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4>{HOSTLINK} Allgemein </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4><code class='font_object'>DHCP</code></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{RBSLINK} RBS/PXE </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{HWLINK} Geo/Hardware </a></h4></td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='5'><h3>DHCP Setup - Rechner &nbsp;<code class='font_object'> {HOSTNAME} </code> </h3></td>
- </tr>
-
- <tr><td colspan='5'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='dhcphost_change.php' method='post'>
-
- <tr>
- <td width='25%' class='tab_h'><b>DHCP Administration - Diensteinbindung, Optionen</b></td>
- <td width='25%' class='tab_h'><b>&nbsp;</b></td>
- <td width='50%' class='tab_h'><b>&nbsp;</b></td>
- </tr>
-
- <tr valign='top'>
-
- {DHCPCONT}
-
- </tr>
-
- {HOST_DHCPOPT}
-
- <!--<tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Default Lease Time:</b></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Max Lease Time:</b></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[dhcpoptmax-lease-time]' value='{MAXLEASE}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptmax-lease-time]' value='{MAXLEASE}'> &nbsp;
- </td>
- </tr>-->
-
- </table></td>
- </tr>
-
-
- <input type='hidden' name='olddhcp' value='{OLDDHCP}'>
- <input type='hidden' name='oldfixadd' value='{OLDFIXADD}'>
- <input type='hidden' name='oldrbs' value='{OLDRBS}'>
- <input type='hidden' name='hostip' value='{IPADDRESS}'>
- <input type='hidden' name='hostmac' value='{HWADDRESS}'>
- <input type='hidden' name='hostdn' value='{HOSTDN}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
-
- <tr>
- <td colspan='4'><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/dhcphost.php b/ldap-site-mngmt/webinterface/computers/dhcphost.php
deleted file mode 100644
index 5e64000d..00000000
--- a/ldap-site-mngmt/webinterface/computers/dhcphost.php
+++ /dev/null
@@ -1,185 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcphost.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$hostDN = $_GET['dn'];
-
-# Rechner Daten
-$attributes = array("hostname","domainname","ipaddress","hwaddress","hlprbservice",
- "dhcphlpcont","dhcpoptfixed-address","dhcpopthardware","dhcpoptfilename",
- "dhcpoptnext-server","dhcpoptmax-lease-time","dhcpoptdefault-lease-time");
-$host = get_node_data($hostDN,$attributes);
-$hostip = explode('_',$host['ipaddress']);
-# print_r($hostip); echo "<br><br>";
-$dhcphlpcont = $host['dhcphlpcont'];
-$dhcpmaxlease = $host['dhcpoptmax-lease-time'];
-$dhcpdefaultlease = $host['dhcpoptdefault-lease-time'];
-$objectDN = $dhcphlpcont;
-$rbsDN = $host['hlprbservice'];
-
-$rbs_dhcpopt = "";
-$host_dhcpopt = "";
-$dhcp_selectbox = "";
-
-##########################################################
-# DHCP Setup
-
-# DHCP Daten
-if ($dhcphlpcont == ""){
- $objecttype = "nodhcp";
-
- # DHCP Selectbox
- $altdhcp = alternative_dhcpobjects($objecttype,$objectDN,$hostip[0]);
- $dhcp_selectbox .= "<td class='tab_d'>
- <select name='dhcpcont' size='3' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>";
- if (count($altdhcp) != 0){
- foreach ($altdhcp as $item){
- $dhcp_selectbox .= "
- <option value='".$item['dn']."'>".$item['cn']." ".$item['au']."</option>";
- }
- }
- $dhcp_selectbox .= "<option value=''>Kein DHCP</option>
- </select></td>";
-
- $dhcp = "<td class='tab_d_ohne' colspan='2'><b>Eingebunden in DHCP Dienst: </b>&nbsp;</td>
- <td class='tab_d_ohne'>
- Rechner ist in keinem DHCP Dienst angemeldet<br></td></tr>
- <tr valign='top'><td class='tab_d' colspan='2'>
- DHCP Dienst ausw&auml;hlen: <br></td>".$dhcp_selectbox;
-
- $rbs = "<td class='tab_d_ohne' colspan='2'>
- Sie m&uuml;ssen den Rechner zuerst in einem DHCP Dienst anmelden, bevor Sie ihn
- einem Remote Boot Dienst zuordnen k&ouml;nnen <br>(DHCP Optionen!!).<br></td>
- </tr>
- <input type='hidden' name='rbs' value='".$rbsDN."'>";
-}else{
- # Host in Service oder Subnet?
- $objecttype = "service";
- $dhcp = "";
-
- /*$ocarray = get_node_data($dhcphlpcont,array("objectclass","dhcphlpcont"));
- #print_r($ocarray); echo "<br>";
- $sub = array_search('dhcpSubnet', $ocarray['objectclass']);
- #print_r($sub);
- if ($sub !== false ){
- $objecttype = "subnet";
- $exp0 = explode(',',$dhcphlpcont);
- $expsub = explode('=',$exp0[0]); $dhcpsub = $expsub[1];
- $dhcp .= "Subnet <b>".$dhcpsub."</b> / ";
- $dhcphlpcont = $ocarray['dhcphlpcont'];
- }*/
-
- $exp1 = explode(',',$dhcphlpcont);
- $expdhcp = explode('=',$exp1[0]); $dhcpserv = $expdhcp[1];
- $expdhcpau = explode('=',$exp1[2]); $dhcpau = $expdhcpau[1];
-
- # DHCP Selectbox
- $altdhcp = alternative_dhcpobjects($objecttype,$objectDN,$hostip[0]);
- $dhcp_selectbox .= "<td class='tab_d'>
- <select name='dhcpcont' size='3' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>";
- if (count($altdhcp) != 0){
- foreach ($altdhcp as $item){
- $dhcp_selectbox .= "
- <option value='".$item['dn']."'>".$item['cn']." ".$item['au']."</option>";
- }
- }
- $dhcp_selectbox .= "<option value=''>Kein DHCP</option>
- </select></td>";
-
- $dhcp .= "<td class='tab_d_ohne' colspan='2'><b>Eingebunden in DHCP Dienst: </b>&nbsp;</td>
- <td class='tab_d_ohne'>
- Service <b>".$dhcpserv."</b> / AU <b>".$dhcpau."</b><br></td></tr>
- <tr valign='top'><td class='tab_d' colspan='2'>
- DHCP Dienst &auml;ndern: <br></td>".$dhcp_selectbox;
-
-
- $fixedaddselopt = "<option selected value='none'>------------</option>";
- switch ( $host['dhcpoptfixed-address'] ){
- case "":
- $fixedaddress = "<b> - </b> <br>(dynamische Vergabe)";
- if ( $hostip[0] != "" ){
- $fixedaddselopt .= "<option value='ip'>".$hostip[0]." &nbsp;(IP Adresse)</option>";
- }
- $fixedaddselopt .= "<option value='hostname'>".$host['hostname']." &nbsp;(Hostname)</option>";
- break;
- case "ip":
- $fixedaddress = "<b>".$hostip[0]."</b><br>(Fixe IP Adresse)";
- $fixedaddselopt .= "<option value='hostname'>".$host['hostname']." &nbsp;(Hostname)</option>
- <option value=''>kein Eintrag &nbsp;(dynamische IP Vergabe)</option>";
- break;
- case "hostname":
- $fixedaddress = "<b>".$host['hostname']."</b><br>(Fixe IP Adresse &uuml;ber DNS aufgel&ouml;st)";
- if ( $hostip[0] != "" ){
- $fixedaddselopt .= "<option value='ip'>".$hostip[0]." &nbsp;(IP Adresse)</option>";
- }
- $fixedaddselopt .= "<option value=''>kein Eintrag (dynamisch)</option>";
- break;
- }
-
-
- $host_dhcpopt = "<tr><td class='tab_d_ohne' colspan='2'><b>DHCP Optionen:</b></td></tr>
- <tr valign='top'>
- <td class='tab_d_ohne'><b>hardware ethernet: </b>&nbsp;</td>
- <td class='tab_d_ohne'><b>".$host['hwaddress']."</b>&nbsp;</td>
- <td class='tab_d_ohne'>&nbsp;</td>
- </tr>
- <tr valign='top'>
- <td class='tab_d'><b>fixed-address:</b> &nbsp;</td>
- <td class='tab_d'>".$fixedaddress."&nbsp;</td>
- <td class='tab_d'>
- <select name='fixadd' size='3' class='medium_form_selectbox'>
- ".$fixedaddselopt."
- </select>
- </td>
- </tr>";
-
-}
-
-$template->assign(array("HOSTDN" => $hostDN,
- "HOSTNAME" => $host['hostname'],
- #"DOMAINNAME" => $host['domainname'],
- "HWADDRESS" => $host['hwaddress'],
- "IPADDRESS" => $hostip[0],
- "OLDDHCP" => $objectDN,
- "OLDFIXADD" => $host['dhcpoptfixed-address'],
- "OLDRBS" => $rbsDN,
- "DHCPCONT" => $dhcp,
- "HOST_DHCPOPT" => $host_dhcpopt,
- "NEXTSERVER" => $host['dhcpoptnext-server'],
- "FILENAME" => $host['dhcpoptfilename'],
- "DEFAULTLEASE" => $dhcpdefaultlease,
- "MAXLEASE" => $dhcpmaxlease,
- "HOSTLINK" => "<a href='host.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "RBSLINK" => "<a href='rbshost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "HWLINK" => "<a href='hwhost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "AUDN" => $auDN,
- "SBMNR" => $sbmnr));
-
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/dhcphost_change.php b/ldap-site-mngmt/webinterface/computers/dhcphost_change.php
deleted file mode 100644
index cbfa7f9f..00000000
--- a/ldap-site-mngmt/webinterface/computers/dhcphost_change.php
+++ /dev/null
@@ -1,236 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$syntax = new Syntaxcheck;
-
-$dhcp = $_POST['dhcpcont'];
-$olddhcp = $_POST['olddhcp'];
-
-$hostDN = $_POST['hostdn'];
-$hostip = $_POST['hostip'];
-$hostmac = $_POST['hostmac'];
-$fixedaddress = $_POST['fixadd'];
-$oldfixedaddress = $_POST['oldfixadd'];
-$oldrbs = $_POST['oldrbs'];
-
-$sbmnr = $_POST['sbmnr'];
-
-$dhcp = htmlentities($dhcp);
-$olddhcp = htmlentities($olddhcp);
-
-# 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>";
-
-/*echo "new dhcp:"; print_r($dhcp); echo "<br>";
-echo "old dhcp:"; print_r($olddhcp); echo "<br>";
-echo "new rbs:"; print_r($rbs); echo "<br>";
-echo "old rbs:"; print_r($oldrbs); echo "<br>";
-echo "Host DN:"; print_r($hostDN); echo "<br>";
-echo "submenuNR:"; print_r($sbmnr); echo "<br><br>";*/
-
-
-$seconds = 2;
-$url = 'dhcphost.php?dn='.$hostDN.'&sbmnr='.$sbmnr;
-
-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>";
-
-##########################################
-# DHCP Einbindung
-
-if ($dhcp != "none" && $dhcp != $olddhcp){
- if ($dhcp != ""){
- $exp = ldap_explode_dn($dhcp, 1);
- $dhcpcn = $exp[0];
- $dhcpau = $exp[2];
-
- $entrydhcp ['dhcphlpcont'] = $dhcp;
- if ($olddhcp != ""){
- echo "DHCP replace "; print_r($olddhcp); echo " with "; print_r($entrydhcp); echo "<br>";
- if ($result = ldap_mod_replace($ds,$hostDN,$entrydhcp)){
- update_dhcpmtime(array());
- $mesg = "Rechner erfolgreich in DHCP <b>".$dhcpcn." [Abt.: ".$dhcpau."]</b> angemeldet<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des DHCP Dienstes zu <b>".$dhcpcn."</b>!<br><br>";
- }
- }else{
- if ( $hostmac != ""){
- if ( $hostip != "" ){
- $entrydhcp ['dhcpoptfixed-address'] = "ip";
- }
- echo "DHCP add "; print_r($entrydhcp); echo "<br>";
- if ($result = ldap_mod_add($ds,$hostDN,$entrydhcp)){
- update_dhcpmtime(array());
- $mesg = "Rechner erfolgreich in DHCP <b>".$dhcpcn." [Abt.: ".$dhcpau."]</b> angemeldet<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des DHCP Dienstes zu <b>".$dhcpcn."</b>!<br><br>";
- }
- }else{
- $mesg = "Es ist keine MAC Adresse f&uuml;r den Rechner eingetragen.<br>
- Dies ist jedoch Voraussetzung f&uuml;r einen DHCP Eintrag.<br><br>";
- }
- }
- }else{
- $entrydhcp ['dhcphlpcont'] = array();
- if ( $oldfixedaddress != "" ){
- $entrydhcp ['dhcpoptfixed-address'] = array();
- }
- #if ( $oldrbs != "" ){
- # $entrydhcp ['hlprbservice'] = array();
- #}
- echo "DHCP delete "; echo "<br>";
- if ($result = ldap_mod_del($ds,$hostDN,$entrydhcp)){
- update_dhcpmtime(array());
- $mesg = "Rechner erfolgreich aus DHCP gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen aus DHCP Dienst!<br><br>";
- }
- }
-
-}
-if ($dhcp == "none"){
- echo " DHCP none <br>";
-}
-
-
-#############################
-# DHCP Option fixed-address
-
-if ($fixedaddress != "none" && $fixedaddress != $oldfixedaddress){
- if ($fixedaddress != ""){
- $entryfixadd ['dhcpoptfixed-address'] = $fixedaddress;
- if ($oldfixedaddress != ""){
- echo "Fixed Address &auml;ndern"; echo "<br>";
- if ($result = ldap_mod_replace($ds,$hostDN,$entryfixadd)){
- update_dhcpmtime(array());
- $mesg = "Option Fixed-Address erfolgreich auf <b>".$fixedaddress."</b> ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern der Option Fixed-Address auf <b>".$fixedaddress."</b>!<br><br>";
- }
- }else{
- echo "Fixed Address auf IP Adresse setzen"; echo "<br>";
- if ($result = ldap_mod_add($ds,$hostDN,$entryfixadd)){
- update_dhcpmtime(array());
- $mesg = "Option Fixed-Address erfolgreich auf <b>".$fixedaddress."</b> gesetzt<br><br>";
- }else{
- $mesg = "Fehler beim setzen der Option Fixed-Address auf <b>".$fixedaddress."</b>!<br><br>";
- }
- }
- }else{
- $entryfixadd ['dhcpoptfixed-address'] = array();
- echo "No Fixed Address"; echo "<br>";
- if ($result = ldap_mod_del($ds,$hostDN,$entryfixadd)){
- update_dhcpmtime(array());
- $mesg = "Option Fixed-Address erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen der Option Fixed-Address!<br><br>";
- }
- }
-}
-
-#####################################
-# Restliche Attribute ...
-
-#if (count($atts) != 0){
-
- $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,$hostDN,$entryadd)){
- $mesg = "Attribute ".$addatts." erfolgreich eingetragen<br><br>";
- update_dhcpmtime(array());
- }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,$hostDN,$entrymod)){
- $mesg = "Attribute ".$modatts." erfolgreich geaendert<br><br>";
- update_dhcpmtime(array());
- }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,$hostDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- update_dhcpmtime(array());
- }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/computers/group.dwt b/ldap-site-mngmt/webinterface/computers/group.dwt
deleted file mode 100644
index cda53f18..00000000
--- a/ldap-site-mngmt/webinterface/computers/group.dwt
+++ /dev/null
@@ -1,397 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Daten bearbeiten Gruppe &nbsp;<code class='font_object'>{GROUPCN}</code>&nbsp; </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='group_change.php' method='post'>
-
- <tr>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='55%' 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 Gruppenname (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='groupcn' value='{GROUPCN}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldgroupcn' value='{GROUPCN}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Beschreibung: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='groupdesc' value='{GROUPDESC}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldgroupdesc' value='{GROUPDESC}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Gruppen-Rechner:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
-
- <b>Aktuelle Mitglieder</b> (zum L&ouml;schen bitte H&auml;kchen setzen):<br>
- <!-- BEGIN DYNAMIC BLOCK: Members -->
- <input type='checkbox' name='delmember[]' value='{MEMBERDN}' size='40' class='medium_form_field'>&nbsp;&nbsp;{MEMBER}<br>
- <!-- END DYNAMIC BLOCK: Members -->
- <br>
-
- <b>Als neues Mitglied aufnehmen</b> (Mehrfachauswahl m&ouml;glich)<br>
- <select name='addmember[]' size='{HOSTNUMBER}' multiple class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}_{HN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- </select>
- </td>
- </tr>
-
-
- <input type='hidden' name='groupdn' value='{GROUPDN}'>
- <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>Gruppe - <code class='font_object'>{GROUPCN}</code> - 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;'>
- Die Rechnergruppe wird komplett gel&ouml;scht, <br>d.h. inklusive aller spezifisch f&uuml;r sie angelegten
- Hardware-Profile (MachineConfig) und PXE Bootmen&uuml;s.
- </tr>
-
- <input type='hidden' name='dn' value='{GROUPDN}'>
- <input type='hidden' name='name' value='{GROUPCN}'>
- <input type='hidden' name='delurl' value='group_delete.php'>
- <input type='hidden' name='backurl' value='group.php?dn={GROUPDN}&sbmnr={SBMNR}'>
-
-
- </table></td>
- </tr>
- <tr>
- <td>
- <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
- </form></td>
- </tr>
-
-
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Wochen &Uuml;bersicht Machine Configs Gruppe &nbsp;<code class='font_object'>{GROUPCN}</code>&nbsp; :</h4></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr><td>
- <table cellpadding='0' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 2 0 2 2;'><b>Uhrzeit</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Montag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Dienstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Mittwoch</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Donnerstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Freitag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Samstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 2 2 1;'><b>Sonntag</b></td>
- </tr>
- <tr heigth='2' align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>0</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G0}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G1}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>2</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G2}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G3}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>4</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G4}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G5}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>6</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G6}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G7}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>8</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G8}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G9}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>10</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G10}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G11}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>12</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G12}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G13}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>14</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G14}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G15}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>16</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G16}'>&nbsp;&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G17}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>18</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G18}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G19}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>20</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G20}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G21}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>22</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G22}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{A23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{B23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{C23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{D23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{E23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{F23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 2 1;{G23}'>&nbsp;</td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Legende:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='3' cellspacing='3' border='1' align='left' width='50%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Machine Config</b></td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Farbe</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>Keine Konfiguration &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Legende -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>{DESCRIPTION} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;background-color:{COLOR};'>&nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Legende -->
-
- </table></td>
- </tr>
-
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/group.php b/ldap-site-mngmt/webinterface/computers/group.php
deleted file mode 100644
index cfacd649..00000000
--- a/ldap-site-mngmt/webinterface/computers/group.php
+++ /dev/null
@@ -1,115 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "group.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 2;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$groupDN = $_GET['dn'];
-
-$group = get_node_data($groupDN,array("cn","description","member","dhcphlpcont"));
-
-$template->assign(array("GROUPDN" => $groupDN,
- "GROUPCN" => $group['cn'],
- "GROUPDESC" => $group['description'],
- # "MEMBERS" => $anzahlmember,
- "MEMBER" => $group['member'],
- "DHCPCONT" => $group['dhcphlpcont'],
- "AUDN" => $auDN,
- "SBMNR" => $sbmnr));
-
-$template->define_dynamic("Members", "Webseite");
-
-if ( count($group['member']) == 1 ){
- $member = $group['member'];
- $group = array();
- $group['member'][] = $member;
-}
-
-if ( count($group['member']) != 0 ){
- sort($group['member']);
- foreach ($group['member'] as $member){
- $exp = explode(',',$member);
- $memberexp = explode('=',$exp[0]);
- $membername = $memberexp[1];
- $template->assign(array("MEMBERDN" => $member,
- "MEMBER" => $membername));
- $template->parse("MEMBERS_LIST", ".Members");
- }
-}
-
-##############################################
-# neues Member anlegen ...
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-# print_r($hosts_array); echo "<br><br>";
-$groups = get_groups($auDN, array("member"));
-$template->assign(array("HN" => ""));
-
-foreach ($groups as $group){
- for ($i=0; $i < count($hosts_array); $i++){
- if (count($group['member']) > 1){
- foreach ($group['member'] as $item){
- if ($hosts_array[$i]['dn'] == $item){
- array_splice($hosts_array, $i, 1);
- $i--; # da ja ein Member gelöscht wurde
- }
- }
- }
- if (count($group['member']) == 1){
- if ($hosts_array[$i]['dn'] == $group['member']){
- array_splice($hosts_array, $i, 1);
- }
- }
- }
-}
-#print_r($hosts_array);echo"<br>";
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname'],
- "HOSTNUMBER" => 5));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-
-
-##########################################################
-# MC Wochenübersicht
-$mc_array = get_machineconfigs($groupDN,array("dn","cn","timerange","description"));
-# print_r($mc_array);
-for ($i=0; $i<count($mc_array); $i++){
- # Timerange Komponenten
- if (count($mc_array[$i]['timerange']) > 1 ){
- foreach ($mc_array[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),$mc_array[$i]['description']);
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- }
- }else{
- $exptime = array_merge(explode('_',$mc_array[$i]['timerange']), $mc_array[$i]['description']);
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- }
-}
-include("mc_wochenplan.php");
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/group_add.php b/ldap-site-mngmt/webinterface/computers/group_add.php
deleted file mode 100644
index dfc7fbe7..00000000
--- a/ldap-site-mngmt/webinterface/computers/group_add.php
+++ /dev/null
@@ -1,84 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$groupcn = $_POST['groupcn'];
-$groupdesc = $_POST['groupdesc'];
-$addmember = $_POST['addmember'];
-
-$groupcn = htmlentities($groupcn);
-$groupdesc = htmlentities($groupdesc);
-
-/*
-echo "AU dn:"; print_r($auDN); echo "<br>";
-echo "groupcn:"; print_r($groupcn); echo "<br>";
-echo "groupdesc:"; print_r($groupdesc); echo "<br>";
-echo "members to add:"; print_r($addmember); echo "<br>";
-*/
-
-$seconds = 2;
-
-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>";
-
-if ( $groupcn != ""){
-
- # Formulareingaben anpassen
- $expgr = explode(" ",$groupcn);
- foreach ($expgr as $word){$expuc[] = ucfirst($word);}
- $groupcn = implode(" ",$expuc);
- $groupcn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $groupcn);
-
- # Host Objekt anlegen
- $brothers = get_hosts($auDN,array("groupcn"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['groupcn'] == $groupcn ){
- $mesg = "Es existiert bereits eine Gruppe mit dem eingegebenen Namen (CN)!<br>
- Bitte geben Sie einen anderen Namen (CN) ein.<br><br>";
- $get_groupdesc = str_replace ( " ", "_", $groupdesc );
- $url = "new_group.php?groupcn=Hier_anderen_CN_eingeben&groupdesc=".$get_groupdesc;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0){
- $groupDN = "cn=".$groupcn.",cn=groups,".$auDN;
- # print_r($groupDN); echo "<br>";
-
- if (add_group($groupDN,$groupcn,$groupdesc,$addmember)){
- $mesg .= "<br>Neue Rechnergruppe erfolgreich angelegt<br>";
- }
- else{
- $mesg .= "<br>Fehler beim anlegen der Rechnergruppe!<br>";
- }
-
- $url = 'groupoverview.php';
- }
-}
-
-
-elseif ( $groupcn == ""){
-
- $get_groupdesc = str_replace ( " ", "_", $groupdesc );
- $mesg = "Sie haben den CN der neuen Gruppe nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "new_group.php?ou=Hier_CN_eingeben&groupdesc=".$get_groupdesc;
-}
-
-
-
-
-$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/computers/group_change.php b/ldap-site-mngmt/webinterface/computers/group_change.php
deleted file mode 100644
index cb26a429..00000000
--- a/ldap-site-mngmt/webinterface/computers/group_change.php
+++ /dev/null
@@ -1,252 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$groupcn = $_POST['groupcn'];
-$oldgroupcn = $_POST['oldgroupcn'];
-$groupdesc = $_POST['groupdesc'];
-$oldgroupdesc = $_POST['oldgroupdesc'];
-
-$delmember = $_POST['delmember'];
-
-$addmember = $_POST['addmember'];
-$n = array_search('none',$addmember);
-if ($n === 0 ){array_splice($addmember, $n, 1);}
-
-$groupDN = $_POST['groupdn'];
-$sbmnr = $_POST['sbmnr'];
-
-$syntax = new Syntaxcheck;
-
-$groupcn = htmlentities($groupcn);
-$oldgroupcn = htmlentities($oldgroupcn);
-$groupdesc = htmlentities($groupdesc);
-$oldgroupdesc = htmlentities($oldgroupdesc);
-
-/*
-echo "new groupcn:"; print_r($groupcn); echo "<br>";
-echo "old groupcn:"; print_r($oldgroupcn); echo "<br>";
-echo "new groupdesc:"; print_r($groupdesc); echo "<br>";
-echo "old groupdesc:"; print_r($oldgroupdesc); echo "<br><br>";
-
-echo "members to delete:"; print_r($delmember); echo "<br><br>";
-echo "members to add:"; print_r($addmember); echo "<br><br>";
-
-echo "Group DN:"; print_r($groupDN); echo "<br>";
-echo "submenuNR:"; print_r($submenu); echo "<br><br>";
-*/
-
-$seconds = 2;
-$url = 'group.php?dn='.$groupDN.'&sbmnr='.$sbmnr;
-
-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>";
-
-##############################################
-# CN (DN)
-
-if ( $oldgroupcn == $groupcn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldgroupcn != "" && $groupcn != "" && $oldgroupcn != $groupcn ){
- echo "Gruppenname aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $expgr = explode(" ",$groupcn);
- foreach ($expgr as $word){$expuc[] = ucfirst($word);}
- $groupcn = implode(" ",$expuc);
- $groupcn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $groupcn);
-
-
- $newgroupDN = "cn=".$groupcn.",cn=groups,".$auDN;
- print_r($newgroupDN); echo "<br><br>";
-
- modify_group_dn($groupDN, $newgroupDN);
-
- # newsubmenu holen...
- $url = 'group.php?dn='.$newgroupDN.'&sbmnr='.$sbmnr;
-}
-
-if ( $oldgroupcn != "" && $groupcn == "" ){
- echo "Gruppenname loeschen!<br>
- Dieses ist Teil des DN, Sie werden die Gruppe komplett l&ouml;schen<br><br>";
- echo "Wollen Sie die Gruppe <b>".$oldgroupcn."</b>mit seinen Hardware-Profilen (MachineConfigs)
- und PXE Bootmen&uuml;s wirklich l&ouml;schen?<br><br>
- <form action='group_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$groupDN."'>
- <input type='hidden' name='name' value='".$oldgroupcn."'>
- <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;
-}
-
-
-########################################
-# Member löschen/aufnehmen
-
-if ( count($delmember) == 0 || count($addmember) == 0 ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( count($delmember) != 0 ){
- echo "Gruppen-Mitglieder l&ouml;schen<br>";
- # hier noch Syntaxcheck
- # print_r($delmember); echo "<br><br>";
-
- $i = 0;
- foreach ($delmember as $member){
- $entry['member'][$i] = $member;
- $i++;
- }
- #print_r($entry); echo "<br><br>";
-
- if ($result = ldap_mod_del($ds,$groupDN,$entry)){
- # Fehler hier muessen die verbliebenen Members hin!!!
- # Filenames in PXEs die an der Gruppe hängen anpassen
- $pxes = get_pxeconfigs($groupDN,array("dn"));
- foreach ($pxes as $pxe){
- if ( $entry['member'] > 1 ){
- $j = 0;
- foreach ($entry['member'] as $host){
- $macdata = get_node_data($host, array("hwaddress"));
- $entryfilename ['filename'][$j] = "01-".$macdata['hwaddress'];
- $j++;
- }
- }
- if ( $entry['member'] == 1 ){
- $macdata = get_node_data($entry['member'], array("hwaddress"));
- $entryfilename ['filename'] = "01-".$macdata['hwaddress'];
- }
- ldap_mod_del($ds,$pxe['dn'],$entryfilename);
- }
- $mesg = "Gruppen-Mitglieder erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen der Gruppen-Mitglieder<br><br>";
- }
-}
-
-if ( count($addmember) != 0 ){
-
- echo "Gruppen-Mitglieder anlegen<br>";
- # hier noch Syntaxcheck
- $members = get_node_data($groupDN,array("member"));
- if ( count($members['member']) == 1 ){
- $member = $members['member'];
- $members = array();
- $members['member'][] = $member;
- }
- if (count($members['member']) != 0){
- foreach ($members['member'] as $member){
- $entry2['member'][] = $member;
- }
- }
- $i = 0;
- foreach ($addmember as $member){
- $exp = explode('_',$member);
- # Falls ein neues Mitglied keine MAC hat und an der Gruppe PXEs hängen
- # dann wird diese nicht aufgenommen ...
- $macdata = get_node_data($exp[0], array("hwaddress"));
- $pxes = get_pxeconfigs($groupDN,array("dn","filename"));
- if ( count($pxes) != 0 && $macdata['hwaddress'] == "" ){
- echo "Rechner ".$exp[1]." hat keine MAC Adresse eingetragen. <br>
- F&uuml; die Gruppe sind PXE Bootmen&uuml;s definiert. <br>
- Da MACs f&uuml;r die PXE Datei notwendig ist wird der Rechner nicht aufgenommen!";
- }
- else{
- $entry2['member'][] = $exp[0];
- }
- $i++;
-
- }
-
- #print_r($entry2); echo "<br><br>";
-
- if ($result = ldap_mod_replace($ds, $groupDN, $entry2)){
-
- # PXEs die an der Gruppe hängen anpassen
- $pxes = get_pxeconfigs($groupDN,array("dn"));
- foreach ($pxes as $pxe){
- if ( $entry2['member'] > 1 ){
- $j = 0;
- foreach ($entry2['member'] as $host){
- $macdata = get_node_data($host, array("hwaddress"));
- $entryfilename ['filename'][$j] = "01-".$macdata['hwaddress'];
- $j++;
- }
- }
- if ( $entry2['member'] == 1 ){
- $macdata = get_node_data($entry2['member'], array("hwaddress"));
- $entryfilename ['filename'] = "01-".$macdata['hwaddress'];
- }
- ldap_mod_replace($ds,$pxe['dn'],$entryfilename);
- }
- $mesg = "Gruppen-Mitglieder erfolgreich angelegt<br><br>";
- }else{
- $mesg = "Fehler beim anlegen der Gruppen-Mitglieder<br><br>";
- }
-}
-
-
-#####################################
-# Description
-
-if ( $oldgroupdesc == $groupdesc ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldgroupdesc == "" && $groupdesc != "" ){
- echo "Gruppen-Beschreibung neu anlegen<br>";
- # hier noch Syntaxcheck
- $entry['description'] = $groupdesc;
- if($result = ldap_mod_add($ds,$groupDN,$entry)){
- $mesg = "Gruppen-Beschreibung erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der Gruppen-Beschreibung<br><br>";
- }
-}
-
-if ( $oldgroupdesc != "" && $groupdesc != "" && $oldgroupdesc != $groupdesc ){
- echo "Gruppen-Beschreibung aendern<br>";
- # hier noch Syntaxcheck
- $entry['description'] = $groupdesc;
- if($result = ldap_mod_replace($ds,$groupDN,$entry)){
- $mesg = "Gruppen-Beschreibung erfolgreich geaendert<br><br>";
- }else{
- $mesg = "Fehler beim aendern der Gruppen-Beschreibung<br><br>";
- }
-}
-
-if ( $oldgroupdesc != "" && $groupdesc == "" ){
- echo "Gruppen-Beschreibung loeschen<br>";
- # hier noch Syntaxcheck
- $entry['description'] = $oldgroupdesc;
- if($result = ldap_mod_del($ds,$groupDN,$entry)){
- $mesg = "Gruppen-Beschreibung erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Gruppen-Beschreibung<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/computers/group_delete.php b/ldap-site-mngmt/webinterface/computers/group_delete.php
deleted file mode 100644
index 2a7e3d29..00000000
--- a/ldap-site-mngmt/webinterface/computers/group_delete.php
+++ /dev/null
@@ -1,47 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$groupDN = $_POST['dn'];
-$groupcn = $_POST['name'];
-$groupDN = htmlentities($groupDN);
-$groupcn = htmlentities($groupcn);
-
-/*
-echo "AU dn:"; print_r($auDN); echo "<br>";
-echo "groupdn:"; print_r($groupDN); echo "<br>";
-echo "groupcn:"; print_r($groupcn); echo "<br>";
-*/
-
-$seconds = 1;
-$url = 'groupoverview.php';
-
-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>";
-
-if ( $groupDN != ""){
-
- if ( delete_group($groupDN) ){
- $mesg = "Rechnergruppe <b>".$groupcn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen der Rechnergruppe <b>".$groupcn."</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/computers/groupoverview.dwt b/ldap-site-mngmt/webinterface/computers/groupoverview.dwt
deleted file mode 100644
index d875c3be..00000000
--- a/ldap-site-mngmt/webinterface/computers/groupoverview.dwt
+++ /dev/null
@@ -1,38 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Rechnergruppen &nbsp;<code class='font_object'>{AU}</code>&nbsp; </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='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Rechnergruppe</b></td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Anzahl Rechner</b></td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP</b></td>
- </tr>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Gruppen -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{GROUPCN} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{MEMBERS} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{DHCPCONT} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Gruppen -->
-
- </table></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- Zum Verwalten einer bestimmten Gruppe, w&auml;hlen Sie links entsprechenden Submen&uuml;-Eintrag.<br>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/groupoverview.php b/ldap-site-mngmt/webinterface/computers/groupoverview.php
deleted file mode 100644
index d14b9d0f..00000000
--- a/ldap-site-mngmt/webinterface/computers/groupoverview.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "groupoverview.dwt";
-include('computers_header.inc.php');
-
-$mnr = 2;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$template->assign(array("DN" => "",
- "GROUPCN" => "Noch keine Rechnergruppen angelegt",
- "GROUPDESC" => "",
- "MEMBERS" => "",
- "DHCPCONT" => ""));
-
-$attributes = array("dn","cn","member","description","dhcphlpcont");
-$group_array = get_groups($auDN,$attributes);
-
-$template->define_dynamic("Gruppen", "Webseite");
-
-foreach ($group_array as $group){
-
- $groupname = "<a href='group.php?dn=".$group['dn']."&sbmnr=".$i."' class='headerlink'>".$group['cn']."</a>";
- $anzahlmember = count($group['member']);
-
- if ( count($group['dhcphlpcont']) != 0 ){
- $subnetCN = explode('cn=',$group['dhcphlpcont']);
- $subnet = explode(',', $subnetCN[1]);
- $dhcpcont = "Subnet $subnet[0]";
- }else{$dhcpcont = "";}
-
- $template->assign(array("DN" => $group['dn'],
- "GROUPCN" => $groupname,
- "GROUPDESC" => $group['description'],
- "MEMBERS" => $anzahlmember,
- # "MEMBER" => $group['member'],
- "DHCPCONT" => $dhcpcont,
- "AUDN" => $auDN ));
- $template->parse("GRUPPEN_LIST", ".Gruppen");
-}
-
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/host.dwt b/ldap-site-mngmt/webinterface/computers/host.dwt
deleted file mode 100644
index 4b3780a2..00000000
--- a/ldap-site-mngmt/webinterface/computers/host.dwt
+++ /dev/null
@@ -1,126 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4><code class='font_object'>Allgemein</code></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{DHCPLINK} DHCP </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{RBSLINK} RBS/PXE </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{HWLINK} Geo/Hardware </a></h4></td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
-
- <tr>
- <td colspan='5'><h3>Administration Rechner &nbsp;<code class='font_object'> {HOSTNAME} </code> </h3></td>
- </tr>
-
- <tr><td colspan='5'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='host_change.php' method='post'>
-
- <tr>
- <td width='45%' class='tab_h'><b>Attribut</b></td>
- <td width='55%' class='tab_h'><b>Wert</b></td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>Eindeutiger Rechnername (hostname):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='hostname' value='{HOSTNAME}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldhostname' value='{HOSTNAME}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>Rechner Beschreibung: &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='desc' value='{DESCRIPTION}' size='40' class='medium_form_field'>
- <input type='hidden' name='olddesc' value='{DESCRIPTION}'>
- &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>MAC Adresse:</b> </td>
- <td class='tab_d'>
- <input type='Text' name='mac' value='{HWADDRESS}' size='17' maxlength='17' class='medium_form_field'>
- <input type='hidden' name='oldmac' value='{HWADDRESS}'>
- (Format hex:hex:hex:hex:hex:hex)&nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td class='tab_d'><b>IP Adresse:</b> &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='ip' value='{IPADDRESS}' size='15' maxlength='15' class='medium_form_field'>
- <input type='hidden' name='oldip' value='{IPADDRESS}'>
- (Format xx.xx.xx.xx)&nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='dhcphlpcont' value='{DHCPCONT}'>
- <input type='hidden' name='dhcptype' value='{DHCPTYPE}'>
- <input type='hidden' name='fixadd' value='{FIXADD}'>
- <input type='hidden' name='hostdn' value='{HOSTDN}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
-
- </table></td>
- </tr>
- <tr>
- <td colspan='4'><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
- <!--<tr>
- <td height='40'></td>
- </tr>
-
- <tr>
- <td colspan='4'><h4>Rechner &nbsp;<code class='font_object'>{HOSTNAME}</code>&nbsp; kopieren:</h4>
- Geben Sie bitte den eindeutigen, noch nicht verwendeten Namen des neuen Rechnerobjekts an.</td>
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <form action='host_copy.php' method='post'>
-
- </table></td>
- </tr><tr><td>
- <input type='Submit' name='apply' value='kopieren' class='small_loginform_button'>
- </form></td></tr>
-
- <tr>-->
-
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='4'><h4>Rechner &nbsp;<code class='font_object'>{HOSTNAME}</code>&nbsp; l&ouml;schen:</h4></td>
- </tr>
- <tr>
- <td colspan='4'>
- <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 Rechner wird komplett gel&ouml;scht, <br>d.h. inklusive aller spezifisch f&uuml;r ihn angelegten
- Hardware-Profile (MachineConfig) und PXE Bootmen&uuml;s.
- </tr>
-
- <input type='hidden' name='dn' value='{HOSTDN}'>
- <input type='hidden' name='name' value='{HOSTNAME}'>
- <input type='hidden' name='dhcphlpcont' value='{DHCPCONT}'>
- <input type='hidden' name='delurl' value='host_delete.php'>
- <input type='hidden' name='backurl' value='host.php?dn={HOSTDN}&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/computers/host.php b/ldap-site-mngmt/webinterface/computers/host.php
deleted file mode 100644
index 454847bb..00000000
--- a/ldap-site-mngmt/webinterface/computers/host.php
+++ /dev/null
@@ -1,92 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "host.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$hostDN = $_GET['dn'];
-
-$attributes = array("hostname","domainname","ipaddress","hwaddress","description","dhcphlpcont","dhcpoptfixed-address",
- "hw-mouse","hw-graphic","hw-monitor");
-$host = get_node_data($hostDN,$attributes);
-$hostip = explode('_',$host['ipaddress']);
-
-# dhcp Typ
-if ($host['dhcphlpcont'] == ""){
- $dhcptype = "nodhcp";
-}else{
- $ocarray = get_node_data($host['dhcphlpcont'],array("objectclass"));
- $subnet = array_search('dhcpSubnet', $ocarray['objectclass']);
- if ($subnet !== false ){
- $dhcptype = "subnet";
- }
- $service = array_search('dhcpService', $ocarray['objectclass']);
- if ($service !== false ){
- $dhcptype = "service";
- }
-}
-#print_r($dhcptype);
-
-$template->assign(array("HOSTDN" => $hostDN,
- "HOSTNAME" => $host['hostname'],
- "DOMAINNAME" => $host['domainname'],
- "HWADDRESS" => $host['hwaddress'],
- "IPADDRESS" => $hostip[0],
- "DESCRIPTION" => $host['description'],
- "DHCPCONT" => $host['dhcphlpcont'],
- "DHCPTYPE" => $dhcptype,
- "FIXADD" => $host['dhcpoptfixed-address'] ,
- "MOUSE" => $host['hw-mouse'],
- "GRAPHIC" => $host['hw-graphic'],
- "MONITOR" => $host['hw-monitor'],
- "DHCPLINK" => "<a href='dhcphost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "RBSLINK" => "<a href='rbshost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "HWLINK" => "<a href='hwhost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "AUDN" => $auDN,
- "SBMNR" => $sbmnr));
-
-
-##########################################################
-# MC Wochenübersicht
-$mc_array = get_machineconfigs($hostDN,array("dn","cn","timerange","description"));
-# print_r($mc_array);
-for ($i=0; $i<count($mc_array); $i++){
- # Timerange Komponenten
- if (count($mc_array[$i]['timerange']) > 1 ){
- foreach ($mc_array[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),$mc_array[$i]['description']);
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- }
- }else{
- $exptime = array_merge(explode('_',$mc_array[$i]['timerange']), $mc_array[$i]['description']);
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- }
-}
-include("mc_wochenplan.php");
-
-###########################################################
-# PXE Wochenübersicht
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/host_add.php b/ldap-site-mngmt/webinterface/computers/host_add.php
deleted file mode 100644
index 0f01fe75..00000000
--- a/ldap-site-mngmt/webinterface/computers/host_add.php
+++ /dev/null
@@ -1,103 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$hostname = $_POST['hostname'];
-$hostdesc = $_POST['hostdesc'];
-$mac = $_POST['mac'];
-$ip = $_POST['ip'];
-$dhcp = $_POST['dhcpcont'];
-
-$hostname = htmlentities($hostname);
-$hostdesc = htmlentities($hostdesc);
-$mac = htmlentities($mac);
-$mac = strtolower($mac);
-$ip = htmlentities($ip);
-
-/*
-echo "AU dn:"; print_r($auDN); echo "<br>";
-echo "hostname:"; print_r($hostname); echo "<br>";
-echo "hostdesc:"; print_r($hostdesc); echo "<br>";
-echo "mac:"; print_r($mac); echo "<br>";
-echo "ip:"; print_r($ip); echo "<br><br>";
-*/
-
-$attribs = $_POST['attribs'];
-if (count($attribs) != 0){
- foreach (array_keys($attribs) as $key){
- $atts[$key] = htmlentities($attribs[$key]);
- }
-}
-
-$seconds = 2;
-
-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>";
-
-if ( $hostname != ""){
-
- # Formulareingaben anpassen
- $exphn = explode(" ",$hostname);
- foreach ($exphn as $word){$expuc[] = ucfirst($word);}
- $hostname = implode(" ",$expuc);
- $hostname = preg_replace ( '/\s+([0-9A-Z])/', '$1', $hostname);
-
- # Host Objekt anlegen
- $brothers = get_hosts($auDN,array("hostname"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['hostname'] == $hostname ){
- $mesg = "Es existiert bereits ein Rechner mit dem eingegebenen HOSTNAME!<br>
- Bitte geben Sie einen anderen HOSTNAME ein.<br><br>";
- $get_hostdesc = str_replace ( " ", "_", $hostdesc );
- $get_mac = str_replace ( " ", "_", $mac );
- $get_ip = str_replace ( " ", "_", $ip );
- $url = "new_host.php?hostname=Hier_anderen_HOSTNAME_eingeben&hostdesc=".$get_hostdesc."&mac=".$get_mac."&ip=".$ip;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0){
- $hostDN = "HostName=".$hostname.",cn=computers,".$auDN;
- # print_r($hostDN); echo "<br>";
-
- if (add_host($hostDN,$hostname,$hostdesc,$mac,$ip,$atts,$dhcp)){
- $mesg .= "<br>Neuer Rechner erfolgreich angelegt<br>";
- }
- else{
- $mesg .= "<br>Fehler beim anlegen des Rechners!<br>";
- }
-
- # DHCP
-
- $url = 'hostoverview.php';
- }
-}
-
-
-elseif ( $hostname == ""){
-
- $get_hostdesc = str_replace ( " ", "_", $hostdesc );
- $get_mac = str_replace ( " ", "_", $mac );
- $get_ip = str_replace ( " ", "_", $ip );
- $mesg = "Sie haben den HOSTNAME des neuen Rechners nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "new_host.php?ou=Hier_HOSTNAME_eingeben&hostdesc=".$get_hostdesc."&mac=".$get_mac."&ip=".$ip;
-}
-
-
-
-
-$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/computers/host_change.php b/ldap-site-mngmt/webinterface/computers/host_change.php
deleted file mode 100644
index 63e64f8a..00000000
--- a/ldap-site-mngmt/webinterface/computers/host_change.php
+++ /dev/null
@@ -1,427 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$hostname = $_POST['hostname'];
-$oldhostname = $_POST['oldhostname'];
-$mac = $_POST['mac'];
-$oldmac = $_POST['oldmac'];
-$ip = $_POST['ip'];
-$oldip = $_POST['oldip'];
-$desc = $_POST['desc'];
-$olddesc = $_POST['olddesc'];
-
-$dhcphlpcont = $_POST['dhcphlpcont'];
-$dhcptype = $_POST['dhcptype'];
-$fixadd = $_POST['fixadd'];
-$hostDN = $_POST['hostdn'];
-$sbmnr = $_POST['sbmnr'];
-
-$syntax = new Syntaxcheck;
-
-$hostname = htmlentities($hostname);
-$oldhostname = htmlentities($oldhostname);
-$mac = htmlentities($mac);
-$mac = strtolower($mac);
-$oldmac = htmlentities($oldmac);
-$ip = htmlentities($ip);
-$oldip = htmlentities($oldip);
-$desc = htmlentities($desc);
-$olddesc = htmlentities($olddesc);
-
-/*
-# 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>";
-
-/*
-echo "new hostname:"; print_r($hostname); echo "<br>";
-echo "old hostname:"; print_r($oldhostname); echo "<br>";
-echo "new mac:"; print_r($mac); echo "<br>";
-echo "old mac:"; print_r($oldmac); echo "<br>";
-echo "new ip:"; print_r($ip); echo "<br>";
-echo "old ip:"; print_r($oldip); echo "<br>";
-echo "new desc:"; print_r($desc); echo "<br>";
-echo "old desc:"; print_r($olddesc); echo "<br><br>";
-echo "Host DN:"; print_r($hostDN); echo "<br>";
-echo "submenuNR:"; print_r($submenu); echo "<br><br>";
-*/
-
-$seconds = 2;
-$url = 'host.php?dn='.$hostDN.'&sbmnr='.$sbmnr;
-
-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>";
-
-##############################################
-# Hostname
-
-if ( $oldhostname == $hostname ){
- $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldhostname != "" && $hostname != "" && $oldhostname != $hostname ){
- echo "Hostname &auml;ndern<br><br>";
- # Check ob Host schon existiert in AU/Domain
- $brothers = get_hosts($auDN,array("hostname"),"");
- if ( check_hostname($hostname) ){
- $url = "hostoverview.php";
- $mesg = "Es existiert bereits ein Rechner mit dem Namen $hostname!<br><br>
- Bitte geben Sie einen anderen Namen ein, oder l&ouml;schen
- Sie zun&auml;chst den gleichnamigen Rechner.<br><br>
- <a href=".$url." style='publink'><< &Uuml;bersicht Rechner</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- die;
- }else{
- # Formulareingaben anpassen
- $exphn = explode(" ",$hostname);
- foreach ($exphn as $word){$expuc[] = ucfirst($word);}
- $hostname = implode(" ",$expuc);
- $hostname = preg_replace ( '/\s+([0-9A-Z])/', '$1', $hostname);
-
- $newhostDN = "hostname=".$hostname.",cn=computers,".$auDN;
- # print_r($newhostDN); echo "<br><br>";
- modify_host_dn($hostDN, $newhostDN);
- $hostDN = $newhostDN;
-
- # newsubmenu holen...hosts neu holen, sortieren, ->position
- #$newhosts = get_hosts($auDN,array("dn"));
- #print_r($newhosts); echo "<br><br>";
- #foreach ($newhosts as $item){
- # $newdnarray [] = $item['dn'];
- #}
- #$key = array_search($newhostDN, $newdnarray);
- #print_r($key); echo "<br>";
-
- $url = 'host.php?dn='.$newhostDN.'&sbmnr='.$sbmnr;
- }
-}
-
-if ( $oldhostname != "" && $hostname == "" ){
- echo "Hostname l&ouml;schen!<br>>br>
- Dies ist Teil des DN, Sie werden den Rechner komplett l&ouml;schen<br><br>";
- echo "Wollen Sie den Rechner <b>".$oldhostname."</b> mit seinen Hardware-Profilen (MachineConfigs)
- und PXE Bootmen&uuml;s wirklich l&ouml;schen?<br><br>
- <form action='host_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$hostDN."'>
- <input type='hidden' name='name' value='".$oldhostname."'>
- <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;
-}
-
-
-
-#####################################
-# MAC
-
-if ( $oldmac == $mac ){
- #$mesg = "keine Aenderung<br>";
-}
-
-if ( $oldmac == "" && $mac != "" ){
- echo "MAC neu anlegen<br>";
- # hier noch Syntaxcheck
- if( $syntax->check_mac_syntax($mac) ){
- $entry['hwaddress'] = $mac;
- $result = ldap_mod_add($ds,$hostDN,$entry);
- if($result){
- $mesg = "MAC erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der MAC<br><br>";
- }
- }else{
- echo "Falsche MAC Syntax<br><br>";
- }
-}
-
-if ( $oldmac != "" && $mac != "" && $oldmac != $mac ){
- echo "MAC aendern<br>";
- # hier noch Syntaxcheck
- if( $syntax->check_mac_syntax($mac) ){
- $entry['hwaddress'] = $mac;
- $pxemac = str_replace (":","-",$mac);
- $pxeoldmac = str_replace (":","-",$oldmac);
- $result = ldap_mod_replace($ds,$hostDN,$entry);
- if($result){
- # in den PXEs auch ändern
- $pxes = get_pxeconfigs($hostDN,array("dn","filename"));
- if ( count($pxes) != 0 ){
- foreach ($pxes as $pxe){
- $entrynewmac ['filename'] = "01-".$pxemac;
- ldap_mod_replace($ds,$pxe['dn'],$entrynewmac);
- }
- }
- # und in Gruppen PXEs
- $groups = get_groups_member($auDN,array("dn"),$hostDN);
- if ( count($groups) != 0 ){
- $pxes = get_pxeconfigs($groups[0]['dn'],array("dn","filename"));
- if ( count($pxes) != 0 ){
- foreach ($pxes as $pxe){
- if (count($pxe['filename']) > 1){
- for ($i=0; $i<count($pxe['filename']); $i++){
- if ($pxe['filename'][$i] == $pxeoldmac){
- $entrynewmac ['filename'][$i] = "01-".$pxemac;
- }else{
- $entrynewmac ['filename'][$i] = $pxe['filename'][$i];
- }
- }
- }
- if (count($pxe['filename']) == 1 && $pxe['filename'][$i] == $pxeoldmac){
- $entrynewmac ['filename'] = "01-".$pxemac;
- }
- ldap_mod_replace($ds,$pxe['dn'],$entrynewmac);
- }
- }
- }
- $mesg = "MAC erfolgreich geaendert<br><br>
- Falls Rechner-Konfiguration via File, <b>Client-Conf</b> Dateiname in untergeordneten <br>
- PXEs bitte auch &auml;ndern";
- }else{
- $mesg = "Fehler beim aendern der MAC<br><br>";
- }
- }else{
- echo "Falsche MAC Syntax<br><br>";
- }
-}
-
-if ( $oldmac != "" && $mac == "" ){
- echo "MAC loeschen<br>";
- # check ob PXEs am Rechnerobjekt hängen
- $pxes = get_pxeconfigs($hostDN,array("dn","filename"));
- $groups = get_groups_member($auDN,array("dn"),$hostDN);
- if ( count($groups) != 0 ){
- $pxes2 = get_pxeconfigs($groups[0]['dn'],array("dn","filename"));
- }
- if ( count($pxes) != 0 || count($pxes2) != 0){
- echo "F&uuml;r den Rechner sind PXE Bootmen&uuml;s angelegt welche die MAC Adresse als <br>
- Dateinamen verwenden. Sie k&ouml;ennen die MAC erst l&ouml;schen, wenn Sie diese PXEs <br>
- entfernt haben.<br><br>
- MAC nicht gel&ouml;scht!";
- }
- else{
- $entry['hwaddress'] = $oldmac;
- $dhcptext = "";
- if ($dhcphlpcont != ""){
- $entry['dhcphlpcont'] = array();
- $dhcptext = "Da die MAC-Adresse Voruassetzung f&uuml;r den
- Eintrag DHCP Dienst ist, wurde der Client dort ausgetragen.<br>";
- }
- $result = ldap_mod_del($ds,$hostDN,$entry);
- if($result){
- $mesg = "MAC erfolgreich geloescht.<br>$dhcptext<br>";
- }else{
- $mesg = "Fehler beim loeschen der MAC<br><br>";
- }
- }
-}
-
-
-########################################
-# IP
-
-if ( $oldip == $ip ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldip == "" && $ip != "" ){
- echo "IP neu anlegen<br>";
- # hier noch Syntaxcheck
- if( $syntax->check_ip_syntax($ip) ){
- $newip_array = array($ip,$ip);
- $newip = implode('_',$newip_array);
- # print_r($newip); echo "<br><br>";
- if (new_ip_host($newip,$hostDN,$auDN)){
- $mesg = "IP erfolgreich eingetragen<br><br>";
- #if ($dhcptype == "subnet"){
- # adjust_hostip_dhcpsubnet($ip,$hostDN,$dhcphlpcont);
- #}
- }else{
- $mesg = "Fehler beim eintragen der IP<br><br>";
- }
- }
- else{echo "Falsche IP Syntax<br><br>";}
-}
-
-if ( $oldip != "" && $ip != "" && $oldip != $ip ){
- echo "IP aendern<br>";
- # hier noch Syntaxcheck
- if( $syntax->check_ip_syntax($ip) ){
- $newip_array = array($ip,$ip);
- $newip = implode('_',$newip_array);
- # print_r($newip); echo "<br><br>";
- $oldip_array = array($oldip,$oldip);
- $oldipp = implode('_',$oldip_array);
- if (modify_ip_host($newip,$hostDN,$auDN,$fixadd)){
- $mesg = "IP erfolgreich geaendert<br><br>";
- if ($dhcptype == "subnet"){
- adjust_hostip_dhcpsubnet($ip,$hostDN,$dhcphlpcont);
- }
- adjust_hostip_tftpserverip($oldip,$ip);
- }else{
- $mesg = "Fehler beim aendern der IP<br><br>";
- # oldip die schon gelöscht wurde wieder einfügen
- new_ip_host($oldipp,$hostDN,$auDN);
- }
- }
- else{echo "Falsche IP Syntax<br><br>";}
-}
-
-if ( $oldip != "" && $ip == "" ){
- echo "IP loeschen<br>";
-
- if(delete_ip_host($hostDN,$auDN)){
- $mesg = "IP erfolgreich geloescht<br><br>";
- adjust_hostip_tftpserverip($oldip,"");
- }else{
- $mesg = "Fehler beim loeschen der IP<br><br>";
- }
-}
-
-
-#####################################
-# Description
-
-if ( $olddesc == $desc ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $olddesc == "" && $desc != "" ){
- echo "Rechner-Beschreibung neu anlegen<br>";
- # hier noch Syntaxcheck
- $entry['description'] = $desc;
- $result = ldap_mod_add($ds,$hostDN,$entry);
- if($result){
- $mesg = "Rechner-Beschreibung erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der Rechner-Beschreibung<br><br>";
- }
-}
-
-if ( $olddesc != "" && $desc != "" && $olddesc != $desc ){
- echo "Rechner-Beschreibung aendern<br>";
- # hier noch Syntaxcheck
- $entry['description'] = $desc;
- $result = ldap_mod_replace($ds,$hostDN,$entry);
- if($result){
- $mesg = "Rechner-Beschreibung erfolgreich geaendert<br><br>";
- }else{
- $mesg = "Fehler beim aendern der Rechner-Beschreibung<br><br>";
- }
-}
-
-if ( $olddesc != "" && $desc == "" ){
- echo "Rechner-Beschreibung loeschen<br>";
- # hier noch Syntaxcheck
- $entry['description'] = $olddesc;
- $result = ldap_mod_del($ds,$hostDN,$entry);
- if($result){
- $mesg = "Rechner-Beschreibung erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Rechner-Beschreibung<br><br>";
- }
-}
-
-####################################
-# restliche Attribute
-/*
-$entryadd = array();
-$entrymod = array();
-$entrydel = array();
-
-foreach (array_keys($atts) as $key){
-
- if ( $oldatts[$key] == $atts[$key] ){
- #$mesg = "keine Aenderung<br>";
- }
- 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,$hostDN,$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,$hostDN,$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,$hostDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
- }
-}
-
-*/
-if ( $dhcphlpcont != "" ){
- update_dhcpmtime(array());
-}
-
-$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/computers/host_delete.php b/ldap-site-mngmt/webinterface/computers/host_delete.php
deleted file mode 100644
index 4d7a935b..00000000
--- a/ldap-site-mngmt/webinterface/computers/host_delete.php
+++ /dev/null
@@ -1,51 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$hostDN = $_POST['dn'];
-$hostname = $_POST['name'];
-$dhcphlpcont = $_POST['dhcphlpcont'];
-$hostDN = htmlentities($hostDN);
-$hostname = htmlentities($hostname);
-
-/*
-echo "AU dn:"; print_r($auDN); echo "<br>";
-echo "hostdn:"; print_r($hostDN); echo "<br>";
-echo "hostname:"; print_r($hostname); echo "<br>";
-*/
-
-$seconds = 1;
-$url = 'hostoverview.php';
-
-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>";
-
-if ( $hostDN != ""){
-
- if ( delete_host($hostDN) ){
- if ( $dhcphlpcont != "" ){
- update_dhcpmtime(array());
- }
- $mesg = "Rechner <b>".$hostname."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen von Rechner <b>".$hostname."</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/computers/hostoverview.dwt b/ldap-site-mngmt/webinterface/computers/hostoverview.dwt
deleted file mode 100644
index 2771ff76..00000000
--- a/ldap-site-mngmt/webinterface/computers/hostoverview.dwt
+++ /dev/null
@@ -1,40 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td width='80%'>
- <h3>Rechner &nbsp;<code class='font_object'>{AU}</code>&nbsp; </h3>
- &Uuml;bersicht der in <b>AU {AU}</b> angelegten <b>Rechnerobjekte</b> und Informationen zu diesen:<br>
- Rechnername, IP/MAC Adresse, Status und Art der Einbindung in die zentralen Dienste DHCP / PXE-Remote-Boot (RBS) und eine Beschreibung.<br><br>
- Zur <b>Verwaltungsmaske</b> eines bestimmten Rechners gelangen Sie durch klicken auf entsprechenden Rechnernamen.<br>
- Die <b>Eingabemaske</b> f&uuml;r einen <b>neuen Rechner</b> erreichen Sie &uuml;ber den Men&uuml;punkt links: "Neuen Rechner anlegen".
- </td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr><td colspan='2'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='17%' class='tab_h'><b><a href='hostoverview.php?sort=hostname' class='headerlink'>Rechnername</a></b></td>
- <td width='13%' class='tab_h'><b><a href='hostoverview.php?sort=ipaddress' class='headerlink'>IP Adresse</a></b></td>
- <td width='17%' class='tab_h'><b>MAC Adresse</b></td>
- <td width='9%' class='tab_h'><b>DHCP</b></td>
- <td width='16%' class='tab_h'><b>RBS</b></td>
- <td width='29%' class='tab_h'><b>Beschreibung des Rechners</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Rechner -->
- <tr valign='top' height='45'>
- <td class='tab_d'><b>{HOSTNAME}</b> &nbsp;</td>
- <td class='tab_d'>{IPADDRESS} &nbsp;</td>
- <td class='tab_d'>{HWADDRESS} &nbsp;</td>
- <td class='tab_d'>{FIXADD} &nbsp;</td>
- <td class='tab_d'>{RBSCONT} &nbsp;</td>
- <td class='tab_d'>{DESC} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Rechner -->
-
- </table></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/hostoverview.php b/ldap-site-mngmt/webinterface/computers/hostoverview.php
deleted file mode 100644
index b1728002..00000000
--- a/ldap-site-mngmt/webinterface/computers/hostoverview.php
+++ /dev/null
@@ -1,102 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "hostoverview.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$sort = "hostname";
-$sort = $_GET['sort'];
-
-$template->assign(array("DN" => "",
- "HOSTNAME" => "Noch keine Rechner angelegt",
- "DOMAINNAME" => "",
- "HWADDRESS" => "",
- "IPADDRESS" => "",
- "DHCPCONT" => "",
- "FIXADD" => "",
- "DESC" => "",
- "RBSCONT" => ""));
-
-$attributes = array("dn","hostname","domainname","hwaddress","ipaddress","description","dhcphlpcont","dhcpoptfixed-address","hlprbservice","dhcpoptnext-server");
-$host_array = get_hosts($auDN,$attributes,$sort);
-#print_r($host_array);
-
-if ($sort == "ipaddress"){
- $host_array = array_natsort($host_array, "ipaddress", "ipaddress");
-}
-
-$template->define_dynamic("Rechner", "Webseite");
-
-$i = 0;
-foreach ($host_array as $host){
-
- $hostname = "<a href='host.php?dn=".$host['dn']."&sbmnr=".$i."' class='headerlink'>".$host['hostname']."</a>";
- $hostip = explode('_',$host['ipaddress']);
-
- $dhcpcont = "";
- $dhcpfixadd = "-";
- if ( count($host['dhcphlpcont']) != 0 ){
- $dhcpexpdn = ldap_explode_dn($host['dhcphlpcont'],1);
- $dhcpcn = $dhcpexpdn[0];
- #$ocarray = get_node_data($host['dhcphlpcont'],array("objectclass","dhcphlpcont"));
- #$sub = array_search('dhcpSubnet', $ocarray['objectclass']);
- #if ($sub !== false ){
- # $dhcpcont = "Subnet ".$dhcpexpdn[0]." <br>[".$dhcpexpdn[2]."]";
- #}else{
- $dhcpcont = $dhcpexpdn[0]." <br>[".$dhcpexpdn[2]."]";
- #}
- $dhcpfixadd = "dyn";
- if ( $host['dhcpoptfixed-address'] == "ip" ){
- $dhcpfixadd = "fix";
- }
- if ( $host['dhcpoptfixed-address'] == "hostname" ){
- $dhcpfixadd = "fix (DNS)";
- }
- }
-
-
- $rbscont = "-";
- $dhcpnxtsrv = "";
- if ( count($host['hlprbservice']) != 0 ){
- $rbsexpdn = ldap_explode_dn($host['hlprbservice'],1);
- $dhcpnxtsrv = $host['dhcpoptnext-server'];
- $rbscont = $rbsexpdn[0]." <br>[".$dhcpnxtsrv."]";
-
-
- }
-
- $template->assign(array("DN" => $host['dn'],
- "HOSTNAME" => $hostname,
- "DOMAINNAME" => $host['domainname'],
- "HWADDRESS" => $host['hwaddress'],
- "IPADDRESS" => $hostip[0],
- "DHCPCONT" => $dhcpcont,
- "FIXADD" => $dhcpfixadd,
- "RBSCONT" => $rbscont,
- "DESC" => $host['description'],
- "AUDN" => $auDN ));
- $template->parse("RECHNER_LIST", ".Rechner");
-
- $i++;
-}
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/hwhost.dwt b/ldap-site-mngmt/webinterface/computers/hwhost.dwt
deleted file mode 100644
index 48c2cd1c..00000000
--- a/ldap-site-mngmt/webinterface/computers/hwhost.dwt
+++ /dev/null
@@ -1,74 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4>{HOSTLINK} Allgemein </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{DHCPLINK} DHCP </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{RBSLINK} RBS/PXE </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4><code class='font_object'>Geo/Hardware</code></h4></td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='5'><h3>Geo / Hardware Optionen - Rechner &nbsp;<code class='font_object'> {HOSTNAME} </code> </h3></td>
- </tr>
-
- <tr><td colspan='5'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='hwhost_change.php' method='post'>
-
- <tr>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Geographic Location </b> (Geb&auml;ude, Raum, ...) <b>:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[geolocation]' value='{GEOLOC}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[geolocation]' value='{GEOLOC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Geo Coordinates: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[geoattribut]' value='{GEOATT}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[geoattribut]' value='{GEOATT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>HW Mouse: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[hw-mouse]' value='{MOUSE}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[hw-mouse]' value='{MOUSE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>HW Graphic: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[hw-graphic]' value='{GRAPHIC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[hw-graphic]' value='{GRAPHIC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>HW Monitor: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[hw-monitor]' value='{MONITOR}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[hw-monitor]' value='{MONITOR}'> &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='hostdn' value='{HOSTDN}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
-
- </table></td>
- </tr>
- <tr>
- <td colspan='4'><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/hwhost.php b/ldap-site-mngmt/webinterface/computers/hwhost.php
deleted file mode 100644
index e0b1f7f8..00000000
--- a/ldap-site-mngmt/webinterface/computers/hwhost.php
+++ /dev/null
@@ -1,76 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "hwhost.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$hostDN = $_GET['dn'];
-
-$attributes = array("hostname","domainname","ipaddress","hwaddress","description","dhcphlpcont",
- "hw-mouse","hw-graphic","hw-monitor","geolocation","geoattribut");
-$host = get_node_data($hostDN,$attributes);
-$hostip = explode('_',$host['ipaddress']);
-
-$template->assign(array("HOSTDN" => $hostDN,
- "HOSTNAME" => $host['hostname'],
- "DOMAINNAME" => $host['domainname'],
- "HWADDRESS" => $host['hwaddress'],
- "IPADDRESS" => $hostip[0],
- "DESCRIPTION" => $host['description'],
- "DHCPCONT" => $host['dhcphlpcont'],
- "GEOLOC" => $host['geolocation'],
- "GEOATT" => $host['geoattribut'],
- "MOUSE" => $host['hw-mouse'],
- "GRAPHIC" => $host['hw-graphic'],
- "MONITOR" => $host['hw-monitor'],
- "DHCPLINK" => "<a href='dhcphost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "HOSTLINK" => "<a href='host.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "RBSLINK" => "<a href='rbshost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "AUDN" => $auDN,
- "SBMNR" => $sbmnr));
-
-
-##########################################################
-# MC Wochenübersicht
-$mc_array = get_machineconfigs($hostDN,array("dn","cn","timerange","description"));
-# print_r($mc_array);
-for ($i=0; $i<count($mc_array); $i++){
- # Timerange Komponenten
- if (count($mc_array[$i]['timerange']) > 1 ){
- foreach ($mc_array[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),$mc_array[$i]['description']);
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- }
- }else{
- $exptime = array_merge(explode('_',$mc_array[$i]['timerange']), $mc_array[$i]['description']);
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- }
-}
-include("mc_wochenplan.php");
-
-###########################################################
-# PXE Wochenübersicht
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/hwhost_change.php b/ldap-site-mngmt/webinterface/computers/hwhost_change.php
deleted file mode 100644
index 83ab270d..00000000
--- a/ldap-site-mngmt/webinterface/computers/hwhost_change.php
+++ /dev/null
@@ -1,116 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$syntax = new Syntaxcheck;
-
-$hostDN = $_POST['hostdn'];
-$sbmnr = $_POST['sbmnr'];
-
-# 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>";
-
-
-$seconds = 2;
-$url = 'hwhost.php?dn='.$hostDN.'&sbmnr='.$sbmnr;
-
-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>";
-
-####################################
-# restliche Attribute
-
-$entryadd = array();
-$entrymod = array();
-$entrydel = array();
-
-foreach (array_keys($atts) as $key){
-
- if ( $oldatts[$key] == $atts[$key] ){
- #$mesg = "keine Aenderung<br>";
- }
- 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,$hostDN,$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,$hostDN,$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,$hostDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
- }
-}
-
-#update_dhcpmtime(array());
-
-
-$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/computers/ip_rechner.dwt b/ldap-site-mngmt/webinterface/computers/ip_rechner.dwt
deleted file mode 100644
index 88d67316..00000000
--- a/ldap-site-mngmt/webinterface/computers/ip_rechner.dwt
+++ /dev/null
@@ -1,40 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Folgende IP Adressen haben Sie an Rechner vergeben: </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='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b><a href='ip_rechner.php?sort=hostname' class='headerlink'>Rechner Name</a></b></td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b><a href='ip_rechner.php?sort=ipaddress' class='headerlink'>IP Adresse</a></b></td>
- <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP</b></td>
- </tr>
-
- <form action='ip_rechner_change.php' method='post'>
-
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{HOSTNAME} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='newip[]' value='{IP}' size='15' class='medium_form_field'></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> {DHCPCONT} &nbsp;</td>
- </tr>
- <input type='hidden' name='oldip[]' value='{OLDIP}'>
- <input type='hidden' name='hostdn[]' value='{HOSTDN}'>
- <input type='hidden' name='fixadd[]' value='{FIXADD}'>
- <input type='hidden' name='audn[]' value='{AUDN}'>
-
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- </table></td>
- </tr>
- <tr>
- <td>
- <input type='Submit' name='apply' value='anwenden' class='small_loginform_button'></form>
- </td>
- </tr>
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/ip_rechner.php b/ldap-site-mngmt/webinterface/computers/ip_rechner.php
deleted file mode 100644
index fcc04883..00000000
--- a/ldap-site-mngmt/webinterface/computers/ip_rechner.php
+++ /dev/null
@@ -1,76 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "ip_rechner.dwt";
-
-include('computers_header.inc.php');
-
-#############################################################################
-
-$mnr = 1;
-$sbmnr = -1;
-$mcnr = -1;
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-#############################################################################
-
-$sort = "hostname";
-$sort = $_GET['sort'];
-
-$template->assign(array("IP" => "",
- "OLDIP" => "",
- "DHCPCONT" => "",
- "FIXADD" => "",
- "HOSTNAME" => "Noch keine Rechner angelegt",
- "HOSTDN" => ""));
-
-$host_array = get_hosts($auDN,array("dn","hostname","ipaddress","dhcphlpcont","dhcpoptfixed-address"),$sort);
-# print_r ($host_array);
-
-if ($sort == "ipaddress"){
- $host_array = array_natsort($host_array, "ipaddress", "ipaddress");
-}
-
-$template->define_dynamic("Hosts", "Webseite");
-
-foreach ($host_array as $host){
- $hostip = explode('_',$host['ipaddress']);
-
- $dhcpcont = "";
- $fixadd = "";
- if ( count($host['dhcphlpcont']) != 0 ){ #&& $host['ipaddress'] == "" ){
- $dhcpcont = " dynamisch";
- #$fixadd = $host['dhcpoptfixed-address'];
- #}elseif( count($host['dhcphlpcont']) != 0 && $host['ipaddress'] != "" ){
- if ( $host['dhcpoptfixed-address'] == "ip") {
- $dhcpcont = " fix";
- #$fixadd = $host['dhcpoptfixed-address'];
- }
- if ( $host['dhcpoptfixed-address'] == "hostname") {
- $dhcpcont = " fix (&uuml;ber DNS Name)";
- #$fixadd = $host['dhcpoptfixed-address'];
- }
- $fixadd = $host['dhcpoptfixed-address'];
- }
-
- $template->assign(array("IP" => $hostip[0],
- "OLDIP" => $hostip[0],
- "DHCPCONT" => $dhcpcont,
- "FIXADD" => $fixadd,
- "HOSTNAME" => $host['hostname'],
- "HOSTDN" => $host['dn'],
- "AUDN" => $auDN ));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-
-
-#####################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/ip_rechner_change.php b/ldap-site-mngmt/webinterface/computers/ip_rechner_change.php
deleted file mode 100644
index 4db8bed0..00000000
--- a/ldap-site-mngmt/webinterface/computers/ip_rechner_change.php
+++ /dev/null
@@ -1,122 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-$hostDN = $_POST['hostdn'];
-$oldip = $_POST['oldip'];
-$newip = $_POST['newip'];
-$fixadd = $_POST['fixadd'];
-
-$syntax = new Syntaxcheck;
-$url = "ip_rechner.php";
-
-echo "
-<html>
-<head>
- <title>IP Address Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-
-$diff1 = array_keys(array_diff_assoc($oldip,$newip));
-$diff2 = array_keys(array_diff_assoc($newip,$oldip));
-$tochange = array_unique(array_merge($diff1,$diff2));
-
-foreach ($tochange as $i){
-
- if ( $oldip[$i] == "" && $newip[$i] != "" ){
- echo "neue IP";echo "<br>";echo "<br>";
- echo "<br>";
- echo "alte IP: ";print_r($oldip[$i]);echo "<br>";
- echo "neue IP: ";print_r($newip[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newip[$i])){
- echo "korrekte IP Syntax";
- $newip[$i] = htmlentities($newip[$i]);
- $newip_array = array($newip[$i],$newip[$i]);
- #print_r($newip_array);
- $newipp = implode('_',$newip_array);
- #print_r($newipp);
- $oldip[$i] = htmlentities($oldip[$i]);
- if (new_ip_host($newipp,$hostDN[$i],$auDN)){
- $mesg = "Neue IP Adresse eingetragen<br>";
- # falls Rechner in DHCP -> fixed-address auf IP Setzen...
- # und update_dhcpmtime(array());
- }else{$mesg = "Fehler beim eintragen der neuen IP Adresse<br>";}
- }else{echo "falsche IP Syntax";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldip[$i] != "" && $newip[$i] != "" ){
- echo "aendern IP";echo "<br>";echo "<br>";
- echo "<br>";
- echo "alte IP: ";print_r($oldip[$i]);echo "<br>";
- echo "neue IP: ";print_r($newip[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newip[$i])){
- echo "korrekte IP Syntax";
- $newip[$i] = htmlentities($newip[$i]);
- $newip_array = array($newip[$i],$newip[$i]);
- #print_r($newip_array);
- $newipp = implode('_',$newip_array);
- #print_r($newipp);
- $oldip[$i] = htmlentities($oldip[$i]);
- $oldip_array = array($oldip[$i],$oldip[$i]);
- $oldipp = implode('_',$oldip_array);
- if (modify_ip_host($newipp,$hostDN[$i],$auDN,$fixadd[$i])){
- $mesg = "IP Adresse geaendert<br>";
- adjust_hostip_tftpserverip($oldip[$i],$newip[$i]);
- # Falls Rechner in DHCP
- update_dhcpmtime(array());
- }else{
- $mesg = "Fehler beim aendern der IP Adresse<br>";
- # oldip die schon gelöscht wurde wieder einfügen
- new_ip_host($oldipp,$hostDN[$i],$auDN);}
- }else{echo "falsche IP Syntax";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldip[$i] != "" && $newip[$i] == "" ){
- echo "loeschen IP";echo "<br>";echo "<br>";
- echo "<br>";
- echo "alte IP: ";print_r($oldip[$i]);echo "<br>";
- echo "neue IP: ";print_r($newip[$i]);echo "<br>";
-
- echo "korrekte IP Syntax";
- $newip[$i] = htmlentities($newip[$i]);
- $oldip[$i] = htmlentities($oldip[$i]);
- if (delete_ip_host($hostDN[$i],$auDN)){
- $mesg = "IP Adresse geloescht<br>";
- adjust_hostip_tftpserverip($oldip[$i],"");
- # falls Rechner in DHCP -> fixed-address auf dynamic/Hostname setzen
- update_dhcpmtime(array());
- }else{$mesg = "Fehler beim loeschen der IP Adresse<br>";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- else{
- $mesg = "keine Aenderung<br>";
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
- }
-
-}
-
-echo "
-</td></tr></table>
-</head>
-</html>";
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/machineconfig_default.dwt b/ldap-site-mngmt/webinterface/computers/machineconfig_default.dwt
deleted file mode 100644
index 3596a0ce..00000000
--- a/ldap-site-mngmt/webinterface/computers/machineconfig_default.dwt
+++ /dev/null
@@ -1,323 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Default MachineConfigs (Konfigurationen) &nbsp;<code class='font_object'> {AU} </code> </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='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Machine Config</b></td>
- <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>G&uuml;ltigkeitsdauer (Time Range)</b></td>
- </tr>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Machineconf -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{MCDESC} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{TRANGES} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Machineconf -->
-
- </table></td>
- </tr>
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Wochen &Uuml;bersicht:</h4></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr><td>
- <table cellpadding='0' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 2 0 2 2;'><b>Uhrzeit</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Montag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Dienstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Mittwoch</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Donnerstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Freitag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Samstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 2 2 1;'><b>Sonntag</b></td>
- </tr>
- <tr heigth='2' align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>0</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G0}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G1}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>2</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G2}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G3}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>4</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G4}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G5}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>6</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G6}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G7}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>8</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G8}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G9}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>10</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G10}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G11}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>12</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G12}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G13}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>14</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G14}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G15}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>16</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G16}'>&nbsp;&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G17}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>18</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G18}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G19}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>20</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G20}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G21}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>22</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G22}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{A23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{B23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{C23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{D23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{E23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{F23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 2 1;{G23}'>&nbsp;</td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Legende:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='3' cellspacing='3' border='1' align='left' width='50%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Machine Config</b></td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Farbe</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>Keine Konfiguration &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Legende -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>{MCDESC} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;background-color:{COLOR};'>&nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Legende -->
-
- </table></td>
- </tr>
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/computers/machineconfig_default.php b/ldap-site-mngmt/webinterface/computers/machineconfig_default.php
deleted file mode 100644
index ff52ced8..00000000
--- a/ldap-site-mngmt/webinterface/computers/machineconfig_default.php
+++ /dev/null
@@ -1,70 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "machineconfig_default.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 3;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$template->assign(array("MCDN" => "",
- "MCCN" => "Noch keine Default MachineConfig angelegt",
- "TRANGES" => "",
- "MCDESC" => "Noch keine Default MachineConfig angelegt"));
-
-
-$mc_array = get_machineconfigs("cn=computers,".$auDN,array("dn","cn","timerange","description"));
-# print_r($mc_array);
-
-
-$template->define_dynamic("Machineconf", "Webseite");
-
-for ($i=0; $i<count($mc_array); $i++){
- # Timerange Komponenten
- $trange = "";
- if (count($mc_array[$i]['timerange']) > 1 ){
- foreach ($mc_array[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),$mc_array[$i]['description']);
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59 / ";
- }
- }else{
- $exptime = array_merge(explode('_',$mc_array[$i]['timerange']), $mc_array[$i]['description']);
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59";
- }
-
- $template->assign(array("MCDN" => $mc_array[$i]['dn'],
- "MCCN" => $mc_array[$i]['cn'],
- "TRANGES" => $trange,
- "MCDESC" => $mc_array[$i]['description'],
- "AUDN" => $auDN));
- $template->parse("MACHINECONF_LIST", ".Machineconf");
-}
-
-#get_entry_number($mc_array[3]['dn'],"machineconfig");
-
-include("mc_wochenplan.php");
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/mc_wochenplan.php b/ldap-site-mngmt/webinterface/computers/mc_wochenplan.php
deleted file mode 100644
index 3df7ab82..00000000
--- a/ldap-site-mngmt/webinterface/computers/mc_wochenplan.php
+++ /dev/null
@@ -1,154 +0,0 @@
-<?php
-
-#####################################
-# Wochenübersicht
-
-$template->assign(array("A0" => "","B0" => "","C0" => "","D0" => "","E0" => "","F0" => "","G0" => "",
- "A1" => "","B1" => "","C1" => "","D1" => "","E1" => "","F1" => "","G1" => "",
- "A2" => "","B2" => "","C2" => "","D2" => "","E2" => "","F2" => "","G2" => "",
- "A3" => "","B3" => "","C3" => "","D3" => "","E3" => "","F3" => "","G3" => "",
- "A4" => "","B4" => "","C4" => "","D4" => "","E4" => "","F4" => "","G4" => "",
- "A5" => "","B5" => "","C5" => "","D5" => "","E5" => "","F5" => "","G5" => "",
- "A6" => "","B6" => "","C6" => "","D6" => "","E6" => "","F6" => "","G6" => "",
- "A7" => "","B7" => "","C7" => "","D7" => "","E7" => "","F7" => "","G7" => "",
- "A8" => "","B8" => "","C8" => "","D8" => "","E8" => "","F8" => "","G8" => "",
- "A9" => "","B9" => "","C9" => "","D9" => "","E9" => "","F9" => "","G9" => "",
- "A10" => "","B10" => "","C10" => "","D10" => "","E10" => "","F10" => "","G10" => "",
- "A11" => "","B11" => "","C11" => "","D11" => "","E11" => "","F11" => "","G11" => "",
- "A12" => "","B12" => "","C12" => "","D12" => "","E12" => "","F12" => "","G12" => "",
- "A13" => "","B13" => "","C13" => "","D13" => "","E13" => "","F13" => "","G13" => "",
- "A14" => "","B14" => "","C14" => "","D14" => "","E14" => "","F14" => "","G14" => "",
- "A15" => "","B15" => "","C15" => "","D15" => "","E15" => "","F15" => "","G15" => "",
- "A16" => "","B16" => "","C16" => "","D16" => "","E16" => "","F16" => "","G16" => "",
- "A17" => "","B17" => "","C17" => "","D17" => "","E17" => "","F17" => "","G17" => "",
- "A18" => "","B18" => "","C18" => "","D18" => "","E18" => "","F18" => "","G18" => "",
- "A19" => "","B19" => "","C19" => "","D19" => "","E19" => "","F19" => "","G19" => "",
- "A20" => "","B20" => "","C20" => "","D20" => "","E20" => "","F20" => "","G20" => "",
- "A21" => "","B21" => "","C21" => "","D21" => "","E21" => "","F21" => "","G21" => "",
- "A22" => "","B22" => "","C22" => "","D22" => "","E22" => "","F22" => "","G22" => "",
- "A23" => "","B23" => "","C23" => "","D23" => "","E23" => "","F23" => "","G23" => ""));
-
-#print_r($timeranges); echo "<br>";
-
-# vom spezifischsten zum unspezifischsten :
-# FR_0_7 -> FR_X_X -> X_0_7 -> X_X_X
-$daytime = array();
-$timex = array();
-$dayx = array();
-$allx = array();
-$legend = array();
-if(count($timeranges) != 0){
-foreach ($timeranges as $tr){
- if (count($tr[0]) > 1){
- foreach ($tr as $item){
- if ($item[0] != "X" && $item[1] != "X" && $item[2] != "X" && ($item[0] == "MO" || $item[0] == "DI" || $item[0] == "MI" || $item[0] == "DO" || $item[0] == "FR" || $item[0] == "SA" || $item[0] == "SO")){
- $daytime[] = $item;
- }
- if ($item[0] != "X" && $item[1] == "X" && $item[2] == "X"){
- $timex[] = $item;
- }
- if ($item[0] == "X" && $item[1] != "X" && $item[2] != "X"){
- $dayx[] = $item;
- }
- if ($item[0] == "X" && $item[1] == "X" && $item[2] == "X"){
- $allx[] = $item;
- }
- }
- }else{
- if ($tr[0] != "X" && $tr[1] != "X" && $tr[2] != "X" && ($tr[0] == "MO" || $tr[0] == "DI" || $tr[0] == "MI" || $tr[0] == "DO" || $tr[0] == "FR" || $tr[0] == "SA" || $tr[0] == "SO")){
- $daytime[] = $tr;
- }
- if ($tr[0] != "X" && $tr[1] == "X" && $tr[2] == "X"){
- $timex[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] != "X" && $tr[2] != "X"){
- $dayx[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] == "X" && $tr[2] == "X"){
- $allx[] = $tr;
- }
- }
-}
-
-#print_r($daytime); echo "<br>";
-#print_r($timex); echo "<br>";
-#print_r($dayx); echo "<br>";
-#print_r($allx); echo "<br>";
-
-$daycode = array("MO" => "A", "DI" => "B", "MI" => "C", "DO" => "D", "FR" => "E", "SA" => "F", "SO" => "G");
-$allxcolors = array("#BEBEBE","A0A0A0","#696969","#EEDFCC","#D8BFD8","#505050");
-$dayxcolors = array("#483D8B","#7B68EE","#191970","#8470FF","#708090","#6A5ACD");
-$timexcolors = array("#CDC673","#A2CD5A","#BDB76B","#8B864E","#6B8E23","#CDBE70");
-$daytimecolors = array("880000","#CD6839","#CC3300","#CC6600","#993300","#8B4C39");
-
-
-if (count($allx) != 0){
- $c = 0;
- foreach ($allx as $range){
- foreach ($daycode as $dc){
- for ($i = 0; $i <= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$allxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$allxcolors[$c]);
- $c++;
- }
-}
-
-if (count($dayx) != 0){
- $c = 0;
- foreach ($dayx as $range){
- foreach ($daycode as $dc){
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$dayxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$dayxcolors[$c]);
- $c++;
- }
-}
-
-if (count($timex) != 0){
- $c = 0;
- foreach ($timex as $range){
- $dc = $daycode[$range[0]];
- for ($i = 0; $i<= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$timexcolors[$c].";"));
- }
- $legend[] = array($range ,$timexcolors[$c]);
- $c++;
- }
-}
-
-if (count($daytime) != 0){
- $c = 0;
- foreach ($daytime as $range){
- $dc = $daycode[$range[0]];
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$daytimecolors[$c].";"));
- }
- $legend[] = array($range ,$daytimecolors[$c]);
- $c++;
- }
-}
-
-}
-
-$template->assign(array("MCDESC" => ""));
-#print_r($legend);
-if (count($legend) != 0){
- $template->define_dynamic("Legende", "Webseite");
- foreach ($legend as $item){
- # Timerange Komponente
- $color = $item[1];
- $template->assign(array("TR1" => $item[0][0],
- "TR2" => $item[0][1],
- "TR3" => $item[0][2],
- "MCDESC" => $item[0][3],
- "COLOR" => $color));
- $template->parse("LEGENDE_LIST", ".Legende");
- }
-}
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/mcdef.dwt b/ldap-site-mngmt/webinterface/computers/mcdef.dwt
deleted file mode 100644
index 15f48548..00000000
--- a/ldap-site-mngmt/webinterface/computers/mcdef.dwt
+++ /dev/null
@@ -1,293 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>MachineConfig &nbsp;<code class='font_object'> {MCCN} </code> </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Allgemein:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='mcdef_change.php' method='post'>
-
- <tr>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- <font size='+2'><b>MC_</b></font><input type='Text' name='mccn' value='{MCCN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldmccn' value='{MCCN}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Machine Config <br>Beschreibung: &nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcdesc' value='{MCDESC}' size='60' class='medium_form_field'>
- <input type='hidden' name='oldmcdesc' value='{MCDESC}'>
- &nbsp;
- </td>
- </tr>
-
-
- <tr valign='top'>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>G&uuml;ltigkeitsdauer <br>(Time Range(s)): </b>&nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- Eines der folgenden:<br>
-
- - <b>Datum</b> &nbsp;(dd.mm, z.B. 21.03/01.11) <br>
- - <b>Monatstag</b> &nbsp;(dd, z.B. 01 oder 25) <br>
- - <b>Wochentag</b> &nbsp;(MO, DI, ... , SO) <br>
- - <b>X</b> f&uuml;r <b>t&auml;glich</b>
-
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- - <b>Uhrzeit</b> &nbsp;(Format: hh, z.B. 07-19)<br>
- - <b>X</b> f&uuml;r rund um die Uhr
-
- </td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: TRanges -->
- <tr valign='top'>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>Zum L&ouml;schen einer Time Range<br>H&auml;kchen setzen&nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='checkbox' name='deltr[]' value='{MCDAY}_{MCBEG}_{MCEND}'>
- &nbsp;</td>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='mcday[]' value='{MCDAY}' size='5' maxlength='5' class='medium_form_field'>
- <input type='hidden' name='oldmcday[]' value='{MCDAY}'> &nbsp;<br>
-
-
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='mcbeg[]' value='{MCBEG}' size='2' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldmcbeg[]' value='{MCBEG}'> <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='mcend[]' value='{MCEND}' size='2' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldmcend[]' value='{MCEND}'> <b><font size='+1'>:59</b> Uhr</font><br>
- </td>
- </tr>
- <!-- END DYNAMIC BLOCK: TRanges -->
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>Neue Time Range hinzuf&uuml;gen&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='newmcday' value='' size='5' maxlength='5' class='medium_form_field'>
-
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='newmcbeg' value='' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='newmcend' value='' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:59</b> Uhr</font><br>
-
- </td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Dienste:</h4></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='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='70%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start X: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-x]' value='{X}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-x]' value='{X}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start SNMP: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-snmp]' value='{SNMP}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-snmp]' value='{SNMP}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start SSHD: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-sshd]' value='{SSHD}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-sshd]' value='{SSHD}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start XDMCP: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-xdmcp]' value='{XDMCP}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-xdmcp]' value='{XDMCP}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start RWHOD: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-rwhod]' value='{RWHOD}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-rwhod]' value='{RWHOD}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start PRINT DAEMON: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-printdaemon]' value='{PRINTD}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-printdaemon]' value='{PRINTD}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>TEX Enable: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[tex-enable]' value='{TEX}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[tex-enable]' value='{TEX}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start CRON: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[start-cron]' value='{CRON}' size='10' maxlength='3' class='medium_form_field'>
- <input type='hidden' name='oldattribs[start-cron]' value='{CRON}'> &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Crontab Entries:</b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <!-- BEGIN DYNAMIC BLOCK: Crontab -->
- <input type='Text' name='crontab[]' value='{CRONTAB}' size='60' class='medium_form_field'>
- <input type='hidden' name='oldcrontab[]' value='{CRONTAB}'> &nbsp;<br>
- <!-- END DYNAMIC BLOCK: Crontab -->
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Language: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[language]' value='{LANG}' size='10' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldattribs[language]' value='{LANG}'>
- &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NETBIOS Workgroup: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[netbios-workgroup]' value='{NETBIOS}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldattribs[netbios-workgroup]' value='{NETBIOS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>VMWARE: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vmware]' value='{VMWARE}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldattribs[vmware]' value='{VMWARE}'> &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='nodedn' value='{NODEDN}'>
- <input type='hidden' name='mcdn' value='{MCDN}'>
- <input type='hidden' name='oldmccn' value='{MCCN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
-
- </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>MachineConfig &nbsp;<code class='font_object'>{MCCN}</code>&nbsp; kopieren:</h4>
- Beachten Sie, dass die Time Ranges der Machine Config nicht mit kopiert werden.<br>
- Sie m&uuml;ssen diese anschlie&szlig;end neu setzen. <br>
- Geben Sie bitte den eindeutigen Namen des neuen MachineConfig-Objektes an.
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <form action='mcdef_copy.php' method='post'>
-
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Ziel Objekt:</b><br>
- (Mehrfachauswahl m&ouml;glich)&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
-
- <select name='copytargets[]' size='10' multiple class='medium_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <option value='{DEFDN}'>DEFAULT</option>
-
- <option value='none'>---- RECHNER -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- <option value='none'>---- GRUPPEN -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Groups -->
- <option value='{GDN}'>{GN}</option>
- <!-- END DYNAMIC BLOCK: Groups -->
- </select>
- </td>
- </tr>
- <tr>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+2'><b>MC_</b></font><input type='Text' name='mccncp' value='{MCCN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldmccncp' value='{MCCN}'> &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='mcdn' value='{MCDN}'>
- <input type='hidden' name='oldmccn' value='{MCCN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- <input type='hidden' name='deltr' value='{DELTR}'>
-
- </table></td>
- </tr><tr><td>
- <input type='Submit' name='apply' value='kopieren' class='small_loginform_button'>
- </form></td></tr>
-
- <tr>
- <td height='40'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Default MachineConfig &nbsp;<code class='font_object'>{MCCN}</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;'>
- Die MachineConfig wird komplett gel&ouml;scht.
- </tr>
-
- <input type='hidden' name='dn' value='{MCDN}'>
- <input type='hidden' name='name' value='{MCCN}'>
- <input type='hidden' name='delurl' value='mcdef_delete.php'>
- <input type='hidden' name='backurl' value='mcdef.php?dn={MCDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
-
-
- </table></td>
- </tr><tr><td>
- <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
- </form></td></tr>
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/computers/mcdef.php b/ldap-site-mngmt/webinterface/computers/mcdef.php
deleted file mode 100644
index 51a760ba..00000000
--- a/ldap-site-mngmt/webinterface/computers/mcdef.php
+++ /dev/null
@@ -1,132 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "mcdef.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$mcDN = $_GET['dn'];
-
-$attributes = array("dn","cn","description","timerange","language","start-x","start-snmp","start-sshd",
- "start-xdmcp","start-rwhod","start-cron","start-printdaemon","crontab-entries",
- "tex-enable","netbios-workgroup","vmware");
-$mc = get_node_data($mcDN,$attributes);
-#print_r($mc);
-
-$exp = explode(',',$mcDN);
-$node = array_slice($exp,1);
-$nodeDN = implode(',',$node);
-
-# Timerange Komponenten
-$template->define_dynamic("TRanges", "Webseite");
-if (count($mc['timerange']) > 1){
- foreach($mc['timerange'] as $tr){
- $exptime = explode('_',$tr);
- $template->assign(array("MCDAY" => $exptime[0],
- "MCBEG" => $exptime[1],
- "MCEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
- }
-}else{
- $exptime = explode('_',$mc['timerange']);
- $template->assign(array("MCDAY" => $exptime[0],
- "MCBEG" => $exptime[1],
- "MCEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
-}
-
-$expcn = explode('_',$mc['cn']);
-$name = array_slice($expcn,1);
-$mccn = implode('_',$name);
-
-$template->assign(array("MCDN" => $mcDN,
- "MCCN" => $mccn,
- "MCDESC" => $mc['description'],
- "LANG" => $mc['language'],
- "X" => $mc['start-x'],
- "SNMP" => $mc['start-snmp'],
- "SSHD" => $mc['start-sshd'],
- "XDMCP" => $mc['start-xdmcp'],
- "RWHOD" => $mc['start-rwhod'],
- "CRON" => $mc['start-cron'],
- "CRONTAB" => "",
- "PRINTD" => $mc['start-printdaemon'],
- "TEX" => $mc['tex-enable'],
- "NETBIOS" => $mc['netbios-workgroup'],
- "VMWARE" => $mc['vmware'],
- "NODEDN" => $nodeDN,
- "DEFDN" => "cn=computers,".$auDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-$template->define_dynamic("Crontab", "Webseite");
-if ( count($mc['crontab-entries']) != 0 ){
- if ( count($mc['crontab-entries']) > 1 ){
- foreach ($mc['crontab-entries'] as $crontab){
- $template->assign(array("CRONTAB" => $crontab));
- $template->parse("CRONTAB_LIST", ".Crontab");
- }
- }
- if ( count($mc['crontab-entries']) == 1 ){
- $template->assign(array("CRONTAB" => $mc['crontab-entries']));
- $template->parse("CRONTAB_LIST", ".Crontab");
- }
-}
-$template->assign(array("CRONTAB" => ""));
-$template->parse("CRONTAB_LIST", ".Crontab");
-
-################################################
-# MC kopieren
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-
-# falls TR vorhanden dann soll sie gelöscht werden (flag deltr setzen)
-if (count($mc['timerange']) != 0){
- $template->assign(array("DELTR" => "1"));
-}
-else{
- $template->assign(array("DELTR" => "0"));
-}
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/mcdef_add.php b/ldap-site-mngmt/webinterface/computers/mcdef_add.php
deleted file mode 100644
index efb86e87..00000000
--- a/ldap-site-mngmt/webinterface/computers/mcdef_add.php
+++ /dev/null
@@ -1,160 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mccn = $_POST['mccn']; $mccn = htmlentities($mccn);
-$mcdesc = $_POST['mcdesc']; $mcdesc = htmlentities($mcdesc);
-$mcday = $_POST['mcday']; $mcday = htmlentities($mcday);
-$mcbeg = $_POST['mcbeg']; $mcbeg = htmlentities($mcbeg);
-$mcend = $_POST['mcend']; $mcend = htmlentities($mcend);
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$targets = $_POST['targets'];
-#print_r($targets); echo "<br>";
-$n = array_keys($targets,'none');
-#print_r($n); echo "<br>";
-for ($i=0; $i<count($n); $i++){
- $match = array_search('none',$targets);
- array_splice($targets, $match, 1);
-}
-#echo "Zielobjekte: ";print_r($targets); echo "<br>";
-
-$mcattribs = $_POST['mcattribs'];
-if (count($mcattribs) != 0){
- foreach (array_keys($mcattribs) as $key){
- $mcatts[$key] = htmlentities($mcattribs[$key]);
- }
-}
-# print_r($mcatts); echo "<br><br>";
-
-$seconds = 2;
-$get_mccn = str_replace ( " ", "_", $mccn );
-$get_mcdesc = str_replace ( " ", "_", $mcdesc );
-$get_mcday = str_replace ( " ", "_", $mcday );
-$get_mcbeg = str_replace ( " ", "_", $mcbeg );
-$get_mcend = str_replace ( " ", "_", $mcend );
-$url = "new_mcdef.php?mccn=".$get_mccn."&mcdesc=".$get_mcdesc."&mcday=".$get_mcday."&mcbeg=".$get_mcbeg."&mcend=".$get_mcend."&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>";
-
-if ( $mccn != "" && $mccn != "Hier_MC_NAME_eintragen"){
-
- $mccn = "MC_".$mccn;
- # Formulareingaben anpassen
- $expmc = explode(" ",$mccn);
- foreach ($expmc as $word){$expuc[] = ucfirst($word);}
- $mccn = implode(" ",$expuc);
- $mccn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mccn);
-
- $mctimerange = "";
-
- if (count($targets) != 0){
- foreach ($targets as $targetDN){
-
- $exptargetdn = ldap_explode_dn($targetDN, 1);
- $targetcn = $exptargetdn[0];
- $targettype = $exptargetdn[1];
-
- # Check auf eindeutigen MC-Namen am Zielobjekt
- $brothers = get_machineconfigs($targetDN,array("cn"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['cn'] == $mccn ){
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml; mit dem eingegebenen Namen!<br>
- Bitte geben Sie einen anderen Namen ein.<br><br>";
- $url = "new_mcdef.php?mccn=".$get_mccn."&mcday=".$get_mcday."&mcbeg=".$get_mcbeg."&mcend=".$get_mcend."&mnr=".$mnr."&sbmnr=".$sbmnr;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0){
-
- if ( $mcday != "" && $mcbeg != "" && $mcend != "" && $mcbeg <= $mcend ){
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($mcday,$mcbeg,$mcend)){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$mcday)){$mcday = strtoupper($mcday);}
- if (preg_match("/([a-z]+)/",$mcbeg)){$mcbeg = strtoupper($mcbeg);}
- if (preg_match("/([a-z]+)/",$mcend)){$mcend = strtoupper($mcend);}
-
- # führende Nullen weg
- $mcbeg = preg_replace ( '/0([0-9])/', '$1', $mcbeg);
- $mcend = preg_replace ( '/0([0-9])/', '$1', $mcend);
-
- # TimeRange auf Ãœberschneidung mit vorhandenen checken
- if(check_timerange($mcday,$mcbeg,$mcend,$targetDN,"")){
- $mctimerange = $mcday."_".$mcbeg."_".$mcend;
- }
- else{
- $mesg = "Es existiert bereits eine MachineConfig, die sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Die neue MachineConfig wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschlie&szlig;end ein.<br><br>";
- }
- }
- else{
- $mesg = "Falsche Syntax in der Time-Range-Eingabe! Die neue MachineConfig wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschlie&szlig;end ein.<br><br>";
- }
- }
- else{
- $mesg = "Keine vollst&auml;ndige Time-Range-Eingabe! Die neue MachineConfig wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschlie&szlig;end ein.<br><br>";
- }
-
- $mcDN = "cn=".$mccn.",".$targetDN;
- print_r($mcDN); echo "<br>";
-
- if (add_mc($mcDN,$mccn,$mctimerange,$mcdesc,$mcattribs)){
- $mesg .= "<br>Neue MachineConfig erfolgreich angelegt<br>";
- if ($targettype == "computers"){
- $url = "mcdef.php?dn=".$mcDN."&mnr=1";
- }
- if ($targettype == "groups"){
- $url = "mcdef.php?dn=".$mcDN."&mnr=2";
- }
- if ($targettype == $au_ou){
- $url = "machineconfig_default.php";
- }
- }
- else{
- $mesg .= "<br>Fehler beim anlegen der MachineConfig!<br>";
- }
- }
- }
- }
- else{
- $mesg .= "<br>Sie haben kein Ziel angegeben!<br>";
- }
-}
-
-elseif ( $mccn == "" || $mccn == "Hier_MC_NAME_eintragen"){
-
- $mesg = "Sie haben den Namen der neuen Machine Config nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "new_mcdef.php?mccn=Hier_MC_NAME_eintragen&mcdesc=".$get_mcdesc."&mcday=".$get_mcday."&mcbeg=".$get_mcbeg."&mcend=".$get_mcend."&mnr=".$mnr."&sbmnr=".$sbmnr;
-}
-
-
-
-$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/computers/mcdef_change.php b/ldap-site-mngmt/webinterface/computers/mcdef_change.php
deleted file mode 100644
index 4aaa29fe..00000000
--- a/ldap-site-mngmt/webinterface/computers/mcdef_change.php
+++ /dev/null
@@ -1,402 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mccn = "MC_".$_POST['mccn'];
-$mcdesc = $_POST['mcdesc']; $mcdesc = htmlentities($mcdesc);
-
-$mcday = $_POST['mcday'];
-$mcbeg = $_POST['mcbeg'];
-$mcend = $_POST['mcend'];
-foreach (array_keys($mcday) as $key){
- $mcday[$key] = htmlentities($mcday[$key]);
-}
-foreach (array_keys($mcbeg) as $key){
- $mcbeg[$key] = htmlentities($mcbeg[$key]);
-}
-foreach (array_keys($mcend) as $key){
- $mcend[$key] = htmlentities($mcend[$key]);
-}
-
-$deltr = $_POST['deltr'];
-
-$newmcday = $_POST['newmcday']; $newmcday = htmlentities($newmcday);
-$newmcbeg = $_POST['newmcbeg']; $newmcbeg = htmlentities($newmcbeg);
-$newmcend = $_POST['newmcend']; $newmcend = htmlentities($newmcend);
-
-$oldmcdesc = $_POST['oldmcdesc']; $oldmcdesc = htmlentities($oldmcdesc);
-$oldmcday = $_POST['oldmcday'];
-$oldmcbeg = $_POST['oldmcbeg'];
-$oldmcend = $_POST['oldmcend'];
-
-$crontab = $_POST['crontab'];
-$oldcrontab = $_POST['oldcrontab'];
-foreach (array_keys($crontab) as $key){
- $crontab[$key] = htmlentities($crontab[$key]);
-}
-
-$mcDN = $_POST['mcdn'];
-$oldmccn = "MC_".$_POST['oldmccn'];
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-# sosntige 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>";
-
-
-$seconds = 2;
-$url = "mcdef.php?dn=".$mcDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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>";
-
-##############################################
-# MC CN (DN)
-
-if ( $oldmccn == $mccn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldmccn != "" && $mccn != "" && $oldmccn != $mccn ){
- echo "Machine Config Name aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $expmc = explode(" ",$mccn);
- foreach ($expmc as $word){$expuc[] = ucfirst($word);}
- $mccn = implode(" ",$expuc);
- $mccn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mccn);
-
-
- $newmcDN = "cn=".$mccn.",".$nodeDN;
- print_r($newmcDN); echo "<br><br>";
-
- if(modify_mc_dn($mcDN, $newmcDN)){
- $mesg = "MC Name erfolgreich ge&auml;ndert<br><br>";
- $mcDN = $newmcDN;
- }else{
- $mesg = "Fehler beim &auml;ndern des MC Name!<br><br>";
- }
-
-
- # newsubmenu holen...
- $url = "mcdef.php?dn=".$newmcDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-if ( $oldmccn != "" && $mccn == "" ){
- echo "Gruppenname loeschen!<br>
- Dieses ist Teil des DN, Sie werden die MachineConfig komplett l&ouml;schen<br><br>";
- echo "Wollen Sie die MachineConfig <b>".$oldmccn."</b> wirklich l&ouml;schen?<br><br>
- <form action='mcdef_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$mcDN."'>
- <input type='hidden' name='name' value='".$oldmccn."'>
- <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;
-}
-
-
-##########################################
-# bereits vorhandene TimeRange(s) bearbeiten
-
-$entrymodtr = array();
-$modtr = 0;
-# TimeRanges zusammensetzen
-# $t = 0; # Laufvariable für $entrymodtr, da nicht jede Timerange ok sein muss
-for ($i=0; $i<count($mcday); $i++){
-
-$oldmctimerange = $oldmcday[$i]."_".$oldmcbeg[$i]."_".$oldmcend[$i];
-
-if ( ($mcbeg[$i] <= $mcend[$i]) && ( ($mcday[$i] != $oldmcday[$i] && $mcday[$i] != "") || ($mcbeg[$i] != $oldmcbeg[$i] && $mcbeg[$i] != "") || ($mcend[$i] != $oldmcend[$i] && $mcend[$i] != "")) ){
-
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($mcday[$i],$mcbeg[$i],$mcend[$i])){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$mcday[$i])){$mcday[$i] = strtoupper($mcday[$i]);}
- if (preg_match("/([a-z]+)/",$mcbeg[$i])){$mcbeg[$i] = strtoupper($mcbeg[$i]);}
- if (preg_match("/([a-z]+)/",$mcend[$i])){$mcend[$i] = strtoupper($mcend[$i]);}
-
- # führende Nullen weg
- $mcbeg[$i] = preg_replace ( '/0([0-9])/', '$1', $mcbeg[$i]);
- $mcend[$i] = preg_replace ( '/0([0-9])/', '$1', $mcend[$i]);
-
- # TimeRange auf Überschneidung mit vorhandenen checken außer mit eigener alter TR da diese
- # ja geändert werden soll
- if(check_timerange($mcday[$i],$mcbeg[$i],$mcend[$i],$nodeDN,$oldmctimerange)){
-
- $mctimerange = $mcday[$i]."_".$mcbeg[$i]."_".$mcend[$i];
- $entrymodtr ['timerange'][$i] = $mctimerange;
- $modtr = 1;
-
- }
- else{
- $mesg = "Es existiert bereits eine MachineConfig, die sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Bitte geben Sie eine andere Time Range ein.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldmctimerange;
- }
- }
- else{
- $mesg = "Falsche Syntax in der Timerange-Eingabe!<br>
- Bitte geben Sie die erneut Time Range ein.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldmctimerange;
- }
-
-}
-
-
-elseif ( $mcday[$i] == "" || $mcbeg[$i] == "" || $mcend[$i] == "" || $mcbeg[$i] > $mcend[$i]){
-
- $mesg = "Sie haben die Time Range <b>Nr.".$i."</b> nicht vollst&auml;ndig angegeben. Diese ist aber ein notwendiges Attribut.<br>
- Diese Time Range wird nicht bearbeitet.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldmctimerange;
-}
-
-else{$entrymodtr ['timerange'][$i] = $oldmctimerange;}
-} # Ende for-Schleife für jede Timerange
-# jetzt noch alle gesammelten Änderungen Durchführen ...
-if ($modtr == 1){
- # erst ändern
- echo "&Auml;ndern: "; print_r($entrymodtr); echo "<br>";
- if($result = ldap_mod_replace($ds,$mcDN,$entrymodtr)){
- $mesg = "TimeRanges erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern der TimeRanges!<br><br>";
- }
-}
-
-
-if ( count($deltr) != 0 && $modtr == 0 ){
- # Time Range löschen
- $j = 0;
- foreach ($deltr as $delrange){
- $entrydeltr ['timerange'][$j] = $delrange;
- $j++;
- }
- # dann löschen
- echo "L&ouml;schen: "; print_r($entrydeltr); echo "<br>";
- if($result = ldap_mod_del($ds,$mcDN,$entrydeltr)){
- $mesg = "TimeRanges erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen der TimeRanges!<br><br>";
- }
-}elseif(count($deltr) != 0 && $modtr == 1){
- echo "Nur &Auml;ndern (gleichzeitig L&ouml;schen und &Auml;ndern geht nicht)";
-}
-
-#####################################
-# TimeRange hinzufügen
-
-if ( $newmcday != "" && $newmcbeg != "" && $newmcend != "" && $newmcbeg <= $newmcend ){
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($newmcday,$newmcbeg,$newmcend)){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$newmcday)){$newmcday = strtoupper($newmcday);}
- if (preg_match("/([a-z]+)/",$newmcbeg)){$newmcbeg = strtoupper($newmcbeg);}
- if (preg_match("/([a-z]+)/",$newmcend)){$newmcend = strtoupper($newmcend);}
-
- # führende Nullen weg
- $newmcbeg = preg_replace ( '/0([0-9])/', '$1', $newmcbeg);
- $newmcend = preg_replace ( '/0([0-9])/', '$1', $newmcend);
-
- # TimeRange auf Ãœberschneidung mit vorhandenen checken
- if(check_timerange($newmcday,$newmcbeg,$newmcend,$nodeDN,"")){
-
- $newmctimerange = $newmcday."_".$newmcbeg."_".$newmcend;
- $entrytr ['timerange'] = $newmctimerange;
- if($result = ldap_mod_add($ds,$mcDN,$entrytr)){
- $mesg = "Zus&auml;tzliche TimeRange erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der zus&auml;tzlichen TimeRange!<br><br>";
- }
- }else{
- $mesg = "Es existiert bereits eine MachineConfig, die sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Bitte geben Sie eine andere Time Range ein.<br><br>";
- }
- }else{
- $mesg = "Falsche Syntax in der Timerange-Eingabe!<br>
- Bitte geben Sie die erneut Time Range ein.<br><br>";
- }
-}
-
-#####################################
-# MC Description
-
-if ( $oldmcdesc == $mcdesc ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldmcdesc == "" && $mcdesc != "" ){
- echo "MC-Beschreibung neu anlegen<br>";
- # hier noch Syntaxcheck
- $entrymc['description'] = $mcdesc;
- if(ldap_mod_add($ds,$mcDN,$entrymc)){
- $mesg = "MC-Beschreibung erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der MC-Beschreibung<br><br>";
- }
-}
-
-if ( $oldmcdesc != "" && $mcdesc != "" && $oldmcdesc != $mcdesc ){
- echo "MC-Beschreibung aendern<br>";
- # hier noch Syntaxcheck
- $entrymc['description'] = $mcdesc;
- if(ldap_mod_replace($ds,$mcDN,$entrymc)){
- $mesg = "MC-Beschreibung erfolgreich geaendert<br><br>";
- }else{
- $mesg = "Fehler beim aendern der MC-Beschreibung<br><br>";
- }
-}
-
-if ( $oldmcdesc != "" && $mcdesc == "" ){
- echo "Rechner-Beschreibung loeschen<br>";
- # hier noch Syntaxcheck
- $entrymc['description'] = $oldmcdesc;
- if(ldap_mod_del($ds,$mcDN,$entrymc)){
- $mesg = "MC-Beschreibung erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der MC-Beschreibung<br><br>";
- }
-}
-
-#####################################
-# Crontab Entries
-
-if (count($crontab) != 0 && (count(array_diff_assoc($crontab,$oldcrontab)) != 0 || count(array_diff_assoc($oldcrontab,$crontab)) != 0) ){
-
- $crontabentry = array();
- foreach ($crontab as $ct){
- if ($ct != ""){
- $crontabentry ['crontab-entries'][] = $ct;
- }
- }
- $oldcrontabentry = array();
- foreach ($oldcrontab as $oldct){
- if ($oldct != ""){
- $oldcrontabentry ['crontab-entries'][] = $oldct;
- }
- }
-
- if (count($crontabentry) == 0){
- echo "Crontab Eintrag l&ouml;schen<br>";
- ldap_mod_del($ds,$mcDN,$oldcrontabentry);
- }else{
- echo "Crontab Eintrag &auml;ndern<br>";
- print_r($crontabentry);
- ldap_mod_replace($ds,$mcDN,$crontabentry);
- }
-}
-
-#####################################
-# 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,$mcDN,$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,$mcDN,$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,$mcDN,$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/computers/mcdef_copy.php b/ldap-site-mngmt/webinterface/computers/mcdef_copy.php
deleted file mode 100644
index 313b22fc..00000000
--- a/ldap-site-mngmt/webinterface/computers/mcdef_copy.php
+++ /dev/null
@@ -1,111 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mcDN = $_POST['mcdn'];
-$mccn = "MC_".$_POST['mccncp'];
-$oldmccn = "MC_".$_POST['oldmccncp'];
-
-$deltr = $_POST['deltr'];
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$copytargets = $_POST['copytargets'];
-#print_r($copytargets); echo "<br>";
-$n = array_keys($copytargets,'none');
-#print_r($n); echo "<br>";
-for ($i=0; $i<count($n); $i++){
- $match = array_search('none',$copytargets);
- array_splice($copytargets, $match, 1);
-}
-print_r($copytargets); echo "<br>";
-
-
-$seconds = 2;
-$url = "mcdef.php?dn=".$mcDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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 ( $mccn != ""){
-
- # Formulareingaben anpassen
- $expmc = explode(" ",$mccn);
- foreach ($expmc as $word){$expuc[] = ucfirst($word);}
- $mccn = implode(" ",$expuc);
- $mccn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mccn);
-
-
- if (count($copytargets) != 0){
- foreach ($copytargets as $targetDN){
-
- $brothers = get_machineconfigs($targetDN,array("cn"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['cn'] == $mccn ){
- $mesg = "Es existiert bereits eine Machine Config mit dem eingegebenen Namen!<br>
- Bitte geben Sie einen anderen Namen ein.<br><br>";
- $url = "mcdef.php?dn=".$mcDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0){
-
- print_r($targetDN); echo "<br>";
- $exptarget = explode(',',$targetDN);
- $target = explode('=',$exptarget[0]);
-
- $newmcDN = "cn=".$mccn.",".$targetDN;
- print_r($newmcDN); echo "<br>";
-
-
- if (dive_into_tree_cp($mcDN,$newmcDN)){
- if($deltr == 1){
- $entrydel ['timerange'] = array();
- # Timeranges im neuen Objekt löschen
- if (ldap_mod_del($ds,$newmcDN,$entrydel)){
- $mesg .= "<br>MachineConfig erfolgreich nach ".$target[1]." kopiert<br>";
- }
- else{
- ldap_delete($ds,$newmcDN);
- $mesg .= "<br>Fehler beim kopieren der MachineConfig nach <b>".$target[1]."</b><br>";
- }
- }
- }
- else{
- $mesg .= "<br>Fehler beim kopieren der MachineConfig nach <b>".$target[1]."</b><br>";
- }
- }
- }
- }
- else{
- $mesg .= "<br>Sie haben kein Ziel angegeben!<br>";
- }
-}
-
-elseif ( $mccn == ""){
-
- $mesg = "Sie haben den Namen der neuen Machine Config nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "mcdef.php?dn=".$mcDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-
-$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/computers/mcdef_delete.php b/ldap-site-mngmt/webinterface/computers/mcdef_delete.php
deleted file mode 100644
index e191f703..00000000
--- a/ldap-site-mngmt/webinterface/computers/mcdef_delete.php
+++ /dev/null
@@ -1,40 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mcDN = $_POST['dn'];
-$mccn = $_POST['name'];
-
-$seconds = 1;
-$url = 'machineconfig_default.php';
-
-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 ( $mcDN != ""){
-
- if ( dive_into_tree_del($mcDN,"") ){
- $mesg = "Machine Config <b>".$mccn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen der Machine Config <b>".$mccn."</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/computers/menu.dwt b/ldap-site-mngmt/webinterface/computers/menu.dwt
deleted file mode 100644
index 7d316674..00000000
--- a/ldap-site-mngmt/webinterface/computers/menu.dwt
+++ /dev/null
@@ -1,32 +0,0 @@
-
-<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="5%" align="left" style="border-width:1 0 1 0;border-color:#000000;border-style:solid;padding:5;background-color:{FARBE}">&nbsp;</td>
- <td width="69%" 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">
- <code class="submenue_schrift">{TEXT_M}</code>
- </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>
diff --git a/ldap-site-mngmt/webinterface/computers/menuentry.dwt b/ldap-site-mngmt/webinterface/computers/menuentry.dwt
deleted file mode 100644
index 57c1e0d7..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuentry.dwt
+++ /dev/null
@@ -1,249 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td height='20'><h4><a href='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}' class='headerlink'><< Zur&uuml;ck zu PXE Config &nbsp;{PXECN}</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h3>Boot Men&uuml; Eintrag &nbsp;<code class='font_object'> {MECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='menuentry_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 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;'>
- <input type='Text' name='mecn' value='{MECN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldmecn' value='{MECN}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Label:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[label]' value='{LABEL}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[label]' value='{LABEL}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Generisches Boot Image: </b><br><br>(Angeboten von) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <h4>{GMECN}</h4> Abteilung: {GMEOU} [Remote Boot Dienst: {GMERBS}]
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Label:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menulabel]' value='{MELABEL}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menulabel]' value='{MELABEL}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Default:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menudefault]' value='{MEDEF}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menudefault]' value='{MEDEF}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Passwd:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menupasswd]' value='{MEPASSWD}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menupasswd]' value='{MEPASSWD}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Hide:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menuhide]' value='{MEHIDE}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menuhide]' value='{MEHIDE}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Localboot:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[localboot]' value='{LOCALBOOT}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[localboot]' value='{LOCALBOOT}'> &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>APPEND Parameter:</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>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Client Konfiguration via: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[clientconfvia]' value='{CCV}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[clientconfvia]' value='{CCV}'> ( dhcp | file | ldap )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vga: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vga]' value='{VGA}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[vga]' value='{VGA}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>splash: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[splash]' value='{SPLASH}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[splash]' value='{SPLASH}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vci: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vci]' value='{VCI}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[vci]' value='{VCI}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>no ldsc: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noldsc]' value='{NOLDSC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[noldsc]' value='{NOLDSC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>elevator: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[elevator]' value='{ELEVATOR}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[elevator]' value='{ELEVATOR}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>apic: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[apic]' value='{APIC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[apic]' value='{APIC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Union FS: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[unionfs]' value='{UNIONFS}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[unionfs]' value='{UNIONFS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>cowloop: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[cowloop]' value='{COWLOOP}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[cowloop]' value='{COWLOOP}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Debug Level: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[debug]' value='{DEBUG}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[debug]' value='{DEBUG}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Men&uuml; Position: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='menpos' value='{MENPOS}' size='2' class='medium_form_field'>
- <input type='hidden' name='oldmenpos' value='{MENPOS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Submen&uuml; Verweis: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[submenulink]' value='{SUBMENULINK}' size='50' class='medium_form_field'>
- <br>
- Dieses Feld sollte nur bei Verweisen auf Submen&uuml;s den vollst&auml;ndigen Link zu diesen enthalten
- <br>(d.h. &lt;TFTP-Server-IP&gt;::/&lt;TFTP-PXE-Pfad&gt;/&lt;Timerange&gt;/&lt;PXE-Dateiname&gt;). <br>
- Bei Textzeilen und Leerzeilen muss hier <b>"self"</b> stehen. <br>
- Bei normalen Men&uuml;eintr&auml;gen (inklusive Localboot) muss diese Feld <b>leer</b> sein.
- <input type='hidden' name='oldattribs[submenulink]' value='{SUBMENULINK}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Kernel: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[kernel]' value='{KERNEL}' size='50' class='medium_form_field'>
- <br>
- Angabe hier nur sinnvoll bei Leer-, Textzeilen oder Submen&uuml;verweisen, <br>
- denn Eingabe wird, wenn der Men&uuml;eintrag auf ein generisches Boot Image verweist (siehe oben) <br>
- bei der PXE Datei Generierung &uuml;berschrieben.
- <input type='hidden' name='oldattribs[kernel]' value='{KERNEL}'> &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='medn' value='{MEDN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timespan' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
-
- </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>Boot Men&uuml; Eintrag &nbsp;<code class='font_object'>{MECN}</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 generische Boot Image wird komplett gel&ouml;scht.
- </tr>
-
- <input type='hidden' name='dn' value='{MEDN}'>
- <input type='hidden' name='name' value='{MECN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='delurl' value='menuentry_delete.php'>
- <input type='hidden' name='successurl' value='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
- <input type='hidden' name='backurl' value='menuentry.php?dn={MEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
-
-
- </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/computers/menuentry.php b/ldap-site-mngmt/webinterface/computers/menuentry.php
deleted file mode 100644
index 386178a3..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuentry.php
+++ /dev/null
@@ -1,165 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "menuentry.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$meDN = $_GET['dn'];
-
-$attributes = array("cn","genericmenuentrydn","label","menulabel","menudefault","menupasswd","vga","splash",
- "noldsc","elevator","clientconfvia","apic",
- "cowloop","unionfs","debug","vci","menuhide","menuposition","localboot","kernel","submenulink");
-$me = get_node_data($meDN,$attributes);
-#print_r($me);
-
-# PXE DN
-$exp = explode(',',$meDN);
-$node = array_slice($exp,1);
-$exppxecn = explode('=',$node[0]);
-$pxecn = $exppxecn[1];
-$pxeDN = implode(',',$node);
-
-# Generic Menu Entry
-$expgbm = ldap_explode_dn ($me['genericmenuentrydn'],1);
-$gmecn = $expgbm[0];
-$gmerbs = $expgbm[1];
-$gmeou = $expgbm[3];
-
-# PXE/RBS Daten
-$pxe = get_node_data($pxeDN,array("rbservicedn","timerange"));
-$timerange = $pxe['timerange'];
-$rbsDN = $pxe['rbservicedn'];
-$exp = explode(',',$rbsDN);
-$exprbsau = explode('=',$exp[2]); $rbsau = $exprbsau[1];
-$rbsdata = get_node_data($rbsDN,array("cn","nfsserverip","exportpath","tftpserverip","tftppath"));
-
-# Bootmenu Daten
-$template->assign(array("MEDN" => $meDN,
- "MECN" => $me['cn'],
- "GMECN" => $gmecn,
- "GMEOU" => $gmeou,
- "GMERBS" => $gmerbs,
- "LABEL" => $me['label'],
- "MELABEL" => $me['menulabel'],
- "MEDEF" => $me['menudefault'],
- "MEPASSWD" => $me['menupasswd'],
- "MEHIDE" => $me['menuhide'],
- "VGA" => $me['vga'],
- "SPLASH" => $me['splash'],
- "NOLDSC" => $me['noldsc'],
- "ELEVATOR" => $me['elevator'],
- "VCI" => $me['vci'],
- "CCV" => $me['clientconfvia'],
- "APIC" => $me['apic'],
- "COWLOOP" => $me['cowloop'],
- "UNIONFS" => $me['unionfs'],
- "DEBUG" => $me['debug'],
- "MENPOS" => $me['menuposition'],
- "LOCALBOOT" => $me['localboot'],
- "KERNEL" => $me['kernel'],
- "SUBMENULINK" => $me['submenulink'],
- "PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "TIMERANGE" => $timerange,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-#$template->define_dynamic("Submenulink", "Webseite");
-#if (count($me['submenulink']) != 0){
-# foreach ($me['submenulink'] as $sbml){
-# $template->assign(array("SUBMENULINK" => $sbml));
-# $template->parse("SUBMENULINK_LIST", ".Submenulink");
-# }
-#}
-
-# Alternative RB Dienste holen
-$altrbs = get_rbservices($auDN,array("dn","cn"));
-if (count($altrbs) != 0){
- for ($i=0; $i < count($altrbs); $i++){
- if ($rbsDN == $altrbs[$i]['dn']){
- array_splice($altrbs, $i, 1);
- }
- }
-}
-
-
-if (count($altrbs) != 0){
-$template->define_dynamic("Altrbs", "Webseite");
- foreach ($altrbs as $item){
- $altrbsexp = explode(',',$item['dn']);
- $altrbsau = explode('=',$altrebsexp[2]);
- $template->assign(array("ALTRBSDN" => $item['dn'],
- "ALTRBSCN" => $item['cn'],
- "ALTRBSAU" => "[ ".$altrbsau[1]." ]"));
- $template->parse("ALTRBS_LIST", ".Altrbs");
- }
-}else{
- $template->assign(array("ALTRBSDN" => "",
- "ALTRBSCN" => "",
- "ALTRBSAU" => ""));
-}
-
-################################################
-# Bootmenü Einträge
-
-$menuentries = get_menuentries($pxeDN,array("dn","menuposition","label","menulabel"));
-#print_r($menuentries); echo "<br>";
-
-$template->define_dynamic("Bootmenu", "Webseite");
-
-foreach ($menuentries as $me){
- $template->assign(array("MENDN" => $me['dn'],
- "MENULABEL" => $me['menulabel'],
- "POSITION" => $me['menuposition'],
- "AUDN" => $auDN));
- $template->parse("BOOTMENU_LIST", ".Bootmenu");
-}
-
-
-################################################
-# PXE kopieren
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/menuentry_add.php b/ldap-site-mngmt/webinterface/computers/menuentry_add.php
deleted file mode 100644
index 4f02d2a6..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuentry_add.php
+++ /dev/null
@@ -1,263 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mecn = $_POST['mecn']; $mecn = htmlentities($mecn);
-$gbmDN = $_POST['gbm'];
-$menpos = $_POST['menpos'];
-$maxpos = $_POST['maxpos'];
-
-$typ = $_POST['typ'];
-$pxeDN = $_POST['pxedn'];
-$timespan = $_POST['timerange'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$meattribs = $_POST['attribs'];
-if (count($meattribs) != 0){
- foreach (array_keys($meattribs) as $key){
- $meatts[$key] = htmlentities($meattribs[$key]);
- }
-}
-# print_r($meatts); echo "<br><br>";
-
-# PXE Typ (computers/groups) für Submenulinks
-$pxearray = ldap_explode_dn($pxeDN, 1);
-$pxetype = $pxearray[2];
-
-$seconds = 2;
-$get_mecn = str_replace ( " ", "_", $mecn );
-$url = "pxe_bootmenue.php?dn=".$pxeDN."&mecn=".$get_mecn."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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>";
-# switch wäre besser ...
-if ($typ == "newme" && $typ != "local" && $typ != "text" && $typ != "leer" && $typ != "submenu" ){
-
- if ( $mecn != "" && $mecn != "Hier_NAME_eintragen" && $gbmDN != "none" ){
-
- # Formulareingaben anpassen
- $expme = explode(" ",$mecn);
- foreach ($expme as $word){$expuc[] = ucfirst($word);}
- $mecn = implode(" ",$expuc);
- $mecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mecn);
-
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- $meDN = "cn=".$mecn.",".$pxeDN;
-
- if (add_me($meDN,$mecn,$gbmDN,$menpos,$meatts,$pxeDN)){
- $mesg .= "<br>Neuen Men&uuml; Eintrag erfolgreich angelegt<br>";
- $url = "pxe_bootmenue.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;;
- }
- else{
- $mesg .= "<br>Fehler beim anlegen des Men&uuml; Eintrags!<br>";
- }
- }
-
- elseif ( $mecn == "" || $mecn == "Hier_NAME_eintragen" || $gbmDN == "none" ){
-
- $mesg = "Sie haben den Namen des neuen Men&uuml; Eintrags nicht angegeben oder kein
- Generisches Boot Image ausgew&auml;hlt. Beide sind aber ein notwendige Attribute.<br>
- Bitte geben Sie sie an.<br><br>";
- $url = "new_menuentry.php?mecn=Hier_NAME_eintragen&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- }
-}
-
-# Localboot Zeile hinzufügen
-elseif ($typ == "local" && $typ != "newme" && $typ != "text" && $typ != "leer" && $typ != "submenu" ){
-
- # Menu Position
- $menpos = $_POST['localpos'];
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- # CN bilden
- $brothers = get_menuentries($pxeDN,array("dn","cn"));
- $i=1;
- $localcn = "localboot".$i;
- if(count($brothers) != 0){
- for ($c=0; $c<count($brothers); $c++){
- foreach ($brothers as $item){
- if ($localcn == strtolower($item['cn'])){
- $i++;
- $localcn = "localboot".$i;
- }
- }
- }
- }
- $meDN = "cn=".$localcn.",".$pxeDN;
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $localcn;
- $entry ['menuposition'] = $menpos;
- $entry ['label'] = $localcn;
- $entry ['menulabel'] = $_POST['locallabel'];
- $entry ['menupasswd'] = $_POST['localpasswd'];
- $entry ['localboot'] = "level 0";
- $pos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- increment_menupositions($pxeDN,$pos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$entry)){
- $mesg .= "Localboot Zeile erfolgeich an Position ".$menpos." eingetragen";
- }else{
- $mesg .= "Fehler beim eintragen der Localboot Zeile!";
- }
- $url = "pxe_bootmenue.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-# Text Zeile hinzufügen
-elseif ($typ == "text" && $typ != "newme" && $typ != "local" && $typ != "leer" && $typ != "submenu" ){
-
- # Menu Position
- $menpos = $_POST['textpos'];
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- $text = $_POST['text'];
- if($text != "" && $text != "TEXT"){
- $brothers = get_menuentries($pxeDN,array("dn","cn"));
- $i=1;
- $textcn = "textzeile".$i;
- if(count($brothers) != 0){
- for ($c=0; $c<count($brothers); $c++){
- foreach ($brothers as $item){
- if ($textcn == strtolower($item['cn'])){
- $i++;
- $textcn = "textzeile".$i;
- }
- }
- }
- }
- $meDN = "cn=".$textcn.",".$pxeDN;
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $textcn;
- $entry ['menuposition'] = $menpos;
- $entry ['label'] = $text;
- $entry ['kernel'] = "menu.c32";
- # Submenulink auf sich selbst
- $pxedata = get_node_data($pxeDN,array("filename"));
- $entry ['submenulink'] = "self";
-
- $pos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- increment_menupositions($pxeDN,$pos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$entry)){
- $mesg .= "Textzeile erfolgeich an Position ".$menpos." eingetragen";
- }else{
- $mesg .= "Fehler beim eintragen der Textzeile!";
- }
- $url = "pxe_bootmenue.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- }
-}
-
-
-elseif ($typ == "leer" && $typ != "newme" && $typ != "local" && $typ != "text" && $typ != "submenu" ){
-
- # Menu Position
- $menpos = $_POST['leerpos'];
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- # CN bilden
- $brothers = get_menuentries($pxeDN,array("dn","cn"));
- $i=1;
- $leercn = "leerzeile".$i;
- if(count($brothers) != 0){
- for ($c=0; $c<count($brothers); $c++){
- foreach ($brothers as $item){
- if ($leercn == strtolower($item['cn'])){
- $i++;
- $leercn = "leerzeile".$i;
- }
- }
- }
- }
- $meDN = "cn=".$leercn.",".$pxeDN;
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $leercn;
- $entry ['menuposition'] = $menpos;
- $entry ['kernel'] = "menu.c32";
- # Submenulink auf sich selbst
- $pxedata = get_node_data($pxeDN,array("filename"));
- $entry ['submenulink'] = "self";
-
- # wieder führende Nullen weg für increment_menpos
- $pos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- increment_menupositions($pxeDN,$pos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$entry)){
- $mesg .= "Leerzeile erfolgeich an Position ".$menpos." eingetragen";
- }else{
- $mesg .= "Fehler beim eintragen der Leerzeile!";
- }
- $url = "pxe_bootmenue.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-elseif ($typ == "submenu" && $typ != "newme" && $typ != "local" && $typ != "text" && $typ != "leer" ){
-}
-
-$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/computers/menuentry_change.php b/ldap-site-mngmt/webinterface/computers/menuentry_change.php
deleted file mode 100644
index bf461f1f..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuentry_change.php
+++ /dev/null
@@ -1,208 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mecn = $_POST['mecn']; $mecn = htmlentities($mecn);
-$oldmecn = $_POST['oldmecn'];
-
-$menpos = $_POST['menpos'];
-if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
-}
-$oldmenpos = $_POST['oldmenpos'];
-if (strlen($oldmenpos) == 1){
- $oldmenpos = "0".$oldmenpos;
-}
-
-$meDN = $_POST['medn'];
-$pxeDN = $_POST['pxedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$attribs = $_POST['attribs'];
-if (count($attribs) != 0){
- foreach (array_keys($attribs) as $key){
- $atts[$key] = htmlentities($attribs[$key]);
- }
-}
-# print_r($meatts); 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>";
-
-
-
-$seconds = 2;
-$get_mecn = str_replace ( " ", "_", $mecn );
-$url = "menuentry.php?dn=".$meDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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>";
-
-##############################################
-# ME CN (DN)
-
-if ( $oldmecn == $mecn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldmecn != "" && $mecn != "" && $oldmecn != $mecn ){
- echo "Men&uuml; Eintrag Name aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $expme = explode(" ",$mecn);
- foreach ($expme as $word){$expuc[] = ucfirst($word);}
- $mecn = implode(" ",$expuc);
- $mecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mecn);
-
-
- $newmeDN = "cn=".$mecn.",".$pxeDN;
- print_r($newmeDN); echo "<br><br>";
-
- if(modify_me_dn($meDN, $newmeDN)){
- $mesg = "Men&uuml; Eintrag Name erfolgreich ge&auml;ndert<br><br>";
- $meDN = $newmeDN;
- }else{
- $mesg = "Fehler beim &auml;ndern des PMen&uuml; Eintrag Namen!<br><br>";
- }
-
-
- # newsubmenu holen...
- $url = "menuentry.php?dn=".$newmeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-if ( $oldmecn != "" && $mecn == "" ){
- echo "Men&uuml; Eintrag Name loeschen!<br>
- Dieses ist Teil des DN, Sie werden den Men&uuml; Eintrag komplett l&ouml;schen<br><br>";
- echo "Wollen Sie den Men&uuml; Eintrag <b>".$oldmecn."</b> wirklich l&ouml;schen?<br><br>
- <form action='menuentry_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$meDN."'>
- <input type='hidden' name='name' value='".$oldmecn."'>
- <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;
-}
-
-
-###################################
-# Menu Position
-
-if ( $menpos == $oldmenpos || $menpos == "" ){
- # keine Änderung
-}
-
-if ( $menpos != "" && $oldmenpos != $menpos ){
- echo "Men&uuml; Position &auml;ndern<br><br>";
- # Syntax Check fehlt noch
-
- # switch partner finden
- $secmeDN = get_dn_menuposition($pxeDN,$menpos);
- $entrysec ['menuposition'] = $oldmenpos;
- if (ldap_mod_replace($ds,$secmeDN,$entrysec)){
- $entry ['menuposition'] = $menpos;
- if (ldap_mod_replace($ds,$meDN,$entry)){
- #cleanup_menupositions($pxeDN);
- $mesg .= "Men&uuml; Position erfolgeich nach <b>".$menpos."</b> ge&auml;ndert";
- }else{
- $mesg .= "Fehler beim &auml;ndern der Men&uuml; Position!";
- }
- }else{
- $mesg .= "Fehler beim &auml;ndern der Men&uuml; Position!";
- }
-}
-
-###################################
-# restliche Attribute
-
-$entryadd = array();
-$entrymod = array();
-$entrydel = array();
-
-foreach (array_keys($atts) as $key){
-
- if ( $oldatts[$key] == $atts[$key] ){
- # nix
- }
- 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,$meDN,$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,$meDN,$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,$meDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
- }
-}
-
-###################################
-# Ende, noch Redirect
-
-
-$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/computers/menuentry_delete.php b/ldap-site-mngmt/webinterface/computers/menuentry_delete.php
deleted file mode 100644
index ba06eb55..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuentry_delete.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$meDN = $_POST['dn'];
-$mecn = $_POST['name'];
-
-$pxeDN = $_POST['pxedn'];
-
-$seconds = 1;
-$url = $_POST['successurl'];
-
-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 ( $meDN != ""){
-
- if ( dive_into_tree_del($meDN,"") ){
- cleanup_menupositions($pxeDN);
- $mesg = "Bootmen&uuml; Eintrag <b>".$mecn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen des Bootmen&uuml; Eintrags <b>".$mecn."</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/computers/menuposition_down.php b/ldap-site-mngmt/webinterface/computers/menuposition_down.php
deleted file mode 100644
index 53e82a21..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuposition_down.php
+++ /dev/null
@@ -1,42 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$meDN = $_GET['dn'];
-$oldpos = $_GET['pos'];
-
-$pxeDN = $_GET['pxedn'];
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-$me = get_menuentries($pxeDN,array("cn"));
-$maxpos = count($me);
-
-$oldpos = preg_replace ( '/0([0-9])/', '$1', $oldpos);
-if ($oldpos < $maxpos){
-
- $newpos = $oldpos +1;
- if (strlen($newpos) == 1){
- $newpos = "0".$newpos;
- }
- if (strlen($oldpos) == 1){
- $oldpos = "0".$oldpos;
- }
-
- if ($secmeDN = get_dn_menuposition($pxeDN,$newpos)){
- #echo "other meDN:"; print_r($secmeDN); echo "<br>";
- $entrysec ['menuposition'] = $oldpos;
- if ($result = ldap_mod_replace($ds,$secmeDN,$entrysec)){
- $entrymenu ['menuposition'] = $newpos;
- $result = ldap_mod_replace($ds,$meDN,$entrymenu);
- }
- }
-}
-$seconds = 0;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr."&#menu";
-$mesg = "";
-#$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);
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/menuposition_up.php b/ldap-site-mngmt/webinterface/computers/menuposition_up.php
deleted file mode 100644
index 4a314aca..00000000
--- a/ldap-site-mngmt/webinterface/computers/menuposition_up.php
+++ /dev/null
@@ -1,40 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$meDN = $_GET['dn'];
-$oldpos = $_GET['pos'];
-
-$pxeDN = $_GET['pxedn'];
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-$oldpos = preg_replace ( '/0([0-9])/', '$1', $oldpos);
-if ($oldpos != 1){
-
- $newpos = $oldpos-1;
- if (strlen($newpos) == 1){
- $newpos = "0".$newpos;
- }
- if (strlen($oldpos) == 1){
- $oldpos = "0".$oldpos;
- }
-
- if ($secmeDN = get_dn_menuposition($pxeDN,$newpos)){
- #echo "other meDN:"; print_r($secmeDN); echo "<br>";
- $entrysec ['menuposition'] = $oldpos;
- if ($result = ldap_mod_replace($ds,$secmeDN,$entrysec)){
- $entrymenu ['menuposition'] = $newpos;
- $result = ldap_mod_replace($ds,$meDN,$entrymenu);
- }
-
- }
-}
-$seconds = 0;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr."&#menu";
-$mesg = "";
-#$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);
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/new_group.dwt b/ldap-site-mngmt/webinterface/computers/new_group.dwt
deleted file mode 100644
index ea9accf0..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_group.dwt
+++ /dev/null
@@ -1,101 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Neue Rechnergruppe anlegen:</h3></td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Notwendige Attribute (m&uuml;ssen angegeben werden):</h3></td>
- </tr>
-
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='group_add.php' method='post'>
-
- <tr>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='55%' 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>Gruppen 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;'>
- <input type='Text' name='groupcn' value='{GROUPCN}' size='40' class='medium_form_field'> &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td><h4>Optionale Attribute:</h3></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='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='55%' 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>Gruppen-Rechner:</b><br>(Mehrfachauswahl m&ouml;glich) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <!-- BEGIN DYNAMIC BLOCK: Members -->
-
- <!-- END DYNAMIC BLOCK: Members -->
-
- <select name='addmember[]' size='{HOSTNUMBER}' multiple class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}_{HOSTNAME}'>{HOSTNAME}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- </select>
- </td>
- </tr>
-
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Gruppen Beschreibung: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='groupdesc' value='{GROUPDESC}' size='40' class='medium_form_field'>
- </td>
- </tr>
-
-
- </tr>
- </table></td>
- </tr>
-
- <tr>
- <td height='25'></td>
- </tr>
- <tr>
- <td><h4>Gruppe als Group-Objekt in den DHCP Dienst aufnehmen (optional):</h3></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='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP Objekt</b></td>
- <td width='55%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Auswahl</b></td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='5'></td>
- </tr>
- <tr>
- <td style='border-width: 0 0 0 0;'><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/computers/new_group.php b/ldap-site-mngmt/webinterface/computers/new_group.php
deleted file mode 100644
index 6d5f4257..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_group.php
+++ /dev/null
@@ -1,71 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_group.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 2;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-
-$groupcn = str_replace ( "_", " ", $_GET['groupcn']);
-$groupdesc = str_replace ( "_", " ", $_GET['groupdesc']);
-
-
-
-$template->assign(array("GROUPCN" => $groupcn,
- "GROUPDESC" => $groupdesc,
- "AUDN" => $auDN));
-
-# DHCP Stuff ...
-
-
-##############################################
-# neues Member anlegen ...
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-# print_r($users_array); echo "<br><br>";
-$groups = get_groups($auDN, array("member"));
-# print_r($groups);
-$template->assign(array("HOSTNAME" => ""));
-
-if (count($groups) != 0){
- foreach ($groups as $group){
- for ($i=0; $i < count($hosts_array); $i++){
- foreach ($group['member'] as $item){ # ist hier sicher dass member ein array ist auch bei 1 member?
- if ($hosts_array[$i]['dn'] == $item){
- array_splice($hosts_array, $i, 1);
- $i--;
- }
- }
- }
- }
-}
-# if (count($users_array) != 0){
- $template->define_dynamic("Hosts", "Webseite");
- foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HOSTNAME" => $item['hostname'],
- "HOSTNUMBER" => 5));
- $template->parse("HOSTS_LIST", ".Hosts");
- }
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/new_host.dwt b/ldap-site-mngmt/webinterface/computers/new_host.dwt
deleted file mode 100644
index e2ae50ba..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_host.dwt
+++ /dev/null
@@ -1,112 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td>
- <h3>Neuer Rechner in &nbsp;<code class='font_object'>{AU}</code>&nbsp; anlegen:</h3>
-
- </td>
- </tr>
-
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='host_add.php' method='post'>
-
- <tr>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Notwendiges Attribut</b></td>
- <td width='55%' 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>Rechner Name (hostname):</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='hostname' value='{HOSTNAME}' size='40' class='medium_form_field'> &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='25'></td>
- </tr>
- <tr>
- <td><h4>Optionale Attribute:</h3></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='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='55%' 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>Rechner Beschreibung: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='hostdesc' value='{HOSTDESC}' 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>MAC Adresse (HWAddress) :</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mac' value='{MAC}' size='17' maxlength='17' class='medium_form_field'>
- Bsp.: 00:12:03:aa:54:e6 &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>IP Adresse:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='ip' value='{IP}' size='15' maxlength='15' class='medium_form_field'>
- </td>
- </tr><tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <select name='dhcpcont' size='2' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
- {DHCPSELECT}
- </select>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Geographic Location </b> (Geb&auml;ude, Raum, ...) <b>:</b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[geolocation]' value='{GEOLOC}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Geo Coordinates: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[geoattribut]' value='{GEOATT}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>HW Mouse: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[hw-mouse]' value='{MOUSE}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>HW Graphic: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[hw-graphic]' value='{GRAPHIC}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>HW Monitor: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[hw-monitor]' value='{MONITOR}' size='30' class='medium_form_field'>
- </td>
- </tr>
-
-
- </table></td>
- </tr>
-
- <tr>
- <td height='5'></td>
- </tr>
- <tr>
- <td style='border-width: 0 0 0 0;'><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/computers/new_host.php b/ldap-site-mngmt/webinterface/computers/new_host.php
deleted file mode 100644
index 4ac144bc..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_host.php
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_host.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-
-$hostname = str_replace ( "_", " ", $_GET['hostname']);
-$hostdesc = str_replace ( "_", " ", $_GET['hostdesc']);
-$mac = str_replace ( "_", " ", $_GET['mac']);
-$ip = str_replace ( "_", " ", $_GET['ip']);
-
-# DHCP Einbindung
-$objecttype = "nodhcp";
-$dhcp_selectbox = "";
-$altdhcp = alternative_dhcpobjects($objecttype,"","");
-if (count($altdhcp) != 0){
- foreach ($altdhcp as $item){
- $dhcp_selectbox .= "
- <option value='".$item['dn']."'>".$item['cn']." ".$item['au']."</option>";
- }
-}
-
-$template->assign(array("HOSTNAME" => $hostname,
- "HOSTDESC" => $hostdesc,
- "MAC" => $mac,
- "IP" => $ip,
- "DHCPSELECT" => $dhcp_selectbox,
- "GEOLOC" => "",
- "GEOATT" => "",
- "MOUSE" => "",
- "GRAPHIC" => "",
- "MONITOR" => "",
- "AUDN" => $auDN));
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/new_mcdef.dwt b/ldap-site-mngmt/webinterface/computers/new_mcdef.dwt
deleted file mode 100644
index 72ebf72d..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_mcdef.dwt
+++ /dev/null
@@ -1,184 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Neue Default MachineConfig anlegen:</h3></td>
- </tr>
- <tr>
- <td height='10'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Allgemein:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='mcdef_add.php' method='post'>
- <tr>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- <font size='+2'><b>MC_</b></font><input type='Text' name='mccn' value='{MCCN}' size='50' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Machine Config <br>Beschreibung: &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcdesc' value='{MCDESC}' size='60' class='medium_form_field'>
- &nbsp;
- </td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Ziel Objekt:</b><br>
- (Mehrfachauswahl m&ouml;glich)&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <select name='targets[]' size='8' multiple class='medium_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <option value='{NODEDN}'>DEFAULT</option>
-
- <option value='none'>----- RECHNER spezif. MC -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- <option value='none'>----- GRUPPEN MC -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Groups -->
- <option value='{GDN}'>{GN}</option>
- <!-- END DYNAMIC BLOCK: Groups -->
- </select>
- </td>
- </tr>
-
- <tr valign='top'>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>G&uuml;ltigkeitsdauer <br>(Time Range): </b>&nbsp;</td>
- <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcday' value='{MCDAY}' size='5' maxlength='5' class='medium_form_field'>
- &nbsp;<br>
- Eines der folgenden:<br>
-
- - <b>Datum</b> &nbsp;(Format: dd.mm, z.B. 21.03/01.11) <br>
- - <b>Monatstag</b> &nbsp;(Format: dd, z.B. 01 oder 25) <br>
- - <b>Wochentag</b> &nbsp;(Format: MO, DI, ... , SO) <br>
- - <b>X</b> f&uuml;r <b>t&auml;glich</b>
-
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcbeg' value='{MCBEG}' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='mcend' value='{MCEND}' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:59</b> Uhr</font><br>
- - <b>Uhrzeit</b> &nbsp;(Format: hh, z.B. 07-19)<br>
- - <b>X</b> f&uuml;r rund um die Uhr
- </td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Dienste:</h4></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='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='70%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start X: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-x]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start SNMP: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-snmp]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start SSHD: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-sshd]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start XDMCP: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-xdmcp]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start RWHOD: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-rwhod]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start PRINT DAEMON: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-printdaemon]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>TEX Enable: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[tex-enable]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Start CRON: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[start-cron]' value='' size='10' maxlength='3' class='medium_form_field'>
- &nbsp;&nbsp;( yes | no )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>CRONTAB Entries: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[crontab-entries]' value='' size='50' class='medium_form_field'>
- </td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Language: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[language]' value='' size='10' class='medium_form_field'>
- &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NETBIOS Workgroup: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[netbios-workgroup]' value='' size='40' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>VMWARE: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='mcattribs[vmware]' value='' size='40' class='medium_form_field'>
- </td>
- </tr>
-
- <input type='hidden' name='nodedn' value='{NODEDN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
-
- </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/computers/new_mcdef.php b/ldap-site-mngmt/webinterface/computers/new_mcdef.php
deleted file mode 100644
index e36c76bb..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_mcdef.php
+++ /dev/null
@@ -1,69 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_mcdef.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 4;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$mccn = str_replace ( "_", " ", $_GET['mccn']);
-$mcdesc = str_replace ( "_", " ", $_GET['mcdesc']);
-$mcday = str_replace ( "_", " ", $_GET['mcday']);
-$mcbeg = str_replace ( "_", " ", $_GET['mcbeg']);
-$mcend = str_replace ( "_", " ", $_GET['mcend']);
-
-
-$template->assign(array("MCCN" => $mccn,
- "MCDAY" => $mcday,
- "MCBEG" => $mcbeg,
- "MCEND" => $mcend,
- "MCDESC" => $mcdesc,
- "NODEDN" => "cn=computers,".$auDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-#################################################
-# Ziel Objekt (nur Rechner und Gruppen, Default)
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/new_menuentry.dwt b/ldap-site-mngmt/webinterface/computers/new_menuentry.dwt
deleted file mode 100644
index 40baf438..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_menuentry.dwt
+++ /dev/null
@@ -1,191 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td height='20'><h4>Zur&uuml;ck zu &nbsp;<a href='pxe_bootmenue.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}' class='headerlink'>{PXECN}</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h3>Neuen Boot Men&uuml; Eintrag anlegen:</h3></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Notwendige Attribute:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='menuentry_add.php' method='post'>
-
- <tr>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='65%' 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 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;'>
- <input type='Text' name='mecn' value='{MECN}' size='60' class='medium_form_field'>
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Label:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[label]' value='{LABEL}' size='60' 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>Generische Boot Images: </b><br>(W&auml;hlen Sie eines aus) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <select name='gbm' size='10' class='large_form_selectbox'>
- <option selected value='none'>-----------------------</option>
- <!-- BEGIN DYNAMIC BLOCK: Rbs -->
- <option value='none'>----- Abteilung {RBSAU} [{RBSCN}] -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Gbms -->
- <option value='{GBMDN}'>{GBMCN} &nbsp;</option>
- <!-- END DYNAMIC BLOCK: Gbms -->
- <!-- END DYNAMIC BLOCK: Rbs -->
- </select>
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Men&uuml; Position: </b><br>
- (Bitte ohne f&uuml;hrende Null)&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='menpos' value='{MAXPOS}' size='2' class='medium_form_field'>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Optionale Attribute:</h4></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='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='65%' 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>Menu Label:</b> <br>(Wird im Bootmen&uuml; statt Label angezeigt) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menulabel]' value='{MELABEL}' 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>Menu Passwd:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menupasswd]' value='{MEPASSWD}' 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>Menu Hide:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menuhide]' value='{MEHIDE}' 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>Localboot:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[localboot]' value='{LOCALBOOT}' size='50' class='medium_form_field'>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>APPEND Parameter:</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>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Client Konfiguration via: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[clientconfvia]' value='{CCV}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vga: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vga]' value='{VGA}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>splash: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[splash]' value='{SPLASH}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vci: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vci]' value='{VCI}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>no ldsc: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noldsc]' value='{NOLDSC}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>elevator: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[elevator]' value='{ELEVATOR}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>apic: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[apic]' value='{APIC}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Union FS: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[unionfs]' value='{UNIONFS}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>cowloop: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[cowloop]' value='{COWLOOP}' size='30' class='medium_form_field'>
- </td>
- </tr>
-
- <input type='hidden' name='typ' value='newme'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
-
- </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/computers/new_menuentry.php b/ldap-site-mngmt/webinterface/computers/new_menuentry.php
deleted file mode 100644
index c407f5e7..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_menuentry.php
+++ /dev/null
@@ -1,145 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_menuentry.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$mecn = str_replace ( "_", " ", $_GET['mecn']);
-
-$pxeDN = $_GET['dn'];
-$dnexp = ldap_explode_dn($pxeDN, 1);
-$pxecn = $dnexp[0];
-
-# RBS Daten
-$pxe = get_node_data($pxeDN,array("rbservicedn"));
-$rbsDN = $pxe['rbservicedn'];
-$exp = explode(',',$rbsDN);
-$exprbsau = explode('=',$exp[2]); $rbsau = $exprbsau[1];
-$rbsdata = get_node_data($rbsDN,array("cn","nfsserverip","exportpath","tftpserverip","tftppath"));
-
-# Anzahl Menüeinträge
-$menens = get_menuentries($pxeDN,array("dn"));
-$maxpos = count($menens)+1;
-
-
-# Bootmenu Daten
-$template->assign(array("MECN" => $mecn,
- "LABEL" => "",
- "MELABEL" => "",
- "MEDEF" => "",
- "MEPASSWD" => "",
- "MEHIDE" => "",
- "VGA" => "",
- "SPLASH" => "",
- "NOLDSC" => "",
- "ELEVATOR" => "",
- "VCI" => "",
- "CCV" => "",
- "APIC" => "",
- "COWLOOP" => "",
- "UNIONFS" => "",
- "DEBUG" => "",
- "LOCALBOOT" => "",
- "SUBMENULINK" => "",
- "MENPOS" => "",
- "MAXPOS" => $maxpos,
- "PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-
-# verwendbare GBMs holen
-# eigene AU (andere noch über "offer" Attribut in RBS suchen)
-$rbsoffers = get_rbsoffers($auDN);
-# eigene AU
-if (count($rbsoffers) != 0){
- $rbservices = get_rbservices($auDN,array("dn"));
- # wenn eigene RBS anbietet dann diese GBMs als erstes (oben in der Liste)
- if (count($rbservices) != 0){
- foreach ($rbservices as $rbs){
- for ($i=0; $i < count($rbsoffers); $i++){
- if ($rbs['dn'] == $rbsoffers[$i]){
- array_splice($rbsoffers, $i, 1);
- }
- }
- }
- # momentan maximal ein RBS in der AU
- $rbsaudn[] = $rbservices[0]['dn'];
- $rbsoffsorted = array_merge($rbsaudn,$rbsoffers);
- }
- # sonst die GBMs des für diese PXE genutzen RBS
- else{
- for ($i=0; $i < count($rbsoffers); $i++){
- if ($rbsDN == $rbsoffers[$i]){
- array_splice($rbsoffers, $i, 1);
- }
- }
- $rbsaudn[] = $rbsDN;
- $rbsoffsorted = array_merge($rbsaudn,$rbsoffers);
- }
-}
-#print_r($rbsoffsorted);echo "<br><br>";
-# RBS Offers nun in der Reihenfolge erst eigene AU dann Rest ...
-$attributes = array("dn","cn","label","kernel","initrd","nfsroot","nbdroot","ipappend");
-$template->assign(array("GBMDN" => "",
- "GBMCN" => "Keine generischen Boot Images verf&uuml;gbar",
- "RBSCN" => "",
- "RBSAU" => ""));
-if (count($rbsoffsorted) != 0){
- $template->define_dynamic("Rbs", "Webseite");
- $template->define_dynamic("Gbms", "Webseite");
-
- foreach ($rbsoffsorted as $rbsoff){
- $template->clear_parse("GBMS_LIST");
- #print_r($rbsoff);echo "<br><br>";
- $rbsdnexp = ldap_explode_dn($rbsoff,1);
- $rbsoffcn = $rbsdnexp[0];
- $rbsoffau = $rbsdnexp[2];
-
- $gbm_array = get_menuentries($rbsoff,$attributes);
- if (count($gbm_array) != 0){
-
- foreach ($gbm_array as $item){
- $template->assign(array("GBMDN" => $item['dn'],
- "GBMCN" => $item['cn']));
- $template->parse("GBMS_LIST", ".Gbms");
- $template->clear_dynamic("Gbms");
- }
-
- }
- $template->assign(array("RBSCN" => $rbsoffcn,
- "RBSAU" => $rbsoffau));
- $template->parse("RBS_LIST", ".Rbs");
- $template->clear_dynamic("Rbs");
-
- }
-}
-
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/new_pxe.dwt b/ldap-site-mngmt/webinterface/computers/new_pxe.dwt
deleted file mode 100644
index 5bb7eee4..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_pxe.dwt
+++ /dev/null
@@ -1,165 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Neues PXE Boot Men&uuml; anlegen:</h3></td>
- </tr>
- <tr>
- <td height='10'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Allgemein:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='pxe_add.php' method='post'>
- <tr>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- <font size='+2'><b>PXE_</b></font><input type='Text' name='pxecn' value='{PXECN}' size='50' class='medium_form_field'>
- </td>
- </tr>
- <!--<tr valign='top'>
- <td width='30%' class='tab_d'><b>Remote Boot Dienst <br>
- ausw&auml;hlen: </b>&nbsp;</td>
- <td colspan='2' class='tab_d'>
- <select name='rbs' size='5' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Altrbs -->
- <option value='{ALTRBSDN}'>{ALTRBSCN} {ALTRBSAU}</option>
- <!-- END DYNAMIC BLOCK: Altrbs -->
-
- </select>
- </td>
- </tr>-->
- <tr valign='top'>
- <td class='tab_d'><b>Ziel Objekt:</b><br>
- (Mehrfachauswahl m&ouml;glich)&nbsp;</td>
- <td colspan='2' class='tab_d'>
- <select name='targets[]' size='8' multiple class='medium_form_selectbox'>
- <option selected value='none'>----- RECHNER spezif. PXE -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- <option value='none'>----- GRUPPEN spezif. PXE -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Groups -->
- <option value='{GDN}'>{GN}</option>
- <!-- END DYNAMIC BLOCK: Groups -->
- </select>
- </td>
- </tr>
- <tr valign='top'>
- <td width='30%' class='tab_d'><b>G&uuml;ltigkeitsdauer <br>(Time Range): </b>&nbsp;</td>
- <td width='40%' class='tab_d'>
- <input type='Text' name='pxeday' value='{PXEDAY}' size='5' maxlength='5' class='medium_form_field'>
- &nbsp;<br>
- Eines der folgenden:<br>
-
- - <b>Datum</b> &nbsp;(Format: dd.mm, z.B. 21.03/01.11) <br>
- - <b>Monatstag</b> &nbsp;(Format: dd, z.B. 01 oder 25) <br>
- - <b>Wochentag</b> &nbsp;(Format: MO, DI, ... , SO) <br>
- - <b>X</b> f&uuml;r <b>t&auml;glich</b>
-
- <td width='30%' class='tab_d'>
- <input type='Text' name='pxebeg' value='{PXEBEG}' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='pxeend' value='{PXEEND}' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:59</b> Uhr</font><br>
- - <b>Uhrzeit</b> &nbsp;(Format: hh, z.B. 07-19)<br>
- - <b>X</b> f&uuml;r rund um die Uhr
- </td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Globale PXE Parameter:</h4></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='30%' class='tab_h'><b>Attribut</b></td>
- <td width='70%' class='tab_h'><b>Wert</b></td>
- </tr>
-
- <tr>
- <td class='tab_d'><b>Default: </b>&nbsp;</td>
- <td class='tab_d'>
- <select name='attribs[default]' size='2' class='small_form_selectbox'>
- <option selected value='vesamenu.c32'>vesamenu.c32</option>
- <option value='menu.c32'>menu.c32</option>
- </select>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>Menu Title: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[menutitle]' value='{MENTIT}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>Menu Master Passwd: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[menumasterpasswd]' value='{MENMPW}' size='20' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>Timeout: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[timeout]' value='{TIMEOUT}' size='10' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>No Escape: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[noescape]' value='{NOESC}' size='10' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>Prompt: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[prompt]' value='{PROMPT}' size='10' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>Allow Options: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[allowoptions]' value='{ALLOW}' size='10' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>On Error: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[onerror]' value='{ONERR}' size='20' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td class='tab_d'><b>ON Timeout: </b>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='attribs[ontimeout]' value='{ONTIME}' size='20' class='medium_form_field'>
- </td>
- </tr>
- <!--<tr>
- <td class='tab_d'><b>Client-Conf Dateiname <br>(File URI): &nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='conffile' value='{FILEURI}' size='50' class='medium_form_field'>
- &nbsp;
- </td>
- </tr>-->
-
- <input type='hidden' name='mnr' value='{MNR}'>
- </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/computers/new_pxe.php b/ldap-site-mngmt/webinterface/computers/new_pxe.php
deleted file mode 100644
index 3c4be824..00000000
--- a/ldap-site-mngmt/webinterface/computers/new_pxe.php
+++ /dev/null
@@ -1,115 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_pxe.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 2;
-$sbmnr = 0;
-$mcnr = -1;
-
-###################################################################################
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$pxecn = str_replace ( "_", " ", $_GET['pxecn']);
-$pxeday = str_replace ( "_", " ", $_GET['pxeday']);
-$pxebeg = str_replace ( "_", " ", $_GET['pxebeg']);
-$pxeend = str_replace ( "_", " ", $_GET['pxeend']);
-
-$template->assign(array("PXECN" => $pxecn,
- "PXEDAY" => $pxeday,
- "PXEBEG" => $pxebeg,
- "PXEEND" => $pxeend,
- #"FILEURI" => "",
- "RBS" => "",
- "RBSAU" => "",
- "FILE" => "",
- "ALLOW" => "",
- #"CONSOLE" => "",
- #"DISPLAY" => "",
- #"FONT" => "",
- "IMPLICIT" => "",
- #"KBDMAP" => "",
- "MENMPW" => "",
- "MENTIT" => "",
- "NOESC" => "1",
- "ONERR" => "",
- "ONTIME" => "",
- "PROMPT" => "0",
- #"SAY" => "",
- "SERIAL" => "",
- "TIMEOUT" => "600",
- "NODEDN" => "cn=rbs,".$auDN,
- "HDN" => "none",
- "HN" => "",
- "GDN" => "none",
- "GN" => "",
- "MNR" => $mnr));
-
-#############################################
-# RB Dienste holen
-$rbsoffers = get_rbsoffers($auDN);
-
-$template->assign(array("ALTRBSDN" => "",
- "ALTRBSCN" => "",
- "ALTRBSAU" => ""));
-
-if (count($rbsoffers) != 0){
-$template->define_dynamic("Altrbs", "Webseite");
- foreach ($rbsoffers as $item){
- $rbsdnexp = ldap_explode_dn($item,1);
- $rbsoffcn = $rbsdnexp[0];
- $rbsoffau = $rbsdnexp[2];
- #$auexp = explode(',',$item['auDN']);
- #$altrbsau = explode('=',$auexp[0]);
- $template->assign(array("ALTRBSDN" => $item,
- "ALTRBSCN" => $rbsoffcn,
- "ALTRBSAU" => " &nbsp;&nbsp;[ Abt.: ".$rbsoffau." ]"));
- $template->parse("ALTRBS_LIST", ".Altrbs");
- }
-}
-
-#################################################
-# Ziel Objekt (nur Rechner und Gruppen, nicht Default)
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-$hosts_array = get_hosts($auDN,array("dn","hostname","hlprbservice","hwaddress"),"");
-if ( count($hosts_array) != 0 ){
- $template->define_dynamic("Hosts", "Webseite");
- foreach ($hosts_array as $item){
- # Nur Hosts die in DHCP/TFTP angemeldet und deren MAC eingetragen ist (für PXE-Filename)
- if ( $item['hlprbservice'] != "" && $item['hwaddress'] != "" ){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
- }
- }
-}
-
-$groups_array = get_groups($auDN,array("dn","cn","hlprbservice"));
-if ( count($groups_array) != 0 ){
- $template->define_dynamic("Groups", "Webseite");
- foreach ($groups_array as $item){
- if ( $item['hlprbservice'] != "" ){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
- }
- }
-}
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/no_ip.dwt b/ldap-site-mngmt/webinterface/computers/no_ip.dwt
deleted file mode 100644
index 5bc09796..00000000
--- a/ldap-site-mngmt/webinterface/computers/no_ip.dwt
+++ /dev/null
@@ -1,11 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Diese Funktion steht Ihnen nicht zur Verf&uuml;gung. </h3>
- Sie verf&uuml;gen &uuml;ber keine IP Adressen, die Sie an Rechner, DHCP Subnetze vergeben,
- bzw. an untergeordnete AUs delegieren k&ouml;nnen.</td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/no_ip.php b/ldap-site-mngmt/webinterface/computers/no_ip.php
deleted file mode 100644
index bfda6f02..00000000
--- a/ldap-site-mngmt/webinterface/computers/no_ip.php
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "no_ip.dwt";
-
-include("computers_header.inc.php");
-
-###############################################################################
-
-$mnr = 2;
-$sbmnr = -1;
-$mcnr = -1;
-
-$mnr = $_GET['mnr'];
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###############################################################################
-
-###############################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/pxe.dwt b/ldap-site-mngmt/webinterface/computers/pxe.dwt
deleted file mode 100644
index 8ce34d26..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe.dwt
+++ /dev/null
@@ -1,171 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td colspan='4' height='20'><h4><a href='pxeconfigs.php' class='headerlink'><< Zur&uuml;ck zur &Uuml;bersicht PXE Configs</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
-
- <tr>
- <td colspan='4'><h3>PXE Konfiguration &nbsp;<code class='font_object'> {PXECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4><code class='font_object'>Allgemein</code></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{OPTLINK} Global Options </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{BMLINK} Bootmenue </a></h4></td>
- <td>&nbsp;</td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
-
- <tr><td colspan='4'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='pxe_change.php' method='post'>
-
- <tr>
- <td width='25%' class='tab_d'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td width='5%' class='tab_d'>&nbsp;</td>
- <td colspan='2' class='tab_d'>
- <font size='+2'><b>PXE_</b></font><input type='Text' name='pxecn' value='{PXECN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldpxecn' value='{PXECN}'> &nbsp;
- </td>
- </tr>
- </table>
- <tr>
- <td height='20'></td>
- </tr>
-
-
-
- <tr><td colspan='4'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr>
- <td colspan='4' class='tab_h'><h4>PXE Konfiguration zuordnen (mit Time Range):</h4></td>
- </tr>
- <tr valign='top'>
- <td class='tab_d'><b>Rechner / Gruppen</b><br>
- (Mehrfachauswahl <br>m&ouml;glich)&nbsp;</td>
- <td class='tab_d'>&nbsp;</td>
- <td class='tab_d'>
- <select name='targethosts[]' size='8' multiple class='small_form_selectbox'>
- <option selected value='none'>----- RECHNER -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
- </select>
- </td>
- <td class='tab_d'>
- <select name='targetgroups[]' size='8' multiple class='small_form_selectbox'>
- <option selected value='none'>----- GRUPPEN -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Groups -->
- <option value='{GDN}'>{GN}</option>
- <!-- END DYNAMIC BLOCK: Groups -->
- </select>
- </td>
- </tr>
-
- <tr valign='top'>
- <td width='25%' class='tab_d_ohne'><b>G&uuml;ltigkeitsdauer <br>(Time Range(s)): </b><br>
- Zum L&ouml;schen einer Time Range<br>H&auml;kchen setzen&nbsp;</td>
- <td width='5%' class='tab_d_ohne'>&nbsp;</td>
- <td width='35%' class='tab_d_ohne'>
- Eines der folgenden:<br>
-
- - <b>Datum</b> &nbsp;(dd.mm, z.B. 21.03/01.11) <br>
- - <b>Monatstag</b> &nbsp;(dd, z.B. 01 oder 25) <br>
- - <b>Wochentag</b> &nbsp;(MO, DI, ... , SO) <br>
- - <b>X</b> f&uuml;r <b>t&auml;glich</b>
-
- <td width='35%' class='tab_d_ohne'>
- - <b>Uhrzeit</b> &nbsp;(Format: hh, z.B. 07-19)<br>
- - <b>X</b> f&uuml;r rund um die Uhr
-
- </td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: TRanges -->
- <tr valign='top'>
- <td width='25%' class='tab_d_ohne'>&nbsp;</td>
- <td width='5%' class='tab_d_ohne'>
- <input type='checkbox' name='deltr[]' value='{PXEDAY}_{PXEBEG}_{PXEEND}'>
- &nbsp;</td>
- <td width='35%' class='tab_d_ohne'>
- <input type='Text' name='pxeday[]' value='{PXEDAY}' size='5' maxlength='5' class='medium_form_field'>
- <input type='hidden' name='oldpxeday[]' value='{PXEDAY}'> &nbsp;<br>
-
-
- <td width='35%' class='tab_d_ohne'>
- <input type='Text' name='pxebeg[]' value='{PXEBEG}' size='2' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldpxebeg[]' value='{PXEBEG}'> <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='pxeend[]' value='{PXEEND}' size='2' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldpxeend[]' value='{PXEEND}'> <b><font size='+1'>:59</b> Uhr</font><br>
- </td>
- </tr>
- <!-- END DYNAMIC BLOCK: TRanges -->
-
- <tr>
- <td class='tab_d'>Neue Time Range hinzuf&uuml;gen&nbsp;</td>
- <td class='tab_d'>&nbsp;</td>
- <td class='tab_d'>
- <input type='Text' name='newpxeday' value='' size='5' maxlength='5' class='medium_form_field'>
-
- <td class='tab_d'>
- <input type='Text' name='newpxebeg' value='' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='newpxeend' value='' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:59</b> Uhr</font><br>
-
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td>
- <input type='hidden' name='nodedn' value='{NODEDN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='oldpxecn' value='{PXECN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- <input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
- <tr>
- <td height='60'></td>
- </tr>
-
- <tr>
- <td colspan='4'><h4>PXE Boot Men&uuml; &nbsp;<code class='font_object'>{PXECN}</code>&nbsp; l&ouml;schen:</h4></td>
- </tr>
- <tr>
- <td colspan='4'>
- <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 class='tab_d_ohne'>
- Die PXE Config wird inklusive aller Client-Zuordnungen auf sie komplett gel&ouml;scht.
- </tr>
-
- <input type='hidden' name='dn' value='{PXEDN}'>
- <input type='hidden' name='name' value='{PXECN}'>
- <input type='hidden' name='delurl' value='pxe_delete.php'>
- <input type='hidden' name='successurl' value='{NODETYP}.php?dn={NODEDN}&mnr={MNR}&sbmnr={SBMNR}'>
- <input type='hidden' name='backurl' value='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
-
- </table></td>
- </tr><tr><td>
- <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
- </form></td></tr>
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/computers/pxe.php b/ldap-site-mngmt/webinterface/computers/pxe.php
deleted file mode 100644
index f92146a2..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe.php
+++ /dev/null
@@ -1,129 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "pxe.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$pxeDN = $_GET['dn'];
-
-$template->assign(array("HDN" => "",
- "HN" => "",
- "GDN" => "",
- "GN" => ""));
-
-# DN, CN des übergeordneten Nodes (Host oder Group)
-$pxednarray = ldap_explode_dn($pxeDN, 0);
-$nodeDN = implode(',',array_slice($pxednarray,2));
-#$nodeDN = $_GET['nodedn'];
-$nodednarray = ldap_explode_dn($nodeDN, 1);
-
-$attributes = array("dn","cn","rbservicedn","filename","timerange","allowoptions","console","default",
- "display","font","implicit","kbdmap","menumasterpasswd","menutitle",
- "noescape","onerror","ontimeout","prompt","say","serial","timeout","ldapuri","fileuri");
-$pxe = get_node_data($pxeDN,$attributes);
-
-# RBS Daten
-$rbsDN = $pxe['rbservicedn'];
-$rbsdata = get_node_data($rbsDN,array("cn","tftpserverip","tftppath","tftpclientconfpath"));
-
-# Timerange Komponenten
-$template->define_dynamic("TRanges", "Webseite");
-if (count($pxe['timerange']) > 1){
- foreach($pxe['timerange'] as $tr){
- $exptime = explode('_',$tr);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
- }
-}else{
- $exptime = explode('_',$pxe['timerange']);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
-}
-
-
-$expcn = explode('_',$pxe['cn']);
-$name = array_slice($expcn,1);
-$pxecn = implode('_',$name);
-
-
-$template->assign(array("PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "TIMERANGE" => $pxe['timerange'],
- "NODEDN" => $nodeDN,
- "NODE" => $nodednarray[0],
- "DEFDN" => "cn=rbs,".$auDN,
- "OPTLINK" => "<a href='pxe_globals.php?dn=".$pxeDN."&mnr=".$mnr."' class='headerlink'>",
- "BMLINK" => "<a href='pxe_bootmenue.php?dn=".$pxeDN."&mnr=".$mnr."' class='headerlink'>",
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-
-
-
-################################################
-# PXE zuordnen
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"),"");
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-$dnexp = ldap_explode_dn($pxeDN, 1);
-if ($dnexp[2] == "computers"){
- $nodetyp = "rbshost";
-}
-if ($dnexp[2] == "groups"){
- $nodetyp = "group";
-}
-# falls TR vorhanden dann soll sie gelöscht werden (flag deltr setzen)
-if (count($pxe['timerange']) != 0){
- $template->assign(array("DELTR" => "1",
- "NODETYP" => $nodetyp));
-}
-else{
- $template->assign(array("DELTR" => "0",
- "NODETYP" => $nodetyp));
-}
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/pxe_add.php b/ldap-site-mngmt/webinterface/computers/pxe_add.php
deleted file mode 100644
index db1dabe2..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_add.php
+++ /dev/null
@@ -1,228 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxecn = $_POST['pxecn']; $pxecn = htmlentities($pxecn);
-#$rbsDN = $_POST['rbs'];
-
-$pxeday = $_POST['pxeday']; $pxeday = htmlentities($pxeday);
-$pxebeg = $_POST['pxebeg']; $pxebeg = htmlentities($pxebeg);
-$pxeend = $_POST['pxeend']; $pxeend = htmlentities($pxeend);
-
-$conffile = $_POST['conffile']; $conffile = htmlentities($conffile);
-
-$mnr = $_POST['mnr'];
-
-$targets = $_POST['targets'];
-#print_r($targets); echo "<br>";
-$n = array_keys($targets,'none');
-#print_r($n); echo "<br>";
-for ($i=0; $i<count($n); $i++){
- $match = array_search('none',$targets);
- array_splice($targets, $match, 1);
-}
-#echo "Zielobjekte: ";print_r($targets); echo "<br>";
-
-$pxeattribs = $_POST['attribs'];
-if (count($pxeattribs) != 0){
- foreach (array_keys($pxeattribs) as $key){
- $pxeatts[$key] = htmlentities($pxeattribs[$key]);
- }
-}
-# print_r($mcatts); echo "<br><br>";
-
-$seconds = 20;
-$get_pxecn = str_replace ( " ", "_", $pxecn );
-$get_pxeday = str_replace ( " ", "_", $pxeday );
-$get_pxebeg = str_replace ( " ", "_", $pxebeg );
-$get_pxeend = str_replace ( " ", "_", $pxeend );
-$url = "new_pxe.php?pxecn=".$get_pxecn."&pxeday=".$get_pxeday."&pxebeg=".$get_pxebeg."&pxeend=".$get_pxeend."&mnr=".$mnr;
-
-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 ( $pxecn != "" && $pxecn != "Hier_PXE_NAME_eintragen" && $rbsDN != "none" ){
-
- $pxecn = "PXE_".$pxecn;
- # Formulareingaben anpassen
- $exppxe = explode(" ",$pxecn);
- foreach ($exppxe as $word){$expuc[] = ucfirst($word);}
- $pxecn = implode(" ",$expuc);
- $pxecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $pxecn);
-
- $pxetimerange = "";
- $nomac = 0;
-
- if (count($targets) != 0){
- foreach ($targets as $targetDN){
-
- $exptargetdn = ldap_explode_dn($targetDN, 1);
- $targetcn = $exptargetdn[0];
- $targettype = $exptargetdn[1];
-
- # falls Target keine MAC hat dann kann keine PXE angelegt werden
- # jetzt schon vorher bei der Zielobjektauswahl abgefangen
- if ($targettype == "computers"){
- $macdata = get_node_data($targetDN, array("hwaddress"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Ziel-Rechner ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst eine MAC ein!<br><br>";
- }
- }
- if ($targettype == "groups"){
- $members = get_node_data($targetDN, array("member"));
- if (count($members) > 1){
- foreach ($members['member'] as $hostDN){
- $macdata = get_node_data($hostDN, array("hwaddress","hostname"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Gruppen-Rechner <b>".$macdata['hostname']."</b> ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; f&uuml;r die Gruppe wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst bei Rechner <b>".$macdata['hostname']."</b> eine MAC ein!<br><br>";
- }
- }
- }
- if (count($members) == 1){
- $macdata = get_node_data($members['member'], array("hwaddress"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Gruppen-Rechner <b>".$macdata['hostname']."</b> ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; f&uuml;r die Gruppe wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst bei Rechner <b>".$macdata['hostname']."</b> eine MAC ein!<br><br>";
- }
- }
- }
-
- # Check auf eindeutigen PXE-Namen (könnte man erweitern auf kompletten RBS)
- $brothers = get_pxeconfigs($targetDN,array("cn"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['cn'] == $pxecn ){
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml; mit dem eingegebenen Namen!<br>
- Bitte geben Sie einen anderen Namen ein.<br><br>";
- $url = "new_pxe.php?pxecn=".$get_pxecn."&pxeday=".$get_pxeday."&pxebeg=".$get_pxebeg."&pxeend=".$get_pxeend."&mnr=".$mnr."&sbmnr=".$sbmnr;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0 && $nomac == 0){
-
- if ( $pxeday != "" && $pxebeg != "" && $pxeend != "" && $pxebeg <= $pxeend ){
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($pxeday,$pxebeg,$pxeend)){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$pxeday)){$pxeday = strtoupper($pxeday);}
- if (preg_match("/([a-z]+)/",$pxebeg)){$pxebeg = strtoupper($pxebeg);}
- if (preg_match("/([a-z]+)/",$pxeend)){$pxeend = strtoupper($pxeend);}
-
- # führende Nullen weg
- $pxebeg = preg_replace ( '/0([0-9])/', '$1', $pxebeg);
- $pxeend = preg_replace ( '/0([0-9])/', '$1', $pxeend);
-
- # TimeRange auf Ãœberschneidung mit vorhandenen checken
- if(check_timerange_pxe($pxeday,$pxebeg,$pxeend,$targetDN,"")){
- $pxetimerange = $pxeday."_".$pxebeg."_".$pxeend;
- }
- else{
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml;, das sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Das neue PXE Boot Men&uuml; wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschlie&szlig;end ein.<br><br>";
- }
- }
- else{
- $mesg = "Falsche Syntax in der Time-Range-Eingabe! Das neue PXE Boot Men&uuml; wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschlie&szlig;end ein.<br><br>";
- }
- }
- else{
- $mesg = "Keine vollst&auml;ndige Time-Range-Eingabe! Das neue PXE Boot Men&uuml; wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschlie&szlig;end ein.<br><br>";
- }
-
- $pxeDN = "cn=".$pxecn.",".$targetDN;
-
-
- # PXE Dateinamen bestimmen, MAC(s)
- $filenames = array();
- if ($targettype == "computers"){
- $macdata = get_node_data($targetDN, array("hwaddress"));
- $pxemac = str_replace (":","-",$macdata['hwaddress']);
- $filenames[] = "01-".$pxemac;
- }
- if ($targettype == "groups"){
- $members = get_node_data($targetDN, array("member"));
- if (count($members) > 1){
- foreach ($members['member'] as $hostDN){
- $macdata = get_node_data($hostDN, array("hwaddress"));
- $pxemac = str_replace (":","-",$macdata['hwaddress']);
- $filenames[] = "01-".$pxemac;
- }
- }
- if (count($members) == 1){
- $macdata = get_node_data($members['member'], array("hwaddress"));
- $pxemac = str_replace (":","-",$macdata['hwaddress']);
- $filenames[] = "01-".$pxemac;
- }
- }
- echo "filenames: ";print_r($filenames); echo "<br>";
- #$ldapuri = LDAP_HOST."/dn=cn=computers,".$auDN;
-
- # rbsDN bestimmen
- $rbs = get_node_data($targetDN,array("hlprbservice"));
- $rbsDN = $rbs['hlprbservice'];
- print_r($rbsDN);
-
- if (add_pxe($pxeDN,$pxecn,$rbsDN,$pxetimerange,$pxeattribs,$filenames,$conffile)){
- $mesg .= "<br>Neues PXE Boot Men&uuml; erfolgreich angelegt<br>";
- if ($targettype == "computers"){
- $mnr=1;
- }
- if ($targettype == "groups"){
- $mnr=2;
- }
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr;
- }
- else{
- $mesg .= "<br>Fehler beim anlegen des PXE Boot Men&uuml;s!<br>";
- }
- }
- }
- }
- else{
- $mesg .= "<br>Sie haben kein Ziel angegeben!<br>";
- }
-}
-
-
-elseif ( $pxecn == "" || $pxecn == "Hier_PXE_NAME_eintragen" || $rbsDN == "none" ){
-
- $mesg = "Sie haben den Namen des neuen PXE Boot Men&uuml;s nicht angegeben oder den
- Remote Boot Dienst nicht ausgew&auml;hlt. Beide sind aber ein notwendige Attribute.<br>
- Bitte geben Sie sie an.<br><br>";
- $url = "new_pxe.php?pxecn=Hier_PXE_NAME_eintragen&pxeday=".$get_pxeday."&pxebeg=".$get_pxebeg."&pxeend=".$get_pxeend."&mnr=".$mnr."&sbmnr=".$sbmnr;
-}
-
-
-
-$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/computers/pxe_bootmenue.dwt b/ldap-site-mngmt/webinterface/computers/pxe_bootmenue.dwt
deleted file mode 100644
index 5c3986b3..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_bootmenue.dwt
+++ /dev/null
@@ -1,176 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td colspan='4' height='20'><h4><a href='pxeconfigs.php' class='headerlink'><< Zur&uuml;ck zur &Uuml;bersicht PXE Configs</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
-
- <tr>
- <td colspan='4'><h3>PXE Konfiguration &nbsp;<code class='font_object'> {PXECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4>{PXELINK} Allgemein</code></a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{OPTLINK} Global Options </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4><code class='font_object'> Bootmenue </h4></td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
-
- <tr>
- <td colspan='4'><h4>PXE Bootmen&uuml;:</h4>
- Klicken Sie auf einen Men&uuml;eintrag um zur Detailansicht zu gelangen und den Eintrag bearbeiten zu k&ouml;nnen</td>
- </tr>
- <tr>
- <td colspan='4'>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='80%' style='border-color: black; border-style: solid; border-width: 2 2 2 2;'>
-
- <tr>
- <td width='8%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>#</td>
- <td width='8%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Flags</td>
- <td width='64%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Menu Label&nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='15%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Bootmenu -->
- <form action='delete_confirm.php' method='post'>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>{POSITION}&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>{MEDEF} {MEPWD} {MEHIDE}&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'><font size='+1'>{ANZEIGE}&nbsp;</font></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>
- <a href='menuposition_up.php?dn={MENDN}&pos={POSITION}&pxedn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'><img style='border-width:0;border-style=none;' src='../pics/up2.gif' height='15'></a> <br>
- <a href='menuposition_down.php?dn={MENDN}&pos={POSITION}&pxedn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'><img style='border-width:0;border-style=none;' src='../pics/down2.gif' height='15'></a></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>
- <input type='hidden' name='dn' value='{MENDN}'>
- <input type='hidden' name='name' value='{ANZEIGENAME}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='delurl' value='menuentry_delete.php'>
- <input type='hidden' name='successurl' value='pxe_bootmenue.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
- <input type='hidden' name='backurl' value='pxe_bootmenue.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
-
- <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
- </tr>
- </form>
- <!-- END DYNAMIC BLOCK: Bootmenu -->
-
- </table></td>
- </tr>
- <tr>
- <td colspan='4'><h4>Flags:</h4></font>
- <ul>
- <li><b>D</b> -> Default Men&uuml;eintrag</li>
- <li><b>P</b> -> Passwort gesch&uuml;tzt</li>
- <li><b>H</b> -> Hidden</li>
- </ul>
- </td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='4'><h4>Neuen Men&uuml;eintrag anlegen: &nbsp;&nbsp;</h4>
- <a href='new_menuentry.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}' style='color:#FFFFFF;' class='small_loginform_button'>&nbsp; zur Eingabemaske &nbsp;</a> </td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td colspan='4'><h4>Standard Men&uuml;eintr&auml;ge anlegen:</h4></td>
- </tr>
- <tr>
- <td colspan='4'>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
-
- <tr>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Typ &nbsp;</td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='10%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Position</td>
- <td width='10%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Localboot</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- Menu Label<br><input type='Text' name='locallabel' value='' size='20' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- Passwort (optional)<br><input type='Text' name='localpasswd' value='' size='20' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='localpos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='local'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Textzeile</b> &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='text' value='TEXT' size='50' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='textpos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='text'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Leerzeile</b> &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='leerpos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='leer'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Verweis zu Submen&uuml;</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>Submen&uuml; Name<br>
- <input type='Text' name='submenu' value='' size='20' class='medium_form_field'></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>Remote Boot Service
- <select name='subrbs' size='3' class='small_form_selectbox'>
- <option selected value='none'>----------</option>
- <!-- BEGIN DYNAMIC BLOCK: Subrbs -->
- <option value='{SUBRBSDN}'>{SUBRBSCN} {SUBRBSAU}</option>
- <!-- END DYNAMIC BLOCK: Subrbs -->
- </select>
- </td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='submenupos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='submenu'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
-
- </table></td>
- </tr>
-
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/computers/pxe_bootmenue.php b/ldap-site-mngmt/webinterface/computers/pxe_bootmenue.php
deleted file mode 100644
index 29d6e338..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_bootmenue.php
+++ /dev/null
@@ -1,151 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "pxe_bootmenue.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$pxeDN = $_GET['dn'];
-# DN, CN des übergeordneten Nodes (Host oder Group)
-$pxednarray = ldap_explode_dn($pxeDN, 0);
-$nodeDN = implode(',',array_slice($pxednarray,2));
-#$nodeDN = $_GET['nodedn'];
-$nodednarray = ldap_explode_dn($nodeDN, 1);
-
-$attributes = array("dn","cn","rbservicedn","filename","timerange","allowoptions","console","default",
- "display","font","implicit","kbdmap","menumasterpasswd","menutitle",
- "noescape","onerror","ontimeout","prompt","say","serial","timeout","ldapuri","fileuri");
-$pxe = get_node_data($pxeDN,$attributes);
-
-# RBS Daten
-$rbsDN = $pxe['rbservicedn'];
-$rbsdata = get_node_data($rbsDN,array("cn","tftpserverip","tftppath","tftpclientconfpath"));
-
-# Timerange Komponenten
-$template->define_dynamic("TRanges", "Webseite");
-if (count($pxe['timerange']) > 1){
- foreach($pxe['timerange'] as $tr){
- $exptime = explode('_',$tr);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
- }
-}else{
- $exptime = explode('_',$pxe['timerange']);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
-}
-
-# Filenames
-$template->define_dynamic("Filenames", "Webseite");
-if (count($pxe['filename']) > 1){
- foreach($pxe['filename'] as $fi){
- $template->assign(array("FILE" => $fi));
- $template->parse("FILENAMES_LIST", ".Filenames");
- }
-}else{
- $exptime = explode('_',$pxe['filename']);
- $template->assign(array("FILE" => $pxe['filename']));
- $template->parse("FILENAMES_LIST", ".Filenames");
-}
-
-$expcn = explode('_',$pxe['cn']);
-$name = array_slice($expcn,1);
-$pxecn = implode('_',$name);
-
-# Bootmenü Einträge
-$menuentries = get_menuentries($pxeDN,array("dn","menuposition","label","menulabel","menudefault","menupasswd","menuhide"));
-# print_r($menuentries); echo "<br>";
-$maxpos = count($menuentries)+1;
-
-# Globale Parameter
-$template->assign(array("PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "TIMERANGE" => $pxe['timerange'],
- "MAXPOS" => $maxpos,
- "NODEDN" => $nodeDN,
- "NODE" => $nodednarray[0],
- "DEFDN" => "cn=rbs,".$auDN,
- "PXELINK" => "<a href='pxe.php?dn=".$pxeDN."&mnr=".$mnr."' class='headerlink'>",
- "OPTLINK" => "<a href='pxe_globals.php?dn=".$pxeDN."&mnr=".$mnr."' class='headerlink'>",
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-
-# Für Submenü Einträge
-$template->assign(array("SUBRBSDN" => "",
- "SUBRBSCN" => "",
- "SUBRBSAU" => ""));
-if (count($subrbs) != 0){
-$template->define_dynamic("Subrbs", "Webseite");
- foreach ($subrbs as $item){
- $rbsdnexp = ldap_explode_dn($item,1);
- $subrbscn = $rbsdnexp[0];
- $subrbsau = $rbsdnexp[2];
- #$subrbsexp = explode(',',$item['dn']);
- #$subrbsau = explode('=',$subrbsexp[2]);
- $template->assign(array("SUBRBSDN" => $item,
- "SUBRBSCN" => $subrbscn,
- "SUBRBSAU" => "[ ".$subrbsau." ]"));
- $template->parse("SUBRBS_LIST", ".Subrbs");
- }
-}
-
-################################################
-# Bootmenü Einträge
-
-$template->define_dynamic("Bootmenu", "Webseite");
-$template->assign(array("MENDN" => "",
- "MENULABEL" => "",
- "ANZEIGE" => "Noch kein Bootmen&uuml; Eintrag angelegt",
- "MEDEF" => "",
- "MEPWD" => "",
- "MEHIDE" => "",
- "BGCDEF" => "",
- "POSITION" => ""));
-foreach ($menuentries as $me){
- $anzeige = ""; $medef = ""; $mepwd = ""; $mehide = "";
- if ($me['label'] != "" && $me['menulabel'] == ""){$anzeige .= $me['label'];}
- if ($me['menulabel'] != ""){$anzeige .= $me['menulabel'];}
- if ($me['menudefault'] == 1){$medef = "<b>D</b>"; $bgcdef = "background-color:#EEDD82;";}
- if ($me['menupasswd'] != ""){$mepwd = "<b>P</b>";}
- if ($me['menuhide'] == 1){$mehide = "<b>H</b>"; $bgcdef = "background-color:#A0A0A0;";}
- $template->assign(array("MENDN" => $me['dn'],
- "ANZEIGE" => "<a href='menuentry.php?dn=".$me['dn']."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr."' class='headerlink'>".$anzeige."</a>",
- "ANZEIGENAME" => $anzeige,
- "POSITION" => $me['menuposition'],
- "MEDEF" => $medef,
- "MEPWD" => $mepwd,
- "MEHIDE" => $mehide,
- "BGCDEF" => $bgcdef,
- "AUDN" => $auDN));
- $template->parse("BOOTMENU_LIST", ".Bootmenu");
- $medef = "";
- $bgcdef = "";
-}
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/pxe_change.php b/ldap-site-mngmt/webinterface/computers/pxe_change.php
deleted file mode 100644
index 07af7ed5..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_change.php
+++ /dev/null
@@ -1,348 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxeDN = $_POST['pxedn'];
-$oldpxecn = "PXE_".$_POST['oldpxecn'];
-$pxecn = "PXE_".$_POST['pxecn'];
-
-$pxeday = $_POST['pxeday'];
-$pxebeg = $_POST['pxebeg'];
-$pxeend = $_POST['pxeend'];
-foreach (array_keys($pxeday) as $key){
- $pxeday[$key] = htmlentities($pxeday[$key]);
-}
-foreach (array_keys($pxebeg) as $key){
- $pxebeg[$key] = htmlentities($pxebeg[$key]);
-}
-foreach (array_keys($pxeend) as $key){
- $pxeend[$key] = htmlentities($pxeend[$key]);
-}
-
-$deltr = $_POST['deltr'];
-
-$newpxeday = $_POST['newpxeday']; $newpxeday = htmlentities($newpxeday);
-$newpxebeg = $_POST['newpxebeg']; $newpxebeg = htmlentities($newpxebeg);
-$newpxeend = $_POST['newpxeend']; $newpxeend = htmlentities($newpxeend);
-$oldpxeday = $_POST['oldpxeday'];
-$oldpxebeg = $_POST['oldpxebeg'];
-$oldpxeend = $_POST['oldpxeend'];
-
-
-$rbs = $_POST['rbs'];
-$filename = $_POST['filename'];
-if (count($filename) != 0){
- foreach (array_keys($filename) as $key){
- $file[$key] = htmlentities($filename[$key]);
- }
-}
-$oldfilename = $_POST['oldfilename'];
-if (count($oldfilename) != 0){
- foreach (array_keys($oldfilename) as $key){
- $oldfile[$key] = htmlentities($oldfilename[$key]);
- }
-}
-$newfilename = $_POST['newfilename']; $newfilename = htmlentities($newfilename);
-
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-
-$seconds = 2;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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>";
-
-##############################################
-# PXE CN (DN)
-
-if ( $oldpxecn == $pxecn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldpxecn != "" && $pxecn != "" && $oldpxecn != $pxecn ){
- echo "PXE Name aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $exppxe = explode(" ",$pxecn);
- foreach ($exppxe as $word){$expuc[] = ucfirst($word);}
- $pxecn = implode(" ",$expuc);
- $pxecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $pxecn);
-
-
- $newpxeDN = "cn=".$pxecn.",".$nodeDN;
- print_r($newpxeDN); echo "<br><br>";
-
- if(modify_pxe_dn($pxeDN, $newpxeDN)){
- $mesg = "PXE Name erfolgreich ge&auml;ndert<br><br>";
- $pxeDN = $newpxeDN;
- }else{
- $mesg = "Fehler beim &auml;ndern des PXE Namen!<br><br>";
- }
-
-
- # newsubmenu holen...
- $url = "pxe.php?dn=".$newpxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-if ( $oldpxecn != "" && $pxecn == "" ){
- echo "PXE Name loeschen!<br>
- Dieses ist Teil des DN, Sie werden das PXE Boot Men&uuml; komplett l&ouml;schen<br><br>";
- echo "Wollen Sie das PXE Boot Men&uuml; <b>".$oldpxecn."</b> wirklich l&ouml;schen?<br><br>
- <form action='pxe_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$pxeDN."'>
- <input type='hidden' name='name' value='".$oldpxecn."'>
- <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;
-}
-
-##########################################
-# Remote Boot Dienst
-
-if ($rbs != "none"){
- $exp = explode(',',$rbs);
- $exprbscn = explode('=',$exp[0]);
- $rbscn = $exprbscn[1];
- $exprbsau = explode('=',$exp[2]);
- $rbsau = $exprbsau[1];
-
- $entryrbs ['rbservicedn'] = $rbs;
- if ($result = ldap_mod_replace($ds,$pxeDN,$entryrbs)){
- $mesg = "Remote Boot Service erfolgreich zu <b>".$rbscn."[Abt.: ".$rbsau."]</b> ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des Remote Boot Services zu <b>".$rbscn."</b>!<br><br>";
- }
-}
-
-
-##########################################
-# bereits vorhandene TimeRange(s) bearbeiten
-
-$entrymodtr = array();
-$modtr = 0;
-# TimeRanges zusammensetzen
-# $t = 0; # Laufvariable für $entrymodtr, da nicht jede Timerange ok sein muss
-for ($i=0; $i<count($pxeday); $i++){
-
-$oldpxetimerange = $oldpxeday[$i]."_".$oldpxebeg[$i]."_".$oldpxeend[$i];
-
-if ( ($pxebeg[$i] <= $pxeend[$i]) && ( ($pxeday[$i] != $oldpxeday[$i] && $pxeday[$i] != "") || ($pxebeg[$i] != $oldpxebeg[$i] && $pxebeg[$i] != "") || ($pxeend[$i] != $oldpxeend[$i] && $pxeend[$i] != "")) ){
-
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($pxeday[$i],$pxebeg[$i],$pxeend[$i])){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$pxeday[$i])){$pxeday[$i] = strtoupper($pxeday[$i]);}
- if (preg_match("/([a-z]+)/",$pxebeg[$i])){$pxebeg[$i] = strtoupper($pxebeg[$i]);}
- if (preg_match("/([a-z]+)/",$pxeend[$i])){$pxeend[$i] = strtoupper($pxeend[$i]);}
-
- # führende Nullen weg
- $pxebeg[$i] = preg_replace ( '/0([0-9])/', '$1', $pxebeg[$i]);
- $pxeend[$i] = preg_replace ( '/0([0-9])/', '$1', $pxeend[$i]);
-
- # TimeRange auf Überschneidung mit vorhandenen checken außer mit eigener alter TR da diese
- # ja geändert werden soll
- if(check_timerange_pxe($pxeday[$i],$pxebeg[$i],$pxeend[$i],$nodeDN,$oldpxetimerange)){
-
- $pxetimerange = $pxeday[$i]."_".$pxebeg[$i]."_".$pxeend[$i];
- $entrymodtr ['timerange'][$i] = $pxetimerange;
- $modtr = 1;
-
- }
- else{
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml;, das sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Bitte geben Sie eine andere Time Range ein.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldpxetimerange;
- }
- }
- else{
- $mesg = "Falsche Syntax in der Timerange-Eingabe!<br>
- Bitte geben Sie die erneut Time Range ein.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldpxetimerange;
- }
-
-}
-
-
-elseif ( $pxeday[$i] == "" || $pxebeg[$i] == "" || $pxeend[$i] == "" || $pxebeg[$i] > $pxeend[$i]){
-
- $mesg = "Sie haben die Time Range <b>Nr.".$i."</b> nicht vollst&auml;ndig angegeben. Diese ist aber ein notwendiges Attribut.<br>
- Diese Time Range wird nicht bearbeitet.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldpxetimerange;
-}
-
-else{$entrymodtr ['timerange'][$i] = $oldpxetimerange;}
-} # Ende for-Schleife für jede Timerange
-# jetzt noch alle gesammelten Änderungen Durchführen ...
-if ($modtr == 1){
- # erst ändern
- echo "&Auml;ndern: "; print_r($entrymodtr); echo "<br>";
- if($result = ldap_mod_replace($ds,$pxeDN,$entrymodtr)){
- $mesg = "TimeRanges erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern der TimeRanges!<br><br>";
- }
-}
-
-
-if ( count($deltr) != 0 && $modtr == 0 ){
- # Time Range löschen
- $j = 0;
- foreach ($deltr as $delrange){
- $entrydeltr ['timerange'][$j] = $delrange;
- $j++;
- }
- # dann löschen
- echo "L&ouml;schen: "; print_r($entrydeltr); echo "<br>";
- if($result = ldap_mod_del($ds,$pxeDN,$entrydeltr)){
- $mesg = "TimeRanges erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen der TimeRanges!<br><br>";
- }
-}elseif(count($deltr) != 0 && $modtr == 1){
- echo "Nur &Auml;ndern (gleichzeitig L&ouml;schen und &Auml;ndern geht nicht)";
-}
-
-#####################################
-# TimeRange hinzufügen
-
-if ( $newpxeday != "" && $newpxebeg != "" && $newpxeend != "" && $newpxebeg <= $newpxeend ){
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($newpxeday,$newpxebeg,$newpxeend)){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$newpxeday)){$newpxeday = strtoupper($newpxeday);}
- if (preg_match("/([a-z]+)/",$newpxebeg)){$newpxebeg = strtoupper($newpxebeg);}
- if (preg_match("/([a-z]+)/",$newpxeend)){$newpxeend = strtoupper($newpxeend);}
-
- # führende Nullen weg
- $newpxebeg = preg_replace ( '/0([0-9])/', '$1', $newpxebeg);
- $newpxeend = preg_replace ( '/0([0-9])/', '$1', $newpxeend);
-
- # TimeRange auf Ãœberschneidung mit vorhandenen checken
- if(check_timerange_pxe($newpxeday,$newpxebeg,$newpxeend,$nodeDN,"")){
-
- $newpxetimerange = $newpxeday."_".$newpxebeg."_".$newpxeend;
- $entrytr ['timerange'] = $newpxetimerange;
- if($result = ldap_mod_add($ds,$pxeDN,$entrytr)){
- $mesg = "Zus&auml;tzliche TimeRange erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der zus&auml;tzlichen TimeRange!<br><br>";
- }
- }else{
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml;, das sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Bitte geben Sie eine andere Time Range ein.<br><br>";
- }
- }else{
- $mesg = "Falsche Syntax in der Timerange-Eingabe!<br>
- Bitte geben Sie die erneut Time Range ein.<br><br>";
- }
-}
-
-
-
-#####################################
-# PXE Filename(s)
-
-$filemod = array();
-$modfi = 0;
-$filedel = array();
-$delfi = 0;
-$j = 0;
-
-if (count($file) != 0){
-
-for ($i=0; $i<count($file); $i++){
-
- if ( $oldfile[$i] == $file[$i] ){
- $filemod ['filename'][$i] = $oldfile[$i];
- # $mesg = "keine Aenderung<br>";
- }
-
- if ( $oldfile[$i] != "" && $file[$i] != "" && $oldfile[$i] != $file[$i] ){
- echo "PXE Dateinamen aendern<br>
- Vorsicht dies kann eine nicht verwendbare PXE Datei zur Folge haben!<br><br>";
- # hier noch Syntaxcheck
- $filemod ['filename'][$i] = $file[$i];
- $modfi = 1;
- }
-
- if ( $oldfile[$i] != "" && $file[$i] == "" ){
- echo "PXE Dateinamen loeschen!<br>
- Achtung: aus ihren PXE Daten wird keine PXE Datei mehr generiert.<br>
- Sie sind solange nicht mehr f&uuml;r den PXE Bootvorgang verwendbar bis Sie einen neuen Dateinamen anlegen!<br><br>";
- $filemod ['filename'][$i] = $oldfile[$i];
- $filedel ['filename'][$j] = $oldfile[$i];
- $j++;
- $delfi = 1;
- $seconds = 4;
- }
-}
-#erst ändern
-if ($modfi == 1){
- echo "&Auml;ndern: "; print_r($filemod); echo "<br>";
- if(ldap_mod_replace($ds,$pxeDN,$filemod)){
- $mesg = "PXE Dateiname(n) erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des(r) PXE Dateinamens!<br><br>";
- }
- $modfi = 0;
-}
-# dann löschen
-if ($delfi == 1){
- echo "L&ouml;schen: "; print_r($filedel); echo "<br>";
- if(ldap_mod_del($ds,$pxeDN,$filedel)){
- $mesg = "PXE Dateiname(n) erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen des PXE Dateinamens !<br><br>";
- }
- $delfi = 0;
-}
-
-}
-
-# PXE Dateiname neu anlegen
-if ($newfilename == ""){
-}
-if ($newfilename != ""){
- echo "PXE Dateiname hinzuf&uuml;gen";
- $fileadd ['filename'] = $newfilename;
- if(ldap_mod_add($ds,$pxeDN,$fileadd)){
- $mesg = "PXE Dateiname <b>".$newfilename."</b> erfolgreich angelegt<br><br>";
- }else{
- $mesg = "Fehler beim anlegen des PXE Dateinamens ".$newfilename." !<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/computers/pxe_copy.php b/ldap-site-mngmt/webinterface/computers/pxe_copy.php
deleted file mode 100644
index 61760a8e..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_copy.php
+++ /dev/null
@@ -1,182 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxeDN = $_POST['pxedn'];
-$pxecn = "PXE_".$_POST['pxecncp'];
-$oldpxecn = "PXE_".$_POST['oldpxecncp'];
-
-$deltr = $_POST['deltr'];
-
-$oldpxeday = $_POST['oldpxedaycp']; $oldpxeday = htmlentities($oldpxeday);
-$oldpxebeg = $_POST['oldpxebegcp']; $oldpxebeg = htmlentities($oldpxebeg);
-$oldpxeend = $_POST['oldpxeendcp']; $oldpxeend = htmlentities($oldpxeend);
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$copytargets = $_POST['copytargets'];
-#print_r($copytargets); echo "<br>";
-$n = array_keys($copytargets,'none');
-#print_r($n); echo "<br>";
-for ($i=0; $i<count($n); $i++){
- $match = array_search('none',$copytargets);
- array_splice($copytargets, $match, 1);
-}
-#print_r($copytargets); echo "<br>";
-
-
-$seconds = 2;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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 ( $pxecn != ""){
-
- # Formulareingaben anpassen
- $exppxe = explode(" ",$pxecn);
- foreach ($exppxe as $word){$expuc[] = ucfirst($word);}
- $pxecn = implode(" ",$expuc);
- $pxecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $pxecn);
-
- $nomac = 0;
-
- if (count($copytargets) != 0){
- foreach ($copytargets as $targetDN){
-
- $exptargetdn = ldap_explode_dn($targetDN, 1);
- $targetcn = $exptargetdn[0];
- $targettype = $exptargetdn[1];
-
- # falls Target keine MAC hat dann kann keine PXE angelegt werden
- if ($targettype == "computers"){
- $macdata = get_node_data($targetDN, array("hwaddress"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Ziel-Rechner ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst eine MAC ein!<br><br>";
- }
- }
- if ($targettype == "groups"){
- $members = get_node_data($targetDN, array("member"));
- if (count($members) > 1){
- foreach ($members['member'] as $hostDN){
- $macdata = get_node_data($hostDN, array("hwaddress","hostname"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Gruppen-Rechner <b>".$macdata['hostname']."</b> ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; f&uuml;r die Gruppe wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst bei Rechner <b>".$macdata['hostname']."</b> eine MAC ein!<br><br>";
- }
- }
- }
- if (count($members) == 1){
- $macdata = get_node_data($members['member'], array("hwaddress"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Gruppen-Rechner <b>".$macdata['hostname']."</b> ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; f&uuml;r die Gruppe wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst bei Rechner <b>".$macdata['hostname']."</b> eine MAC ein!<br><br>";
- }
- }
- }
-
- $brothers = get_pxeconfigs($targetDN,array("cn"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['cn'] == $pxecn ){
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml; mit dem eingegebenen Namen!<br>
- Bitte geben Sie einen anderen Namen ein.<br><br>";
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0 && $nomac == 0){
-
- $exptargetdn = ldap_explode_dn($targetDN, 1);
- $target = $exptargetdn[0];
- $targettype = $exptargetdn[1];
-
- $newpxeDN = "cn=".$pxecn.",".$targetDN;
- print_r($newpxeDN); echo "<br>";
-
- if (dive_into_tree_cp($pxeDN,$newpxeDN)){
-
- # Filename anpassen
- if ($targettype == "computers"){
- $macdata = get_node_data($targetDN, array("hwaddress"));
- $pxemac = str_replace (":","-",$macdata['hwaddress']);
- $entrymod ['filename'] = "01-".$pxemac;
- #$entrymod ['fileuri'] = "01-".$macdata['hwaddress'].".tgz";
- }
- if ($targettype == "groups"){
- $members = get_node_data($targetDN, array("member"));
- if (count($members) != 0){
- foreach ($members['member'] as $hostDN){
- $macdata = get_node_data($hostDN, array("hwaddress"));
- $pxemac = str_replace (":","-",$macdata['hwaddress']);
- $entrymod ['filename'][] = "01-".$pxemac;
- #$entrymod ['fileuri'] = $target.".tgz";
- }
- }
- }
- if(ldap_mod_replace($ds,$newpxeDN,$entrymod)){
- if($deltr == 1){
- # Timeranges und FileURI im neuen Objekt löschen (todo: anpassen statt löschen)
- $entrydel ['timerange'] = array();
- $entrydel ['fileuri'] = array();
- if ( ldap_mod_del($ds,$newpxeDN,$entrydel) ){
- $mesg .= "<br>PXE Boot Men&uuml; erfolgreich nach ".$target[1]." kopiert<br>";
- }
- else{
- ldap_delete($ds,$newpxeDN);
- $mesg .= "<br>Fehler beim kopieren des PXE Boot Men&uuml;s nach <b>".$target[1]."</b><br>";
- }
- }
- }
- else{
- ldap_delete($ds,$newpxeDN);
- $mesg .= "<br>Fehler beim kopieren des PXE Boot Men&uuml;s nach <b>".$target[1]."</b><br>";
- }
- }
- else{
- $mesg .= "<br>Fehler beim kopieren des PXE Boot Men&uuml;s nach <b>".$target[1]."</b><br>";
- }
- }
- }
- }
- else{
- $mesg .= "<br>Sie haben kein Ziel angegeben!<br>";
- }
-}
-
-elseif ( $pxecn == ""){
-
- $mesg = "Sie haben den Namen des neuen PXE Boot Men&uuml;s nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-
-$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/computers/pxe_delete.php b/ldap-site-mngmt/webinterface/computers/pxe_delete.php
deleted file mode 100644
index a1b7a060..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_delete.php
+++ /dev/null
@@ -1,42 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxeDN = $_POST['dn'];
-$oldpxecn = $_POST['name'];
-
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$seconds = 1;
-$url = $_POST['successurl'];
-
-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 ( $pxeDN != ""){
-
- if ( dive_into_tree_del($pxeDN,"") ){
- $mesg = "PXE Boot Men&uuml; <b>".$pxecn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen des PXE Boot Men&uuml;s <b>".$pxecn."</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/computers/pxe_globals.dwt b/ldap-site-mngmt/webinterface/computers/pxe_globals.dwt
deleted file mode 100644
index f0497183..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_globals.dwt
+++ /dev/null
@@ -1,128 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td colspan='4' height='20'><h4><a href='pxeconfigs.php' class='headerlink'><< Zur&uuml;ck zur &Uuml;bersicht PXE Configs</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
-
- <tr>
- <td colspan='4'><h3>PXE Konfiguration &nbsp;<code class='font_object'> {PXECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4>{PXELINK} Allgemein</code></a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4><code class='font_object'> Global Options </h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{BMLINK} Bootmenue </a></h4></td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
-
-
- <tr>
- <td colspan='4'><h4>Globale Optionen der PXE Konfiguration:</h4></td>
- </tr>
-
- <tr><td colspan='4'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='pxe_globals_change.php' method='post'>
-
- <tr>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[default]' value='{DEFAULT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[default]' value='{DEFAULT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Title: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menutitle]' value='{MENTIT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menutitle]' value='{MENTIT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Master Passwd: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menumasterpasswd]' value='{MENMPW}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menumasterpasswd]' value='{MENMPW}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Timeout: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[timeout]' value='{TIMEOUT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[timeout]' value='{TIMEOUT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>No Escape: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noescape]' value='{NOESC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[noescape]' value='{NOESC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Prompt: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[prompt]' value='{PROMPT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[prompt]' value='{PROMPT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Allow Options: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[allowoptions]' value='{ALLOW}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[allowoptions]' value='{ALLOW}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>On Error: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[onerror]' value='{ONERR}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[onerror]' value='{ONERR}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>ON Timeout: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[ontimeout]' value='{ONTIME}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[ontimeout]' value='{ONTIME}'> &nbsp;
- </td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>File URI: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+1'>tftp://{TFTP}/{TFTPFILE}</font><input type='Text' name='attribs[fileuri]' value='{FILEURI}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[fileuri]' value='{FILEURI}'>
- &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td>
- <input type='hidden' name='nodedn' value='{NODEDN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='oldpxecn' value='{PXECN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- <input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/pxe_globals.php b/ldap-site-mngmt/webinterface/computers/pxe_globals.php
deleted file mode 100644
index 211a47c8..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_globals.php
+++ /dev/null
@@ -1,96 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "pxe_globals.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$pxeDN = $_GET['dn'];
-# DN, CN des übergeordneten Nodes (Host oder Group)
-$pxednarray = ldap_explode_dn($pxeDN, 0);
-$nodeDN = implode(',',array_slice($pxednarray,2));
-#$nodeDN = $_GET['nodedn'];
-$nodednarray = ldap_explode_dn($nodeDN, 1);
-
-$attributes = array("dn","cn","rbservicedn","filename","timerange","allowoptions","console","default",
- "display","font","implicit","kbdmap","menumasterpasswd","menutitle",
- "noescape","onerror","ontimeout","prompt","say","serial","timeout","ldapuri","fileuri");
-$pxe = get_node_data($pxeDN,$attributes);
-
-# RBS Daten
-$rbsDN = $pxe['rbservicedn'];
-$rbsdata = get_node_data($rbsDN,array("cn","nfsserverip","exportpath","tftpserverip","tftppath","tftpclientconfpath"));
-
-# Timerange Komponenten
-$template->define_dynamic("TRanges", "Webseite");
-if (count($pxe['timerange']) > 1){
- foreach($pxe['timerange'] as $tr){
- $exptime = explode('_',$tr);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
- }
-}else{
- $exptime = explode('_',$pxe['timerange']);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
-}
-
-
-# Globale Parameter
-$template->assign(array("PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "TIMERANGE" => $pxe['timerange'],
- "TFTP" => $rbsdata['tftpserverip'],
- "TFTPFILE" => $rbsdata['tftpclientconfpath'],
- #"LDAPURI" => $pxe['ldapuri'],
- "FILEURI" => $pxe['fileuri'],
- "ALLOW" => $pxe['allowoptions'],
- "CONSOLE" => $pxe['console'],
- "DEFAULT" => $pxe['default'],
- "DISPLAY" => $pxe['display'],
- "FONT" => $pxe['font'],
- "IMPLICIT" => $pxe['implicit'],
- "KBDMAP" => $pxe['kbdmap'],
- "MENMPW" => $pxe['menumasterpasswd'],
- "MENTIT" => $pxe['menutitle'],
- "NOESC" => $pxe['noescape'],
- "ONERR" => $pxe['onerror'],
- "ONTIME" => $pxe['ontimeout'],
- "PROMPT" => $pxe['prompt'],
- "SAY" => $pxe['say'],
- "SERIAL" => $pxe['serial'],
- "TIMEOUT" => $pxe['timeout'],
- "NODEDN" => $nodeDN,
- "NODE" => $nodednarray[0],
- "DEFDN" => "cn=rbs,".$auDN,
- "PXELINK" => "<a href='pxe.php?dn=".$pxeDN."&mnr=".$mnr."' class='headerlink'>",
- "BMLINK" => "<a href='pxe_bootmenue.php?dn=".$pxeDN."&mnr=".$mnr."' class='headerlink'>",
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/pxe_globals_change.php b/ldap-site-mngmt/webinterface/computers/pxe_globals_change.php
deleted file mode 100644
index 06f388bb..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_globals_change.php
+++ /dev/null
@@ -1,126 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxeDN = $_POST['pxedn'];
-$oldpxecn = "PXE_".$_POST['oldpxecn'];
-$pxecn = "PXE_".$_POST['pxecn'];
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-# 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>";
-
-
-$seconds = 2;
-$url = "pxe_globals.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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>";
-
-
-
-
-
-##################################################################
-# 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,$pxeDN,$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,$pxeDN,$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,$pxeDN,$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/computers/pxe_wochenplan.php b/ldap-site-mngmt/webinterface/computers/pxe_wochenplan.php
deleted file mode 100644
index 8296762a..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxe_wochenplan.php
+++ /dev/null
@@ -1,262 +0,0 @@
-<?php
-
-#####################################
-# Wochenübersicht
-
-$template->assign(array("A0" => "","B0" => "","C0" => "","D0" => "","E0" => "","F0" => "","G0" => "",
- "A1" => "","B1" => "","C1" => "","D1" => "","E1" => "","F1" => "","G1" => "",
- "A2" => "","B2" => "","C2" => "","D2" => "","E2" => "","F2" => "","G2" => "",
- "A3" => "","B3" => "","C3" => "","D3" => "","E3" => "","F3" => "","G3" => "",
- "A4" => "","B4" => "","C4" => "","D4" => "","E4" => "","F4" => "","G4" => "",
- "A5" => "","B5" => "","C5" => "","D5" => "","E5" => "","F5" => "","G5" => "",
- "A6" => "","B6" => "","C6" => "","D6" => "","E6" => "","F6" => "","G6" => "",
- "A7" => "","B7" => "","C7" => "","D7" => "","E7" => "","F7" => "","G7" => "",
- "A8" => "","B8" => "","C8" => "","D8" => "","E8" => "","F8" => "","G8" => "",
- "A9" => "","B9" => "","C9" => "","D9" => "","E9" => "","F9" => "","G9" => "",
- "A10" => "","B10" => "","C10" => "","D10" => "","E10" => "","F10" => "","G10" => "",
- "A11" => "","B11" => "","C11" => "","D11" => "","E11" => "","F11" => "","G11" => "",
- "A12" => "","B12" => "","C12" => "","D12" => "","E12" => "","F12" => "","G12" => "",
- "A13" => "","B13" => "","C13" => "","D13" => "","E13" => "","F13" => "","G13" => "",
- "A14" => "","B14" => "","C14" => "","D14" => "","E14" => "","F14" => "","G14" => "",
- "A15" => "","B15" => "","C15" => "","D15" => "","E15" => "","F15" => "","G15" => "",
- "A16" => "","B16" => "","C16" => "","D16" => "","E16" => "","F16" => "","G16" => "",
- "A17" => "","B17" => "","C17" => "","D17" => "","E17" => "","F17" => "","G17" => "",
- "A18" => "","B18" => "","C18" => "","D18" => "","E18" => "","F18" => "","G18" => "",
- "A19" => "","B19" => "","C19" => "","D19" => "","E19" => "","F19" => "","G19" => "",
- "A20" => "","B20" => "","C20" => "","D20" => "","E20" => "","F20" => "","G20" => "",
- "A21" => "","B21" => "","C21" => "","D21" => "","E21" => "","F21" => "","G21" => "",
- "A22" => "","B22" => "","C22" => "","D22" => "","E22" => "","F22" => "","G22" => "",
- "A23" => "","B23" => "","C23" => "","D23" => "","E23" => "","F23" => "","G23" => ""));
-
-#print_r($timeranges); echo "<br>";
-
-############################################################################
-# Default-Dienst PXE Timeranges
-# vom spezifischsten zum unspezifischsten :
-# FR_0_7 -> FR_X_X -> X_0_7 -> X_X_X
-$daytime = array();
-$timex = array();
-$dayx = array();
-$allx = array();
-$legend = array();
-if(count($wopldeftranges) != 0){
-foreach ($wopldeftranges as $tr){
- if (count($tr[0]) > 1){
- foreach ($tr as $item){
- if ($item[0] != "X" && $item[1] != "X" && $item[2] != "X" && ($item[0] == "MO" || $item[0] == "DI" || $item[0] == "MI" || $item[0] == "DO" || $item[0] == "FR" || $item[0] == "SA" || $item[0] == "SO")){
- $daytime[] = $item;
- }
- if ($item[0] != "X" && $item[1] == "X" && $item[2] == "X"){
- $timex[] = $item;
- }
- if ($item[0] == "X" && $item[1] != "X" && $item[2] != "X"){
- $dayx[] = $item;
- }
- if ($item[0] == "X" && $item[1] == "X" && $item[2] == "X"){
- $allx[] = $item;
- }
- }
- }else{
- if ($tr[0] != "X" && $tr[1] != "X" && $tr[2] != "X" && ($tr[0] == "MO" || $tr[0] == "DI" || $tr[0] == "MI" || $tr[0] == "DO" || $tr[0] == "FR" || $tr[0] == "SA" || $tr[0] == "SO")){
- $daytime[] = $tr;
- }
- if ($tr[0] != "X" && $tr[1] == "X" && $tr[2] == "X"){
- $timex[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] != "X" && $tr[2] != "X"){
- $dayx[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] == "X" && $tr[2] == "X"){
- $allx[] = $tr;
- }
- }
-}
-
-#print_r($daytime); echo "<br>";
-#print_r($timex); echo "<br>";
-#print_r($dayx); echo "<br>";
-#print_r($allx); echo "<br>";
-
-$daycode = array("MO" => "A", "DI" => "B", "MI" => "C", "DO" => "D", "FR" => "E", "SA" => "F", "SO" => "G");
-$daytimexcolors = array("#BEBEBE","A0A0A0","#696969","#EEDFCC","#D8BFD8","#505050");
-$allxcolors = array("#483D8B","#7B68EE","#191970","#8470FF","#708090","#6A5ACD");
-$dayxcolors = array("#CDC673","#A2CD5A","#BDB76B","#8B864E","#6B8E23","#CDBE70");
-$timecolors = array("880000","#CD6839","#CC3300","#CC6600","#993300","#8B4C39");
-
-
-if (count($allx) != 0){
- $c = 0;
- foreach ($allx as $range){
- foreach ($daycode as $dc){
- for ($i = 0; $i <= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$allxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$allxcolors[$c]);
- $c++;
- }
-}
-
-if (count($dayx) != 0){
- $c = 0;
- foreach ($dayx as $range){
- foreach ($daycode as $dc){
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$dayxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$dayxcolors[$c]);
- $c++;
- }
-}
-
-if (count($timex) != 0){
- $c = 0;
- foreach ($timex as $range){
- $dc = $daycode[$range[0]];
- for ($i = 0; $i<= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$timexcolors[$c].";"));
- }
- $legend[] = array($range ,$timexcolors[$c]);
- $c++;
- }
-}
-
-if (count($daytime) != 0){
- $c = 0;
- foreach ($daytime as $range){
- $dc = $daycode[$range[0]];
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$daytimecolors[$c].";"));
- }
- $legend[] = array($range ,$daytimecolors[$c]);
- $c++;
- }
-}
-
-}
-
-############################################################################
-# Rechner-spezifische PXE Timeranges
-# vom spezifischsten zum unspezifischsten :
-# FR_0_7 -> FR_X_X -> X_0_7 -> X_X_X
-$daytime = array();
-$timex = array();
-$dayx = array();
-$allx = array();
-
-if(count($wopltranges) != 0){
-foreach ($wopltranges as $tr){
- if (count($tr[0]) > 1){
- foreach ($tr as $item){
- if ($item[0] != "X" && $item[1] != "X" && $item[2] != "X" && ($item[0] == "MO" || $item[0] == "DI" || $item[0] == "MI" || $item[0] == "DO" || $item[0] == "FR" || $item[0] == "SA" || $item[0] == "SO")){
- $daytime[] = $item;
- }
- if ($item[0] != "X" && $item[1] == "X" && $item[2] == "X"){
- $timex[] = $item;
- }
- if ($item[0] == "X" && $item[1] != "X" && $item[2] != "X"){
- $dayx[] = $item;
- }
- if ($item[0] == "X" && $item[1] == "X" && $item[2] == "X"){
- $allx[] = $item;
- }
- }
- }else{
- if ($tr[0] != "X" && $tr[1] != "X" && $tr[2] != "X" && ($tr[0] == "MO" || $tr[0] == "DI" || $tr[0] == "MI" || $tr[0] == "DO" || $tr[0] == "FR" || $tr[0] == "SA" || $tr[0] == "SO")){
- $daytime[] = $tr;
- }
- if ($tr[0] != "X" && $tr[1] == "X" && $tr[2] == "X"){
- $timex[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] != "X" && $tr[2] != "X"){
- $dayx[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] == "X" && $tr[2] == "X"){
- $allx[] = $tr;
- }
- }
-}
-
-#print_r($daytime); echo "<br>";
-#print_r($timex); echo "<br>";
-#print_r($dayx); echo "<br>";
-#print_r($allx); echo "<br>";
-
-$daycode = array("MO" => "A", "DI" => "B", "MI" => "C", "DO" => "D", "FR" => "E", "SA" => "F", "SO" => "G");
-$allxcolors = array("#BEBEBE","A0A0A0","#696969","#EEDFCC","#D8BFD8","#505050");
-$dayxcolors = array("#483D8B","#7B68EE","#191970","#8470FF","#708090","#6A5ACD");
-$timexcolors = array("#CDC673","#A2CD5A","#BDB76B","#8B864E","#6B8E23","#CDBE70");
-$daytimecolors = array("880000","#CD6839","#CC3300","#CC6600","#993300","#8B4C39");
-
-
-if (count($allx) != 0){
- $c = 0;
- foreach ($allx as $range){
- foreach ($daycode as $dc){
- for ($i = 0; $i <= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$allxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$allxcolors[$c]);
- $c++;
- }
-}
-
-if (count($dayx) != 0){
- $c = 0;
- foreach ($dayx as $range){
- foreach ($daycode as $dc){
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$dayxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$dayxcolors[$c]);
- $c++;
- }
-}
-
-if (count($timex) != 0){
- $c = 0;
- foreach ($timex as $range){
- $dc = $daycode[$range[0]];
- for ($i = 0; $i<= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$timexcolors[$c].";"));
- }
- $legend[] = array($range ,$timexcolors[$c]);
- $c++;
- }
-}
-
-if (count($daytime) != 0){
- $c = 0;
- foreach ($daytime as $range){
- $dc = $daycode[$range[0]];
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$daytimecolors[$c].";"));
- }
- $legend[] = array($range ,$daytimecolors[$c]);
- $c++;
- }
-}
-
-}
-
-$template->assign(array("PXEPLANDESC" => ""));
-#print_r($legend);
-if (count($legend) != 0){
- $template->define_dynamic("Legende", "Webseite");
- foreach ($legend as $item){
- # Timerange Komponente
- $color = $item[1];
- $template->assign(array("TR1" => $item[0][0],
- "TR2" => $item[0][1],
- "TR3" => $item[0][2],
- "PXEPLANDESC" => $item[0][3],
- "COLOR" => $color));
- $template->parse("LEGENDE_LIST", ".Legende");
- }
-}
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/pxeconfigs.dwt b/ldap-site-mngmt/webinterface/computers/pxeconfigs.dwt
deleted file mode 100644
index 428eb13b..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxeconfigs.dwt
+++ /dev/null
@@ -1,318 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='4'><h3>PXE Konfigurationen (Boot Men&uuml;s) &nbsp;<code class='font_object'> {AU} </code> </h3></td>
- </tr>
-
- <tr><td colspan='4'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='20%' class='tab_h'><b>PXE Config</b></td>
- <td width='20%' class='tab_h'><b>g&uuml;ltig f&uuml;r Client(s)</b></td>
- <td width='30%' class='tab_h'><b>Time Range (G&uuml;ltigkeitsdauer)</b></td>
- <td width='30%' class='tab_h'><b>&nbsp;</b></td>
- </tr>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Pxeconf -->
- <tr valign='top'>
- <td class='tab_d'>{PXECN} &nbsp;</td>
- <td class='tab_d'>{PXECLIENTS} &nbsp;</td>
- <td class='tab_d'>{TRANGES} &nbsp;</td>
- <td class='tab_d'> &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Pxeconf -->
-
- </table></td>
- </tr>
-
-
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='4'><h4>Wochen &Uuml;bersicht PXE Configs:</h4></td>
- </tr>
- <tr valign='top'>
- <td width="70%">
- <table cellpadding='0' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 2 0 2 2;'><b>Uhrzeit</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Montag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Dienstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Mittwoch</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Donnerstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Freitag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Samstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 2 2 1;'><b>Sonntag</b></td>
- </tr>
- <tr heigth='2' align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>0</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G0}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G1}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>2</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G2}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G3}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>4</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G4}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G5}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>6</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G6}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G7}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>8</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G8}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G9}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>10</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G10}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G11}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>12</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G12}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G13}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>14</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G14}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G15}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>16</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G16}'>&nbsp;&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G17}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>18</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G18}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G19}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>20</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G20}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G21}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>22</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G22}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{A23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{B23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{C23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{D23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{E23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{F23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 2 1;{G23}'>&nbsp;</td>
- </tr>
-
- </table></td>
-
- <td width="30%">
- <table cellpadding='3' cellspacing='3' border='1' align='left' width='50%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>PXE Config</b></td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Farbe</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>No Config &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Legende -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>{PXEPLANDESC} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;background-color:{COLOR};'>&nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Legende -->
-
- </table></td>
- </tr>
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/computers/pxeconfigs.php b/ldap-site-mngmt/webinterface/computers/pxeconfigs.php
deleted file mode 100644
index 95d1abfd..00000000
--- a/ldap-site-mngmt/webinterface/computers/pxeconfigs.php
+++ /dev/null
@@ -1,92 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "pxeconfigs.dwt";
-
-include('computers_header.inc.php');
-
-###################################################################################
-
-$mnr = 2;
-$sbmnr = -1;
-$mcnr = -1;
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$rbsDN = $_GET['rbsdn'];
-
-$template->assign(array("PXEDN" => "",
- "PXECN" => "Noch keine PXE Boot Konfiguration angelegt",
- "TRANGES" => "",
- "PXECLIENTS" => "",
- "RBS" => "",
- "CN" => ""));
-
-$pxe_array = get_pxeconfigs2("",array("dn","cn","timerange","rbservicedn","pxeclientdn"));
-
-$template->define_dynamic("Pxeconf", "Webseite");
-
-for ($i=0; $i<count($pxe_array); $i++){
-
- # PXE Config Name
- $pxename = "<a href='pxe.php?dn=".$pxe_array[$i]['dn']."&mnr=".$mnr."&sbmnr=".$i."' class='headerlink'>".$pxe_array[$i]['cn']."</a><br>";
-
- # Timerange Komponenten
- $trange = "";
- if (count($pxe_array[$i]['timerange']) > 1 ){
- foreach ($pxe_array[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),$pxe_array[$i]['cn']);
- $wopltranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59 / ";
- }
- }elseif (count($pxe_array[$i]['timerange']) == 1 ){
- $exptime = array_merge(explode('_',$pxe_array[$i]['timerange']), array($pxe_array[$i]['cn']));
- $wopltranges[$i] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59";
- }
-
- # PXE Config Clients
- $pxeclients = "";
- if (count($pxe_array[$i]['pxeclientdn']) > 1 ){
- #echo "ClientsARRAY: "; print_r($pxe_array[$i]['pxeclientdn']); echo "<br>";
- foreach ($pxe_array[$i]['pxeclientdn'] as $item) {
- $pxecldn = ldap_explode_dn($item, 1);
- $pxeclients .= $pxecldn[0]."<br>";
- }
-
- }elseif (count($pxe_array[$i]['pxeclientdn']) == 1 ){
- $pxecldn = ldap_explode_dn($pxe_array[$i]['pxeclientdn'], 1);
- $pxeclients = $pxecldn[0];
- }
-
- $template->assign(array("PXEDN" => $pxe_array[$i]['dn'],
- "PXECN" => $pxename,
- "TRANGES" => $trange,
- "PXECLIENTS" => $pxeclients,
- "RBS" => $rbsDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "AUDN" => $auDN));
- $template->parse("PXECONF_LIST", ".Pxeconf");
-
-}
-
-
-include("pxe_wochenplan.php");
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/computers/rbshost.dwt b/ldap-site-mngmt/webinterface/computers/rbshost.dwt
deleted file mode 100644
index abff2cd8..00000000
--- a/ldap-site-mngmt/webinterface/computers/rbshost.dwt
+++ /dev/null
@@ -1,385 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 1;'><h4>{HOSTLINK} Allgemein </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{DHCPLINK} DHCP </a></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4><code class='font_object'> RBS/PXE </code></h4></td>
- <td align='center' width='15%' style='border-color: black; border-style: solid; border-width: 0 1 0 0;'><h4>{HWLINK} Geo/Hardware </a></h4></td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
-
- <tr>
- <td colspan='5'><h3>RBS/PXE Setup - Rechner &nbsp;<code class='font_object'> {HOSTNAME} </code> </h3></td>
- </tr>
- <tr>
- <td colspan='4' class='tab_d_ohne'>{NODHCP}&nbsp;</td>
- </tr>
-
- <tr><td colspan='5'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='rbshost_change.php' method='post'>
-
- <tr>
- <td width='40%' class='tab_h'><b>Remote Boot Dienst Einbindung (DHCP/TFTP)</b></td>
- <td width='60%' class='tab_h'><b>&nbsp;</b></td>
- </tr>
-
-
-
- {RBS}
-
-
- </table></td>
- </tr>
-
- <input type='hidden' name='olddhcp' value='{OLDDHCP}'>
- <input type='hidden' name='oldfixadd' value='{OLDFIXADD}'>
- <input type='hidden' name='oldrbs' value='{OLDRBS}'>
- <input type='hidden' name='hostip' value='{IPADDRESS}'>
- <input type='hidden' name='hostdn' value='{HOSTDN}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
-
- <tr>
- <td colspan='4'><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
-
- <tr>
- <td height='20'></td>
- </tr>
-
- <tr><td colspan='5'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <tr>
- <td colspan='3' width='50%' class='tab_h'><b>Rechner-spezifische PXE Konfigurationen (Bootmen&uuml;s)</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Rechnerpxes -->
- <tr valign='top'>
- <td width='20%' class='tab_d'>{PXECN} &nbsp;</td>
- <td width='30%' class='tab_d'>{PXETR} &nbsp;</td>
- <td class='tab_d'>{PXEDESC} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Rechnerpxes -->
-
-
- </table></td>
- </tr>
-
- <tr>
- <td height='20'></td>
- </tr>
-
- <tr><td colspan='5'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <tr>
- <td colspan='3' width='50%' class='tab_h'><b>Default PXE Konfigurationen des Remote Boot Dienstes</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Defpxes -->
- <tr valign='top'>
- <td width='20%' class='tab_d'>{DEFPXECN} &nbsp;</td>
- <td width='30%' class='tab_d'>{DEFPXETR} &nbsp;</td>
- <td class='tab_d'>{DEFPXEDESC} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Defpxes -->
-
-
- </table></td>
- </tr>
-
-
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='4'><h4>Wochen &Uuml;bersicht PXE Configs f&uuml;r Rechner &nbsp;<code class='font_object'>{HOSTNAME}</code>&nbsp; :</h4></td>
- </tr>
- <tr><td colspan='4'>
- <table cellpadding='0' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 2 0 2 2;'><b>Uhrzeit</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Montag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Dienstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Mittwoch</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Donnerstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Freitag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Samstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 2 2 1;'><b>Sonntag</b></td>
- </tr>
- <tr heigth='2' align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>0</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G0}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G1}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>2</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G2}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G3}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>4</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G4}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G5}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>6</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G6}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G7}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>8</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G8}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G9}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>10</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G10}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G11}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>12</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G12}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G13}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>14</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G14}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G15}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>16</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G16}'>&nbsp;&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G17}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>18</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G18}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G19}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>20</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G20}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G21}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>22</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G22}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{A23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{B23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{C23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{D23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{E23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{F23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 2 1;{G23}'>&nbsp;</td>
- </tr>
-
- </table></td>
-
- <td colspan='2'>
- <table cellpadding='3' cellspacing='3' border='1' align='left' width='50%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>PXE Config</b></td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Farbe</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>No Config &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Legende -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>{PXEPLANDESC} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;background-color:{COLOR};'>&nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Legende -->
-
- </table></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/rbshost.php b/ldap-site-mngmt/webinterface/computers/rbshost.php
deleted file mode 100644
index b28e0726..00000000
--- a/ldap-site-mngmt/webinterface/computers/rbshost.php
+++ /dev/null
@@ -1,250 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "rbshost.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$hostDN = $_GET['dn'];
-
-# Rechner Daten
-$attributes = array("hostname","domainname","ipaddress","hwaddress","description","hlprbservice",
- "dhcphlpcont","dhcpoptfixed-address","dhcpopthardware","dhcpoptfilename",
- "dhcpoptnext-server","hw-mouse","hw-graphic","hw-monitor");
-$host = get_node_data($hostDN,$attributes);
-$hostip = explode('_',$host['ipaddress']);
-# print_r($hostip); echo "<br><br>";
-$dhcphlpcont = $host['dhcphlpcont'];
-$objectDN = $dhcphlpcont;
-$rbsDN = $host['hlprbservice'];
-
-$rbs_dhcpopt = "";
-$host_dhcpopt = "";
-$dhcp_selectbox = "";
-
-$rbs = "";
-$nodhcptext = "";
-
-# Falls nicht DHCP Dienst dann Erklärung ...
-if ($dhcphlpcont == ""){
-
- $nodhcptext .= "Der Rechner ist in keinem DHCP Dienst eingetragen. Dies ist jedoch Voraussetzung,
- um einen Remote Boot Dienst nutzen zu k&ouml;nnen.<br>
- D.h. die hier verwalteten RBS-relevanten DHCP Optionen werden bzw. sind f&uuml;r den Client zentral gespeichert,
- werden jedoch in keine DHCP Dienst Konfiguration &uuml;nernommen.
- ";
-}
-# <input type='hidden' name='rbs' value='".$rbsDN."'>
-###########################################################
-# RBS Setup
-$rbs_selectbox = "";
-$rbs_dhcpopt = "";
-$altrbs = alternative_rbservices($rbsDN);
-
-
- $rbs_selectbox .= "<td class='tab_d'>
- <select name='rbs' size='4' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>";
-if (count($altrbs) != 0){
- foreach ($altrbs as $item){
- $rbs_selectbox .= "
- <option value='".$item['dn']."'>".$item['cn']." ".$item['au']."</option>";
- }
-}
-$rbs_selectbox .= "<option value=''>Kein RBS</option>
- </select></td>";
-
-# RBS Daten
-if ($rbsDN == ""){
-
- $rbs .= "<td class='tab_d_ohne'><b>Remote Boot Dienst: </b>&nbsp;</td>
- <td class='tab_d_ohne'>
- Rechner ist in keinem Remote Boot Dienst angemeldet<br></td></tr>
- <tr valign='top'><td class='tab_d'>
- RBS ausw&auml;hlen: <br></td>".$rbs_selectbox;
-}else{
-
- $rbsdata = get_node_data($rbsDN,array("tftpserverip"));
- #print_r($rbsdata); echo "<br>";
- $exp2 = explode(',',$host['hlprbservice']);
- $exprbs = explode('=',$exp2[0]); $rbserv = $exprbs[1];
- $exprbsau = explode('=',$exp2[2]); $rbsau = $exprbsau[1];
- $rbs .= "<tr valign='top'>
- <td class='tab_d_ohne'><b>Remote Boot Dienst: </b>&nbsp;</td>
- <td class='tab_d_ohne'>
- Remote Boot Service <b>".$rbserv."</b> / AU <b>".$rbsau."</b></td>
- </tr>
- <tr>
- <td class='tab_d_ohne'>DHCP Option <b>next-server</b> &nbsp;(TFTP Boot Server IP):</td>
- <td class='tab_d_ohne'><b>".$host['dhcpoptnext-server']."</b>&nbsp;</td>
- </tr>
- <tr>
- <td class='tab_d'>DHCP Option <b>filename</b> &nbsp;(initiale remote Bootdatei):</td>
- <td class='tab_d'><b>".$host['dhcpoptfilename']."</b>&nbsp;</td>
- </tr>
- <tr valign='top'><td class='tab_d'>
- RBS Einbindung &auml;ndern: <br></td>".$rbs_selectbox."
- </tr>";
-
- $rbs_dhcpopt = "";
-
-}
-
-
-$template->assign(array("HOSTDN" => $hostDN,
- "HOSTNAME" => $host['hostname'],
- "DOMAINNAME" => $host['domainname'],
- "HWADDRESS" => $host['hwaddress'],
- "IPADDRESS" => $hostip[0],
- "DESCRIPTION" => $host['description'],
- "OLDDHCP" => $objectDN,
- "OLDFIXADD" => $host['dhcpoptfixed-address'],
- "NODHCP" => $nodhcptext,
- "OLDRBS" => $rbsDN,
- "RBS" => $rbs,
- "HOSTLINK" => "<a href='host.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "DHCPLINK" => "<a href='dhcphost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "HWLINK" => "<a href='hwhost.php?dn=".$hostDN."&sbmnr=".$sbmnr."' class='headerlink'>",
- "AUDN" => $auDN,
- "SBMNR" => $sbmnr));
-
-
-
-
-# Rechnerspezifische PXEs
-$hostpxeconfigs = get_pxeconfigs2($hostDN, array("dn","cn","description","timerange"));
-
-$template->assign(array("PXEDN" => "",
- "PXECN" => "Keine PXE Config angelegt",
- "PXEDESC" => "",
- "PXETR" => "",));
-$template->define_dynamic("Rechnerpxes", "Webseite");
-
-if (count($hostpxeconfigs) != 0){
- for ($i=0;$i<count($hostpxeconfigs);$i++){
- $pxelink = "<a href='pxe.php?dn=".$hostpxeconfigs[$i]['dn']."&mnr=1&sbmnr=".$sbmnr."&mcnr=".$i."&nodedn=".$hostDN."' class='headerlink'>".$hostpxeconfigs[$i]['cn']."</a>";
-
- $trange = "";
- if (count($hostpxeconfigs[$i]['timerange']) > 1 ){
- foreach ($hostpxeconfigs[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr), array($hostpxeconfigs[$i]['cn']));
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59 <br> ";
- }
- }else{
- $exptime = array_merge(explode('_',$hostpxeconfigs[$i]['timerange']), array($hostpxeconfigs[$i]['cn']));
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59";
- }
- $template->assign(array("PXEDN" => $hostpxeconfigs[$i]['dn'],
- "PXECN" => $pxelink,
- #"PXEDESC" => $hostpxeconfigs['description'],
- "PXETR" => $trange, ));
- $template->parse("RECHNERPXES_LIST", ".Rechnerpxes");
-
- }
-}
-
-
-# Default PXEs des RBS
-$template->assign(array("DEFPXEDN" => "",
- "DEFPXECN" => "Keine PXE Config angelegt",
- "DEFPXEDESC" => "",
- "DEFPXETR" => "",
- "PXEPLANDESC" => ""));
-$template->define_dynamic("Defpxes", "Webseite");
-
-if ($rbsDN != ""){
- $defaultpxeconfigs = get_pxeconfigs($rbsDN,array("dn","cn","description","timerange","filename"));
-
- if (count($defaultpxeconfigs) != 0){
- for ($i=0;$i<count($defaultpxeconfigs);$i++){
- if ($defaultpxeconfigs[$i]['filename'] == "default"){
- $defpxelink = "<a href='showpxe.php?dn=".$defaultpxeconfigs[$i]['dn']."&mnr=1&sbmnr=".$sbmnr."&mcnr=-1&hostdn=".$hostDN."' class='headerlink'>".$defaultpxeconfigs[$i]['cn']."</a>";
-
- $deftrange = "";
- if (count($defaultpxeconfigs[$i]['timerange']) > 1 ){
- foreach ($defaultpxeconfigs[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr), array($defaultpxeconfigs[$i]['cn']));
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $deftrange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59 <br> ";
- }
- }else{
- $exptime = array_merge(explode('_',$defaultpxeconfigs[$i]['timerange']), array($defaultpxeconfigs[$i]['cn']));
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $deftrange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59";
- }
-
- $template->assign(array("DEFPXEDN" => $defaultpxeconfigs[$i]['dn'],
- "DEFPXECN" => $defpxelink,
- "DEFPXEDESC" => $defaultpxeconfigs['description'],
- "DEFPXETR" => $deftrange, ));
- $template->parse("DEFPXES_LIST", ".Defpxes");
- }
- }
- }
-#}
-
-##########################################################
-# PXE Wochenübersicht
-
-# erst Defaults vom RBS Dienst
-for ($i=0; $i<count($defaultpxeconfigs); $i++){
- # Timerange Komponenten
- if (count($defaultpxeconfigs[$i]['timerange']) > 1 ){
- foreach ($defaultpxeconfigs[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),array($defaultpxeconfigs[$i]['cn']));
- $wopldeftranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- }
- }else{
- $exptime = array_merge(explode('_',$defaultpxeconfigs[$i]['timerange']), array($defaultpxeconfigs[$i]['cn']));
- $wopldeftranges[$i] = $exptime; # Für grafische Wo-Ansicht
- }
-}
-# Diese dann mit möglichen Rechnerspezifischen überschreiben
-for ($i=0; $i<count($hostpxeconfigs); $i++){
- # Timerange Komponenten
- if (count($hostpxeconfigs[$i]['timerange']) > 1 ){
- foreach ($hostpxeconfigs[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),array($hostpxeconfigs[$i]['cn']));
- $wopltranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- }
- }else{
- $exptime = array_merge(explode('_',$hostpxeconfigs[$i]['timerange']), array($hostpxeconfigs[$i]['cn']));
- $wopltranges[$i] = $exptime; # Für grafische Wo-Ansicht
- }
-}
-
-include("pxe_wochenplan.php");
-
-}
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/computers/rbshost_change.php b/ldap-site-mngmt/webinterface/computers/rbshost_change.php
deleted file mode 100644
index 179451ad..00000000
--- a/ldap-site-mngmt/webinterface/computers/rbshost_change.php
+++ /dev/null
@@ -1,98 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$syntax = new Syntaxcheck;
-
-$hostip = $_POST['hostip'];
-
-$rbs = $_POST['rbs'];
-$oldrbs = $_POST['oldrbs'];
-
-$hostDN = $_POST['hostdn'];
-$sbmnr = $_POST['sbmnr'];
-
-$rbs = htmlentities($rbs);
-$oldrbs = htmlentities($oldrbs);
-
-
-/*echo "new dhcp:"; print_r($dhcp); echo "<br>";
-echo "old dhcp:"; print_r($olddhcp); echo "<br>";
-echo "new rbs:"; print_r($rbs); echo "<br>";
-echo "old rbs:"; print_r($oldrbs); echo "<br>";
-echo "Host DN:"; print_r($hostDN); echo "<br>";
-echo "submenuNR:"; print_r($sbmnr); echo "<br><br>";*/
-
-
-$seconds = 2;
-$url = 'rbshost.php?dn='.$hostDN.'&sbmnr='.$sbmnr;
-
-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>";
-
-
-##########################################
-# RBS
-
-if ($rbs != "none" && $rbs != $oldrbs){
- if ($rbs != ""){
- $exp = ldap_explode_dn($rbs, 1);
- $rbscn = $exp[0];
- $rbsau = $exp[2];
-
- $dhcpdata = get_node_data($rbs,array("tftpserverip","initbootfile"));
- $entryrbs ['hlprbservice'] = $rbs;
- $entryrbs ['dhcpoptnext-server'] = $dhcpdata['tftpserverip'];
- $entryrbs ['dhcpoptfilename'] = $dhcpdata['initbootfile'];
- if ($oldrbs != ""){
- echo "RBS replace "; print_r($oldrbs); echo " with "; print_r($entryrbs); echo "<br>";
- if ($result = ldap_mod_replace($ds,$hostDN,$entryrbs)){
- update_dhcpmtime(array());
- rbs_adjust_host($hostDN, $rbs);
- $mesg = "Remote Boot Service erfolgreich zu <b>".$rbscn." [Abt.: ".$rbsau."]</b> ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des Remote Boot Services zu <b>".$rbscn."</b>!<br><br>";
- }
- }else{
- echo "RBS add "; print_r($entryrbs); echo "<br>";
- if ($result = ldap_mod_add($ds,$hostDN,$entryrbs)){
- update_dhcpmtime(array());
- rbs_adjust_host($hostDN, $rbs);
- $mesg = "Remote Boot Service erfolgreich zu <b>".$rbscn." [Abt.: ".$rbsau."]</b> ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des Remote Boot Services zu <b>".$rbscn."</b>!<br><br>";
- }
- }
- }else{
- $entryrbs ['hlprbservice'] = array();
- $entryrbs ['dhcpoptnext-server'] = array();
- $entryrbs ['dhcpoptfilename'] = array();
- echo "RBS delete "; echo "<br>";
- if ($result = ldap_mod_del($ds,$hostDN,$entryrbs)){
- update_dhcpmtime(array());
- $mesg = "Rechner erfolgreich aus RBS gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen aus RBS!<br><br>";
- }
- }
-}
-if ($rbs == "none"){
- echo "RBS none <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/computers/showpxe.dwt b/ldap-site-mngmt/webinterface/computers/showpxe.dwt
deleted file mode 100644
index d6f37f66..00000000
--- a/ldap-site-mngmt/webinterface/computers/showpxe.dwt
+++ /dev/null
@@ -1,57 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td height='20'><h4><a href='rbshost.php?dn={HOSTDN}&mnr=1&sbmnr={SBMNR}&mcnr=-1' class='headerlink'><< Zur&uuml;ck zu Rechner &nbsp;{HOST}</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
-
- <tr>
- <td colspan='2'><h3>Default PXE Config &nbsp;<code class='font_object'> {PXECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
-
- <tr>
- <td colspan='3'>Diese PXE Config wird vom RBS Betreiber verwaltet (Sie haben keine Schreibrechte).</td>
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='80%' style='border-color: black; border-style: solid; border-width: 2 2 2 2;'>
-
- <tr>
- <td width='8%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>#</td>
- <td width='12%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Flags</td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Menu Label&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Bootmenu -->
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>{POSITION}&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>{MEDEF} {MEPWD} {MEHIDE}&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'><font size='+1'>{ANZEIGE}&nbsp;</font></td>
- </tr>
- </form>
- <!-- END DYNAMIC BLOCK: Bootmenu -->
-
- </table></td>
- </tr>
- <tr>
- <td><h4>Flags:</h4></font>
- <ul>
- <li><b>D</b> -> Default Men&uuml;eintrag</li>
- <li><b>P</b> -> Passwort gesch&uuml;tzt</li>
- <li><b>H</b> -> Hidden</li>
- </ul>
- </td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
-
-
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/computers/showpxe.php b/ldap-site-mngmt/webinterface/computers/showpxe.php
deleted file mode 100644
index 7386aa83..00000000
--- a/ldap-site-mngmt/webinterface/computers/showpxe.php
+++ /dev/null
@@ -1,89 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "showpxe.dwt";
-
-include('computers_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr);
-
-###################################################################################
-
-$pxeDN = $_GET['dn'];
-
-$hostdn = $_GET['hostdn'];
-$hostdnarray = ldap_explode_dn($hostdn, 1);
-
-$attributes = array("dn","cn","rbservicedn","filename","timerange","kbdmap","menumasterpasswd","menutitle");
-$pxe = get_node_data($pxeDN,$attributes);
-#print_r($pxe);
-$expcn = explode('_',$pxe['cn']);
-$name = array_slice($expcn,1);
-$pxecn = implode('_',$name);
-
-
-
-
-# Bootmenü Einträge
-$menuentries = get_menuentries($pxeDN,array("dn","menuposition","label","menulabel","menudefault","menupasswd","menuhide"));
-# print_r($menuentries); echo "<br>";
-$maxpos = count($menuentries)+1;
-
-
-################################################
-# Bootmenü Einträge
-
-$template->define_dynamic("Bootmenu", "Webseite");
-$template->assign(array("PXECN" => $pxecn,
- "HOSTDN" => $hostdn,
- "HOST" => $hostdnarray[0],
- "SBMNR" => $sbmnr,
- "MENDN" => "",
- "MENULABEL" => "",
- "ANZEIGE" => "Kein Bootmen&uuml; Eintrag angelegt",
- "MEDEF" => "",
- "MEPWD" => "",
- "MEHIDE" => "",
- "BGCDEF" => "",
- "POSITION" => ""));
-foreach ($menuentries as $me){
- $anzeige = "";
- if ($me['label'] != "" && $me['menulabel'] == ""){$anzeige .= $me['label'];}
- if ($me['menulabel'] != ""){$anzeige .= $me['menulabel'];}
- if ($me['menudefault'] == 1){$medef = "<b>D</b>"; $bgcdef = "background-color:#EEDD82;";}
- if ($me['menupasswd'] != ""){$mepwd = "<b>P</b>";}
- if ($me['menuhide'] == 1){$mehide = "<b>H</b>"; $bgcdef = "background-color:#A0A0A0;";}
- $template->assign(array("MENDN" => $me['dn'],
- "ANZEIGE" => $anzeige,
- "ANZEIGENAME" => $anzeige,
- "POSITION" => $me['menuposition'],
- "MEDEF" => $medef,
- "MEPWD" => $mepwd,
- "MEHIDE" => $mehide,
- "BGCDEF" => $bgcdef,
- "AUDN" => $auDN));
- $template->parse("BOOTMENU_LIST", ".Bootmenu");
- $medef = "";
- $bgcdef = "";
-}
-
-
-###################################################################################
-
-include("computers_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/dhcp/delete_confirm.php b/ldap-site-mngmt/webinterface/dhcp/delete_confirm.php
deleted file mode 100644
index 3bb798b2..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/delete_confirm.php
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$dn = $_POST['dn'];
-$name = $_POST['name'];
-$delurl = $_POST['delurl'];
-$backurl = $_POST['backurl'];
-$successurl = $_POST['successurl'];
-$mnr = $_POST['mnr'];
-
-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='hidden' name='mnr' value='".$mnr."'>
- <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
deleted file mode 100644
index 9946aae9..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcp.dwt
+++ /dev/null
@@ -1,85 +0,0 @@
-<html>
-
-<head>
- <title>{SEITENTITEL}</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'></head>
-<body>
-
-<table cellpadding='0' cellspacing='0' border='0' width='100%' style='background-color: #F0F0F0;border-color: #505050; border-style: solid; border-width: 0 0 1 0;'>
- <tr>
- <td width='30%'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr valign='top'>
- <td width='1'></td>
- <td><h2>Client / IP Management</h2></td>
- </tr>
- </table>
- </td>
-
- <td width='45%'>
- <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>
- <tr>
- <td colspan='3'>{MAINMENU}</td>
- </tr>
-</table>
-
-<br>
-
-
-
-<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>
- <tr>
- <td>
-
- {IPBLOCKS}
-
- </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
deleted file mode 100644
index a54d5b17..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcp.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcp_start.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-
-###################################################################################
-
-# 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
deleted file mode 100644
index 7849823e..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcp_footer.inc.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?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("IPBLOCKS", "IPBlocks");
-$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
deleted file mode 100644
index 8cd98c00..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcp_header.inc.php
+++ /dev/null
@@ -1,29 +0,0 @@
-<?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 = 2;
-
-
-$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",
- "IPBlocks" => "../common/ipblocks.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));
-
-
-include("dhcp_menu.php");
-include("../common/ip_blocks.inc.php");
-
-?> \ 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
deleted file mode 100644
index 01ec5b92..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcp_menu.php
+++ /dev/null
@@ -1,215 +0,0 @@
-<?php
-
-function createDhcpMenu($rollen, $mnr, $auDN, $sbmnr) {
-
- global $template, $START_PATH, $rootAU;
-
- $mipbs = get_maxipblocks_au($auDN);
- #echo "MIPB: "; print_r ($mipbs); echo "<br>";
- if ($mipbs[0] != ""){
- $hauptmenu = array();
- }else{
- $hauptmenu = array(array("link" => "no_dhcp.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => "alle"));
- }
-
- $pools = get_dhcppools($auDN, array("dn"));
- if (count($pools) == 0){
- $poollink = "dhcpnopool.php";
- }else{
- $poollink = "dhcppool.php";
- }
-
- $i=0;
- if ( $auDN == $rootAU ) {
- $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";
- }
- $hauptmenu []= array("link" => $dhcpsvlink,
- "text" => "DHCP Service",
- "zugriff" => array("MainAdmin","DhcpAdmin"));
- $i++;
- }
- if ($mipbs[0] != ""){
- if ( check_if_max_networks() ){
- $hauptmenu [] = array("link" => "dhcpsubnets.php?mnr=".$i,
- "text" => "DHCP Subnets",
- "zugriff" => array("MainAdmin","DhcpAdmin"));
-
- $subnets = array();
- # falls komplette Netze verfügbar, link zum Neuanlegen
- if ( check_if_free_networks() ){
- #$dhcpsubnet_array = get_dhcpsubnets($auDN,array("dn","cn"));
- /*for ($j=0;$j<count($dhcpsubnet_array);$j++){
- $subnets[] = array("link" => "dhcpsubnet.php?dn=".$dhcpsubnet_array[$j]['dn']."&mnr=".$i."&sbmnr=".$j,
- "text" => $dhcpsubnet_array[$j]['cn'],
- "zugriff" => array("MainAdmin","DhcpAdmin"));
- }*/
- $subnets[] = array("link" => "new_dhcpsubnet.php?mnr=".$i."&sbmnr=0",
- "text" => "Neues DHCP Subnet anlegen",
- "zugriff" => array("MainAdmin","DhcpAdmin"));
- }
- $i++;
- $hauptmenu [] = array("link" => $poollink."?mnr=".$i,
- "text" => "Dynamische DHCP Pools",
- "zugriff" => array("MainAdmin","DhcpAdmin"));
-
- $submenu = array(#array(),
- $subnets,
- array());
- }else{
- $hauptmenu [] = array("link" => $poollink."?mnr=".$i,
- "text" => "Dynamische DHCP Pools",
- "zugriff" => array("MainAdmin","DhcpAdmin"));
- }
- }
-
- # 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="";}
- else {$zwisch="";}
- $lastaktive=true;
- $farb="#505050";
- }
- else{
- if($maxsub == 1){$zwisch="";}
- else {$zwisch="";}
- $farb="#A0A0A0";
- $lastaktive=false;
- }
- }
- else {
- if ($sbmnr==$j) {
- if($maxsub == $j+1){$zwisch="";}
- else {$zwisch="";}
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $farb="#A0A0A0";
- if($maxsub == $j+1){$zwisch="";}
- else {$zwisch="";}
- # if ($lastaktive) {$zwisch="branch";}
- # else {$zwisch="branch";}
- $lastaktive=false;
- }
- }
- $htmlcode= "
- <tr height='4'>
- <td></td><td></td><td></td><td></td>
- </tr>
- <tr>
- <td width='8%'>&nbsp;</td>
- <td width='8%' align='right'>".$zwisch."</td>
- <td width='74%' align='left' style='border-width:1 1 1 1;border-color:#000000;border-style:solid;padding:2;padding-left:15px;background-color:{FARBE_S}'>
- <a href='".$item2['link']."' style='text-decoration:none'><code class='submenue_schrift'>".$item2['text']."</code></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
deleted file mode 100644
index a80c77d7..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcp_start.dwt
+++ /dev/null
@@ -1,32 +0,0 @@
-<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>Modul zur Verwaltung von DHCP Subnets, dynamischen Pools und Classes <br>
- Benutzen Sie die Navigation links, um die einzelnen Verwaltungsbereiche anzusteuern:</p>
- <ul>
- <li><p><b>DHCP Subnets</b><br>
- Verwalten Sie ihre Subnetze ... </p>
- </li>
- <li><p><b>DHCP Pools</b><br>
- Weisen Sie ihren DHCP Subnets IP Ranges zur dynamischen Adressvergabe zu ... </p>
- </li>
- <li><p><b>DHCP Classes</b><br>
- Verwalten Sie Klassen von DHCP Objekten ...</p>
- </li>
- </ul>
-
- <br>
- <p>Die Verwaltung von DHCP Hosts, etwa das Eintragen ihrer Rechner im zentralen DHCP Dienst, erfolgt &uuml;ber das<br>
- Modul <a class='headerlink' href='../computers/computers.php' >Rechner Management</a>.
-
- </p>
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcpnopool.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcpnopool.dwt
deleted file mode 100644
index 63047a9a..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpnopool.dwt
+++ /dev/null
@@ -1,53 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Dynamische DHCP Pools </h3></td>
- </tr>
-
- <tr>
- <td>Noch keine dynamischen DHCP Pools angelegt</td>
- </tr>
-
- <tr>
- <td height='30'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Dynamischen DHCP Pool hinzuf&uuml;gen </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='dhcppool_add.php' method='post'>
-
- <tr valign='bottom'>
- <td width='50%' class='tab_h'><b>IP Range (innerhalb eines Subnetzes)</b><br>
- weitere Ranges k&ouml;nnen sp&auml;ter hinzugef&uuml;gt werden</td>
- <td width='50%' class='tab_h'><b>Unknown Clients</b></td>
- </tr>
-
- <tr height='50' valign='top'>
- <td class='tab_d'>
- <input type='Text' name='addrange1' value='' size='15' maxlength='15' class='medium_form_field'>
- &nbsp;&nbsp; - &nbsp;&nbsp;
- <input type='Text' name='addrange2' value='' size='15' maxlength='15' class='medium_form_field'>
- </td>
- <td class='tab_d'>
- <select name='unknownclients' size='3' class='small_form_selectbox'>
- <option selected value='deny'> DENY </option>
- <option value='allow'> ALLOW </option>
- <option value='ignore'> IGNORE </option>
- </select>
- </td>
- </tr>
- <input type='hidden' name='mnr' value='{MNR}'>
-
- </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/dhcpnopool.php b/ldap-site-mngmt/webinterface/dhcp/dhcpnopool.php
deleted file mode 100644
index fd198bc1..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpnopool.php
+++ /dev/null
@@ -1,128 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcpnopool.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 3;
-$sbmnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$template->assign(array("POOLDN" => "",
- "CN" => "",
- "SUBNETDN" => "",
- "SUBNET" => "",
- "RANGE1" => "",
- "RANGE2" => "",
- "DESCRIPTION" => "",
- "STATEMENTS" => "",
- "ALLOW" => "",
- "DENY" => "",
- "IGNORE" => "",
- "DEFAULTLEASE" => "",
- "MAXLEASE" => "",
- "MNR" => $mnr));
-/*
-# DHCP Pools Daten holen
-$attributes = array("dn","cn","dhcphlpcont","dhcprange","description","dhcpstatements","dhcpoptallow",
- "dhcpoptdefault-lease-time","dhcpoptdeny","dhcpoptignore","dhcpoptmax-lease-time",
- "dhcpoptgeneric");
-$pools = get_dhcppools($auDN, $attributes);
-#print_r($pools);
-
-$template->define_dynamic("Dhcppools", "Webseite");
-$template->define_dynamic("Dhcpranges", "Webseite");
-
-# Für jeden Pool ...
-foreach ($pools as $pool){
-
- # DHCP Subnet des Pools
- $subnet = ldap_explode_dn($pool['dhcphlpcont'],1);
- $subnetdnexp = ldap_explode_dn( $pool['dhcphlpcont'], 0);
- $subnetauexp = array_slice($subnetdnexp, 3);
- $subnetau = implode(',',$subnetauexp);
-
-
- $template->clear_parse("DHCPRANGES_LIST");
-
- # DHCP Ranges
- if (count($pool['dhcprange']) != 0){
- #$template->define_dynamic("Dhcpranges", "Webseite");
- if (count($pool['dhcprange']) > 1){
- foreach ($pool['dhcprange'] as $dhcprange){
- $iprange = explode('_',$dhcprange);
- $template->assign(array(
- "RANGE1" => $iprange[0],
- "RANGE2" => $iprange[1],
- "RPOOLDN" => $pool['dn']));
- $template->parse("DHCPRANGES_LIST", ".Dhcpranges");
- $template->clear_dynamic("Dhcpranges");
- }
- }else{
- $iprange = explode('_',$pool['dhcprange']);
- $template->assign(array(
- "RANGE1" => $iprange[0],
- "RANGE2" => $iprange[1],
- "RPOOLDN" => $pool['dn']));
- $template->parse("DHCPRANGES_LIST", ".Dhcpranges");
- $template->clear_dynamic("Dhcpranges");
- }
- }
-
- # Unknown-Clients
- if ($pool['dhcpoptallow'] == "unknown-clients"){
- $unknownclients = "allow";
- $ucselectbox = "<option selected value='allow'> ALLOW </option>
- <option value='deny'> DENY </option>
- <option value='ignore'> IGNORE </option>";
- }
- elseif ($pool['dhcpoptignore'] == "unknown-clients") {
- $unknownclients = "ignore";
- $ucselectbox = "<option selected value='ignore'> IGNORE </option>
- <option value='allow'> ALLOW </option>
- <option value='deny'> DENY </option>";
- }
- else{
- $unknownclients = "deny";
- $ucselectbox = "<option selected value='deny'> DENY </option>
- <option value='allow'> ALLOW </option>
- <option value='ignore'> IGNORE </option>";
- }
-
- $template->assign(array("POOLDN" => $pool['dn'],
- "CN" => $pool['cn'],
- "SUBNETDN" => $pool['dhcphlpcont'],
- "SUBNET" => $subnet[0],
- "SUBNETAU" => $subnetau,
- "DESCRIPTION" => $pool['description'],
- "STATEMENTS" => $pool['dhcpstatements'],
- "UCSELECT" => $ucselectbox,
- "UCNOW" => $unknownclients,
- "ALLOW" => $pool['dhcpoptallow'],
- "DENY" => $pool['dhcpoptdeny'],
- "IGNORE" => $pool['dhcpoptignore'],
- "DEFAULTLEASE" => $pool['dhcpoptdefault-lease-time'],
- "MAXLEASE" => $pool['dhcpoptmax-lease-time'],
- "MNR" => $mnr));
- $template->parse("DHCPPOOLS_LIST", ".Dhcppools");
-
-}
-*/
-###################################################################################
-
-include("dhcp_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcppool.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcppool.dwt
deleted file mode 100644
index a4a1f79b..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcppool.dwt
+++ /dev/null
@@ -1,123 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td width='80%'>
- <h3>Dynamische DHCP Pools </h3>
- Administration Ihrer eingetragenen <b>dynamischen DHCP Pools</b>:<br>
- Bearbeiten von bzw. Anlegen neuer IP Ranges zur dynamischen Vergabe. Zulassen von unbekannten bzw. einschr&auml;nken auf bekannte Clients (d.h. im DHCP angelegte Clients).<br>
- Sie k&ouml;nnen IP Ranges nur entsprechend der Ihnen noch frei verf&uuml;baren IP Adressen definieren.<br><br>
- &Uuml;ber die <b>Eingabemaske</b> unten k&ouml;nnen Sie weitere Pools anlegen
- </td>
- <td>&nbsp;</td>
- </tr>
-
- <tr><td colspan='2'>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='dhcppools_change.php' method='post'>
-
- <tr>
- <td width='30%' class='tab_h'><b>Subnetz</b></td>
- <td width='50%' class='tab_h'><b>IP Ranges (innerhalb Subnetz)</b></td>
- <td width='20%' class='tab_h'><b>Unknown Clients</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Dhcppools -->
-
- <tr height='50' valign='top'>
- <td class='tab_d_ohne'><b>{SUBNET}/24</b><br><br>
- <input type='checkbox' name='delpool[]' value='{POOLDN}' size='10' class='medium_form_field'>
- Pool l&ouml;schen</td>
-
- <td class='tab_d_ohne'>
-
- <!-- BEGIN DYNAMIC BLOCK: Dhcpranges -->
-
- <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}'><br>
- <input type='hidden' name='rangepooldn[]' value='{RPOOLDN}'>
-
- <!-- END DYNAMIC BLOCK: Dhcpranges -->
-
- <input type='Text' name='addrange1[]' value='' size='15' maxlength='15' class='medium_form_field'>
- &nbsp;&nbsp; - &nbsp;&nbsp;
- <input type='Text' name='addrange2[]' value='' size='15' maxlength='15' class='medium_form_field'>
- </td>
-
- <td class='tab_d_ohne'>
- <select name='unknownclients[]' size='3' class='100_form_selectbox'>
- {UCSELECT}
- </select>
- <input type='hidden' name='olduc[]' value='{UCNOW}'> &nbsp;
- </td>
- </tr>
- <tr height='50' valign='top'>
- <td class='tab_d'><b>Remote Boot Service:</b><br>{RBS}</td>
- <td class='tab_d' colspan='2'>{RBSSELECT}</td>
- </tr>
-
- <input type='hidden' name='pooldn[]' value='{POOLDN}'>
- <input type='hidden' name='oldrbs[]' value='{OLDRBS}'>
- <input type='hidden' name='subnet[]' value='{SUBNET}'>
- <input type='hidden' name='subnetau[]' value='{SUBNETAU}'>
-
- <!-- END DYNAMIC BLOCK: Dhcppools -->
-
- <input type='hidden' name='mnr' value='{MNR}'>
-
- </table></td>
- </tr>
- <tr>
- <td colspan='2'><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
- <tr>
- <td height='50' colspan='2'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Dynamischen DHCP Pool hinzuf&uuml;gen </h4></td>
- </tr>
-
- <tr>
- <td colspan='2'>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <form action='dhcppool_add.php' method='post'>
-
- <tr valign='bottom'>
- <td width='50%' class='tab_h'><b>IP Range (innerhalb eines Subnetzes)</b><br>
- weitere Ranges k&ouml;nnen sp&auml;ter hinzugef&uuml;gt werden</td>
- <td width='20%' class='tab_h'><b>Unknown Clients</b></td>
- <td width='30%' class='tab_h'><b>Remote Boot Service</b></td>
- </tr>
-
- <tr height='50' valign='top'>
- <td class='tab_d'>
- <input type='Text' name='addrange1' value='' size='15' maxlength='15' class='medium_form_field'>
- &nbsp;&nbsp; - &nbsp;&nbsp;
- <input type='Text' name='addrange2' value='' size='15' maxlength='15' class='medium_form_field'>
- </td>
- <td class='tab_d'>
- <select name='unknownclients' size='3' class='100_form_selectbox'>
- <option selected value='deny'> DENY </option>
- <option value='allow'> ALLOW </option>
- <option value='ignore'> IGNORE </option>
- </select>
- </td>
- <td class='tab_d'>{RBSADD}
- </td>
- </tr>
- <input type='hidden' name='mnr' value='{MNR}'>
-
- </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/dhcppool.php b/ldap-site-mngmt/webinterface/dhcp/dhcppool.php
deleted file mode 100644
index aa58201f..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcppool.php
+++ /dev/null
@@ -1,166 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcppool.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 3;
-$sbmnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-# DHCP Pools Daten holen
-$attributes = array("dn","cn","dhcphlpcont","dhcprange","description","dhcpstatements","dhcpoptallow",
- "dhcpoptdefault-lease-time","dhcpoptdeny","dhcpoptignore","dhcpoptmax-lease-time",
- "dhcpoptgeneric","hlprbservice","dhcpoptfilename","dhcpoptnext-server");
-$pools = get_dhcppools($auDN, $attributes);
-
-if (count($pools) == 0){
- redirect(0, "dhcpnopool.php?mnr=".$mnr, "", $addSessionId = TRUE);
- die;
-}
-
-$template->assign(array("POOLDN" => "",
- "CN" => "",
- "SUBNETDN" => "",
- "SUBNET" => "",
- "RANGE1" => "",
- "RANGE2" => "",
- "DESCRIPTION" => "",
- "STATEMENTS" => "",
- "ALLOW" => "",
- "DENY" => "",
- "IGNORE" => "",
- "RBS" => "",
- "RBSSELECT" => "",
- "DEFAULTLEASE" => "",
- "MAXLEASE" => "",
- "MNR" => $mnr));
-
-
-$template->define_dynamic("Dhcppools", "Webseite");
-$template->define_dynamic("Dhcpranges", "Webseite");
-
-# Für jeden Pool ...
-foreach ($pools as $pool){
-
- # DHCP Subnet des Pools
- $subnet = ldap_explode_dn($pool['dhcphlpcont'],1);
- $subnetdnexp = ldap_explode_dn( $pool['dhcphlpcont'], 0);
- $subnetauexp = array_slice($subnetdnexp, 3);
- $subnetau = implode(',',$subnetauexp);
- $rbsDN = $pool['hlprbservice'];
-
-
- $template->clear_parse("DHCPRANGES_LIST");
-
- # DHCP Ranges
- if (count($pool['dhcprange']) != 0){
- #$template->define_dynamic("Dhcpranges", "Webseite");
- if (count($pool['dhcprange']) > 1){
- foreach ($pool['dhcprange'] as $dhcprange){
- $iprange = explode('_',$dhcprange);
- $template->assign(array(
- "RANGE1" => $iprange[0],
- "RANGE2" => $iprange[1],
- "RPOOLDN" => $pool['dn']));
- $template->parse("DHCPRANGES_LIST", ".Dhcpranges");
- $template->clear_dynamic("Dhcpranges");
- }
- }else{
- $iprange = explode('_',$pool['dhcprange']);
- $template->assign(array(
- "RANGE1" => $iprange[0],
- "RANGE2" => $iprange[1],
- "RPOOLDN" => $pool['dn']));
- $template->parse("DHCPRANGES_LIST", ".Dhcpranges");
- $template->clear_dynamic("Dhcpranges");
- }
- }
-
- # Unknown-Clients
- if ($pool['dhcpoptallow'] == "unknown-clients"){
- $unknownclients = "allow";
- $ucselectbox = "<option selected value='allow'> ALLOW </option>
- <option value='deny'> DENY </option>
- <option value='ignore'> IGNORE </option>";
- }
- elseif ($pool['dhcpoptignore'] == "unknown-clients") {
- $unknownclients = "ignore";
- $ucselectbox = "<option selected value='ignore'> IGNORE </option>
- <option value='allow'> ALLOW </option>
- <option value='deny'> DENY </option>";
- }
- else{
- $unknownclients = "deny";
- $ucselectbox = "<option selected value='deny'> DENY </option>
- <option value='allow'> ALLOW </option>
- <option value='ignore'> IGNORE </option>";
- }
-
- # RBS Setup
- $rbs_selectbox = "";
- $rbs_addselectbox = "";
- $altrbs = alternative_rbservices($rbsDN);
-
- $rbs_selectbox .= "<select name='rbs[]' size='4' class='tftp_form_selectbox'>
- <option selected value='none'>----------</option>";
- $rbs_addselectbox = "<select name='rbs' size='3' class='tftp_form_selectbox'>
- <option selected value='none'>----------</option>";
- if (count($altrbs) != 0){
- foreach ($altrbs as $item){
- $rbs_selectbox .= "<option value='".$item['dn']."'>".$item['cn']." ".$item['au']."</option>";
- $rbs_addselectbox .= "<option value='".$item['dn']."'>".$item['cn']." ".$item['au']."</option>";
- }
- }
- $rbs_selectbox .= "<option value=''>Kein RBS</option></select>";
- $rbs_addselectbox .= "</select>";
-
- if ($rbsDN == ""){
- $rbs = "Keine Einbindung";
- }else{
- $rbsdnexp = ldap_explode_dn($pool['hlprbservice'],1);
- $rbs = $rbsdnexp[0]."<br>DHCP Next-Server: ".$pool['dhcpoptnext-server']."<br>DHCP Filename: ".$pool['dhcpoptfilename'];
- }
-
-
- $template->assign(array("POOLDN" => $pool['dn'],
- "CN" => $pool['cn'],
- "SUBNETDN" => $pool['dhcphlpcont'],
- "SUBNET" => $subnet[0],
- "SUBNETAU" => $subnetau,
- "DESCRIPTION" => $pool['description'],
- "STATEMENTS" => $pool['dhcpstatements'],
- "UCSELECT" => $ucselectbox,
- "UCNOW" => $unknownclients,
- "ALLOW" => $pool['dhcpoptallow'],
- "DENY" => $pool['dhcpoptdeny'],
- "IGNORE" => $pool['dhcpoptignore'],
- "RBS" => $rbs,
- "RBSSELECT" => $rbs_selectbox,
- "RBSADD" => $rbs_addselectbox,
- "OLDRBS" => $rbsDN,
- "DEFAULTLEASE" => $pool['dhcpoptdefault-lease-time'],
- "MAXLEASE" => $pool['dhcpoptmax-lease-time'],
- "MNR" => $mnr));
- $template->parse("DHCPPOOLS_LIST", ".Dhcppools");
-
-}
-
-###################################################################################
-
-include("dhcp_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcppool_add.php b/ldap-site-mngmt/webinterface/dhcp/dhcppool_add.php
deleted file mode 100644
index bddb8282..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcppool_add.php
+++ /dev/null
@@ -1,106 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$syntax = new Syntaxcheck;
-
-$range1 = $_POST['addrange1'];
-$range2 = $_POST['addrange2'];
-$unknownclients = $_POST['unknownclients'];
-$rbs = $_POST['rbs'];
-
-$mnr = $_POST['mnr'];
-
-$seconds = 2;
-$url = "dhcppool.php?mnr=".$mnr;
-
-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 ($syntax->check_ip_syntax($range1) && $syntax->check_ip_syntax($range2)){
-
- $fs = explode('.',$range1);
- $fe = explode('.',$range2);
- if ( $fs[0] == $fe[0] && $fs[1] == $fe[1] && $fs[2] == $fe[2] ) {
- if ( $fs[3] <= $fe[3] ){
-
- # DHCP Subnet DN finden
- $subnet = implode(".", array($fs[0],$fs[1],$fs[2],"0"));
- print_r($subnet);echo"<br><br>";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=dhcpSubnet)(cn=$subnet))", array("dn","dhcphlpcont"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result);echo "<br><br>";
- if (count($result[0]) != 0){
-
- $subnetdn = $result[0]['dn'];
- $subnetdnexp = ldap_explode_dn( $subnetdn, 0);
- $subnetauexp = array_slice($subnetdnexp, 3);
- $subnetau = implode(',',$subnetauexp);
-
- # Range zusammenstellen
- $range = implode("_", array($range1,$range2));
-
- # Freie IP Bereiche testen
- $fipb_array = get_freeipblocks_au($auDN);
- for ($i=0; $i < count($fipb_array); $i++){
- if ( split_iprange($range,$fipb_array[$i]) != 0 ){
- $ipranges = split_iprange($range,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- break;
- }
- }
- if ($i < count($fipb_array) ){
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- echo "<br>Neue FIPBs erfolgreich eingetragen!<br>";
- $result = add_dhcppool($subnetdn,$range,$unknownclients,$result[0]['dhcphlpcont'],$rbs);
- if ($result){
- echo "<br>Dynamischer DHCP Pool erfolgreich eingetragen!<br>" ;
- update_dhcpmtime(array($subnetau));
- }else{
- echo "<br>Fehler beim eintragen des dynamischen DHCP Pools!<br>";
- # Range wieder in FIPBs aufnehmen.
- $entry2 ['FreeIPBlock'] = $range;
- ldap_mod_add($ds,$auDN,$entry2);
- merge_ipranges($auDN);
- }
- }else{
- echo "<br>Fehler beim eintragen der FIPBs!<br>";
- }
- }else{
- printf("<br>IP Range %s ist nicht im verfuegbaren Bereich!<br>", $range );
- }
- }else{
- echo "DHCP Subnet nicht im System vorhanden!<br>";
- }
- }else{
- echo "erster Range Wert gr&ouml;sser als zweiter Range Wert<br>";
- }
- }else{
- echo "Range nicht im gleichen Subnetz<br>";
- }
-}else{
- echo "falsche IP Syntax<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/dhcppool_new.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcppool_new.dwt
deleted file mode 100644
index 8c9aefdc..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcppool_new.dwt
+++ /dev/null
@@ -1,49 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Dynamische DHCP Pools </h3></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Poolform -->
- {POOLFORMULAR}
- <!-- END DYNAMIC BLOCK: Poolform -->
-
- <tr>
- <td colspan='2'><h4>Dynamischen DHCP Pool hinzuf&uuml;gen </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='dhcppool_add.php' method='post'>
-
- <tr valign='bottom'>
- <td width='50%' class='tab_h'><b>IP Range (innerhalb eines Subnetzes)</b><br>
- weitere Ranges k&ouml;nnen sp&auml;ter hinzugef&uuml;gt werden</td>
- <td width='50%' class='tab_h'><b>Unknown Clients</b></td>
- </tr>
-
- <tr height='50' valign='top'>
- <td class='tab_d'>
- <input type='Text' name='addrange1' value='' size='15' maxlength='15' class='medium_form_field'>
- &nbsp;&nbsp; - &nbsp;&nbsp;
- <input type='Text' name='addrange2' value='' size='15' maxlength='15' class='medium_form_field'>
- </td>
- <td class='tab_d'>
- <select name='unknownclients' size='3' class='small_form_selectbox'>
- <option selected value='deny'> DENY </option>
- <option value='allow'> ALLOW </option>
- <option value='ignore'> IGNORE </option>
- </select>
- </td>
- </tr>
- <input type='hidden' name='mnr' value='{MNR}'>
-
- </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/dhcppool_new.php b/ldap-site-mngmt/webinterface/dhcp/dhcppool_new.php
deleted file mode 100644
index 74592459..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcppool_new.php
+++ /dev/null
@@ -1,201 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcppool.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 3;
-$sbmnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$template->define_dynamic("Poolform", "Webseite");
-$template->assign(array("POOLFORMULAR" => "",
- #"POOLDN" => "",
- "CN" => "",
- "SUBNETDN" => "",
- #"SUBNET" => "",
- #"RANGE1" => "",
- #"RANGE2" => "",
- "DESCRIPTION" => "",
- "STATEMENTS" => "",
- "DEFAULTLEASE" => "",
- "MAXLEASE" => "",
- "MNR" => $mnr));
-
-# DHCP Pools Daten holen
-$attributes = array("dn","cn","dhcphlpcont","dhcprange","description","dhcpstatements","dhcpoptallow",
- "dhcpoptdefault-lease-time","dhcpoptdeny","dhcpoptignore","dhcpoptmax-lease-time",
- "dhcpoptgeneric");
-$pools = get_dhcppools($auDN, $attributes);
-#print_r($pools);
-
-if (count($pools) != 0){
-
-
-
-$poolform = "
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='dhcppools_change.php' method='post'>
-
- <tr>
- <td width='30%' class='tab_h'><b>Subnetz</b></td>
- <td width='50%' class='tab_h'><b>IP Ranges (innerhalb Subnetz)</b></td>
- <td width='20%' class='tab_h'><b>Unknown Clients</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Dhcppools -->
-
- <tr height='50' valign='top'>
- <td class='tab_d'><b>{SUBNET}/24</b><br><br>
- <input type='checkbox' name='delpool[]' value='{POOLDN}' size='10' class='medium_form_field'>
- Pool l&ouml;schen (H&auml;kchen setzen)</td>
-
- <td class='tab_d'>
-
- <!-- BEGIN DYNAMIC BLOCK: Dhcpranges -->
-
- <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}'><br>
- <input type='hidden' name='rangepooldn[]' value='{RPOOLDN}'>
-
- <!-- END DYNAMIC BLOCK: Dhcpranges -->
-
- <input type='Text' name='addrange1[]' value='' size='15' maxlength='15' class='medium_form_field'>
- &nbsp;&nbsp; - &nbsp;&nbsp;
- <input type='Text' name='addrange2[]' value='' size='15' maxlength='15' class='medium_form_field'>
- </td>
-
- <td class='tab_d'>
- <select name='unknownclients[]' size='3' class='small_form_selectbox'>
- {UCSELECT}
- </select>
- <input type='hidden' name='olduc[]' value='{UCNOW}'> &nbsp;
- </td>
- </tr>
- <!--<tr>
- <td colspan='3' class='tab_d'><input type='checkbox' name='delpool[]' value='{POOLDN}' size='10' class='medium_form_field'>
- Pool l&ouml;schen (H&auml;kchen setzen)</td>
- </tr>-->
-
- <input type='hidden' name='pooldn[]' value='{POOLDN}'>
- <input type='hidden' name='subnet[]' value='{SUBNET}'>
- <input type='hidden' name='subnetau[]' value='{SUBNETAU}'>
-
- <!-- END DYNAMIC BLOCK: Dhcppools -->
-
- <input type='hidden' name='mnr' value='{MNR}'>
-
- </table></td>
- </tr>
- <tr>
- <td><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
- <tr>
- <td height='50'></td>
- </tr>";
-
-$template->assign(array("POOLFORMULAR" => $poolform));
-$template->parse("POOLFORM_LIST", "Poolform");
-#$template->clear_dynamic("Poolform");
-#$template->clear_parse("POOLFORM_LIST");
-
-$template->define_dynamic("Dhcppools", "Webseite");
-$template->define_dynamic("Dhcpranges", "Webseite");
-# Für jeden Pool ...
-foreach ($pools as $pool){
-
- # DHCP Subnet des Pools
- $subnet = ldap_explode_dn($pool['dhcphlpcont'],1);
- $subnetdnexp = ldap_explode_dn( $pool['dhcphlpcont'], 0);
- $subnetauexp = array_slice($subnetdnexp, 3);
- $subnetau = implode(',',$subnetauexp);
-
-
- $template->clear_parse("DHCPRANGES_LIST");
-
- # DHCP Ranges
- if (count($pool['dhcprange']) != 0){
- #$template->define_dynamic("Dhcpranges", "Webseite");
- if (count($pool['dhcprange']) > 1){
- foreach ($pool['dhcprange'] as $dhcprange){
- $iprange = explode('_',$dhcprange);
- $template->assign(array(
- "RANGE1" => $iprange[0],
- "RANGE2" => $iprange[1],
- "RPOOLDN" => $pool['dn']));
- $template->parse("DHCPRANGES_LIST", ".Dhcpranges");
- $template->clear_dynamic("Dhcpranges");
- }
- }else{
- $iprange = explode('_',$pool['dhcprange']);
- $template->assign(array(
- "RANGE1" => $iprange[0],
- "RANGE2" => $iprange[1],
- "RPOOLDN" => $pool['dn']));
- $template->parse("DHCPRANGES_LIST", ".Dhcpranges");
- $template->clear_dynamic("Dhcpranges");
- }
- }
-
- # Unknown-Clients
- if ($pool['dhcpoptallow'] == "unknown-clients"){
- $unknownclients = "allow";
- $ucselectbox = "<option selected value='allow'> ALLOW </option>
- <option value='deny'> DENY </option>
- <option value='ignore'> IGNORE </option>";
- }
- elseif ($pool['dhcpoptignore'] == "unknown-clients") {
- $unknownclients = "ignore";
- $ucselectbox = "<option selected value='ignore'> IGNORE </option>
- <option value='allow'> ALLOW </option>
- <option value='deny'> DENY </option>";
- }
- else{
- $unknownclients = "deny";
- $ucselectbox = "<option selected value='deny'> DENY </option>
- <option value='allow'> ALLOW </option>
- <option value='ignore'> IGNORE </option>";
- }
-
- $template->assign(array("POOLDN" => $pool['dn'],
- "CN" => $pool['cn'],
- "SUBNETDN" => $pool['dhcphlpcont'],
- "SUBNET" => $subnet[0],
- "SUBNETAU" => $subnetau,
- "DESCRIPTION" => $pool['description'],
- "STATEMENTS" => $pool['dhcpstatements'],
- "UCSELECT" => $ucselectbox,
- "UCNOW" => $unknownclients,
- "DEFAULTLEASE" => $pool['dhcpoptdefault-lease-time'],
- "MAXLEASE" => $pool['dhcpoptmax-lease-time'],
- "MNR" => $mnr));
- $template->parse("DHCPPOOLS_LIST", ".Dhcppools");
-
-}
-}
-
-###################################################################################
-
-include("dhcp_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dhcp/dhcppools_change.php b/ldap-site-mngmt/webinterface/dhcp/dhcppools_change.php
deleted file mode 100644
index 1a62cfed..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcppools_change.php
+++ /dev/null
@@ -1,336 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$syntax = new Syntaxcheck;
-
-$pooldn = $_POST['pooldn'];
-$subnet = $_POST['subnet'];
-$subnetau = $_POST['subnetau'];
-$delpool = $_POST['delpool'];
-$poolranges = array();
-foreach ($pooldn as $dn){
- $poolranges [$dn] = get_dhcppoolranges($dn);
-}
-$range1 = $_POST['range1'];
-$range2 = $_POST['range2'];
-$oldrange1 = $_POST['oldrange1'];
-$oldrange2 = $_POST['oldrange2'];
-$rangepooldn = $_POST['rangepooldn'];
-$addrange1 = $_POST['addrange1'];
-$addrange2 = $_POST['addrange2'];
-$uc = $_POST['unknownclients'];
-$olduc = $_POST['olduc'];
-$rbs = $_POST['rbs'];
-$oldrbs = $_POST['oldrbs'];
-
-# Array to fill with AUs to update dhcpMTime
-$au_to_update = array();
-
-$mnr = $_POST['mnr'];
-
-#print_r($pooldn); echo "<br>";
-#print_r($subnet); echo "<br>";
-#print_r($subnetau); echo "<br>";
-#print_r($delpool); echo "<br><br>";
-#print_r($oldrange1); echo "<br>";
-#print_r($oldrange2); echo "<br>";
-#print_r($range1); echo "<br>";
-#print_r($range2); echo "<br>";
-#print_r($rangepooldn); echo "<br><br>";
-#print_r($addrange1); echo "<br>";
-#print_r($addrange2); echo "<br><br>";
-#print_r($olduc); echo "<br><br>";
-#print_r($uc); echo "<br><br>";
-
-$seconds = 2;
-$url = "dhcppool.php?mnr=".$mnr;
-
-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>";
-
-#########################################################################################
-# Pools löschen, entsprechende Arrays ($pooldn, $uc, ...) zur weiteren Verarbeitung anpassen
-for ($i=0;$i<count($delpool);$i++){
-
- $key = array_keys ( $pooldn, $delpool[$i] );
- $key_r = array_keys ( $rangepooldn, $delpool[$i] );
-
- # Ranges wieder in FIPBs aufnehmen
- if (count($key_r) > 1){
- foreach ($key_r as $item){
- $modentry['FreeIPBlock'][] = $oldrange1[$item]."_".$oldrange2[$item];
- }
- }else{
- $modentry['FreeIPBlock'] = $oldrange1[$key_r[0]]."_".$oldrange2[$key_r[0]];
- }
- print_r($modentry); echo "<br><br>";
- $add_fipb = ldap_mod_add($ds,$auDN,$modentry);
- if ($add_fipb){
- echo "<br>geloeschte IP Range(s) erfolgreich als neuer FIPB in die AU eingetragen!<br>" ;
- merge_ipranges($auDN);
-
- $delete = ldap_delete($ds,$delpool[$i]);
- if ($delete){
- # Subnet-AU auf DHCP-Modify setzen
- $au_to_update [] = $subnetau[$i];
- # Arrays von gelöschten Pools für weitere Verarbeitung bereinigen
- foreach ( $key as $nr ){
- array_splice ( &$pooldn, $nr, 1 );
- array_splice ( &$addrange1, $nr, 1 );
- array_splice ( &$addrange2, $nr, 1 );
- array_splice ( &$uc, $nr, 1 );
- array_splice ( &$olduc, $nr, 1 );
- array_splice ( &$rbs, $nr, 1 );
- array_splice ( &$oldrbs, $nr, 1 );
- }
- # da sich Arrays verkleinern, Wert in $key_r entsprechend verkleinern,
- $j=0; # Variable $j als Zähler um wieviel
- foreach ( $key_r as $nr ){
- array_splice ( &$rangepooldn, $nr-$j, 1 );
- array_splice ( &$range1, $nr-$j, 1 );
- array_splice ( &$range2, $nr-$j, 1 );
- array_splice ( &$oldrange1, $nr-$j, 1 );
- array_splice ( &$oldrange2, $nr-$j, 1 );
- $j++;
- }
- printf("Pool <b>%s</b> erfolgreich gel&ouml;scht<br>", $delpool[$i]);
- }else{
- printf("Fehler beim L&ouml;schen des Pools <b>%s</b>", $delpool[$i]);
- }
- }else{
- echo "<br>Fehler beim eintragen der geloeschten IP Range(s) als neuen FIPB! <br>DHCP Pool nicht gel&ouml;scht<br>";
- }
-}
-
-#########################################################################################
-# Änderungen in bestehenden Pools (unknown-clients) und Ranges hinzufügen
-for ($i=0;$i<count($pooldn);$i++){
-
- $entrydel = array();
- $entryadd = array();
- $entryrbs = array();
- # DENY, ALLOW, IGNORE Unknown-clients verarbeiten
- if ( $uc[$i] != $olduc[$i] ){
- $dhcpoptdel = "dhcpopt".$olduc[$i];
- $entrydel [$dhcpoptdel] = array();
- #print_r($entrydel); echo "<br>";
- ldap_mod_del($ds,$pooldn[$i],$entrydel);
- $dhcpoptadd = "dhcpopt".$uc[$i];
- $entryadd [$dhcpoptadd] = "unknown-clients";
- #print_r($entryadd); echo "<br><br>";
- ldap_mod_add($ds,$pooldn[$i],$entryadd);
- printf("Pool %s:<br>DHCP Option <b>unknown-clients</b> von <b>%s</b> auf <b>%s</b> ge&auml;ndert<br><br>",$pooldn[$i],$olduc[$i],$uc[$i]);
- # Subnet-AU auf DHCP-Modify setzen
- $au_to_update [] = $subnetau[$i];
- }
- # RBS
- if ( $rbs[$i] != "none" && $rbs[$i] != $oldrbs[$i] ){
- $dhcpdata = get_node_data($rbs[$i],array("tftpserverip","initbootfile"));
- $entryrbs ['hlprbservice'] = $rbs[$i];
- $entryrbs ['dhcpoptnext-server'] = $dhcpdata['tftpserverip'];
- $entryrbs ['dhcpoptfilename'] = $dhcpdata['initbootfile'];
- if ( $oldrbs[$i] == "" ){
- echo "RBS add "; print_r($entryrbs); echo "<br>";
- if ($result = ldap_mod_add($ds,$pooldn[$i],$entryrbs)){
- echo "DHCP Pool erfolgreich in RBS eingebunden.<br>";
- }
- }elseif ( $rbs[$i] == "" ){
- $entryrbs ['hlprbservice'] = array();
- $entryrbs ['dhcpoptnext-server'] = array();
- $entryrbs ['dhcpoptfilename'] = array();
- echo "RBS delete "; echo "<br>";
- if ($result = ldap_mod_del($ds,$pooldn[$i],$entryrbs)){
- echo "DHCP Pool erfolgreich aus RBS gel&ouml;scht.<br>";
- }
- }else{
- echo "RBS replace "; print_r($oldrbs[$i]); echo " with "; print_r($entryrbs); echo "<br>";
- if ($result = ldap_mod_replace($ds,$pooldn[$i],$entryrbs)){
- echo "DHCP Pool RBS Einbindung erfolgreich ge&auml;ndert.<br>";
- }
- }
- }
-
- # Ranges hinzufügen
- if ( $addrange1[$i] != "" && $addrange2[$i] != "" ){
- if ($syntax->check_ip_syntax($addrange1[$i]) && $syntax->check_ip_syntax($addrange2[$i])){
- $net = strrev(strchr(strrev($subnet[$i]), "."));
- $add1 = strrev(strchr(strrev($addrange1[$i]), "."));
- $add2 = strrev(strchr(strrev($addrange2[$i]), "."));
- if ( $net == $add1 && $net == $add2 ){
-
- printf("Range in Pool %s hinzuf&uuml;gen<br>",$pooldn[$i]);
- # Range zusammenstellen
- $newrange = implode("_", array($addrange1[$i],$addrange2[$i]));
- $result = add_dhcprange($newrange,$pooldn[$i]);
- if ($result){
- # Subnet-AU auf DHCP-Modify setzen
- $au_to_update [] = $subnetau[$i];
- printf("Neue dynamische IP Range %s - %s erfolgreich in Subnetz %s0 eingetragen!<br>",$addrange1[$i],$addrange2[$i],$net);
- }else{
- echo "<br>Fehler beim eintragen des dynamischen DHCP Pools!<br>";
- }
-
- }else{
- printf("Neue Range %s - %s nicht in Subnetz %s0",$addrange1[$i],$addrange2[$i],$net);
- }
- }else{
- printf("falsche IP Syntax der neuen Range %s - %s<br>", $addrange1[$i],$addrange2[$i]);
- }
- }
-
-}
-
-#########################################################################################
-# In Pools bereits angelegte Ranges verarbeiten (löschen, verkleinern, vergrößern)
-# vorzunehmende Änderungen in Arrays ($mod_dhcpranges, $new_fibs) speichern
-$fipbs = get_freeipblocks_au($auDN);
-$new_fipbs ['freeipblock'] = $fipbs;
-$mod_dhcpranges = array();
-
-for ($i=0;$i<count($rangepooldn);$i++){
-
- $range = implode('_',array($range1[$i],$range2[$i]));
- $oldrange = implode('_',array($oldrange1[$i],$oldrange2[$i]));
-
- if ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $range1[$i] == "" && $range2[$i] == "" ){
- # Range löschen
- $mod_dhcpranges [$rangepooldn[$i]] = $poolranges [$rangepooldn[$i]];
- $range_key = array_search ( $oldrange, $mod_dhcpranges[$rangepooldn[$i]] );
- #print_r($range_key); echo "<br>";
- array_splice ( &$mod_dhcpranges[$rangepooldn[$i]], $range_key, 1 );
- array_splice ( &$poolranges[$rangepooldn[$i]], $range_key, 1 );
- $new_fipbs ['freeipblock'][] = $oldrange;
- # Subnet-AU auf DHCP-Modify setzen
- $au_to_update [] = $subnetau[$i];
- }
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $range1[$i] != "" && $range2[$i] != "" ){
- $or1 = ip2long($oldrange1[$i]);
- $or2 = ip2long($oldrange2[$i]);
- $nr1 = ip2long($range1[$i]);
- $nr2 = ip2long($range2[$i]);
-
- if ( ($nr1 > $or1 || $nr2 < $or2) && !($nr1 < $or1 || $nr2 > $or2) ){
- if ($syntax->check_ip_syntax($range1[$i]) && $syntax->check_ip_syntax($range2[$i])){
- # Range verkleinern
- $diffrange = split_iprange($range,$oldrange);
- echo "<br>diffrange: "; print_r($diffrange); echo "<br>";
- # array $poolranges aktualisieren (neue Ranges)
- $mod_dhcpranges [$rangepooldn[$i]] = $poolranges [$rangepooldn[$i]];
- $range_key = array_search ( $oldrange, $mod_dhcpranges [$rangepooldn[$i]] );
- #print_r($range_key); echo "<br>";
- $poolranges [$rangepooldn[$i]][$range_key] = $range;
- $mod_dhcpranges [$rangepooldn[$i]][$range_key] = $range;
- # Subnet-AU auf DHCP-Modify setzen
- $au_to_update [] = $subnetau[$i];
-
- foreach ($diffrange as $dr){
- $new_fipbs ['freeipblock'][] = $dr;
- }
- }else{
- printf("falsche IP Syntax der neuen Range %s - %s<br>", $range1[$i],$range2[$i]);
- }
- }
- elseif( ($nr1 < $or1 || $nr2 > $or2) && !($nr1 > $or1 || $nr2 < $or2) ){
- if ($syntax->check_ip_syntax($range1[$i]) && $syntax->check_ip_syntax($range2[$i])){
- # Range vergrößern
- $addrange = split_iprange($oldrange,$range);
- echo "addrange: "; print_r($addrange); echo "<br>";
- $mod_dhcpranges [$rangepooldn[$i]] = $poolranges [$rangepooldn[$i]];
-
- foreach ($addrange as $ar){
- $test = 0;
- for ($c=0; $c < count($new_fipbs['freeipblock']); $c++){
- if ( split_iprange($ar,$new_fipbs['freeipblock'][$c]) != 0 ){
- $ipranges = split_iprange($ar,$new_fipbs['freeipblock'][$c]);
- array_splice($new_fipbs['freeipblock'], $c, 1, $ipranges);
- $test = 1;
- break;
- }
- }
- if ( $test ){
- $poolranges [$rangepooldn[$i]][] = $ar;
- $mod_dhcpranges [$rangepooldn[$i]][] = $ar;
- # Subnet-AU auf DHCP-Modify setzen
- $au_to_update [] = $subnetau[$i];
- }
- }
- }else{
- printf("falsche IP Syntax der neuen Range %s - %s<br>", $range1[$i],$range2[$i]);
- }
- }
- #else{
- # $mesg = "<br>Verschieben (Shiften) einer IP Range nicht moeglich!<br>
- # Nur Vergroessern und Verkleinern moeglich!<br>";
- # $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- # Falls nicht, klicken Sie hier <a href='dhcppool.php' style='publink'>back</a>";
- # redirect($seconds, $url, $mesg, $addSessionId = TRUE);
- #}
- }
-}
-#print_r($mod_dhcpranges); echo "<br>";
-#print_r($new_fipbs); echo "<br><br>";
-
-#########################################################################################
-# In Arrays $dhcp_modranges und $new_fipbs gespeicherte Änderungen im LDAP schreiben
-$keys = array_keys($mod_dhcpranges);
-foreach ($keys as $pdn){
- #print_r($pdn); echo "<br>";
- #print_r($mod_dhcpranges[$pdn]); echo "<br>";
- if ( count($mod_dhcpranges[$pdn]) == 0 ){
- printf("Pool %s l&ouml;schen<br>",$pdn);
- if ($res = ldap_delete($ds,$pdn)){
- printf("Pool %s erfolgreich gel&ouml;scht",$pdn);
- }else{
- printf("Fehler beim L&ouml;schen von %s",$pdn);
- }
- }else{
- echo "Pool Ranges anpassen<br>";
- foreach ($mod_dhcpranges[$pdn] as $rg){
- $modpool ['dhcprange'][] = $rg;
- }
- #print_r($modpool); echo "<br>";
- $modpool ['dhcprange'] = merge_ipranges_array($modpool ['dhcprange']);
- print_r($modpool); echo "<br>";
- if ($res = ldap_mod_replace($ds,$pdn,$modpool)){
- printf("Pool Ranges von %s erfolgreich angepasst",$pdn);
- }else{
- printf("Fehler beim Anpassen der Pool Ranges von %s",$pdn);
- }
- }
-}
-
-$diff = array_diff( $new_fipbs['freeipblock'], $fipbs );
-$revdiff = array_diff( $fipbs, $new_fipbs['freeipblock'] );
-if ( count($diff) != 0 || count($revdiff) != 0 ){
- echo "<br>FIPBS anpassen<br>";
- #print_r($new_fipbs['freeipblock']); echo "<br>";
- $new_fipbs['freeipblock'] = merge_ipranges_array($new_fipbs['freeipblock']);
- print_r($new_fipbs); echo "<br>";
- if ($res = ldap_mod_replace($ds,$auDN,$new_fipbs)){
- printf("FIPBs erfolgreich angepasst");
- }else{
- printf("Fehler beim Anpassen der FIPBs");
- }
-}
-
-#########################################################################################
-# DHCP Modify Timestamps in betreffenden AUs aktualisieren
-#echo "<br>Subnet-AU: ";print_r ($au_to_update); echo "<br>";
-update_dhcpmtime($au_to_update);
-
-
-
-$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.dwt b/ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt
deleted file mode 100644
index eb8e99b6..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpservice.dwt
+++ /dev/null
@@ -1,262 +0,0 @@
-<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>Failover Peer Name</b><br clear="all"><br>
- Falls f&uuml;r Ihren Dienst ein Failoverpeer deklariert ist, tragen Sie seinen Namen hier ein.
- (Damit werden f&uuml;r dynamische IP Ranges entsprechende Pool Deklarationen, mit Failover Peer generiert)</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[dhcpfailoverpeer]' value='{FAILOVERPEER}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpfailoverpeer]' value='{FAILOVERPEER}'> &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='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
- <td width='70%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert(e)</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Default Lease Time:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <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='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptmax-lease-time]' value='{MAXLEASE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Use Host DCL Names:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptuse-host-decl-names]' value='{USEHOSTDCL}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptuse-host-decl-names]' value='{USEHOSTDCL}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>DHCP Max Message Size:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdhcp-max-message-size]' value='{MAXMESSIZE}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdhcp-max-message-size]' value='{MAXMESSIZE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <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='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptddns-update-style]' value='{DDNSUPDATE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Domain Name:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdomain-name]' value='{DOMAINNAME}' size='60' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdomain-name]' value='{DOMAINNAME}'>&nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Domain Name Servers:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}' size='60' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <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>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Allow:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 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>
- <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>
- <tr>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Self-definierte Optionen:</b></td>
- </tr>
- {OPTDEF}
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Option hinzuf&uuml;gen:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='adddhcpoptdefinition' value='' size='40' class='medium_form_field'>
- </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
deleted file mode 100644
index 304739ca..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpservice.php
+++ /dev/null
@@ -1,182 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcpservice.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$template->assign(array("DHCPDN" => "",
- "CN" => "",
- "PRIMARY" => "",
- "SECONDARY" => "",
- "DESCRIPTION" => "",
- "STATEMENTS" => "",
- "FAILOVERPEER" => "",
- "ALLOW" => "",
- "DENY" => "",
- "IGNORE" => "",
- "DDNSUPDATE" => "",
- "DEFAULTLEASE" => "",
- "MAXLEASE" => "",
- "USEHOSTDCL" => "",
- "DOMAINNAME" => "",
- "DOMAINNAMESERVERS" => "",
- "MAXMESSIZE" => "",
- "NTPSERVERS" => "",
- "OPTGENERIC" => "",
- "OPTDEF" => "",
- "OPTDEFINITION" => "",
- "DHCPOFFERNOWDN" => "",
- "DHCPOFFERNOW" => "",
- "SUBNET" => "keine Subnetze zugewiesen",
- "NETMASK" => "",
- "SUBNETAU" => ""));
-
-# 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","dhcpfailoverpeer",
- "dhcpoptallow","dhcpoptddns-update-style","dhcpoptdefault-lease-time","dhcpoptdeny","dhcpoptfilename",
- "dhcpoptignore","dhcpoptmax-lease-time","dhcpoptnext-server","optiondefinition",
- "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);
-
-# DHCP Service 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);
-
-$optdef = "";
-if (count($dhcpsv_data['optiondefinition']) == 1){
- $dhcpsv_data['optiondefinition'] = array($dhcpsv_data['optiondefinition']);
-}
-if (count($dhcpsv_data['optiondefinition']) > 0){
- foreach ($dhcpsv_data['optiondefinition'] as $optdefinition){
- $optdef .= "
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='dhcpoptdefinition[]' value='".$optdefinition."' size='40' class='medium_form_field'>
- <input type='hidden' name='olddhcpoptdefinition[]' value='".$optdefinition."'> &nbsp;
- </td>
- </tr>";
- }
-}
-
-$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'],
- "FAILOVERPEER" => $dhcpsv_data['dhcpfailoverpeer'],
- "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'],
- "NTPSERVERS" => $dhcpsv_data['dhcpoptntp-servers'],
- "DHCPOFFERNOWDN" => $dhcpsv_data['dhcpofferdn'],
- "DHCPOFFERNOW" => $dhcpoffernow,
- "OPTDEF" => $optdef,
- "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_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
deleted file mode 100644
index ecaa27d9..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpservice_add.php
+++ /dev/null
@@ -1,70 +0,0 @@
-<?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 = 2;
-$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
deleted file mode 100644
index 687a5bbd..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpservice_change.php
+++ /dev/null
@@ -1,229 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$cn = "DHCP_".$_POST['cn'];
-$oldcn = "DHCP_".$_POST['oldcn'];
-$dhcpoffer = $_POST['dhcpoffer'];
-$olddhcpoffer = $_POST['olddhcpoffer'];
-$dhcpoptdefinition = $_POST['dhcpoptdefinition'];
-$olddhcpoptdefinition = $_POST['olddhcpoptdefinition'];
-$adddhcpoptdefinition = $_POST['adddhcpoptdefinition'];
-
-$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 = 2;
-$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) || ($dhcpoffer == "off" && $olddhcpoffer == "") ){
- $mesg = "Sie haben die gleiche Abteilung ausgew&auml;hlt<br>
- Keine &Auml;nderung!";
- }
-
- if ( $dhcpoffer != "off" && $dhcpoffer != $olddhcpoffer ){
- $entryoffer ['dhcpofferdn'] = $dhcpoffer;
- if ($olddhcpoffer == ""){
- # Offer anlegen
- if(ldap_mod_add($ds,$dhcpDN,$entryoffer)){
- $mesg = "DHCP Service Offer erfolgreich angelegt<br><br>";
- }
- else{
- $mesg = "Fehler beim &auml;ndern des DHCP Service Offers!<br><br>";
- }
- }
- else{
- # Offer ändern
- 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 gel&ouml;scht<br><br>";
- cleanup_del_dhcpservice ($dhcpDN);
- }
- else{
- $mesg = "Fehler beim &auml;ndern des DHCP Service Offers!<br><br>";
- }
- }
-
-}
-
-#####################################
-# Selbstdefinierte Optionen
-
-if ( $adddhcpoptdefinition != "" ){
- echo "Selbst-definierte DHCP Option hinzuf&uuml;gen.<br>";
- $entryadd['optiondefinition'] = $adddhcpoptdefinition;
- if(ldap_mod_add($ds,$dhcpDN,$entryadd)){
- $mesg = "Selbst-definierte DHCP Option erfolgreich eingetragen<br><br>";
- update_dhcpmtime(array());
- }else{
- $mesg = "Fehler beim eintragen Selbst-definierte DHCP Option<br><br>";
- }
-}
-
-#todo: array_vergleich -> Änderung -> ldap_modify
-#print_r($dhcpoptdefinition);echo "<br>";
-#print_r($olddhcpoptdefinition);echo "<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];
- }
-}
-
-
-if (count($entryadd) != 0 ){
- foreach (array_keys($entryadd) as $key){
- $addatts .= "<b>".$key."</b>,";
- }
- if(ldap_mod_add($ds,$dhcpDN,$entryadd)){
- $mesg = "Attribute ".$addatts." erfolgreich eingetragen<br><br>";
- update_dhcpmtime(array());
- }else{
- $mesg = "Fehler beim eintragen der Attribute ".$addatts."<br><br>";
- }
-}
-
-if (count($entrymod) != 0 ){
- foreach (array_keys($entrymod) as $key){
- $modatts .= "<b>".$key."</b>,";
- }
- if(ldap_mod_replace($ds,$dhcpDN,$entrymod)){
- $mesg = "Attribute ".$modatts." erfolgreich geaendert<br><br>";
- update_dhcpmtime(array());
- }else{
- $mesg = "Fehler beim aendern der Attribute ".$modatts."<br><br>";
- }
-}
-
-if (count($entrydel) != 0 ){
- foreach (array_keys($entrydel) as $key){
- $delatts .= "<b>".$key."</b>,";
- }
- if(ldap_mod_del($ds,$dhcpDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- update_dhcpmtime(array());
- }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
deleted file mode 100644
index 3d121397..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpservice_delete.php
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$dhcpDN = $_POST['dn'];
-$dhcpcn = $_POST['name'];
-
-$seconds = 2;
-$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
deleted file mode 100644
index 9160219c..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.dwt
+++ /dev/null
@@ -1,219 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td colspan='4' height='20'><h4><a href='dhcpsubnets.php?mnr={MNR}' class='headerlink'><< Zur&uuml;ck zur &Uuml;bersicht </a></h4></td>
- </tr>
-
- <tr>
- <td colspan='2'><h3>DHCP Subnet &nbsp;<code class='font_object'> {CN} / {NETMASK} </code> </h3></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;'>{DHCPSVNOW}&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>
- </table></td>
- </tr>
-
- <!--<tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Subnet Ranges / Pools:</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='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>IP Range</b></td>
- <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Pool Declaration Options</b></td>
- </tr>
-
- <tr height='50'>
- <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>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</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>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <tr valign='top'>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
- <td width='70%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert(e)</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Routers:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 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>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Broadcast Address:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 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>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Domain Name:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdomain-name]' value='{DOMAINNAME}' size='60' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdomain-name]' value='{DOMAINNAME}'> &nbsp;
- </td>
- </tr>
- <tr>
- <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='60' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdomain-name-servers]' value='{DOMAINNAMESERVERS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Default Lease Time:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='attribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptdefault-lease-time]' value='{DEFAULTLEASE}'> &nbsp;
- </td>
- </tr>
- <tr>
- <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='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[dhcpoptmax-lease-time]' value='{MAXLEASE}'> &nbsp;
- </td>
- </tr>
- <!-- <tr>
- <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>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Allow:</b></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 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>
- <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='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='mnr' value='{MNR}'>
- <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
deleted file mode 100644
index a7da175d..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet.php
+++ /dev/null
@@ -1,125 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcpsubnet.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-
-###################################################################################
-
-$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" => "",
- "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
-if ($subnet_data['dhcphlpcont'] != ""){
- $dhcpsvnowdn = ldap_explode_dn($subnet_data['dhcphlpcont'], 1);
- $dhcpsvnow = "<b>".$dhcpsvnowdn[0]."</b> &nbsp;[AU: ".$dhcpsvnowdn[2]."]";
-}else{
- $dhcpsvnow = "<b>&#8211;</b>";
-}
-
-# 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" => $dhcpsvnow,
- "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
deleted file mode 100644
index 5fdc0dec..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_add.php
+++ /dev/null
@@ -1,76 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$syntax = new Syntaxcheck;
-
-$subnet = $_POST['dhcpsubnet'];
-$subnetexp = explode("|",$subnet);
-$cn = $subnetexp[0];
-$netmask = $subnetexp[1];
-#print_r($subnet); echo "<br><br>";
-#print_r($cn); echo "<br><br>";
-#print_r($netmask); echo "<br><br>";
-
-$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 = 2;
-$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,$atts)){
- $mesg .= "<br>DHCP Subnet erfolgreich angelegt<br>";
- $url = "dhcpsubnets.php?mnr=".$mnr;
- }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=".$mnr;
- }
-}
-
-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=".$mnr;
-}
-
-$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
deleted file mode 100644
index 875f464b..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_change.php
+++ /dev/null
@@ -1,294 +0,0 @@
-<?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 = 2;
-$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>";
- }
-}
-
-
-update_dhcpmtime(array());
-
-$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
deleted file mode 100644
index 28c8277b..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnet_delete.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$subnetDN = $_POST['dn'];
-$cn = $_POST['name'];
-$mnr = $_POST['mnr'];
-
-$seconds = 1;
-$url = "dhcpsubnets.php?mnr=".$mnr;
-
-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>";
- update_dhcpmtime(array());
- }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
deleted file mode 100644
index 514f5b72..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.dwt
+++ /dev/null
@@ -1,36 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td width='80%'>
- <h3>DHCP Subnets</h3>
- &Uuml;bersicht der in <b>{AU}</b> angelegten <b>DHCP Subnets</b>:<br>
- Subnetz (-maske), Status der Einbindung in den zentralen DHCP Dienst, sowie Informationen zu angelegten dynamischen DHCP Pools des Subnetzes.<br><br>
- Zur <b>Verwaltungsmaske</b> eines bestimmten Subnetzes gelangen Sie durch klicken auf entsprechendes Subnetz.<br><br>
- DHCP Subnets k&ouml;nnen nur f&uuml;r Ihnen <b>komplett zugewiesene Subnetze</b> angelegt werden.<br>
- &Uuml;ber die <b>Eingabemaske</b> k&ouml;nnen Sie noch nicht als DHCP Subnets anlegte komplette Subnetze eintragen (Men&uuml;punkt links "Neues DHCP Subnet anlegen").
- </td>
- <td>&nbsp;</td>
- </tr>
-
- <tr><td colspan='2'>
- <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='15%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Netmask</b></td>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP Service</b></td>
- <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Dynamic Pools (IP Ranges)</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Subnets -->
- <tr height='45' valign='top'>
- <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;'>{POOLS}&nbsp;</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
deleted file mode 100644
index 88e10576..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/dhcpsubnets.php
+++ /dev/null
@@ -1,89 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dhcpsubnets.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-###################################################################################
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createDhcpMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$template->assign(array("SUBNETDN" => "",
- "SUBNETCN" => "Noch keine Subnets angelegt",
- "NETMASK" => "",
- "DHCP" => "",
- "POOLS" => ""));
-
-# rbservice und pxe daten (voerst nur ein rbs)
-$subnet_array = get_dhcpsubnets($auDN,array("dn","cn","dhcpoptnetmask","dhcprange","dhcphlpcont"));
-
-$template->define_dynamic("Subnets", "Webseite");
-$template->define_dynamic("Pools", "Webseite");
-
-foreach ($subnet_array as $subnet){
- # Pools des Subnetzes
- $pools = get_dhcppools_subnet($subnet['dn'],array("dhcprange","dhcpoptallow","dhcpoptdeny","dhcpoptignore"));
- #print_r($pools); echo "<br><br>";
- $poollist = "<ul>";
- foreach ($pools as $pool){
- $poollist .= "<li>";
- if (count($pool['dhcprange']) >1){
- for ($i=0; $i<count($pool['dhcprange']); $i++){
- $range = explode('_',$pool['dhcprange'][$i]);
- $poollist .= $range[0]." - ".$range[1];
- if ($i+1 != count($pool['dhcprange'])){
- $poollist .= "<br>";
- }
- }
- }else{
- $range = explode('_',$pool['dhcprange']);
- $poollist .= $range[0]." - ".$range[1];
- }
- if ($pool['dhcpoptallow'] != ""){
- $poollist .= "<br>ALLOW ".$pool['dhcpoptallow'];
- }
- if ($pool['dhcpoptignore'] != ""){
- $poollist .= "<br>IGNORE ".$pool['dhcpoptignore'];
- }
- if ($pool['dhcpoptdeny'] != ""){
- $poollist .= "<br>DENY ".$pool['dhcpoptdeny'];
- }
- $poollist .= " &nbsp;[Abt.: ".$pool['poolAU']."]</li><br>";
- }
- $poollist .= "</ul>";
-
- # Dienstzuordnung des Subnetzes
- $dhcpservice = "";
- if ($subnet['dhcphlpcont'] != ""){
- $exp = ldap_explode_dn($subnet['dhcphlpcont'],1);
- $dhcpservice = $exp[0]."<br>[".$exp[2]."]";
- }
-
- $subnetcn = "<a href='dhcpsubnet.php?dn=".$subnet['dn']."&mnr=".$mnr."' class='headerlink'><b>".$subnet['cn']."</b></a>";
- $template->assign(array("SUBNETDN" => $subnet['dn'],
- "SUBNETCN" => $subnetcn,
- "NETMASK" => $subnet['dhcpoptnetmask'],
- "DHCP" => $dhcpservice,
- "POOLS" => $poollist));
- $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
deleted file mode 100644
index 24e68a3c..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/menu.dwt
+++ /dev/null
@@ -1,32 +0,0 @@
-
-<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">
- <code class="submenue_schrift">{TEXT_M}</code>
- </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
deleted file mode 100644
index 7d964715..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.dwt
+++ /dev/null
@@ -1,151 +0,0 @@
-<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
deleted file mode 100644
index 622bff20..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/new_dhcpservice.php
+++ /dev/null
@@ -1,75 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_dhcpservice.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-
-###################################################################################
-
-$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
deleted file mode 100644
index 61d052b1..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.dwt
+++ /dev/null
@@ -1,144 +0,0 @@
-<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='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='70%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
-
- <tr height='50' valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>DHCP Subnet (+ Netmask):</b><br>
- (Noch freie verf&uuml;gbare Netze) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <select name='dhcpsubnet' size='{SUBLIST}' class='medium_form_selectbox'>
-
- <!-- BEGIN DYNAMIC BLOCK: Dhcpsubnets -->
- <option value='{SUBNET}'>{CN} / {NETMASK}</option>
- <!-- END DYNAMIC BLOCK: Dhcpsubnets -->
-
- </select>
- </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='{SRVLIST}' 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='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Option</b></td>
- <td width='70%' 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>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>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>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>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
deleted file mode 100644
index 2d2835ec..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/new_dhcpsubnet.php
+++ /dev/null
@@ -1,109 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_dhcpsubnet.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-
-###################################################################################
-
-$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,
- "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));
-
-
-
-$freenets = get_networks();
-#print_r($freenets);
-$subnets = array();
-if (count($freenets) != 0){
- $template->define_dynamic("Dhcpsubnets", "Webseite");
-
- foreach ($freenets as $subnet){
- $netexp = explode(".",$subnet);
- $mask = array(255,255,255,255);
- for ($i=0; $i<count($netexp); $i++){
- if ($netexp[$i] == "0"){
- $mask[$i] = "0";
- }
- }
- $netmask = implode(".", $mask);
- $subnets[] = $subnet."|".$netmask;
-
- $template->assign(array("SUBNET" => $subnet."|".$netmask,
- "CN" => $subnet,
- "NETMASK" => $netmask));
- $template->parse("DHCPSUBNETS_LIST", ".Dhcpsubnets");
- }
- #print_r($subnets);
-
-# 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");
- }
-}
-
-$template->assign(array("SUBLIST" => count($freenets)+1,
- "SRVLIST" => count($dhcpservices)+1));
-
-}else{
- # keine freie Netze mehr zur Verfügung
- # wird schon über das DHCP Menu abgefangen ...
-}
-
-###################################################################################
-
-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
deleted file mode 100644
index 4e83f948..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/no_dhcp.dwt
+++ /dev/null
@@ -1,27 +0,0 @@
-<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>Verwaltung von DHCP Subnets, Pools (und Classes).<br>
- <br>
- <b>Sie verf&uuml;gen &uuml;ber keine IP Adressen, so dass Sie keine dieser Objekte
- anlegen bzw. verwalten k&ouml;nnen.</b><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>
- Sie k&ouml;nnen jedoch ihre Rechner im zentralen DHCP Dienst eintragen, &uuml;ber das<br>
- Modul <a class='headerlink' href='../computers/computers.php' >Rechner Management</a>.
-
- </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
deleted file mode 100644
index 06fd226e..00000000
--- a/ldap-site-mngmt/webinterface/dhcp/no_dhcp.php
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "no_dhcp.dwt";
-
-include('dhcp_header.inc.php');
-
-$mnr = 0;
-$sbmnr = -1;
-
-###################################################################################
-
-# 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/dns/dns.dwt b/ldap-site-mngmt/webinterface/dns/dns.dwt
deleted file mode 100644
index 968d8c16..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns.dwt
+++ /dev/null
@@ -1,76 +0,0 @@
-<html>
-
-<head>
- <title>{SEITENTITEL}</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'></head>
-<body>
-
-<table cellpadding='0' cellspacing='0' border='0' width='100%' style='background-color: #F0F0F0;border-color: #505050; border-style: solid; border-width: 0 0 1 0;'>
- <tr>
- <td width='30%'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr valign='top'>
- <td width='1'></td>
- <td><h2>Client / IP Management</h2></td>
- </tr>
- </table>
- </td>
-
- <td width='45%'>
- <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>
- <tr>
- <td colspan='3'>{MAINMENU}</td>
- </tr>
-</table>
-
-<!-- <hr align='center' width='98%' noshade> -->
-<br>
-
-
-<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/dns/dns.php b/ldap-site-mngmt/webinterface/dns/dns.php
deleted file mode 100644
index 4368d6a9..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns.php
+++ /dev/null
@@ -1,21 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "dns_inwork.dwt";
-
-include('dns_header.inc.php');
-
-###################################################################################
-
-$mnr = 0;
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createDNSMenu($rollen, $mnr);
-
-###################################################################################
-
-include("dns_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dns/dns_footer.inc.php b/ldap-site-mngmt/webinterface/dns/dns_footer.inc.php
deleted file mode 100644
index 311721c5..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns_footer.inc.php
+++ /dev/null
@@ -1,18 +0,0 @@
-<?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/dns/dns_header.inc.php b/ldap-site-mngmt/webinterface/dns/dns_header.inc.php
deleted file mode 100644
index b6dfd984..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns_header.inc.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?php
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "DNS Zone Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 4;
-
-
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$definedTemplates = array("Vorlage" => "dns.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));
-
-
-include("dns_menu.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dns/dns_inwork.dwt b/ldap-site-mngmt/webinterface/dns/dns_inwork.dwt
deleted file mode 100755
index d64dc090..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns_inwork.dwt
+++ /dev/null
@@ -1,15 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - DNS Zonen Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul steht noch nicht zur Verf&uuml;gung ...<br>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dns/dns_menu.php b/ldap-site-mngmt/webinterface/dns/dns_menu.php
deleted file mode 100644
index bf6e5bbe..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns_menu.php
+++ /dev/null
@@ -1,73 +0,0 @@
-<?php
-
-function createDNSMenu($rollen , $mnr) {
- global $template;
- global $START_PATH;
- # Struktur der Registerkartenleiste
- $hauptmenu = array(array("link" => "dns.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => "alle"),
- #array("link" => "dns.php",
- # "text" => "SOA Record",
- # "zugriff" => array("MainAdmin")),
- #array("link" => "dns.php",
- # "text" => "INCLUDE Direktiven",
- # "zugriff" => array("MainAdmin","ZoneAdmin")),
- #array("link" => "dns.php",
- # "text" => "Zonen Delgierung",
- # "zugriff" => array("MainAdmin")),
- #array("link" => "dns.php",
- # "text" => "Resource Records",
- # "zugriff" => array("MainAdmin","HostAdmin","ZoneAdmin"))
- );
-
- #$rollen = array_keys($roles);
-
- # Zusammenstellen der Menuleiste
- $template->define_dynamic("Hauptmenu", "Menu");
- $i=0;
- foreach($hauptmenu as $item) {
- if($item['zugriff'] === "alle" || vergleicheArrays($rollen , $item['zugriff'])) {
- if ($i==0) {
- if ($mnr==0) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $zwisch="";
- $farb="#A0A0A0";
- $lastaktive=false;
- }
- }
- else {
- if ($mnr==$i) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $farb="#A0A0A0";
- if ($lastaktive) {$zwisch="";}
- else {$zwisch="";}
- $lastaktive=false;
- }
- }
- $template->assign(array("ZWISCHEN" => $zwisch,
- "FARBE" => $farb,
- "LINK_M" => $item["link"],
- "TEXT_M" => $item["text"]));
- $template->parse("HAUPTMENU_LIST", ".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/dns/dns_start.dwt b/ldap-site-mngmt/webinterface/dns/dns_start.dwt
deleted file mode 100644
index 0595dde7..00000000
--- a/ldap-site-mngmt/webinterface/dns/dns_start.dwt
+++ /dev/null
@@ -1,30 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - DNS Zonen Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung ...<br>
- Benutzen Sie die Navigation links, um die einzelnen Verwaltungsbereiche anzusteuern:</p>
- <ul>
- <li><p><b>SOA Record</b></p>
- Verwalten Sie hier den Start Of Authority (SOA) ihrer DNS Zone ...
- </li>
- <li><p><b>Include Direktiven</b></p>
- Verwalten Sie hier die $INCLUDE Direktiven ihrer includeten Zonendateien ...
- </li>
- <li><p><b>Zonen Delegierung</b></p>
- Delegieren Sie hier neue DNS Zonen ...
- </li>
- <li><p><b>Resource Records Zone</b></p>
- Verwalten Sie hier alle weiteren Namenseintraege ihrer Zone und deren RRs ...
- </li>
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/dns/menu.dwt b/ldap-site-mngmt/webinterface/dns/menu.dwt
deleted file mode 100644
index a57ab962..00000000
--- a/ldap-site-mngmt/webinterface/dns/menu.dwt
+++ /dev/null
@@ -1,22 +0,0 @@
-
-<table cellpadding='5' cellspacing='0' border='0' width='100%'>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Hauptmenu -->
-
- <tr valign='middle' align='left'>
-
- <td width='8%' align='right' style="border-style=none;"></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>
- <tr height='5'></tr>
- <!-- END DYNAMIC BLOCK: Hauptmenu -->
-
-
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/hauptmenue.dwt b/ldap-site-mngmt/webinterface/hauptmenue.dwt
deleted file mode 100644
index 7295b5f6..00000000
--- a/ldap-site-mngmt/webinterface/hauptmenue.dwt
+++ /dev/null
@@ -1,16 +0,0 @@
-
-<table width='100%' height="25" border="0" cellspacing="0" cellpadding="3">
-<tr height="25">
- <td width='5'></td>
- <!-- BEGIN DYNAMIC BLOCK: Mainmenu -->
- <td width='2'></td>
- <td height="20" width="120" align="center" style="border-width:1 1 0 1;border-color:#505050;border-style:solid;background-color:{MFARBE}">
- <a href="{MLINK_M}" style="text-decoration:none"><code class="menue_schrift">
- {MTEXT_M}</code></a>
- </td>
- <!-- END DYNAMIC BLOCK: Mainmenu -->
- <td>&nbsp;</td>
-
-</tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/home.dwt b/ldap-site-mngmt/webinterface/home.dwt
deleted file mode 100644
index 9d89dadc..00000000
--- a/ldap-site-mngmt/webinterface/home.dwt
+++ /dev/null
@@ -1,72 +0,0 @@
-<table cellpadding='0' cellspacing='0' border='0' width='100%' style='background-color: #F0F0F0;border-color: #505050; border-style: solid; border-width: 0 0 1 0;'>
- <tr valign='middle'>
- <td width='35%'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr>
- <td width='1'></td>
- <td><h2>Client / 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;</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='100%' height='85%'>
-
- <tr valign='top' height='100%'>
- <td width='95%'>
-
- <table border='0' cellpadding='10' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Admin Units (AU) in denen Sie Administrator sind</h3>
- Um zu den Administrations-Seiten einer AU zu kommen, w&auml;hlen Sie entsprechenden Link.
- </td>
- </tr>
-
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='100%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='70%' colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Administrative Einheiten</b></td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Rolle</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Aus -->
- <tr>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <a href='zwischen.php?audn={AUDN}&rollen={ROLLEN}' class='headerlink'>{AU}</a> </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{CN} &nbsp;</td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{MA} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Aus -->
-
- </table>
- </td>
- </tr>
- </table>
-
- </td>
- </tr>
-</table>
-
diff --git a/ldap-site-mngmt/webinterface/index.dwt b/ldap-site-mngmt/webinterface/index.dwt
deleted file mode 100644
index 048a34cb..00000000
--- a/ldap-site-mngmt/webinterface/index.dwt
+++ /dev/null
@@ -1,27 +0,0 @@
-<html>
-
-<head>
- <title>{SEITENTITEL}</title>
- <link rel='stylesheet' href='styles.css' type='text/css'>
-
-</head>
-<body>
-
-<!--<table cellpadding='0' cellspacing='0' border='0' align='center' width='100%' height='100%'>
- <tr height='10'>
- <td colspan='3'></td>
- </tr>
- <tr height='100%'>
- <td width='2%'></td>
- <td width='96%' style='border-color: #C0C0C0; border-style: solid; border-width: 1 1 1 1;'>-->
-
- {HAUPTFENSTER}
-
- <!--</td>
- <td width='2%'></td>
- </tr>
-</table>-->
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/index.php b/ldap-site-mngmt/webinterface/index.php
deleted file mode 100644
index be6cfe50..00000000
--- a/ldap-site-mngmt/webinterface/index.php
+++ /dev/null
@@ -1,46 +0,0 @@
-<?php
-# Nach dem Logout wird die Session beim Aufruf der index.php zerstört.
-if(isset($_POST['Logout']) || $_SESSION['status'] != "in") {
- session_start();
- session_unregister('uid');
- session_unregister('userPassword');
- session_unregister('cn');
- session_unregister('dn');
- session_unregister('roles');
- session_unregister('au_dn');
- session_unregister('status');
- session_destroy();
-}
-
-###########################################################
-
-#Pfad festlegen wo die Dateien sich befinden
-#include('standard_header.inc.php');
-include("class.FastTemplate.php");
-
-$titel = "Zentrales Client / IP Management";
-$webseite = "start.dwt";
-
-# neues Template-Objekt erstellen
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$template->define(array("Vorlage" => "index.dwt",
- "Login" => "login_form.inc.html",
- "Webseite" => $webseite));
-$template->assign(array("SEITENTITEL" => $titel));
-
-############################################################
-
-# Daten in die Vorlage parsen
-$template->assign(array("PFAD" => $START_PATH));
-
-# $template->parse("MAINMENU", "Mmenu");
-# $template->parse("NAVIGATION", "Menu");
-$template->parse("LOGIN", "Login");
-$template->parse("HAUPTFENSTER", "Webseite");
-$template->parse("PAGE", "Vorlage");
-
-# Fertige Seite an den Browser senden
-$template->FastPrint("PAGE");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/ip/ip.dwt b/ldap-site-mngmt/webinterface/ip/ip.dwt
deleted file mode 100644
index 9dd6a28e..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip.dwt
+++ /dev/null
@@ -1,88 +0,0 @@
-<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>Client / 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>
- <tr>
- <td>
-
- {IPBLOCKS}
-
- </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> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip.php b/ldap-site-mngmt/webinterface/ip/ip.php
deleted file mode 100644
index 9566d124..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip.php
+++ /dev/null
@@ -1,22 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "ip_start.dwt";
-
-include("ip_header.inc.php");
-
-###################################################################################
-
-$mnr = 0;
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createIPMenu($rollen, $mnr);
-
-###################################################################################
-
-include("ip_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_blocks.inc.php b/ldap-site-mngmt/webinterface/ip/ip_blocks.inc.php
deleted file mode 100644
index 8530e079..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_blocks.inc.php
+++ /dev/null
@@ -1,68 +0,0 @@
-<?php
-
-# Max und Free IP Blocks
-$mipb_array = get_maxipblocks_au($auDN);
-$fipb_array = get_freeipblocks_au($auDN);
-#print_r(count($mipb_array)); echo "<br>";
-#print_r(count($fipb_array)); echo "<br>";
-$ipblocks = "";
-
-# print_r($mipb_array);
-if ($mipb_array[0] != "" ){
- if (count($mipb_array) > 1 ){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <h4>Zugewiesene IP Bereiche:</h4></td></tr>";
- foreach ($mipb_array as $mipb){
- $exp = explode('_',$mipb);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></td></tr>";
- }
- }
- elseif (count($mipb_array) == 1){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <h4>Zugewiesener IP Bereich:</h4></td></tr>";
- $exp = explode('_',$mipb_array[0]);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></tr>";
- }
- elseif( $fipb_array[0] == "" ){
- $ipblocks .= "<table border='0' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td><h4>Keine IP Adressen mehr verf&uuml;gbar</h4></td></tr>";
- }
- if (count($fipb_array) > 1 ){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr valign='bottom' height='50'>
- <td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <h4>Davon noch frei verf&uuml;gbar:</h4></td></tr>";
- foreach ($fipb_array as $fipb){
- $exp = explode('_',$fipb);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></tr>";
- }
- }
- elseif (count($fipb_array) == 1){
- $ipblocks .= "<table border='1' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td colspan='3' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>
- <h4>Davon noch frei verf&uuml;gbar:</h4></td></tr>";
- $exp = explode('_',$fipb_array[0]);
- $ipblocks .= "<tr><td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[0]&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> - </td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>$exp[1]&nbsp;</td></tr>";
- }
-
-}
-
-if( $mipb_array[0] == "" ){
- $ipblocks .= "<table border='0' cellpadding='2' cellspacing='0' width='100%' style='border-width: 0 0 0 0;'>
- <tr><td><h4>Ihnen wurden keine IP Adressen zugewiesen</h4></td></tr>";
-}
-$ipblocks .= "</table>";
-
-$template->assign(array("IPBLOCKS" => $ipblocks));
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_deleg.dwt b/ldap-site-mngmt/webinterface/ip/ip_deleg.dwt
deleted file mode 100644
index 3eb0ea74..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_deleg.dwt
+++ /dev/null
@@ -1,40 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Folgende IP Adressen haben Sie an untergeordnete Abteilungen delegiert: </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='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Untergeordnete Abteilung</b></td>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Delegierte IP Bereiche</b></td>
- </tr>
-
- <form action='ip_deleg_change.php' method='post'>
-
- <!-- BEGIN DYNAMIC BLOCK: AUs -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{CHILDOU} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
-
- <!-- BEGIN DYNAMIC BLOCK: Delegs -->
- <input type='Text' name='range1[]' value='{RANGE1}' size='15' class='medium_form_field'>
- &nbsp;&nbsp;- &nbsp;&nbsp;
- <input type='Text' name='range2[]' value='{RANGE2}' size='15' class='medium_form_field'><br>
- <input type='hidden' name='oldrange1[]' value='{RANGE1}'>
- <input type='hidden' name='oldrange2[]' value='{RANGE2}'>
- <input type='hidden' name='childaudn[]' value='{CHILDDN}'>
- <input type='hidden' name='audn[]' value='{AUDN}'>
- <!-- END DYNAMIC BLOCK: Delegs -->
- </td>
- </tr>
- <!-- END DYNAMIC BLOCK: AUs -->
-
- </table></td>
- <tr>
- <td><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_deleg.php b/ldap-site-mngmt/webinterface/ip/ip_deleg.php
deleted file mode 100644
index 6e15b6f2..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_deleg.php
+++ /dev/null
@@ -1,102 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "IP Address Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-$mnr = 2;
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "ip_deleg.dwt";
-
-include("../class.FastTemplate.php");
-
-include("ip_header.inc.php");
-
-#############################################################################
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createIPMenu($rollen, $mnr);
-
-include("ip_blocks.inc.php");
-
-
-#############################################################################
-
-$template->assign(array("CHILDOU" => "Noch keine untergeordnete AU angelegt",
- "RANGE1" => "",
- "RANGE2" => "",
- "CHILDDN" => ""));
-
-$childau_array = get_childau($auDN,array("dn","ou","maxipblock"));
-# print_r ($childau_array);
-
-$template->define_dynamic("Delegs", "Webseite");
-$template->define_dynamic("AUs", "Webseite");
-
-foreach ($childau_array as $childau){
-
- $template->clear_parse("DELEGS_LIST");
- if ( count($childau['maxipblock']) > 1 ){
- foreach ($childau['maxipblock'] as $j){
- $exp = explode('_',$j);
- $template->assign(array("CHILDOU" => $childau['ou'],
- "RANGE1" => $exp[0],
- "RANGE2" => $exp[1],
- "CHILDDN" => $childau['dn'],
- "AUDN" => $auDN));
- $template->parse("DELEGS_LIST", ".Delegs");
- $template->clear_dynamic("Delegs");
- }
- $template->assign(array("CHILDOU" => $childau['ou'],
- "RANGE1" => "",
- "RANGE2" => "",
- "CHILDDN" => $childau['dn'],
- "AUDN" => $auDN));
- $template->parse("DELEGS_LIST", ".Delegs");
- $template->clear_dynamic("Delegs");
- $template->assign(array("OU" => $childau['ou']));
- $template->parse("AUS_LIST", ".AUs");
-
- }elseif ( count($childau['maxipblock']) == 1 ){
-
- $exp = explode('_',$childau['maxipblock']);
- $template->assign(array("CHILDOU" => $childau['ou'],
- "RANGE1" => $exp[0],
- "RANGE2" => $exp[1],
- "CHILDDN" => $childau['dn'],
- "AUDN" => $auDN));
- $template->parse("DELEGS_LIST", ".Delegs");
- $template->clear_dynamic("Delegs");
- $template->assign(array("CHILDOU" => $childau['ou'],
- "RANGE1" => "",
- "RANGE2" => "",
- "CHILDDN" => $childau['dn'],
- "AUDN" => $auDN));
- $template->parse("DELEGS_LIST", ".Delegs");
- $template->clear_dynamic("Delegs");
- $template->assign(array("OU" => $childau['ou']));
- $template->parse("AUS_LIST", ".AUs");
-
- }else{
- $template->assign(array("CHILDOU" => $childau['ou'],
- "RANGE1" => "",
- "RANGE2" => "",
- "CHILDDN" => $childau['dn'],
- "AUDN" => $auDN));
- $template->parse("DELEGS_LIST", ".Delegs");
- $template->clear_dynamic("Delegs");
- $template->assign(array("OU" => $childau['ou']));
- $template->parse("AUS_LIST", ".AUs");
- }
-
-}
-
-
-#####################################################################################
-
-include("ip_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/ip/ip_deleg_change.php b/ldap-site-mngmt/webinterface/ip/ip_deleg_change.php
deleted file mode 100644
index d9122eb0..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_deleg_change.php
+++ /dev/null
@@ -1,194 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-$auDN = $_POST['audn'];
-$childauDN = $_POST['childaudn'];
-$oldrange1 = $_POST['oldrange1'];
-$oldrange2 = $_POST['oldrange2'];
-$newrange1 = $_POST['range1'];
-$newrange2 = $_POST['range2'];
-
-/*
-print_r($oldrange1);echo "<br>";
-print_r($newrange1);echo "<br><br>";
-print_r($oldrange2);echo "<br>";
-print_r($newrange2);echo "<br>";
-print_r($childauDN);echo "<br>";
-print_r($auDN);echo "<br><br>";
-*/
-
-$syntax = new Syntaxcheck;
-$url = "ip_deleg.php";
-$seconds = 200;
-
-echo "
-<html>
-<head>
- <title>IP Address Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-
-$diff1 = array_keys(array_diff_assoc($oldrange1,$newrange1));
-$diff2 = array_keys(array_diff_assoc($newrange1,$oldrange1));
-$tochange1 = array_unique(array_merge($diff1,$diff2));
-
-$diff3 = array_keys(array_diff_assoc($oldrange2,$newrange2));
-$diff4 = array_keys(array_diff_assoc($newrange2,$oldrange2));
-$tochange2 = array_unique(array_merge($diff3,$diff4));
-
-# print_r($tochange1);echo "<br><br>";
-# print_r($tochange2);echo "<br><br>";
-
-$tochange = array_unique(array_merge($tochange1,$tochange2));
-#print_r($tochange);echo "<br><br>";
-
-
-foreach ($tochange as $i){
-
- $childaudnexp = ldap_explode_dn($childauDN[$i], 1);
- $childau = $childaudnexp[0];
- #print_r($childau);
-
- if ( $oldrange1[$i] == "" && $oldrange2[$i] == "" && $newrange1[$i] != "" && $newrange2[$i] != "" ){
-
- echo "Neuen IP Bereich an <b>$childau</b> delegieren:";echo "<br>";echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- #echo "korrekte IP Syntax<br>";
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- #print_r($newrange_array);
- $newrange = implode('_',$newrange_array);
- #print_r($newrange);
- # $oldip[$i] = htmlentities($oldip[$i]);
- if (new_ip_delegation($newrange,$childauDN[$i],$auDN[$i])){
- echo "<br>Neuer IP Bereich erfolgreich delegiert<br>";
- }else{echo "<br>Fehler beim delegieren des neuen IP Bereichs<br>";}
- }else{echo "falsche IP Syntax<br>";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_deleg.php' style='publink'>back</a>";
- redirect($seconds, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $newrange1[$i] == "" && $newrange2[$i] == "" ){
-
- echo "IP Delegierung von <b>$childau</b> l&ouml;schen:";echo "<br>";echo "<br>";
- echo "zu l&ouml;schende IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
-
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldip_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldip_array);
- if (delete_ip_delegation($oldrange,$childauDN[$i],$auDN[$i])){
- $mesg = "<br>IP Delegierung geloescht<br>";
- }else{
- $mesg = "<br>Fehler beim loeschen der IP Delegierung<br>";
- }
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_deleg.php' style='publink'>back</a>";
- redirect($seconds, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $newrange1[$i] != "" && $newrange2[$i] != "" ){
- $or1 = ip2long($oldrange1[$i]);
- $or2 = ip2long($oldrange2[$i]);
- $nr1 = ip2long($newrange1[$i]);
- $nr2 = ip2long($newrange2[$i]);
-
- if ( ($nr1 > $or1 || $nr2 < $or2) && !($nr1 < $or1 || $nr2 > $or2) ){
-
- echo "IP Delegierung von <b>$childau</b> reduzieren:";echo "<br>";echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- #echo "korrekte IP Syntax<br>";
-
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- $newrange = implode('_',$newrange_array);
- #print_r($newrange);
-
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldip_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldip_array);
- #print_r($oldrange);
-
- if (reduce_ip_delegation($oldrange,$newrange,$childauDN[$i],$auDN[$i])){
- $mesg = "<br>IP Range verkleinert<br>";
- }else{
- $mesg = "<br>Fehler beim verkleinern der IP Range<br>";
- }
- }else{echo "falsche IP Syntax<br>";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_deleg.php' style='publink'>back</a>";
- redirect($seconds, $url, $mesg, $addSessionId = TRUE);
-
-
- }elseif( ($nr1 < $or1 || $nr2 > $or2) && !($nr1 > $or1 || $nr2 < $or2) ){
-
- echo "IP Delegierung von <b>$childau</b> erweitern:";echo "<br>";echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- #echo "korrekte IP Syntax<br>";
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- $newrange = implode('_',$newrange_array);
- #print_r($newrange);
-
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldip_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldip_array);
- #print_r($oldrange);
-
- if (expand_ip_delegation($oldrange,$newrange,$childauDN[$i],$auDN[$i])){
- $mesg = "<br>IP Range erweitert<br>";
- }else{
- $mesg = "<br>Fehler beim erweitern der IP Range<br>";
- }
- }else{
- echo "falsche IP Syntax<br>";
- }
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_deleg.php' style='publink'>back</a>";
- redirect($seconds, $url, $mesg, $addSessionId = TRUE);
- }
- else{
- $mesg = "<br>Verschieben (Shiften) der Delegierung nicht moeglich!<br>
- Nur Vergroessern und Verkleinern moeglich!<br>";
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_deleg.php' style='publink'>back</a>";
- redirect($seconds, $url, $mesg, $addSessionId = TRUE);
- }
- }
- else{
- $mesg = "keine Aenderung<br>";
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_deleg.php' style='publink'>back</a>";
- redirect($seconds, $url, $mesg, $addSessionId = TRUE);
- }
-
- echo "<br><br>";
-}
-
-echo "
-</td></tr></table>
-</head>
-</html>";
-?>
diff --git a/ldap-site-mngmt/webinterface/ip/ip_dhcp.dwt b/ldap-site-mngmt/webinterface/ip/ip_dhcp.dwt
deleted file mode 100644
index b2739df1..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_dhcp.dwt
+++ /dev/null
@@ -1,39 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Folgende IP Adressen haben Sie in DHCP Ranges vergeben: </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='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP Subnet</b></td>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Dynamisch zuweisbare IP Adressen (range)</b></td>
- </tr>
-
- <form action='ip_dhcp_change.php' method='post'>
-
- <!-- BEGIN DYNAMIC BLOCK: Subnets -->
- <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;'>
- <input type='Text' name='range1[]' value='{RANGE1}' size='15' class='medium_form_field'>
- &nbsp;&nbsp; - &nbsp;&nbsp;
- <input type='Text' name='range2[]' value='{RANGE2}' size='15' class='medium_form_field'>
-
- <input type='hidden' name='oldrange1[]' value='{RANGE1}'>
- <input type='hidden' name='oldrange2[]' value='{RANGE2}'>
- <input type='hidden' name='dhcpdn[]' value='{DHCPDN}'>
- <input type='hidden' name='audn[]' value='{AUDN}'>
- &nbsp;
- </td>
- </tr>
- <!-- END DYNAMIC BLOCK: Subnets -->
-
- </table></td>
- <tr>
- <td><input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_dhcp.php b/ldap-site-mngmt/webinterface/ip/ip_dhcp.php
deleted file mode 100644
index a1c2eea0..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_dhcp.php
+++ /dev/null
@@ -1,54 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "IP Address Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-$mnr = 2;
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "ip_dhcp.dwt";
-
-include("../class.FastTemplate.php");
-
-include("ip_header.inc.php");
-
-#############################################################################
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createIPMenu($rollen, $mnr);
-
-include("ip_blocks.inc.php");
-
-
-#############################################################################
-
-$template->assign(array("SUBNET" => "Noch kein DHCP Objekt angelegt",
- "RANGE1" => "",
- "RANGE2" => "",
- "DHCPDN" => ""));
-
-$subnet_array = get_subnets($auDN,array("dn","cn","dhcprange"));
-# print_r ($subnet_array);
-
-$template->define_dynamic("Subnets", "Webseite");
-
-foreach ($subnet_array as $subnet){
- $exp = explode('_',$subnet['dhcprange']);
-
- $template->assign(array("SUBNET" => $subnet['cn'],
- "RANGE1" => $exp[0],
- "RANGE2" => $exp[1],
- "DHCPDN" => $subnet['dn'],
- "AUDN" => $auDN ));
- $template->parse("SUBNETS_LIST", ".Subnets");
-}
-
-
-#####################################################################################
-
-include("ip_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_dhcp_change.php b/ldap-site-mngmt/webinterface/ip/ip_dhcp_change.php
deleted file mode 100644
index 43474eec..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_dhcp_change.php
+++ /dev/null
@@ -1,146 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-$auDN = $_POST['audn'];
-$dhcpDN = $_POST['dhcpdn'];
-$oldrange1 = $_POST['oldrange1'];
-$oldrange2 = $_POST['oldrange2'];
-$newrange1 = $_POST['range1'];
-$newrange2 = $_POST['range2'];
-
-/*
-print_r($oldrange1);echo "<br>";
-print_r($newrange1);echo "<br><br>";
-print_r($oldrange2);echo "<br>";
-print_r($newrange2);echo "<br>";
-*/
-
-$syntax = new Syntaxcheck;
-$url = "ip_dhcp.php";
-
-echo "
-<html>
-<head>
- <title>IP Address Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-
-$diff1 = array_keys(array_diff_assoc($oldrange1,$newrange1));
-$diff2 = array_keys(array_diff_assoc($newrange1,$oldrange1));
-$tochange1 = array_unique(array_merge($diff1,$diff2));
-
-$diff3 = array_keys(array_diff_assoc($oldrange2,$newrange2));
-$diff4 = array_keys(array_diff_assoc($newrange2,$oldrange2));
-$tochange2 = array_unique(array_merge($diff3,$diff4));
-
-# print_r($tochange1);echo "<br><br>";
-# print_r($tochange2);echo "<br><br>";
-
-$tochange = array_unique(array_merge($tochange1,$tochange2));
-# print_r($tochange);echo "<br><br>";
-
-
-foreach ($tochange as $i){
-
- if ( $oldrange1[$i] == "" && $oldrange2[$i] == "" && $newrange1[$i] != "" && $newrange2[$i] != "" ){
- echo "neue IP Range";echo "<br>";echo "<br>";
- print_r($auDN[$i]);echo "<br>";
- print_r($dhcpDN[$i]);echo "<br>";
- echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- echo "korrekte IP Syntax<br>";
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- print_r($newrange_array);
- $newrange = implode('_',$newrange_array);
- print_r($newrange);
- # $oldip[$i] = htmlentities($oldip[$i]);
- if (new_ip_dhcprange($newrange,$dhcpDN[$i],$auDN[$i])){
- $mesg = "Neue IP Range eingetragen<br>";
- }else{
- $mesg = "Fehler beim eintragen der neuen IP Range<br>";
- }
- }else{echo "falsche IP Syntax<br>";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_dhcp.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $newrange1[$i] == "" && $newrange2[$i] == "" ){
- echo "loeschen IP Range";echo "<br>";echo "<br>";
- print_r($auDN[$i]);echo "<br>";
- print_r($dhcpDN[$i]);echo "<br>";
- echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- if (delete_ip_dhcprange($dhcpDN[$i],$auDN[$i])){
- $mesg = "IP Range geloescht<br>";
- }else{
- $mesg = "Fehler beim loeschen der IP Range<br>";
- }
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_dhcp.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldrange1[$i] != "" && $oldrange2[$i] != "" && $newrange1[$i] != "" && $newrange2[$i] != "" ){
- echo "aendern IP Range";echo "<br>";echo "<br>";
- print_r($auDN[$i]);echo "<br>";
- print_r($dhcpDN[$i]);echo "<br>";
- echo "<br>";
- echo "alte IP Range: ";print_r($oldrange1[$i]);echo " - ";print_r($oldrange2[$i]);echo "<br>";
- echo "neue IP Range: ";print_r($newrange1[$i]);echo " - ";print_r($newrange2[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newrange1[$i]) && $syntax->check_ip_syntax($newrange2[$i])){
- echo "korrekte IP Syntax<br>";
- $newrange1[$i] = htmlentities($newrange1[$i]);
- $newrange2[$i] = htmlentities($newrange2[$i]);
- $newrange_array = array($newrange1[$i],$newrange2[$i]);
- $newrange = implode('_',$newrange_array);
- print_r($newrange);
- $oldrange1[$i] = htmlentities($oldrange1[$i]);
- $oldrange2[$i] = htmlentities($oldrange2[$i]);
- $oldrange_array = array($oldrange1[$i],$oldrange2[$i]);
- $oldrange = implode('_',$oldrange_array);
- if (modify_ip_dhcprange($newrange,$dhcpDN[$i],$auDN[$i])){
- $mesg = "IP Range geaendert<br>";
- }else{
- $mesg = "Fehler beim aendern der IP Range<br>";
- # alte Range wiederherstellen
- new_ip_dhcprange($oldrange,$dhcpDN[$i],$auDN[$i]);
- }
- }else{echo "falsche IP Syntax<br>";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_dhcp.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- else{
- $mesg = "keine Aenderung<br>";
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_dhcp.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
-}
-
-echo "
-</td></tr></table>
-</head>
-</html>";
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_footer.inc.php b/ldap-site-mngmt/webinterface/ip/ip_footer.inc.php
deleted file mode 100644
index 7849823e..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_footer.inc.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?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("IPBLOCKS", "IPBlocks");
-$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/ip/ip_header.inc.php b/ldap-site-mngmt/webinterface/ip/ip_header.inc.php
deleted file mode 100644
index a07c513e..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_header.inc.php
+++ /dev/null
@@ -1,31 +0,0 @@
-<?php
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "IP Address Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-
-
-$template = new FastTemplate(".");
-
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$definedTemplates = array("Vorlage" => "ip.dwt",
- "Login" => "../logout_form.inc.dwt",
- "Mmenu" => "../hauptmenue.dwt",
- "Menu" => "menu.dwt",
- "IPBlocks" => "ipblocks.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));
-
-
-include("ip_menu.php");
-include("ip_blocks.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_menu.php b/ldap-site-mngmt/webinterface/ip/ip_menu.php
deleted file mode 100644
index 8b1ebd4c..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_menu.php
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-
-function createIPMenu($rollen , $mnr) {
- global $template;
- global $START_PATH;
- global $auDN;
-
- $mipb_array = get_maxipblocks_au($auDN);
- #print_r($mipb_array);
- if ( $mipb_array[0] == "" ){
- $iprechnerlink = "no_ip.php?mnr=1";
- $ipdhcplink = "no_ip.php?mnr=2";
- $ipdeleglink = "no_ip.php?mnr=3";
- }else{
- $iprechnerlink = "ip_rechner.php";
- $ipdhcplink = "ip_dhcp.php";
- $ipdeleglink = "ip_deleg.php";
- }
- # Struktur der Registerkartenleiste
- $hauptmenu = array(array("link" => "ip.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => "alle"),
- array("link" => $iprechnerlink,
- "text" => "IP Adressen Rechner",
- "zugriff" => array("MainAdmin","DhcpAdmin","HostAdmin")),
- #array("link" => $ipdhcplink,
- # "text" => "IP Adressen DHCP",
- # "zugriff" => array("MainAdmin","HostAdmin","DhcpAdmin")),
- array("link" => $ipdeleglink,
- "text" => "Delegierte IP Bereiche",
- "zugriff" => array("MainAdmin")));
-
- # $rollen = array_keys($roles);
-
- # Zusammenstellen der Menuleiste
- $template->define_dynamic("Hauptmenu", "Menu");
- $i=0;
- foreach($hauptmenu as $item) {
- if($item['zugriff'] === "alle" || vergleicheArrays($rollen , $item['zugriff'])) {
- if ($i==0) {
- if ($mnr==0) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $zwisch="";
- $farb="#A0A0A0";
- $lastaktive=false;
- }
- }
- else {
- if ($mnr==$i) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $farb="#A0A0A0";
- if ($lastaktive) {$zwisch="";}
- else {$zwisch="";}
- $lastaktive=false;
- }
- }
- $template->assign(array("ZWISCHEN" => $zwisch,
- "FARBE" => $farb,
- "LINK_M" => $item["link"],
- "TEXT_M" => $item["text"]));
- $template->parse("HAUPTMENU_LIST", ".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/ip/ip_rechner.dwt b/ldap-site-mngmt/webinterface/ip/ip_rechner.dwt
deleted file mode 100644
index b300e88e..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_rechner.dwt
+++ /dev/null
@@ -1,40 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Folgende IP Adressen haben Sie an Rechner vergeben: </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='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Rechner Name</b></td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>IP Adresse</b></td>
- <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>DHCP</b></td>
- </tr>
-
- <form action='ip_rechner_change.php' method='post'>
-
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{HOSTNAME} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='newip[]' value='{IP}' size='15' class='medium_form_field'></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'> {DHCPCONT} &nbsp;</td>
- </tr>
- <input type='hidden' name='oldip[]' value='{OLDIP}'>
- <input type='hidden' name='hostdn[]' value='{HOSTDN}'>
- <input type='hidden' name='fixadd[]' value='{FIXADD}'>
- <input type='hidden' name='audn[]' value='{AUDN}'>
-
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- </table></td>
- </tr>
- <tr>
- <td>
- <input type='Submit' name='apply' value='anwenden' class='small_loginform_button'></form>
- </td>
- </tr>
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ip_rechner.php b/ldap-site-mngmt/webinterface/ip/ip_rechner.php
deleted file mode 100644
index e49c6a40..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_rechner.php
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "IP Address Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-$mnr = 1;
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "ip_rechner.dwt";
-
-include("../class.FastTemplate.php");
-
-include("ip_header.inc.php");
-
-#############################################################################
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createIPMenu($rollen, $mnr);
-
-include("ip_blocks.inc.php");
-
-#############################################################################
-
-$template->assign(array("IP" => "",
- "OLDIP" => "",
- "DHCPCONT" => "",
- "FIXADD" => "",
- "HOSTNAME" => "Noch keine Rechner angelegt",
- "HOSTDN" => ""));
-
-$host_array = get_hosts($auDN,array("dn","hostname","ipaddress","dhcphlpcont","dhcpoptfixed-address"));
-# print_r ($host_array);
-
-$template->define_dynamic("Hosts", "Webseite");
-
-foreach ($host_array as $host){
- $hostip = explode('_',$host['ipaddress']);
-
- $dhcpcont = "";
- $fixadd = "";
- if ( count($host['dhcphlpcont']) != 0 && $host['ipaddress'] == "" ){
- #$subnetCN = explode('cn=',$host['dhcphlpcont']);
- #$dynsubnet = explode(',', $subnetCN[1]);
- #$dhcpcont = " DYNAMISCH &nbsp;&nbsp;(DHCP, Subnet $dynsubnet[0])";
- $dhcpcont = " dynamisch";
- $fixadd = $host['dhcpoptfixed-address'];
- }elseif( count($host['dhcphlpcont']) != 0 && $host['ipaddress'] != "" ){
- #$subnetCN = explode('cn=',$host['dhcphlpcont']);
- #$dynsubnet = explode(',', $subnetCN[1]);
- #$dhcpcont = " STATISCH &nbsp;&nbsp;(DHCP, Subnet $dynsubnet[0])";
- if ( $host['dhcpoptfixed-address'] == "ip") {
- $dhcpcont = " fix";
- $fixadd = $host['dhcpoptfixed-address'];
- }
- if ( $host['dhcpoptfixed-address'] == "hostname") {
- $dhcpcont = " fix (&uuml;ber DNS Name)";
- $fixadd = $host['dhcpoptfixed-address'];
- }
- }
-
- $template->assign(array("IP" => $hostip[0],
- "OLDIP" => $hostip[0],
- "DHCPCONT" => $dhcpcont,
- "FIXADD" => $fixadd,
- "HOSTNAME" => $host['hostname'],
- "HOSTDN" => $host['dn'],
- "AUDN" => $auDN ));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-
-
-#####################################################################################
-
-include("ip_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/ip/ip_rechner_change.php b/ldap-site-mngmt/webinterface/ip/ip_rechner_change.php
deleted file mode 100644
index 4db8bed0..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_rechner_change.php
+++ /dev/null
@@ -1,122 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-$hostDN = $_POST['hostdn'];
-$oldip = $_POST['oldip'];
-$newip = $_POST['newip'];
-$fixadd = $_POST['fixadd'];
-
-$syntax = new Syntaxcheck;
-$url = "ip_rechner.php";
-
-echo "
-<html>
-<head>
- <title>IP Address Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-
-$diff1 = array_keys(array_diff_assoc($oldip,$newip));
-$diff2 = array_keys(array_diff_assoc($newip,$oldip));
-$tochange = array_unique(array_merge($diff1,$diff2));
-
-foreach ($tochange as $i){
-
- if ( $oldip[$i] == "" && $newip[$i] != "" ){
- echo "neue IP";echo "<br>";echo "<br>";
- echo "<br>";
- echo "alte IP: ";print_r($oldip[$i]);echo "<br>";
- echo "neue IP: ";print_r($newip[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newip[$i])){
- echo "korrekte IP Syntax";
- $newip[$i] = htmlentities($newip[$i]);
- $newip_array = array($newip[$i],$newip[$i]);
- #print_r($newip_array);
- $newipp = implode('_',$newip_array);
- #print_r($newipp);
- $oldip[$i] = htmlentities($oldip[$i]);
- if (new_ip_host($newipp,$hostDN[$i],$auDN)){
- $mesg = "Neue IP Adresse eingetragen<br>";
- # falls Rechner in DHCP -> fixed-address auf IP Setzen...
- # und update_dhcpmtime(array());
- }else{$mesg = "Fehler beim eintragen der neuen IP Adresse<br>";}
- }else{echo "falsche IP Syntax";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldip[$i] != "" && $newip[$i] != "" ){
- echo "aendern IP";echo "<br>";echo "<br>";
- echo "<br>";
- echo "alte IP: ";print_r($oldip[$i]);echo "<br>";
- echo "neue IP: ";print_r($newip[$i]);echo "<br>";
-
- if ($syntax->check_ip_syntax($newip[$i])){
- echo "korrekte IP Syntax";
- $newip[$i] = htmlentities($newip[$i]);
- $newip_array = array($newip[$i],$newip[$i]);
- #print_r($newip_array);
- $newipp = implode('_',$newip_array);
- #print_r($newipp);
- $oldip[$i] = htmlentities($oldip[$i]);
- $oldip_array = array($oldip[$i],$oldip[$i]);
- $oldipp = implode('_',$oldip_array);
- if (modify_ip_host($newipp,$hostDN[$i],$auDN,$fixadd[$i])){
- $mesg = "IP Adresse geaendert<br>";
- adjust_hostip_tftpserverip($oldip[$i],$newip[$i]);
- # Falls Rechner in DHCP
- update_dhcpmtime(array());
- }else{
- $mesg = "Fehler beim aendern der IP Adresse<br>";
- # oldip die schon gelöscht wurde wieder einfügen
- new_ip_host($oldipp,$hostDN[$i],$auDN);}
- }else{echo "falsche IP Syntax";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- elseif ( $oldip[$i] != "" && $newip[$i] == "" ){
- echo "loeschen IP";echo "<br>";echo "<br>";
- echo "<br>";
- echo "alte IP: ";print_r($oldip[$i]);echo "<br>";
- echo "neue IP: ";print_r($newip[$i]);echo "<br>";
-
- echo "korrekte IP Syntax";
- $newip[$i] = htmlentities($newip[$i]);
- $oldip[$i] = htmlentities($oldip[$i]);
- if (delete_ip_host($hostDN[$i],$auDN)){
- $mesg = "IP Adresse geloescht<br>";
- adjust_hostip_tftpserverip($oldip[$i],"");
- # falls Rechner in DHCP -> fixed-address auf dynamic/Hostname setzen
- update_dhcpmtime(array());
- }else{$mesg = "Fehler beim loeschen der IP Adresse<br>";}
-
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(4, $url, $mesg, $addSessionId = TRUE);
- }
-
- else{
- $mesg = "keine Aenderung<br>";
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='ip_rechner.php' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
- }
-
-}
-
-echo "
-</td></tr></table>
-</head>
-</html>";
-?>
diff --git a/ldap-site-mngmt/webinterface/ip/ip_start.dwt b/ldap-site-mngmt/webinterface/ip/ip_start.dwt
deleted file mode 100644
index 2b451f4e..00000000
--- a/ldap-site-mngmt/webinterface/ip/ip_start.dwt
+++ /dev/null
@@ -1,36 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - IP Adress Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung von IP Adressen in ihrer Abteilung.
- Benutzen Sie die Navigation links, um die einzelnen Bereiche anzusteuern. <br>
- Unterhalb des Navigations-Menue haben Sie stets einen Ueberblick ueber die Ihnen
- zugewiesenen IP Bereiche sowie ueber die davon noch frei verfuegbaren IP Adressen.</p>
- <p> Folgende Bereiche stehen Ihnen zur Verfuegung:</p>
-
- <ul>
- <li><p><b>IP Adressen Rechner</b></p>
- Hier koennen Sie die IP Adressen ihrer Rechner verwalten. Sie koennen IP Adressen neu zuweisen,
- aendern oder loeschen.
- </li>
- <!-- <li><p><b>IP Adressen DHCP</b></p>
- In diesem Bereich koennen Sie die IP Adressen verwalten, die Sie fuer den DHCP Dienst reservieren.
- D.h. die IP Adress Ranges, welche Sie DHCP Subnetzen oder Pools zugewiesen haben zur dynamischen
- IP Adresszuweisung.
- </li> -->
- <li><p><b>Delegierte IP Adressen</b></p>
- In diesem Bereich verwalten Sie ihre an untergeordnete Abteilungen delegierten
- IP Adressbereiche. Sie koennen neue IP Bereiche delegieren, Delegierungen aendern oder
- ganz zureucknehmen (loeschen).
- </li>
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/ipblocks.dwt b/ldap-site-mngmt/webinterface/ip/ipblocks.dwt
deleted file mode 100644
index b77f53b3..00000000
--- a/ldap-site-mngmt/webinterface/ip/ipblocks.dwt
+++ /dev/null
@@ -1,11 +0,0 @@
-<table cellpadding='5' cellspacing='0' border='1' width='100%' style='border-width: 0 0 0 0;'>
-
- <tr align='left'>
- <td width='8%'></td>
- <td width='82%' style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>{IPBLOCKS}</td>
- <td width='10%'></td>
-
- </tr>
- <tr height='5'></tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/menu.dwt b/ldap-site-mngmt/webinterface/ip/menu.dwt
deleted file mode 100644
index 34b227c1..00000000
--- a/ldap-site-mngmt/webinterface/ip/menu.dwt
+++ /dev/null
@@ -1,22 +0,0 @@
-
-<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;"></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>
-
- <tr height='5'>
- </tr>
-
-<!-- END DYNAMIC BLOCK: Hauptmenu -->
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/ip/no_ip.dwt b/ldap-site-mngmt/webinterface/ip/no_ip.dwt
deleted file mode 100644
index 5bc09796..00000000
--- a/ldap-site-mngmt/webinterface/ip/no_ip.dwt
+++ /dev/null
@@ -1,11 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Diese Funktion steht Ihnen nicht zur Verf&uuml;gung. </h3>
- Sie verf&uuml;gen &uuml;ber keine IP Adressen, die Sie an Rechner, DHCP Subnetze vergeben,
- bzw. an untergeordnete AUs delegieren k&ouml;nnen.</td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/ip/no_ip.php b/ldap-site-mngmt/webinterface/ip/no_ip.php
deleted file mode 100644
index 51a4b030..00000000
--- a/ldap-site-mngmt/webinterface/ip/no_ip.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "no_ip.dwt";
-
-include("ip_header.inc.php");
-
-###############################################################################
-
-$mnr = 1;
-
-$mnr = $_GET['mnr'];
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createIPMenu($rollen, $mnr);
-
-###############################################################################
-
-###############################################################################
-
-include("ip_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/lib/au_management_functions.php b/ldap-site-mngmt/webinterface/lib/au_management_functions.php
deleted file mode 100644
index d924aec0..00000000
--- a/ldap-site-mngmt/webinterface/lib/au_management_functions.php
+++ /dev/null
@@ -1,1333 +0,0 @@
-<?php
-
-/**
-* au_management_functions.php - Administrative Unit Management Funktions-Bibliothek
-* Diese Bibliothek enthält alle Funktionen für die Verwaltung von AUs, deren DNS Domains, sowie
-* zum Rollen-Management
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Tarik Gasmi
-* @copyright Tarik Gasmi
-*/
-
-# Konfiguration laden
-require_once("config.inc.php");
-
-$ldapError = null;
-
-########################################################################################################
-
-
-
-###############################################################################
-# Funktionen zur Verwaltung der AU (und Child-AUs)
-#
-
-
-# Ändern des DN der AU, d.h. beim Ändern des Attributes 'ou'
-function modify_au_dn($auDN, $newauDN){
-
- global $ds, $suffix, $ldapError;
-
- if (move_subtree($auDN,$newauDN)){
- adjust_dn_entries($auDN,$newauDN);}
-}
-
-
-
-# Anlegen neue untergeordnete AU
-function new_childau($childDN,$childou,$childcn,$childdesc,$mainadmin){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $entryAU ["objectclass"][0] = "administrativeunit";
- $entryAU ["objectclass"][1] = "organizationalunit";
- $entryAU ["objectclass"][2] = "top";
- $entryAU ["ou"] = $childou;
- $entryAU ["dhcpmtime"] = 0;
- if ($childcn != ""){$entryAU ["cn"] = $childcn;}
- if ($childdesc != ""){$entryAU ["description"] = $childdesc;}
-
- if ($resultAU = ldap_add($ds,$childDN,$entryAU)){
-
- # alle Au Container anlegen
- $containers = array("computers","dhcp","groups","pxe","rbs","roles");
- foreach ($containers as $cont){
- $entryCont = array();
- $entryCont ['objectclass'] = "AUContainer";
- $entryCont ['cn'] = $cont;
- #print_r($entryRolesCont); echo "<br><br>";
- $resultC = ldap_add($ds,"cn=".$cont.",".$childDN,$entryCont);
- if (!($resultC)) break;
- }
-
- # MainAdmin anlegen
- $entryMA ['objectclass'] = "groupOfNames";
- $entryMA ['cn'] = "MainAdmin";
- $entryMA ['member'] = $mainadmin;
- if ($resultMA = ldap_add($ds,"cn=MainAdmin,cn=roles,".$childDN,$entryMA)){
- #$admins = array("HostAdmin","DhcpAdmin","ZoneAdmin");
- #foreach ($admins as $admin){
- # $entryAdmin ['objectclass'] = "Admins";
- # $entryAdmin ['cn'] = $admin;
- # ldap_add($ds,"cn=".$admin.",cn=roles,".$childDN,$entryAdmin);
- #}
- return 1;
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
-}
-
-
-
-# Löschen untergeordnete AU (d.h. deren untergeordnete AUs werden als neue uAUs integriert)
-function delete_childau($childDN,$childou,$delmodus){
-
- global $ds, $suffix, $auDN, $domDN, $assocdom, $ldapError;
-
- if ( $delmodus == "integrate"){
-
- # Associated DNS Domain integrieren
- $childdc = get_domain_data($childDN,array("dn","associatedname"));
- print_r($childdc); echo "<br>";
- # wenn einzige AU dann einfach in Parentdomain aufnehmen und betroffene Einträge löschen
- if (count($childdc[0]['associatedname']) == 1 ){
- echo "einzige AU<br>";
- # dc Childs verschieben
- $dcchilds = get_dc_childs($childdc[0]['dn'],array("dn","dc"));
- # print_r($dcchilds); echo "<br>";
- if (count($dcchilds) != 0){
- foreach ($dcchilds as $dcc){
- # print_r($dcc['dn']); echo " >> "; print_r("dc=".$dcc['dc'].",".$domDN); echo "<br>";
- if(move_subtree($dcc['dn'],"dc=".$dcc['dc'].",".$domDN)){
- $newdom = $dcc['dc'].".".$assocdom;
- #print_r($newdom); echo "<br><br>";
- dive_into_dctree_adapt("dc=".$dcc['dc'].",".$domDN,$newdom);
- }
- }
- }
-
- # alten dc-Knoten löschen
- dive_into_tree_del($childdc[0]['dn'],"");
-
- }
- # wenn noch andere AUs in der Domain, dann nur betroffene Einträge entfernen
- if (count($childdc[0]['associatedname']) > 1 ){
- echo "mehrere AUs<br>";
- # ChildAU-Rollen unterhalb dc-Knoten löschen (nur diese)(oder übernehmen: MA zu HA, HA zu HA)
- $roles = get_roles($childDN);
- #print_r($roles); echo "<br>";
-
- # was ist wenn rollen nur noch ein member haben ... fehler
- if(count($roles['MainAdmin']) != 0){
- $mainadmins = $roles['MainAdmin'];
- for ($i=0; $i<count($mainadmins); $i++){
- $entryRoleMain ['member'][$i] = $mainadmins[$i];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultMA = ldap_mod_del($ds,"cn=MainAdmin,cn=roles,".$childdc[0]['dn'],$entryRoleMain);
- }
- if(count($roles['HostAdmin']) != 0){
- $hostadmins = $roles['HostAdmin'];
- for ($i=0; $i<count($hostadmins); $i++){
- $entryRoleHost ['member'][$i] = $hostadmins[$i];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultHA = ldap_mod_del($ds,"cn=HostAdmin,cn=roles,".$childdc[0]['dn'],$entryRoleHost);
- }
- if(count($roles['ZoneAdmin']) != 0){
- $zoneadmins = $roles['ZoneAdmin'];
- for ($i=0; $i<count($zoneadmins); $i++){
- $entryRoleZone ['member'][$i] = $zoneadmins[$i];
- }
- $resultZA = ldap_mod_del($ds,"cn=ZoneAdmin,cn=roles,".$childdc[0]['dn'],$entryRoleZone);
- }
-
- $entrydel ['associatedname'] = $childDN;
- # print_r($entrydel); echo "<br>";
- ldap_mod_del($ds, $childdc[0]['dn'], $entrydel);
- $zentries = get_zone_entries_assocname($childdc[0]['dn'],array("dn"),$childDN);
- # print_r($zentries); echo "<br>";
- foreach ($zentries as $ze){
- # print_r($ze['dn']); echo "<br>";
- ldap_delete($ds, $ze['dn']);
- }
- }
-
- # Rechner (mit IP) + dranhängende MCs, PXEs verschieben
- $hosts = get_hosts($childDN,array("dn","hostname"));
- if (count($hosts) != 0){
- foreach ($hosts as $host){
- # print_r($host['dn']); echo "<br>";
- # print_r($host['hostname']); echo "<br>";
- # print_r("hostname=".$host['hostname']."-int-".$childou.",cn=computers,".$auDN); echo "<br><br>";
- if (move_subtree($host['dn'], "hostname=".$host['hostname']."-ex-".$childou.",cn=computers,".$auDN)){
- $newhostDN = "hostname=".$host['hostname']."-ex-".$childou.",cn=computers,".$auDN;
- $dhcp = get_node_data($newhostDN, array("dhcphlpcont"));
- # print_r($dhcp); echo "<br>";
- if ($dhcp['dhcphlpcont'] != ""){
- $entrydel ['dhcphlpcont'] = array();
- $entrydel ['objectclass'] = "dhcpHost";
- # print_r($dhcphlpcont);
- ldap_mod_del($ds, $newhostDN, $entrydel);
- }
- }
- }
- }
- # DHCP Objekte IP Ranges löschen
- $subnets = get_subnets($childDN,array("dn"));
- # print_r($subnets); echo "<br>";
- if (count($subnets) != 0){
- foreach ($subnets as $subnet){
- # print_r($subnet['dn']); echo "<br>";
- delete_ip_dhcprange($subnet['dn'],$childDN);
- }
- } # DHCP Pools auch noch
-
- # Freie IP Bereiche zurücknehmen
- $fipb_array = get_freeipblocks_au($childDN);
- # print_r($fipb_array); echo "<br>";
- # print_r(count($fipb_array)); echo "<br>";
- if (count($fipb_array) == 1 && $fipb_array[0] != ""){
- $entry_ipblock ['freeipblock'] = $fipb_array[0];
- # print_r($entry_ipblock); echo "<br>";
- ldap_mod_add($ds,$auDN,$entry_ipblock);
- }
- if (count($fipb_array) > 1 ){
- foreach ($fipb_array as $fipb){
- $entry_ipblock ['FreeIPBlock'][] = $fipb;
- # print_r($entry_ipblock); echo "<br>";
- ldap_mod_add($ds,$auDN,$entry_ipblock);
- }
- }
- merge_ipranges($auDN);
-
-
- # Verschieben der Childs an neue Stelle
- $child_childs = get_childau($childDN,array("dn","ou"));
- # print_r($child_childs); echo "<br>";
- if (count($child_childs) != 0){
- foreach ($child_childs as $cc){
- $child_childDN = $cc['dn'];
- $newccDN = "ou=".$cc['ou'].",".$auDN;
- # print_r($child_childDN); echo " >> ";
- # print_r($newccDN); echo "<br>";
- if (move_subtree($child_childDN,$newccDN)){
- adjust_dn_entries($child_childDN,$newccDN);
- }
- }
- }
-
- # Löschen des AU Knotens
- dive_into_tree_del($childDN,"");
-
- $mesg = "<br>Erfolgreich gel&ouml;scht mit Integration<br>";
- return $mesg;
- }
-
- if ( $delmodus == "complete" ){
- # IP Bereiche zurück
- # DNS Teilbaum Objekte löschen
- # alles rekursive löschen
-
- /*if (dive_into_tree_del($dcDN,"")){
- $delentry ['objectclass'] = "domainrelatedobject";
- $delentry ['associateddomain'] = $domsuffix;
- #print_r($delentry); echo "<br>";
- $delresult = ldap_mod_del($ds,$childDN,$delentry);
- if ($delresult){
- $mesg = "Domain komplett gel&ouml;scht<br>";
- }else{$mesg = "Fehler! ldap_mod_del<br>";}
- }else{$mesg = "Fehler! dive_into_tree_del<br>";}
- */
- $mesg = "Komplettes l&ouml;schen mometan noch nicht unterst&uuml;tzt.<br>
- Nur eine Ebene mit Integration ...<br>";
- return $mesg;
- }
-}
-
-
-
-
-###############################################################################
-# Funktionen zur Verwaltung von Domains
-#
-
-
-# Anlegen Domain beim Anlegen einer Child-AU
-function new_child_domain($childdomain, $childDN, $assocdom, $domDN){
-
- global $ds, $suffix, $domprefix, $domsuffix, $ldapError;
- $domsuffix_actual = $domsuffix;
-
- # ChildAU in gleicher Domain wie AU
- if ( $childdomain == "" || $childdomain == $domprefix ){
-
- $entryDC ["associatedname"] = $childDN;
- $resultDC = ldap_mod_add($ds,$domDN,$entryDC);
- if ($resultDC){
- # HostAdmins übernehmen, welche Admins noch? MainAdmin?
- $roles = get_roles($childDN);
- if(count($roles['MainAdmin']) != 0){
- $mainadmins = $roles['MainAdmin'];
- for ($i=0; $i<count($mainadmins); $i++){
- $entryRoleMain ['member'][$i] = $mainadmins[$i];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultMA = ldap_mod_add($ds,"cn=MainAdmin,cn=roles,".$domDN,$entryRoleMain);
- }
- #if(count($roles['HostAdmin']) != 0){
- # $dnsroles = get_roles($domDN);
- # ...
- # $hostadmins = $roles['HostAdmin'];
- # for ($i=0; $i<count($hostadmins); $i++){
- # $entryRoleHost ['member'][$i] = $hostadmins[$i];
- # }
- # #print_r($entryRoleHost); echo "<br>";
- # $resultHA = ldap_mod_add($ds,"cn=HostAdmin,cn=roles,".$domDN,$entryRoleHost);
- #}
- # Domainname zu associatedDomain der ChildAU
- $entryAD['objectclass'] = "domainRelatedObject";
- $entryAD['associateddomain'] = $assocdom;
- $resultAD = ldap_mod_add($ds,$childDN,$entryAD);
- if($resultAD){return 1;}else{return 0;}
- }
- else{return 0;}
- }
-
- # ChildAU in eigner Domain (inklusive Subdomain von AU Domain)
- if ( $childdomain != "" && $childdomain != $domprefix ){
-
- # entsprechenden DC Knoten anlegen, sowie Roles (MainAdmin, HostAdmin)
- $dc_array = explode('.',$childdomain);
- $dc_array = array_reverse($dc_array);
- $dcDN = "ou=DNS,".$suffix;
- # $childdomainfull = $childdomain.".".$domsuffix;
- #print_r($dc_array);
- foreach ($dc_array as $dc){
- $resultsum = false;
- if (check_for_dc($dcDN,$dc)){
- echo "dc <b>".$dc."</b> schon vorhanden ... n&auml;chster dc<br>";
- $domsuffix_actual = $dc.".".$domsuffix_actual;
- $dcDN = "dc=".$dc.",".$dcDN;
- }
- else{
- $dcDN = "dc=".$dc.",".$dcDN;
-
- $entryDC ["objectclass"][0] = "dnsdomain";
- $entryDC ["objectclass"][1] = "domainrelatedobject";
- $entryDC ["objectclass"][2] = "top";
- $entryDC ["dc"] = $dc;
- $entryDC ["associatedname"] = $childDN;
- $entryDC ["associateddomain"] = $dc.".".$domsuffix_actual;
- #print_r($entryDC); echo "<br>";
- #print_r($dcDN); echo "<br><br>";
- $resultDC = ldap_add($ds,$dcDN,$entryDC);
- if ($resultDC){
- $domsuffix_actual = $dc.".".$domsuffix_actual;
-
- #print_r($dcDN); echo"<br><br>";
-
- $entryRolesCont ['objectclass'] = "AUContainer";
- $entryRolesCont ['cn'] = "roles";
- #print_r($entryRolesCont); echo "<br><br>";
- $resultRC = ldap_add($ds,"cn=roles,".$dcDN,$entryRolesCont);
- if ($resultRC){
- # Rollen eintragen
- $roles = get_roles($childDN);
- #print_r($roles); echo "<br><br>";
- $mainadmins = $roles['MainAdmin'];
- $entryRoleMain ['objectclass'] = "groupOfNames";
- $entryRoleMain ['cn'] = "MainAdmin";
- for ($i=0; $i<count($mainadmins); $i++){
- $entryRoleMain ['member'][$i] = $mainadmins[$i];
- }
- #print_r($entryRoleMain); echo "<br>";
- $resultMA = ldap_add($ds,"cn=MainAdmin,cn=roles,".$dcDN,$entryRoleMain);
-
- if(count($roles['HostAdmin']) != 0){
- $entryRoleHost ['objectclass'] = "groupOfNames";
- $entryRoleHost ['cn'] = "HostAdmin";
- $hostadmins = $roles['HostAdmin'];
- for ($i=0; $i<count($hostadmins); $i++){
- $entryRoleHost ['member'][$i] = $hostadmins[$i];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultHA = ldap_add($ds,"cn=HostAdmin,cn=roles,".$dcDN,$entryRoleHost);
- }
-
- #$entryRoleZone ['objectclass'] = "Admins";
- #$entryRoleZone ['cn'] = "ZoneAdmin";
- #$resultZA = ldap_add($ds,"cn=ZoneAdmin,cn=roles,".$dcDN,$entryRoleZone);
-
- if ($resultMA){$resultsum = true;}
- }
- }
- break; # damit dc-Zuwachs immer nur um eine neue Ebene moeglich
- }
- }
- # Domainname zu associatedDomain der ChildAU
- if ($resultsum == true){
- $entryAD['objectclass'] = "domainRelatedObject";
- $entryAD['associateddomain'] = $domsuffix_actual;
- $resultAD = ldap_mod_add($ds,$childDN,$entryAD);
- }
- # fixme: fehlt noch anlegen der INCLUDE-Direktive in der parentdomain
- if($resultAD){return 1;}
- else{return 0;}
- }
-}
-
-
-# Domain einer Child-AU ändern
-function change_child_domain($childdomain, $oldchilddomain, $childDN, $assocdom, $domDN, $domprefix){
-
- global $ds, $suffix, $domsuffix, $ldapError;
- #print_r($oldchilddomain); echo "<br>";
- #print_r($domprefix); echo "<br>";
- # dcDNnew
- $dcDN = "ou=DNS,".$suffix;
- $dc_array = explode('.',$childdomain);
- $dc_array = array_reverse($dc_array);
- $dcDNnew = "";
- foreach ($dc_array as $dc){
- if (check_for_dc($dcDN,$dc)){
- $dcDN = "dc=".$dc.",".$dcDN;
- }
- else{
- $dcDN = "dc=".$dc.",".$dcDN;
- $dcDNnew .= $dcDN;
- break;
- }
- }
- # dcDNold
- $dcDNold = "ou=DNS,".$suffix;
- $dcold_array = explode('.',$oldchilddomain);
- $dcold_array = array_reverse($dcold_array);
- foreach ($dcold_array as $dc){
- $dcDNold = "dc=".$dc.",".$dcDNold;
- }
-
- #print_r($dcDNnew); echo "<br>";
- #print_r($dcDNold); echo "<br>";
- # Aus eigener AU Domain heraus in neue nicht AU Domain, d.h. dcDNold = domDN
- # Subdomain oder neue Domain anlegen
- if ($oldchilddomain == $domprefix){
-
- # associatedDomain aus ChildAU entfernen
- $entryAD['objectclass'] = "domainRelatedObject";
- $entryAD['associateddomain'] = $assocdom;
- #print_r($entryAD); echo "<br>";
- if ($resultAD = ldap_mod_del($ds,$childDN,$entryAD)){
-
- # neuen dc Knoten anlegen mit Rollen ...
- if(new_child_domain($childdomain, $childDN, $assocdom, $domDN)){
-
- # associatedName ChildDN aus altem dc-Knoten entfernen
- $entryAN ['associatedname'] = $childDN;
- #print_r($entryAN); echo "<br>";
- $result = ldap_mod_del($ds,$domDN,$entryAN);
-
- # Eigene Rollen aus dc-Knoten entfernen
- $roles = get_roles($childDN);
- if(count($roles['MainAdmin']) != 0){
- $mainadmins = $roles['MainAdmin'];
- if (count($mainadmins) > 1){
- for ($i=0; $i<count($mainadmins); $i++){
- $entryRoleMain ['member'][$i] = $mainadmins[$i];
- }
- }else{
- $entryRoleMain ['member'] = $mainadmins[0];
- }
- #print_r($entryRoleMain); echo "<br>";
- $resultMA = ldap_mod_del($ds,"cn=MainAdmin,cn=roles,".$dcDNold,$entryRoleMain);
- }
- if(count($roles['HostAdmin']) != 0){
- $hostadmins = $roles['HostAdmin'];
- if (count($hostadmins) > 1){
- for ($i=0; $i<count($hostadmins); $i++){
- $entryRoleHost ['member'][$i] = $hostadmins[$i];
- }
- }else{
- $entryRoleHost ['member'] = $hostadmins[0];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultHA = ldap_mod_del($ds,"cn=HostAdmin,cn=roles,".$dcDNold,$entryRoleHost);
- }
- if(count($roles['ZoneAdmin']) != 0){
- $zoneadmins = $roles['ZoneAdmin'];
- if (count($zoneadmins) > 1){
- for ($i=0; $i<count($zoneadmins); $i++){
- $entryRoleZone ['member'][$i] = $zoneadmins[$i];
- }
- }else{
- $entryRoleZone ['member'] = $zoneadmins[0];
- }
- #print_r($entryRoleZone); echo "<br>";
- $resultZA = ldap_mod_del($ds,"cn=ZoneAdmin,cn=roles,".$dcDNold,$entryRoleZone);
- }
-
-
- # DNS Einträge mit associatedName ChildDN verschieben
- $zone_entries = get_zone_entries_assocname($domDN,array("dn","relativedomainname"),$childDN);
- #echo "<br>"; print_r($zone_entries); echo "<br>";
- if (count($zone_entries) >= 1){
- foreach ($zone_entries as $ze){
- #print_r($ze['relativedomainname']); echo "<br>";
- #print_r($dcDNnew); echo "<br>";
- move_subtree($ze['dn'], "relativedomainname=".$ze['relativedomainname'].",".$dcDNnew);
- $domsuffix = "uni-freiburg.de"; # neu setzen da es beim new_child_domain schon mal hochgezählt wurde
- $newassocdom = $childdomain.".".$domsuffix;
- $entryZE ['zonename'] = $newassocdom;
- #print_r($entryZE); echo "<br>";
- $resultZE = ldap_mod_replace($ds,"relativedomainname=".$ze['relativedomainname'].",".$dcDNnew,$entryZE);
- }
- }
- # fixme: fehlt noch anpassen der INCLUDE-Direktive in der parentdomain
- return 1;
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
- }
- # Aus nicht AU Domain (aber eventuell Subdomain) in nicht AU Domain
- # Verschieben des dc-Teilbaumes
- if ($oldchilddomain != $domprefix){
- # Verschiebe dc-Baum von dcDNold nach dcDNnew
- # dcDNnew
- $dcDN = "ou=DNS,".$suffix;
- $dc_array = explode('.',$childdomain);
- $dc_array = array_reverse($dc_array);
- $dcDNnew = "";
- foreach ($dc_array as $dc){
- if (check_for_dc($dcDN,$dc)){
- $dcDN = "dc=".$dc.",".$dcDN;
- }
- else{
- $dcDN = "dc=".$dc.",".$dcDN;
- $dcDNnew .= $dcDN;
- break;
- }
- }
-
- # dcDNold
- $dcDNold = "ou=DNS,".$suffix;
- $dcold_array = explode('.',$oldchilddomain);
- $dcold_array = array_reverse($dcold_array);
- foreach ($dcold_array as $dc){
- $dcDNold = "dc=".$dc.",".$dcDNold;
- }
-
- # dc Baum verschieben
- if ($dcDNnew != ""){
- if (move_subtree($dcDNold, $dcDNnew)){
- # rekursives anpassen im neue dc-Baum:
- # associatedDomain, zoneName, includeFilename, includeOrigin
- $newassocdom = $childdomain.".".$domsuffix;
- if(dive_into_dctree_adapt($dcDNnew,$newassocdom)){
- return 1;
- # fixme: fehlt noch anpassen der INCLUDE-Direktive in der parentdomain
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
- }else{
- echo "Domain existiert schon, bitte anderen Domainnamen w&auml;hlen!";
- return 0;
- }
- }
-}
-
-function dive_into_dctree_adapt($dcDNnew,$newassocdom){
-
- global $ds, $suffix, $domprefix, $domsuffix, $ldapError;
- print_r($dcDNnew); echo "<br>";
- print_r($newassocdom); echo "<br><br>";
-
- # associatedDomain in dc-Knoten und in allen (mehrere) associatedName-ou-Knoten
- $entryAD['associateddomain'] = $newassocdom;
- print_r($entryAD); echo "<br>";
- $resultAD = ldap_mod_replace($ds,$dcDNnew,$entryAD);
- #$top_dcDN = str_replace("ou=DNS,","",$dcDNnew);
- #print_r($top_dcDN); echo "<br>";
- $assocnames = get_dc_data($dcDNnew,array("associatedname")); # funkt nicht bei uni-freiburg.de
- echo "<br>"; print_r($assocnames); echo "<br>";
- if (count($assocnames['associatedname']) > 1){
- foreach ($assocnames['associatedname'] as $aname){
- print_r($aname); echo "<br>";
- $resultAU = ldap_mod_replace($ds,$aname,$entryAD);
- }
- }else{
- $aname = $assocnames['associatedname'];
- print_r($aname); echo "<br>";
- $resultAU = ldap_mod_replace($ds,$aname,$entryAD);
- }
-
- # ZoneName in allen Knoten eine Ebene tiefer
- $zone_entries = get_zone_entries($dcDNnew,array("dn","zonename"));
- echo "<br>"; print_r($zone_entries); echo "<br>";
- foreach ($zone_entries as $ze){
- $entryZE ['zonename'] = $newassocdom;
- print_r($entryZE); echo "<br>";
- $resultZE = ldap_mod_replace($ds,$ze['dn'],$entryZE);
- }
-
- # Zonenamen in Reversezones ... Fehlt noch
-
- # Rekursion
- # child dc für Rekursion
- $dcchilds = get_dc_childs($dcDNnew,array("dn","dc"));
- echo "<br>"; print_r($dcchilds); echo "<br>";
- foreach ($dcchilds as $dcc){
- $newassocdom = $dcc['dc'].".".$newassocdom;
- print_r($dcc['dn']); echo " >> "; print_r($newassocdom); echo "<br>";
- dive_into_dctree_adapt($dcc['dn'],$newassocdom);
- }
-
-}
-
-
-function delete_child_domain($oldchilddomain,$assocdom,$childDN, $domDN, $delmodus){
-
- global $ds, $suffix, $domprefix, $domsuffix, $ldapError;
- #print_r($domDN); echo "<br>";
-
- # dcDNold
- $dcDNold = "ou=DNS,".$suffix;
- $dcold_array = explode('.',$oldchilddomain);
- $dcold_array = array_reverse($dcold_array);
- foreach ($dcold_array as $dc){
- $dcDNold = "dc=".$dc.",".$dcDNold;
- }
- #print_r($dcDNold); echo "<br>";
- # dcDNnew = domDN
-
- if ( $delmodus == "integrate" ){
-
- # associatedNames zu neuem dc-Knoten hinzufügen
- $assocnames = get_dc_data($dcDNold,array("associatedname")); # funkt nicht bei uni-freiburg.de
- # echo "<br>"; print_r($assocnames); echo "<br>";
- if (count($assocnames['associatedname']) > 1){
- foreach ($assocnames['associatedname'] as $aname){
- #print_r($aname); echo "<br>";
- $entryAN['associatedname'][] = $aname;
- }
- }else{
- $entryAN['associatedname'] = $assocnames['associatedname'];
- $assocname = $assocnames['associatedname'];
- $assocnames ['associatedname'] = array($assocname);
- }
- #print_r($entryAN); echo "<br>";
- $resultAN = ldap_mod_add($ds,$domDN,$entryAN);
- if($resultAN){
-
- # DNS Einträge verschieben und an neue Domain anpassen
- $zone_entries = get_zone_entries($dcDNold,array("dn","relativedomainname"));
- #echo "<br>"; print_r($zone_entries); echo "<br>";
- if (count($zone_entries) >= 1){
- foreach ($zone_entries as $ze){
- #print_r($ze['relativedomainname']); echo "<br>";
- #print_r($domDN); echo "<br>";
- move_subtree($ze['dn'], "relativedomainname=".$ze['relativedomainname'].",".$domDN);
- $entryZE ['zonename'] = $assocdom;
- print_r($entryZE); echo "<br>";
- $resultZE = ldap_mod_replace($ds,"relativedomainname=".$ze['relativedomainname'].",".$domDN,$entryZE);
- }
- }
-
- # Rollenmembers kopieren für jeden associatedName (ohne Duplikate zu generieren)
- $newdom_roles = get_roles_dns($domDN);
- #print_r($newdom_roles); echo "<br>";
- if (count($newdom_roles['MainAdmin']) != 0){$newmainadmins = $newdom_roles['MainAdmin'];}else{$newmainadmins = array();}
- if (count($newdom_roles['HostAdmin']) != 0){$newhostadmins = $newdom_roles['HostAdmin'];}else{$newhostadmins = array();}
- if (count($newdom_roles['ZoneAdmin']) != 0){$newzoneadmins = $newdom_roles['ZoneAdmin'];}else{$newzoneadmins = array();}
- #print_r($newmainadmins); echo "<br>";
- #print_r($newhostadmins); echo "<br>";
- #print_r($newzoneadmins); echo "<br><br>";
- foreach ($assocnames['associatedname'] as $aname){
- #echo "_________________________________________<br>";
- #print_r($aname); echo "<br>";
- $roles = get_roles($aname);
- #print_r($roles); echo "<br>";
- $mainadmins = $roles['MainAdmin'];
- #print_r($mainadmins); echo "<br>";
- #print_r($newmainadmins); echo "<br>";
- $mainadmins = array_diff($mainadmins, $newmainadmins);
- $mainadmins = array_merge($newmainadmins,$mainadmins);
- #print_r($mainadmins); echo "<br>";
- if (count($mainadmins) > 1){
- for ($i=0; $i<count($mainadmins); $i++){
- $entryRoleMain ['member'][$i] = $mainadmins[$i];
- }
- }else{
- $entryRoleMain ['member'] = $mainadmins[0];
- }
- #print_r($entryRoleMain); echo "<br><br>";
- $resultMA = ldap_mod_replace($ds,"cn=MainAdmin,cn=roles,".$domDN,$entryRoleMain);
-
- if(count($roles['HostAdmin']) != 0){
- $hostadmins = $roles['HostAdmin'];
- #print_r($hostadmins); echo "<br>";
- #print_r($newhostadmins); echo "<br>";
- $hostadmins = array_diff($hostadmins, $newhostadmins);
- $hostadmins = array_merge($newhostadmins,$hostadmins);
- #print_r($hostadmins); echo "<br>";
- if (count($hostadmins) > 1){
- for ($i=0; $i<count($hostadmins); $i++){
- $entryRoleHost ['member'][$i] = $hostadmins[$i];
- }
- }else{
- $entryRoleHost ['member'] = $hostadmins[0];
- }
-
- #print_r($entryRoleHost); echo "<br><br>";
- $resultHA = ldap_mod_replace($ds,"cn=HostAdmin,cn=roles,".$domDN,$entryRoleHost);
-
- }
- if(count($roles['ZoneAdmin']) != 0){
- $zoneadmins = $roles['ZoneAdmin'];
- #print_r($zoneadmins); echo "<br>";
- #print_r($newzoneadmins); echo "<br>";
- $zoneadmins = array_diff($zoneadmins, $newzoneadmins);
- $zoneadmins = array_merge($newzoneadmins,$zoneadmins);
- #print_r($zoneadmins); echo "<br>";
- if (count($zoneadmins) > 1){
- for ($i=0; $i<count($zoneadmins); $i++){
- $entryRoleZone ['member'][$i] = $zoneadmins[$i];
- }
- }else{
- $entryRoleZone ['member'] = $zoneadmins[0];
- }
- #print_r($entryRoleZone); echo "<br><br>";
- $resultZA = ldap_mod_replace($ds,"cn=ZoneAdmin,cn=roles,".$domDN,$entryRoleZone);
-
- }
-
- # associatedDomain anpassen in allen AUs von $assocnames (alt)
- $entryAD ['associateddomain'] = $assocdom;
- #print_r($entryAD); echo "<br>";
- $resultAD = ldap_mod_replace($ds,$aname,$entryAD);
-
- #echo "_________________________________________<br>";
- }
-
- # Falls alter dc-Knoten noch Subdomains, d.h. dc-Teilbäume hat, diese verschieben mit
- # rekursivem Anpassen aller Einträge
- $dcchilds = get_dc_childs($dcDNold,array("dn","dc"));
- #echo "<br><br>"; print_r($dcchilds); echo "<br>";
- if (count($dcchilds) != 0){
- foreach ($dcchilds as $dcc){
- print_r($dcc['dn']); echo " >> "; print_r("dc=".$dcc['dc'].",".$domDN); echo "<br>";
- if(move_subtree($dcc['dn'],"dc=".$dcc['dc'].",".$domDN)){
- $newdom = $dcc['dc'].".".$assocdom;
- #print_r($newdom); echo "<br><br>";
- dive_into_dctree_adapt("dc=".$dcc['dc'].",".$domDN,$newdom);
- }
- }
- }
-
- # alten dc-Knoten entfernen
- dive_into_tree_del($dcDNold,"");
-
- # fixme: fehlt noch löschen der INCLUDE-Direktive in der parentdomain
-
- }
- else{
- return 0;
- }
- }
-
-
- if ( $delmodus == "complete" ){
- # if (dive_into_tree_del($dcDNold,"")){
- $delentry ['objectclass'] = "domainrelatedobject";
- $delentry ['associateddomain'] = $oldchilddomain.".".$domsuffix;
- print_r($delentry); echo "<br>";
- # $delresult = ldap_mod_del($ds,$childDN,$delentry);
- # if ($delresult){
- # $mesg = "Domain komplett gel&ouml;scht<br>";
- # }else{$mesg = "Fehler! ldap_mod_del<br>";}
- # }else{$mesg = "Fehler! dive_into_tree_del<br>";}
- }
-
- # return $mesg;
-}
-
-
-/*
-function modify_childau_domain($childdomain, $oldchilddomain, $childDN){
-
- global $ds, $suffix, $domsuffix, $ldapError;
- $dcDN = "ou=DNS,".$suffix;
- $dcoldDN = "ou=DNS,".$suffix;
-
- $dc_array = explode('.',$childdomain);
- $dc_array = array_reverse($dc_array);
- $dcold_array = explode('.',$oldchilddomain);
- $dcold_array = array_reverse($dcold_array);
-
- foreach ($dcold_array as $dc){
- $dcoldDN = "dc=".$dc.",".$dcoldDN;
- $aname = get_dc_data($dcoldDN,array("associatedname"));
- if ($aname == $childDN){
- break;
- }
- }
- #print_r($dcoldDN); echo "<br>";
- #print_r($domsuffix); echo "<br>";
-
- $dcnewDN = "";
- foreach ($dc_array as $dc){
- if (check_for_dc($dc)){
- # echo "dc <b>".$dc."</b> schon vorhanden ... n&auml;chster dc<br>";
- $domsuffix = $dc.".".$domsuffix;
- $dcDN = "dc=".$dc.",".$dcDN;
- }
- else{
- $dcDN = "dc=".$dc.",".$dcDN;
- $domsuffix = $dc.".".$domsuffix;
- $dcnewDN .= $dcDN;
- break;
- }
- }
- #print_r($dcnewDN); echo "<br>";
- #print_r($domsuffix); echo "<br>";
-
- if ($dcnewDN != ""){
- if (move_subtree($dcoldDN,$dcnewDN)){
- $entryAD['associateddomain'] = $childdomain.".".$domsuffix;
- $resultAD = ldap_mod_replace($ds,$childDN,$entryAD);
- $resultAD2 = ldap_mod_replace($ds,$dcnewDN,$entryAD);
- if ($resultAD && $resultAD2){return 1;}else{return 0;}
- }
- }else{
- echo "Domain existiert schon, bitte anderen Domainnamen w&auml;hlen!";
- }
-
-}
-
-
-function same_domain($assocdom, $dcDN, $childDN){
-
- global $ds, $suffix, $domsuffix, $ldapError;
-
- $entryDC ["associatedname"] = $childDN;
- $resultDC = ldap_mod_add($ds,$dcDN,$entryDC);
- if ($resultDC){
- # HostAdmins übernehmen, welche Admins noch? MainAdmin?
- $roles = get_roles($childDN);
- if(count($roles['HostAdmin']) != 0){
- $hostadmins = $roles['HostAdmin'];
- for ($i=0; $i<count($hostadmins); $i++){
- $entryRoleHost ['member'][$i] = $hostadmins[$i];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultHA = ldap_mod_add($ds,"cn=HostAdmin,cn=roles,".$dcDN,$entryRoleHost);
- }
- # Domainname zu associatedDomain der ChildAU
- $entryAD['objectclass'] = "domainRelatedObject";
- $entryAD['associateddomain'] = $assocdom;
- $resultAD = ldap_mod_add($ds,$childDN,$entryAD);
- if($resultAD){return 1;}else{return 0;}
- }
- else{return 0;}
-}
-
-
-function new_childau_domain($childdomain, $childDN){
-
- global $ds, $suffix, $domsuffix, $ldapError;
-
- # entsprechenden DC Knoten anlegen, sowie Roles (MainAdmin, HostAdmin)
- $dc_array = explode('.',$childdomain);
- $dc_array = array_reverse($dc_array);
- $dcDN = "ou=DNS,".$suffix;
- # $childdomainfull = $childdomain.".".$domsuffix;
- #print_r($dc_array);
- foreach ($dc_array as $dc){
- $resultsum = false;
- if (check_for_dc($dc)){
- echo "dc <b>".$dc."</b> schon vorhanden ... n&auml;chster dc<br>";
- $domsuffix = $dc.".".$domsuffix;
- $dcDN = "dc=".$dc.",".$dcDN;
- }
- else{
- $dcDN = "dc=".$dc.",".$dcDN;
-
- $entryDC ["objectclass"][0] = "dnsdomain";
- $entryDC ["objectclass"][1] = "domainrelatedobject";
- $entryDC ["objectclass"][2] = "top";
- $entryDC ["dc"] = $dc;
- $entryDC ["associatedname"] = $childDN;
- $entryDC ["associateddomain"] = $dc.".".$domsuffix;
- #print_r($entryDC); echo "<br>";
- #print_r($dcDN); echo "<br><br>";
- $resultDC = ldap_add($ds,$dcDN,$entryDC);
- if ($resultDC){
- $domsuffix = $dc.".".$domsuffix;
-
- #print_r($dcDN); echo"<br><br>";
-
- $entryRolesCont ['objectclass'] = "AUContainer";
- $entryRolesCont ['cn'] = "roles";
- #print_r($entryRolesCont); echo "<br><br>";
- $resultRC = ldap_add($ds,"cn=roles,".$dcDN,$entryRolesCont);
- if ($resultRC){
- $roles = get_roles($childDN);
- print_r($roles); echo "<br><br>";
- $mainadmins = $roles['MainAdmin'];
- $entryRoleMain ['objectclass'] = "groupOfNames";
- $entryRoleMain ['cn'] = "MainAdmin";
- for ($i=0; $i<count($mainadmins); $i++){
- $entryRoleMain ['member'][$i] = $mainadmins[$i];
- }
- #print_r($entryRoleMain); echo "<br>";
- $resultMA = ldap_add($ds,"cn=MainAdmin,cn=roles,".$dcDN,$entryRoleMain);
-
- if(count($roles['HostAdmin']) != 0){
- $hostadmins = $roles['HostAdmin'];
- $entryRoleHost ['objectclass'] = "groupOfNames";
- $entryRoleHost ['cn'] = "HostAdmin";
- for ($i=0; $i<count($hostadmins); $i++){
- $entryRoleHost ['member'][$i] = $hostadmins[$i];
- }
- #print_r($entryRoleHost); echo "<br>";
- $resultHA = ldap_add($ds,"cn=HostAdmin,cn=roles,".$dcDN,$entryRoleHost);
- }
- if ($resultMA){$resultsum = true;}
- }
- }
- break; # damit dc-Zuwachs immer nur um eine neue Ebene moeglich
- }
- }
- # Domainname zu associatedDomain der ChildAU
- if ($resultsum == true){
- $entryAD['objectclass'] = "domainRelatedObject";
- $entryAD['associateddomain'] = $domsuffix;
- $resultAD = ldap_mod_add($ds,$childDN,$entryAD);
- }
- if($resultAD){return 1;}
- else{return 0;}
-
-}
-
-
-
-function delete_childau_domain($oldchilddomain,$childDN,$delmodus){
-
- global $ds, $suffix, $domsuffix, $ldapError;
-
- $dcold_array = explode('.',$oldchilddomain);
- $dcold_array = array_reverse($dcold_array);
- $dcDN = "ou=DNS,".$suffix;
-
- foreach ($dcold_array as $dc){
- $dcDN = "dc=".$dc.",".$dcDN;
- $aname = get_dc_data($dcDN,array("associatedname"));
- $domsuffix = $dc.".".$domsuffix;
-
- if ($aname == $childDN){
- break;
- }
- }
- #print_r($dcDN); echo "<br>";
- #print_r($domsuffix); echo "<br>";
-
- if ( $delmodus == "complete" ){
- if (dive_into_tree_del($dcDN,"")){
- $delentry ['objectclass'] = "domainrelatedobject";
- $delentry ['associateddomain'] = $domsuffix;
- #print_r($delentry); echo "<br>";
- $delresult = ldap_mod_del($ds,$childDN,$delentry);
- if ($delresult){
- $mesg = "Domain komplett gel&ouml;scht<br>";
- }else{$mesg = "Fehler! ldap_mod_del<br>";}
- }else{$mesg = "Fehler! dive_into_tree_del<br>";}
- }
-
- if ( $delmodus == "integrate"){
- $mesg = "DNS Integration, noch nicht fertiggestellt";
- }
-
- return $mesg;
-}
-*/
-
-
-
-
-###############################################################################
-# Funktionen für das Rollen Management
-#
-
-
-function new_role_member($userDN,$role,$auDN,$domDN){
-
- global $ds, $suffix, $ldapError;
-
- $actroles = get_roles($auDN);
-
- $entry['member'] = $userDN;
-
- if ($domDN != ""){
- $actdnsroles = get_roles_dns($domDN);
- switch ($role){
- case 'MainAdmin':
- $roleDN1 = "cn=".$role.",cn=roles,".$auDN;
- $roleDN2 = "cn=".$role.",cn=roles,".$domDN;
- $results1 = ldap_mod_add($ds,$roleDN1,$entry);
- $results2 = ldap_mod_add($ds,$roleDN2,$entry);
- if ($results1 && $results2){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'HostAdmin':
- $roleDN1 = "cn=".$role.",cn=roles,".$auDN;
- #$roleDN2 = "cn=".$role.",cn=roles,".$domDN;
- if ( count($actroles['HostAdmin']) != 0 ){
- $results1 = ldap_mod_add($ds,$roleDN1,$entry);
- #$results2 = ldap_mod_add($ds,$roleDN2,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results1 = ldap_add($ds,$roleDN1,$entrynew);
- #$results2 = ldap_add($ds,$roleDN2,$entryHA);
- }
- if ($results1){ #&& $results2){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'DhcpAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['DhcpAdmin']) != 0 ){
- $results = ldap_mod_add($ds,$roleDN,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN,$entrynew);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'RbsAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['RbsAdmin']) != 0 ){
- $results = ldap_mod_add($ds,$roleDN,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN,$entrynew);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'ZoneAdmin':
- $roleDN1 = "cn=".$role.",cn=roles,".$auDN;
- #$roleDN2 = "cn=".$role.",cn=roles,".$domDN;
- if ( count($actroles['ZoneAdmin']) != 0 ){
- $results1 = ldap_mod_add($ds,$roleDN1,$entry);
- #$results2 = ldap_mod_add($ds,$roleDN2,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN1,$entrynew);
- }
- if ($results1){ #&& $results2){
- return 1;
- }else{
- return 0;
- }
- break;
- }
- }else{
- switch ($role){
- case 'MainAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- $results = ldap_mod_add($ds,$roleDN,$entry);
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'HostAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['HostAdmin']) != 0 ){
- $results = ldap_mod_add($ds,$roleDN,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN,$entrynew);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'DhcpAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['DhcpAdmin']) != 0 ){
- $results = ldap_mod_add($ds,$roleDN,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN,$entrynew);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'RbsAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['RbsAdmin']) != 0 ){
- $results = ldap_mod_add($ds,$roleDN,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN,$entrynew);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'ZoneAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['ZoneAdmin']) != 0 ){
- $results = ldap_mod_add($ds,$roleDN,$entry);
- }else{
- $entrynew ['objectclass'] = "groupOfNames";
- $entrynew ['cn'] = $role;
- $entrynew ['member'] = $userDN;
- $results = ldap_add($ds,$roleDN,$entrynew);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- }
- }
-}
-
-
-function delete_role_member($userDN,$role,$auDN,$domDN){
-
- global $ds, $suffix, $ldapError;
-
- $actroles = get_roles($auDN);
-
- $entry['member'] = $userDN;
-
- if ($domDN != ""){
- $actdnsroles = get_roles_dns($domDN);
-
- switch ($role){
- case 'MainAdmin':
- $roleDN1 = "cn=".$role.",cn=roles,".$auDN;
- $roleDN2 = "cn=".$role.",cn=roles,".$domDN;
- if ( count($actroles['MainAdmin']) == 1 || count($actdnsroles['MainAdmin']) == 1 ){
- echo "Rolle <b>MainAdmin</b> muss mindestens ein Mitglied haben!<br>
- <b>$userDN</b> wird nicht gel&ouml;scht.<br><br>";
- }else{
- $results1 = ldap_mod_del($ds,$roleDN1,$entry);
- $results2 = ldap_mod_del($ds,$roleDN2,$entry);
- }
- if ($results1 && $results2){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'HostAdmin':
- $roleDN1 = "cn=".$role.",cn=roles,".$auDN;
- #$roleDN2 = "cn=".$role.",cn=roles,".$domDN;
- if ( count($actroles['HostAdmin']) == 1 ){
- $results1 = ldap_delete($ds,$roleDN1);
- }else{
- $results1 = ldap_mod_del($ds,$roleDN1,$entry);
- }
- #$results2 = ldap_mod_del($ds,$roleDN2,$entry);
- if ($results1){ #&& $results2){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'DhcpAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['DhcpAdmin']) == 1 ){
- $results = ldap_delete($ds,$roleDN);
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'RbsAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['RbsAdmin']) == 1 ){
- $results = ldap_delete($ds,$roleDN);
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'ZoneAdmin':
- $roleDN1 = "cn=".$role.",cn=roles,".$auDN;
- #$roleDN2 = "cn=".$role.",cn=roles,".$domDN;
- if ( count($actroles['ZoneAdmin']) == 1 ){
- $results1 = ldap_delete($ds,$roleDN1);
- }else{
- $results1 = ldap_mod_del($ds,$roleDN1,$entry);
- }
- #$results2 = ldap_mod_del($ds,$roleDN2,$entry);
- if ($results1){ #&& $results2){
- return 1;
- }else{
- return 0;
- }
- break;
- }
- }else{
- switch ($role){
- case 'MainAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['MainAdmin']) == 1 ){
- echo "Rolle <b>MainAdmin</b> muss mindestens ein Mitglied haben!<br>
- <b>$userDN</b> wird nicht gel&oumlscht.<br><br>";
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'HostAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['HostAdmin']) == 1 ){
- $results = ldap_delete($ds,$roleDN);
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'DhcpAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['DhcpAdmin']) == 1 ){
- $results = ldap_delete($ds,$roleDN);
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'RbsAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['RbsAdmin']) == 1 ){
- $results = ldap_delete($ds,$roleDN);
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- case 'ZoneAdmin':
- $roleDN = "cn=".$role.",cn=roles,".$auDN;
- if ( count($actroles['ZoneAdmin']) == 1 ){
- $results = ldap_delete($ds,$roleDN);
- }else{
- $results = ldap_mod_del($ds,$roleDN,$entry);
- }
- if ($results){
- return 1;
- }else{
- return 0;
- }
- break;
- }
- }
-}
-
-
-function get_role_members($roleDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $roleDN, "objectclass=*", array("member"), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "search problem";
- die;
- } else {
- $members_array = array();
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- if (count($item['member']) > 1){
- $members_array = $item['member'];
- }
- else{
- $members_array[] = $item['member'];
- }
- }
- }
- return $members_array;
-}
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/commonlib.inc.php b/ldap-site-mngmt/webinterface/lib/commonlib.inc.php
deleted file mode 100644
index 95fc0776..00000000
--- a/ldap-site-mngmt/webinterface/lib/commonlib.inc.php
+++ /dev/null
@@ -1,554 +0,0 @@
-<?php
-
-
-/**
-* attributesToString($entry, $name, $delemiter = "", $pattern = "", $empty = "&nbsp") -
-* Gibt die Attribute eines LDAP-Eintrages formatiert aus
-*
-* Gibt die Attribute des Schl�ssels $name des LDAP-Eintraes $entry aus. Mehrere Werte werden mit $delemiter
-* voneinander getrennt. F�r jeden Wert des Attributes wird in $pattern an die Stelle "$name" (Dallarzeichen plus die Bezeichnung)
-* das aktuelle Attribut eingef�gt - �hnlich (aber nicht gleich!) der String-Interpretation von PHP. Falls $pattern = "" wird
-* einfach der Wert zur�ck gegeben. Falls f�r den Schl�ssel keine Attribut-Werte definiert sind, wird $empty zur�ck gegeben
-*
-* @param array entry LDAP-Array
-* @param string name Hashbezeichnung
-* @param string delimiter Trennzeichen
-* @param string pattern Muster
-* @param string empty Zeichen f�r leere Felder
-*
-* @return string Array-Werte als String
-*
-* @author Timothy Burk, lt. Musterl�sung
-*
-*/
-
- function attributesToString($entry, $name, $delimiter = "", $pattern = "", $empty = "") {
- $buffer = "";
- $name=strtolower($name);
- if (isset($entry[$name])) {
- $count = $entry[$name]['count'];
- for ($i = 0; $i < $count; $i++) {
- if ($pattern) {
- $tmp = $pattern;
- $buffer .= str_replace('$' . $name, $entry[$name][$i], $tmp);
- } else {
- $buffer .= $entry[$name][$i];
- }
- if ($delimiter && ($i + 1) < $count) {
- $buffer .= $delimiter;
- }
- }
- }
-
- if ("" == $buffer && $empty) {
- $buffer = $empty;
- }
- return $buffer;
- }
-
-/*
- * oneAttribute($entry, $name, $empty = "", $i = 0) {
- * liefert den ($i-ten) Wert des Attributes $name aus $entry
- * Eingabe ist entweder ein Datensatz aus dem ldapsearch-Ergebnis, oder
- * ein um die Meta-Infos (count) bereinigtes Ergebnis
- * sorry f�r die mangelhafte Doku - Thomas
- */
-
- function oneAttribute($entry, $name, $empty = "", $i = 0) {
- $buffer = "";
- if (isset($entry[$name][$i])) {
- $buffer = $entry[$name];
- } else if (isset($entry[$name])) {
- $buffer = $entry[$name];
- }
-
- if ("" == $buffer && $empty) {
- $buffer = $empty;
- }
- return $buffer;
- }
-
-
- /**
- * redirect($seconds, $url, $msg = "", $addSessionId = TRUE) - leitet den Benutzer auf eine andere Seite weiter
- *
- * Leitet den Benuzter nach $seconds Sekunden auf die Seite $url weiter. W�hrend der Wartezeit bekommt der Benutzer
- * die Information $msg mitgeteilt (Achtung: keine automatische Formatierung der $msg). Wenn $addSessionId TRUE ist,
- * dann wird an den URL die SessionId angeh�ngt.
- *
- * @author Timothy Burk, lt. Musterl�sung
- */
-
- function redirect($seconds, $url, $msg = "", $addSessionId = TRUE) {
- if ($addSessionId) {
- if (strpos($url, "?") === FALSE) {
- $url .= "?";
- } else {
- $url .= "&";
- }
- $url .= SID;
- }
-
- echo "<html>\n" .
- " <head>\n" .
- ' <meta http-equiv="refresh" content="' . $seconds . "; URL=$url" . '">' . "\n" .
- " </head>\n";
- if ($msg) {
- echo " <body>\n" .
- $msg .
- " </body>\n";
- }
- echo "</html>\n";
- }
-
-
-
-/**
-* getRights($ds, $userDn) - ermittelt die Rechte eines Users.
-*
-* Die Funktion erwartet ein Directory-Handle und den vollst�ndigen Distiguished Name des
-* Users. R�ckgabewert ist ein numerisches eindimensionales Array, welches die Rechte enth�lt.
-*
-* @param resource ds LDAP Directory Handle
-* @param string userDn Distinguishedname des Users
-*
-* @return array rechte
-*
-* @author Timothy Burk
-*/
-
-function getRoles($ds, $userDN) {
- global $ldapError, $suffix, $uid;
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(member=$userDN)(cn=*))", array("dn","cn"), "dn", "sub", 0, 0))) {
- redirect(5, "index.php", $ldapError, FALSE);
- die;
- }
- $result = ldapArraySauber($result);
- $clean = array();
-
- foreach($result as $item) {
- $dn = ldap_explode_dn($item['dn'], 0);
- $dnsub = array_slice($dn,3);
- $auDN = implode(',',$dnsub);
- $element['au'] = $auDN;
- $element['role'] = $item['cn'];
- $clean[] = $element;
- }
-
- $res = array();
- foreach($clean as $item){
- $au = $item['au'];
- $role = $item['role'];
- if(array_key_exists($au,$res)){
- $res[$au][] = $role;
- }
- else{
- $res[$au] = array($role);
- }
- }
- $i=0;
- foreach (array_keys($res) as $key){
- $au_roles[$i]['au'] = $key;
- $au_roles[$i]['role'] = $res[$key];
- $i++;
- }
- return $au_roles;
-}
-
-
-/**
-* createMenu($rechte) - erstellt die Menuleiste abh�ngig von der Rechten des Users.
-*
-* Die Navigationsleiste wird dynamisch erzeugt und von dieser Funktion direkt in das
-* entsprechende Template geparst. Dabei werden nur die Schaltfl�chen zur Verf�gung
-* gestellt, die der User mit seinen Rechten anzeigen darf.
-*
-* @param array rechte Eindimensionales Array mit den Rechten des Users
-* @param int mainnr Nummer des aktiven Hauptmenus
-*
-* @author Timothy Burk
-*/
-
-function createMainMenu($rollen , $mainnr) {
-
- global $template, $START_PATH, $auDN;
-
- # pre-checks
- $mipbs = get_maxipblocks_au($auDN);
- #echo "MIPB: "; print_r ($mipbs); echo "<br>";
- if ($mipbs[0] != ""){
- $dhcplink = "dhcp/dhcpsubnets.php?mnr=0";
- }else{
- $dhcplink = "dhcp/no_dhcp.php";
- }
-
- # Struktur der Registerkartenleiste
- $mainmenu = array(array("link" => "au/au.php",
- "text" => "AU Home",
- "zugriff" => "alle"),
- #array("link" => "roles/roles.php",
- # "text" => "Admin Rollen",
- # "zugriff" => array("MainAdmin","DhcpAdmin")),
- #array("link" => "ip/ip.php",
- # "text" => "IP Management",
- # "zugriff" => array("MainAdmin","HostAdmin","DhcpAdmin")),
- array("link" => "computers/hostoverview.php?sort=hostname",
- "text" => "Rechner",
- "zugriff" => array("MainAdmin","HostAdmin","DhcpAdmin")),
- array("link" => $dhcplink,
- "text" => "DHCP",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- array("link" => "rbs/rbs.php",
- "text" => "RemoteBoot/PXE",
- "zugriff" => array("MainAdmin","RbsAdmin")),
- array("link" => "dns/dns.php",
- "text" => "DNS",
- "zugriff" => array("MainAdmin","ZoneAdmin")));
-
-
- # Zusammenstellen der Menuleiste
- $template->define_dynamic("Mainmenu", "Mmenu");
- $i=0;
- foreach($mainmenu as $item) {
- if($item['zugriff'] === "alle" || vergleicheArrays($rollen , $item['zugriff'])) {
- if ($i==0) {
- if ($mainnr==0) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $zwisch="";
- $farb="#A0A0A0";
- $lastaktive=false;
- }
- }
- else {
- if ($mainnr==$i) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $farb="#A0A0A0";
- if ($lastaktive) {$zwisch="";}
- else {$zwisch="";}
- $lastaktive=false;
- }
- }
- $template->assign(array("MZWISCHEN" => $zwisch,
- "MFARBE" => $farb,
- "MLINK_M" => $START_PATH.$item["link"],
- "MTEXT_M" => $item["text"]));
- $template->parse("MAINMENU_LIST", ".Mainmenu");
- }
- $i=$i+1;
- }
- if ($lastaktive) {$template->assign(array("MENDE" => ""));}
- else {
- $template->assign(array("MENDE" => ""));
- }
-
-}
-
-
-
-/**
-* vergleicheArrays($a, $b) - Ermitteln der Schnittmenge zweier Arrays
-*
-* @param array a
-* @param array b
-*
-* @return boolean TRUE, wenn die Schnittmenge von a und b nicht leer ist, sonst FALSE
-*
-* @author Timothy Burk
-*/
-
-function vergleicheArrays($a, $b) {
- if((sizeof(array_unique($a)) + sizeof($b)) > sizeof(array_unique(array_merge($a, $b)))) {
- return TRUE;
- } else {
- return FALSE;
- }
-}
-
-
-/**
-* inputArraySauber($Array)
-*
-* L�scht aus einem Array, welches POST-Daten enth�lt leere Felder. N�tig f�r die Formatierung
-* vor dem Anlegen neuer Objekte.
-*
-* @param array _POST-Array
-*
-* @return array Bereinigtes Array.
-*
-* @author Timothy Burk
-*/
-function inputArraySauber($Array) {
- $b = array();
- foreach($Array as $key => $a) {
- if(!is_array($a)) {
- trim($a);
- }
- if (!$a == "") {
- if(is_array($a)) {
- $b[$key] = $a;
- } else {
- $b[$key] = htmlentities($a);
- }
- }
- }
- return $b;
-}
-
-
-/**
-* numArraySauber($Array)
-*
-* L�scht aus einemn numerischen Array leere Felder.
-*
-* @param array Numerisches Array
-*
-* @return array Bereinigtes Array.
-*
-* @author Timothy Burk
-*/
-function numArraySauber($Array) {
- $b = array();
- $arr = array();
- if(!(is_array($Array))) {
- $arr[] = $Array;
- } else {
- $arr = $Array;
- }
- foreach($arr as $key => $a) {
- if (!$a == "") {
- $b[] = $a;
- }
- }
- return $b;
-}
-
-/**
-* ldapArraySauber($Array, [$delEmpty])
-*
-* Bereinigt ein dreidimensionales Array, so wie es aus der Funktion uniLdapSearch kommt.
-* Dabei werden alle count-Felder sowie alle numerischen Felder in denen der Schl�ssel
-* gespeichert ist entfernt. Attributarrays mit nur einem Element werden gel�scht, das Element
-* wir als Skalar gespeichert.
-* Wenn $delEmpty = TRUE ist, werden nur nichtleere Felder gespeichert.
-*
-* @param array $Array uniLdapSearch()-Ausgabe
-* @param boolean $delEmpty (Standard: $delEmpty = FALSE)
-*
-* @return array Bereinigtes Array.
-*
-* @author Timothy Burk
-*/
-function ldapArraySauber($Array, $delEmpty = FALSE) {
- $b = array();
- foreach($Array as $key => $item) {
- if(is_array($item)) {
- foreach($item as $key_attr => $attr) {
- if(!is_int($key_attr)) {
- if(is_array($attr)) {
- if($attr['count'] == 1) {
- $attr[0] = str_replace(chr(160),"",trim($attr[0]));
- if(($delEmpty && $attr[0] != "") || !($delEmpty)) {
- $b[$key][$key_attr] = $attr[0];
- }
- } else {
- for($i=0; $i < $attr['count']; $i++) {
- $attr[$i] = str_replace(chr(160),"",trim($attr[$i]));
- if(($delEmpty && $attr[$i] != "") || !($delEmpty)) {
- $b[$key][$key_attr][$i] = $attr[$i];
- }
- }
- }
- } else {
- $attr = str_replace(chr(160),"",trim($attr));
- if(($delEmpty && $attr != "") || !($delEmpty)) {
- $b[$key][$key_attr] = $attr;
- }
- }
- }
- }
- } else {
- if(is_int($key)) {
- $item = str_replace(chr(160),"",trim($item));
- if(($delEmpty && $item != "") || !($delEmpty)) {
- $b[$key] = $item;
- }
- }
- }
- }
- return $b;
-}
-
-/**
-* personOptionen($rechte)
-*
-* Enth�lt die m�glichen Optionen, die auf einen User angewandt werden k�nnen als
-* zweidimensionales Array mit folgenden Attributen:
-* [ziel]: Aufzurufendes PHP-Skript
-* [text]: Beschriftung der Schaltfl�che
-* [desc]: Beschreibung der Funktion
-* [rechte][]: Array mit den erforderlichen Rechten f�r die jeweilige Option. array("alle") steht f�r "ohne Einschr�nkung".
-*
-* Dieses in dieser Funktion gespeicherte Array wird abh�ngig von den �bergebenen
-* Rechten um nicht erlaubte Optionen reduziert und dann ausgegeben.
-*
-* @param array $rechte Eindimensionales Array $_SESSION['rechte']
-*
-* @return array Zweidimensionales Array mit den erlaubten Optionen.
-*
-* @author Timothy Burk
-*/
-function personOptionen($rechte) {
- global $utc_uid, $utc_cn, $START_PATH;
- $optionen = array();
- $optionen[] = array("ziel" => $START_PATH."person/datensatz.php?aktion=edit",
- "text" => "Userdaten bearbeiten",
- "desc" => "Anzeigen und �ndern der pers�nlichen Daten des Users.",
- "rechte" => array("writeMitarbeiter"),
- "hidden" => array("aktion" => "edit"));
- $optionen[] = array("ziel" => $START_PATH."person/datensatz.php",
- "text" => "Datensatz l�schen",
- "desc" => "Der User wird vollst�ndig mit allen Daten aus der Datenbank gel�scht.",
- "rechte" => array("writeMitarbeiter"),
- "hidden" => array("aktion" => "delete"));
- $optionen[] = array("ziel" => $START_PATH."person/datensatz.php",
- "text" => "User (de)aktivieren",
- "desc" => "Diese Funktion legt einen User durch die Deaktivierung im Archiv ab. Von dort kann der Datensatz weiterhin eingesehen und ggf. reaktiviert werden.",
- "rechte" => array("writeMitarbeiter"),
- "hidden" => array("aktion" => "archiv"));
- $optionen[] = array("ziel" => $START_PATH."person/vertrag_show.php",
- "text" => "Vertr�ge bearbeiten",
- "desc" => "Bearbeiten oder Anlegen eines Vertrages. Sie k�nnen dabei zwischen verschiedenen Vertragsarten w�hlen.",
- "rechte" => array("writeVertrag", "readVertrag"));
- $optionen[] = array("ziel" => $START_PATH."urlaub/krank_angabe.php",
- "text" => "Krankheitstage",
- "desc" => "Krankheitsdaten bearbeiten.",
- "rechte" => array("writeKrankheitUrlaub"),
- "hidden" => array("uidToChange" => $utc_uid, "GName" => $utc_cn));
- $optionen[] = array("ziel" => $START_PATH."urlaub/liste.php",
- "text" => "Urlaubstage anzeigen",
- "desc" => "Urlaubstage des Users in grafischer �bersicht anzeigen.",
- "rechte" => array("readKrankheitUrlaub"),
- "hidden" => array("wer" => $utc_uid, "wann" => "g", "sub" => $utc_cn));
- $optionen[] = array("ziel" => $START_PATH."person/rechte_show.php",
- "text" => "Rechte vergeben",
- "desc" => "Diese Option dient dazu, dem User bestimmte Rechte zuzuweisen, beispielsweise das Recht Urlaub zu beantragen, Vertragsdaten andere User zu bearbeiten oder einzusehen usw..",
- "rechte" => array("writeRechte"));
- $optionen[] = array("ziel" => $START_PATH."person/suchen.php",
- "text" => "Abbrechen",
- "desc" => "&nbsp;",
- "rechte" => array("alle"));
-
- $opt_reduced = array();
- foreach($optionen as $option) {
- if(in_array("alle",$option['rechte']) || vergleicheArrays($option['rechte'],$rechte)) {
- array_push($opt_reduced, $option);
- }
- }
- return $opt_reduced;
-}
-
-
-/**
-* makeArrFromAttribute($a, $attribute)
-*
-* Ein zweidimensionales Array wird nach der ersten Dimension durchlaufen.
-* Dabei werden die Werte des angegebenen Attributes $attribute f�r alle
-* Eintr�ge extrahiert und in einem neuen Array gespeichert, welches
-* anschlie�end zur�ckgegeben wird.
-*
-* @param array $a Zweidimensionales Array
-* @param string $attribute Schl�sselname der zweiten Dimension
-*
-* @return array Eindimensionales numerisches Array mit den Attributwerten.
-*
-* @author Timothy Burk
-*/
-function makeArrFromAttribute($a, $attribute) {
- $c = array();
- foreach($a as $b) {
- $c[] = $b[$attribute];
- }
- return $c;
-}
-?>
-
-<?php
-
-
-/**
-* sortArrayByKey sortiert die 1.Dimension von bis zu 5-dimensionalen Arrays
-* nach den Werten in einem beliebigen Schl�ssel in beliebiger Dimension
-*
-* PS: die Funktion sortArrayByKey ist nur sinnvoll, wenn sich die Array-Eintr�ge
-* der 1.Dim sehr �hnlich sind, sprich bei Suchergebnissen!!
-*
-* @param array $array : das zu sortierende Array
-* @param string $sortKey : der Schl�ssel, nach dem sortiert werden soll
-* Bsp.:
-* es soll nach $array[$i][$j][$k]['sortkey'] sortiert werden
-* => $sortKey = "$j#$k#sortkey"
-* @param string $sortDirection : die Sortierrichtung, g�ltige Werte sind "up", "down"
-*
-*
-* @author Daniel H�fler
-*/
-function sortArrayByKey($array, $sortKey, $sortDirection = "up") {
- $sortKeyArray = explode("#", $sortKey);
- $count = count($sortKeyArray);
- if($count < 5) {
- switch($count) {
- case 0:
- foreach($array as $key => $item) {
- $toSortKeys[$key] = $item;
- }
- break;
- case 1:
- foreach($array as $key => $item) {
- $toSortKeys[$key] = $item[$sortKeyArray[0]];
- }
- break;
- case 2:
- foreach($array as $key => $item) {
- $toSortKeys[$key] = $item[$sortKeyArray[0]][$sortKeyArray[1]];
- }
- break;
- case 3:
- foreach($array as $key => $item) {
- $toSortKeys[$key] = $item[$sortKeyArray[0]][$sortKeyArray[1]][$sortKeyArray[2]];
- }
- break;
- case 4:
- foreach($array as $key => $item) {
- $toSortKeys[$key] = $item[$sortKeyArray[0]][$sortKeyArray[1]][$sortKeyArray[2]][$sortKeyArray[3]];
- }
- break;
- }
- } else {
- echo "zu viele Dimensionen!! H�chstens 4 Dimensionen m�glich";
- return false;
- }
- if($sortDirection == "up") {
- asort($toSortKeys);
- } elseif($sortDirection == "down") {
- arsort($toSortKeys);
- } else {
- echo "Keine g�ltige Sortierrichtung!! W�hlen sie \"up\" oder \"down\"\n";
- return false;
- }
- $sortArray = array();
- foreach($toSortKeys as $key => $item) {
- $sortArray[$key] = $array[$key];
- }
- return($sortArray);
-}
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/config.inc.php b/ldap-site-mngmt/webinterface/lib/config.inc.php
deleted file mode 100644
index 18a59409..00000000
--- a/ldap-site-mngmt/webinterface/lib/config.inc.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-
- # URL and Root Path of LSM Webinterface
- $START_PATH="https://dhcp.uni-freiburg.de/";
- #$START_PATH="http://localhost/lsm/";
-
- ###################################
- # LSM LDAP Directory Information
-
- # LDAP Server
- # Master
- define('LDAP_HOST', 'ldap://foo.ruf.uni-freiburg.de');
- #define('LDAP_HOST', 'ldaps://foo.ruf.uni-freiburg.de');
- # Slave
- #define('LDAP_HOST', 'ldap://bar.ruf.uni-freiburg.de');
- #define('LDAP_HOST', 'ldaps://bar.ruf.uni-freiburg.de');
-
- # Local for Testing
- #define('LDAP_HOST', 'localhost');
-
- define('LDAP_PORT', 389);
- #define('LDAP_PORT', 636);
-
- $suffix = "dc=uni-freiburg,dc=de";
- $domsuffix = "uni-freiburg.de";
- $rootAU = "ou=UniFreiburg,ou=RIPM,dc=uni-freiburg,dc=de";
- ###################################
-
-
- # einige Sachen, die aus Sicherheitsgr�nden in produktiven Umgebungen ge�ndert werden sollten!!!
- #$dummyUid = "rz-ldap"; // Dummy-User f�r einige Aktionen - muss angelegt werden!!!
- #$dummyPassword = "dummy";
-
- #$standardPassword = "..."; // das Passwort mit dem alle User im Anwendungsldap angelegt werden!!!
-
-?>
diff --git a/ldap-site-mngmt/webinterface/lib/dhcp_management_functions.php b/ldap-site-mngmt/webinterface/lib/dhcp_management_functions.php
deleted file mode 100644
index 97259728..00000000
--- a/ldap-site-mngmt/webinterface/lib/dhcp_management_functions.php
+++ /dev/null
@@ -1,727 +0,0 @@
-<?php
-
-/**
-* dhcp_management_functions.php - DHCP Management Funktions-Bibliothek
-* Diese Bibliothek enthält alle Funktionen für die Verwaltung des DHCP Dienstes
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Tarik Gasmi
-* @copyright Tarik Gasmi
-*/
-
-# Konfiguration laden
-require_once("config.inc.php");
-
-$ldapError = null;
-
-###################################################################################################
-
-# wenn DHCP Objekte geändert werden DHCP modify time der AU aktualisieren, und auch der AUs
-# referenzierter Objekte (Subnetz, RBS Dhcp Optionen) aktualisieren
-function update_dhcpmtime($au_array){
-
- global $ds, $auDN, $ldapError;
-
- $entry ['dhcpmtime'] = time();
-
- # eigene AU
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- echo "<br><b>dhcpMTime</b> erfolgreich in AU ".$auDN." aktualisiert!<br>" ;
- #return 1;
- }else{
- echo "<br>Fehler beim Aktualisieren der <b>dhcpMTime</b>!<br>" ;
- }
-
- # andere AUs
- if ( count($au_array) != 0 ) {
- $au_array = array_unique($au_array);
- # Bind als DHCP Manager
- $dhcp_uid = "dhcpmanager";
- $dhcp_userPassword = "dhcpman02";
- if (!($dhcp_ds = uniLdapConnect($dhcp_uid,$dhcp_userPassword))){
- echo "Konnte nicht als <b>DHCP-Manager</b> mit LDAP Server verbinden";
- die;
- }else{
- #echo "DHCP BIND erfolgreich";
- foreach ($au_array as $au){
- $results = ldap_mod_replace($dhcp_ds,$au,$entry);
- if ($results){
- echo "<b>dhcpMTime</b> erfolgreich in AU ".$au." aktualisiert!<br>" ;
- #return 1;
- }else{
- echo "<br>Fehler beim Aktualisieren der <b>dhcpMTime</b>!<br>" ;
- }
- }
- ldap_unbind($dhcp_ds);
- }
- }
-}
-
-
-# freie x.x.x.0/24 Netzwerke einer AU holen
-function get_networks(){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $networks = array();
- $fipb_array = get_freeipblocks_au($auDN);
- foreach ( $fipb_array as $fipb ){
- $exp = explode('_',$fipb);
- $fs = explode('.',$exp[0]);
- $fe = explode('.',$exp[1]);
- #print_r($fs); echo "<br>";
- #print_r($fe); echo "<br>";
-
- if ($fs[3] == 0){$networks [] = $exp[0];}
- $fs[2] = $fs[2] + 1;
- $fs[3] = 0;
-
- while ( $fs[2] <= $fe[2] ){
- $iprange = implode('_',array(implode('.',$fs),implode('.',$fs)));
- if (check_ip_in_iprange($iprange,$fipb)){
- $networks [] = implode('.',$fs);
- if ($fs[2] == 255){ $fs[1] = $fs[1] + 1; $fs[2] = 0; }
- else{ $fs[2] = $fs[2] + 1; }
- }
- }
- }
- #print_r($networks); echo "<br>";
- return $networks;
-}
-
-# Check ob AU über noch freie x.x.x.0/24 Netzwerke verfügt (freie IP Blöcke)
-function check_if_free_networks(){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $networks = 0;
- $fipb_array = get_freeipblocks_au($auDN);
- if ( $fipb_array[0] != "" ){
- foreach ( $fipb_array as $fipb ){
- $exp = explode('_',$fipb);
- $fs = explode('.',$exp[0]);
- $fe = explode('.',$exp[1]);
-
- if ($fs[3] == 0){return 1; break;}
- else{
- $fs[2] = $fs[2] + 1;
- $fs[3] = 0;
-
- while ( $fs[2] <= $fe[2] ){
- $iprange = implode('_',array(implode('.',$fs),implode('.',$fs)));
- if (check_ip_in_iprange($iprange,$fipb)){
- return 1; break 2;
- }
- if ($fs[2] == 255){ $fs[1] = $fs[1] + 1; $fs[2] = 0; }
- else{ $fs[2] = $fs[2] + 1; }
- }
- }
- }
- }
- return $networks;
-}
-
-# Check ob AU über x.x.x.0/24 Netzwerke insgesamt verfügt (maximale IP Blöcke)
-function check_if_max_networks(){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $networks = 0;
- $mipb_array = get_maxipblocks_au($auDN);
- if ( $mipb_array[0] != "" ){
- foreach ( $mipb_array as $mipb ){
- $exp = explode('_',$mipb);
- $fs = explode('.',$exp[0]);
- $fe = explode('.',$exp[1]);
-
- if ($fs[3] == 0){return 1; break;}
- else{
- $fs[2] = $fs[2] + 1;
- $fs[3] = 0;
-
- while ( $fs[2] <= $fe[2] ){
- $iprange = implode('_',array(implode('.',$fs),implode('.',$fs)));
- if (check_ip_in_iprange($iprange,$mipb)){
- return 1; break 2;
- }
- if ($fs[2] == 255){ $fs[1] = $fs[1] + 1; $fs[2] = 0; }
- else{ $fs[2] = $fs[2] + 1; }
- }
- }
- }
- }
- return $networks;
-}
-
-###################################################################################################
-
-function get_dhcpoffers($auDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $attribs = array("dn","dhcpofferdn");
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(objectclass=dhcpService)", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- #print_r($result);echo "<br><br>";
-
- $dhcp_offers = array();
- foreach ($result as $dhcp){
- if ( strpos($auDN, $dhcp['dhcpofferdn']) !== false ) # && $dhcp['dn'] != $dhcpserviceDN
- $dhcp_offers [] = $dhcp['dn'];
- }
- }
- #print_r($dhcp_offers);echo "<br><br>";
- return $dhcp_offers;
-}
-
-function alternative_dhcpservices($dhcpserviceDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $alt_dhcp = array();
-
- $dhcparray = get_dhcpoffers($auDN);
- # print_r($dhcparray); echo "<br>";
- if (count($dhcparray) != 0){
- for ($i=0; $i < count($dhcparray); $i++){
- if ($dhcparray[$i] != $dhcpserviceDN){
- $exp = ldap_explode_dn ( $dhcparray[$i], 1 );
- $alt = array ("dn" => $dhcparray[$i], "cn" => $exp[0], "au" => " / ".$exp[2]);
- $alt_dhcp[] = $alt;
- }
- }
- }
-
- return $alt_dhcp;
-}
-
-function alternative_dhcpsubnets($dhcpsubnetDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $alt_subnet = array();
- $dhcpservices = get_dhcpoffers($auDN);
- #print_r($dhcpservices); echo "<br>";
- if (count($dhcpservices) != 0){
- foreach ($dhcpservices as $servDN){
- $attribs = array("dn","cn","dhcphlpcont");
- #$servDN = $item['dn'];
- #print_r($servDN); echo "<br>";
- $filter = "(&(objectclass=dhcpSubnet)(dhcphlpcont=$servDN))";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, $filter, $attribs, "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }else{
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br>";
- foreach ($result as $subnet){
- if ( check_subnet_mipb($subnet['cn']) && $subnet['dn'] != $dhcpsubnetDN){
- $exp = ldap_explode_dn ( $subnet['dn'], 1 );
- $alt = array ("dn" => $subnet['dn'], "cn" => $exp[0], "au" => " / ".$exp[2]);
- $alt_subnet[] = $alt;
- }
- }
- }
-
- }
- }
-
- return $alt_subnet;
-}
-
-function check_subnet_mipb($subnet){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $subexp = explode('.',$subnet);
- $ret = 0;
- $mipb_array = get_maxipblocks_au($auDN);
- if ( $mipb_array[0] != "" ){
- foreach ( $mipb_array as $mipb ){
- $exp = explode('_',$mipb);
- $ms = explode('.',$exp[0]);
- $me = explode('.',$exp[1]);
- if ( $subexp[2] >= $ms[2] && $subexp[2] <= $me[2] ){
- $ret = 1;
- break;
- }
- }
- }
- if ($ret){return 1;}
- else{return 0;}
-
-}
-
-###############################################################################
-# Funktionen zur Verwaltung von DHCP Service Objekten
-#
-
-function add_dhcpservice ($dhcpserviceName,$dhcpoffer,$atts){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- #$dnarray = ldap_explode_dn ( $dhcpserviceDN, 1 );
- $dhcpserviceDN = "cn=".$dhcpserviceName.",cn=dhcp,".$auDN;
-
- $entrydhcp ['objectclass'][0] = "dhcpService";
- $entrydhcp ['objectclass'][1] = "dhcpOptions";
- $entrydhcp ['objectclass'][2] = "top";
- $entrydhcp ['cn'] = $dhcpserviceName;
- $entrydhcp ['dhcpofferdn'] = $dhcpoffer;
-
- # weitere Attribute
- foreach (array_keys($atts) as $key){
- if ($atts[$key] != ""){
- $entrydhcp[$key] = $atts[$key];
- }
- }
- print_r($entrydhcp); echo "<br>";
- print_r($dhcpserviceDN); echo "<br>";
-
- if ($result = ldap_add($ds, $dhcpserviceDN, $entrydhcp)){
- return 1;
- }
- else{
- $mesg = "Fehler beim eintragen des neuen DHCP Service Objekts!";
- return 0;
- }
-}
-
-
-# Löschen von Referenzen (dhcpHlpService) auf DHCP Service Objekt
-function cleanup_del_dhcpservice ($dhcpserviceDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $filter = "(&(|(objectClass=dhcpSubnet)(objectclass=dhcpHost))(dhcphlpcont=$dhcpserviceDN))";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, $filter, array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $delentry ['dhcphlpcont'] = $dhcpserviceDN;
- foreach ($result as $item){
- ldap_mod_del($ds, $item['dn'], $delentry);
- }
-}
-
-
-# Anpassen von Referenzen auf DHCP Service Objekt an neuen DN
-function adjust_dhcpservice_dn ($newdhcpserviceDN,$dhcpserviceDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $filter = "(&(|(objectClass=dhcpSubnet)(objectclass=dhcpHost))(dhcphlpcont=$dhcpserviceDN))";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, $filter, array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $modentry ['dhcphlpcont'] = $newdhcpserviceDN;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modentry);
- }
-
-}
-
-
-
-function alternative_dhcpobjects($objecttype,$objectDN,$ip){
-
- global $ds, $suffix, $auDN, $assocdom, $ldapError;
-
- $alt_dhcp = array();
- $expip = explode('.',$ip);
- $subnetDN = "";
-
- /*if ($objecttype == "subnet"){
- # alternative DHCP Dienstobjekte eigene AU/übergeordnete AUs
- $servarray = alternative_dhcpservices("");
- #print_r($servarray); echo "<br>";
- if (count($servarray) != 0){
- for ($i=0; $i < count($servarray); $i++){
- $alt_dhcp[] = $servarray[$i];
- }
- }
- if ($ip == ""){
- # alternative DHCP Subnetzobjekte eigene AU/übergeordnete AUs hinzufügen
- $subarray = alternative_dhcpsubnets($objectDN);
- #print_r($subarray);
- if (count($subarray) != 0){
- for ($i=0; $i < count($subarray); $i++){
- $alt_dhcp[] = $subarray[$i];
- }
- }
- }
- }*/
-
- if ($objecttype == "service"){
- # alternative DHCP Dienstobjekte eigene AU/übergeordnete AUs
- $servarray = alternative_dhcpservices($objectDN);
- #print_r($servarray); echo "<br>";
- if (count($servarray) != 0){
- for ($i=0; $i < count($servarray); $i++){
- $alt_dhcp[] = $servarray[$i];
- }
- }
- /*# Subnetz entsprechend IP
- $subarray = alternative_dhcpsubnets($objectDN);
- #print_r($subarray);
- if (count($subarray) != 0){
- for ($i=0; $i < count($subarray); $i++){
- $expsub = explode('.', $subarray[$i]['cn']);
- if ($expip[0] == $expsub[0] && $expip[1] == $expsub[1] && $expip[2] == $expsub[2]){
- $alt_dhcp[] = $subarray[$i];
- $subnetDN = $subarray[$i]['dn'];
- break;
- }
- }
- }
- # falls keine IP weitere Subnetze hinzufügen
- #print_r($subarray);
- if ( $ip == "" && count($subarray) != 0 ){
- for ($i=0; $i < count($subarray); $i++){
- if ($subnetDN != $subarray[$i]['dn']){
- $alt_dhcp[] = $subarray[$i];
- }
- }
- }*/
- }
-
- if ($objecttype == "nodhcp"){
- # alternative DHCP Dienstobjekte eigene AU/übergeordnete AUs
- $servarray = alternative_dhcpservices("");
- #print_r($servarray); echo "<br>";
- if (count($servarray) != 0){
- for ($i=0; $i < count($servarray); $i++){
- $alt_dhcp[] = $servarray[$i];
- }
- }
- /*# Subnetz entsprechend IP
- $subarray = alternative_dhcpsubnets($objectDN);
- #print_r($subarray);
- if (count($subarray) != 0){
- for ($i=0; $i < count($subarray); $i++){
- $expsub = explode('.', $subarray[$i]['cn']);
- if ($expip[0] == $expsub[0] && $expip[1] == $expsub[1] && $expip[2] == $expsub[2]){
- $alt_dhcp[] = $subarray[$i];
- $subnetDN = $subarray[$i]['dn'];
- break;
- }
- }
- }
- # falls keine IP weitere Subnetze hinzufügen
- #print_r($subarray); echo "<br>";print_r($subnetDN);
- if ( $ip == "" && count($subarray) != 0 ){
- for ($i=0; $i < count($subarray); $i++){
- if ($subnetDN != $subarray[$i]['dn']){
- $alt_dhcp[] = $subarray[$i];
- }
- }
- }*/
- }
- #echo "<br>";print_r($alt_dhcp);
- return $alt_dhcp;
-}
-
-
-###############################################################################
-# Funktionen zur Verwaltung von DHCP Subnet Objekten
-#
-
-function add_dhcpsubnet ($cn,$dhcpservice,$netmask,$atts){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $subnet = implode('_',array($cn,$cn));
-
- # IP checken und FIBS anpassen
- $fipb_array = get_freeipblocks_au($auDN);
-
- for ($i=0; $i < count($fipb_array); $i++){
- if ( split_iprange($subnet,$fipb_array[$i]) != 0 ){
- $ipranges = split_iprange($subnet,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- break;
- }
- }
-
- if ($i < count($fipb_array) ){
- # ldap_mod_replace -> Array fipb_array aktualisiert die FIPB in AU mit $auDN
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
-
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- echo "<br>Neue FIPBs erfolgreich eingetragen!<br>" ;
-
- $dhcpsubnetDN = "cn=".$cn.",cn=dhcp,".$auDN;
-
- $entrydhcp ['objectclass'][0] = "dhcpSubnet";
- $entrydhcp ['objectclass'][1] = "dhcpOptions";
- $entrydhcp ['objectclass'][2] = "top";
- $entrydhcp ['cn'] = $cn;
- $entrydhcp ['dhcpoptnetmask'] = $netmask;
- if ( $dhcpservice != "none" ){
- $entrydhcp ['dhcphlpcont'] = $dhcpservice;
- }
- # weitere Attribute
- foreach (array_keys($atts) as $key){
- if ($atts[$key] != ""){
- $entrydhcp[$key] = $atts[$key];
- }
- }
- print_r($entrydhcp); echo "<br>";
- print_r($dhcpsubnetDN); echo "<br>";
-
- if ($result = ldap_add($ds, $dhcpsubnetDN, $entrydhcp)){
- printf("Subnet <b>%s / %s</b> erfolgreich eingetragen",$cn,$netmask);
- update_dhcpmtime(array());
- return 1;
- #if ( check_ip_in_subnet($range1,$cn) && check_ip_in_subnet($range2,$cn)){
- # $dhcprange = implode('_',array($range1,$range2));
- # if ( $range = new_ip_dhcprange($dhcprange,$dhcpsubnetDN,$auDN) ){
- # echo "DHCP Range <b>".$range1." - ".$range2."</b> erfolgreich im Subnetobjekt eingetragen";
- # }else{
- # echo "DHCP Range <b>".$range1." - ".$range2."</b> konnte nicht im Subnetobjekt eingetragen werden!";
- # }
- # return 1;
- #}else{
- # echo "DHCP Range nicht in Subnetz ".$cn." enthalten.<br>Keine DHCP Range angelegt.<br>";
- # return 1;
- #}
- }else{
- echo "<br>Fehler beim anlegen des DHCP Subnet Objekts!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim eintragen der FIPBs!<br>";
- return 0;
- }
- }
- else{
- printf("<br>Subnet %s nicht im verfuegbaren IP Bereich!<br>", $subnet );
- return 0;
- }
-
-}
-
-function delete_dhcpsubnet($subnetDN,$cn){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- delete_ip_dhcprange($subnetDN,$auDN);
- if ( dive_into_tree_del($subnetDN,"") ){
- cleanup_del_dhcpsubnet($subnetDN);
- $oldsubnetip = implode("_",array($cn,$cn));
- $entry ['FreeIPBlock'] = $oldsubnetip;
- $results = ldap_mod_add($ds,$auDN,$entry);
- if ($results){
- merge_ipranges($auDN);
- update_dhcpmtime(array());
- return 1;
- }else{
- return 0;
- }
- }else{
- return 0;
- }
-
-}
-
-function modify_subnet_dn($subnetDN,$newsubnetDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- # check IP-Net-Syntax ...
-
- # Subnet CNs (IP) in internes Range ".._.." Format bringen
- $newcn = ldap_explode_dn($newsubnetDN,1);
- $newcnarray = array($newcn[0],$newcn[0]);
- $newsubnetip = implode("_",$newcnarray);
- $oldcn = ldap_explode_dn($subnetDN,1);
- $oldcnarray = array($oldcn[0],$oldcn[0]);
- $oldsubnetip = implode("_",$oldcnarray);
-
- # IP checken und FIBS anpassen
- $fipb_array = get_freeipblocks_au($auDN);
- for ($i=0; $i < count($fipb_array); $i++){
- if ( split_iprange($newsubnetip,$fipb_array[$i]) != 0 ){
- $ipranges = split_iprange($newsubnetip,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- break;
- }
- }
-
- if ($i < count($fipb_array) ){
-
- # zunächst alte DHCP Ranges löschen
- delete_ip_dhcprange($subnetDN,$auDN);
- # Move Subtree
- if(move_subtree($subnetDN, $newsubnetDN)){
- adjust_dhcpsubnet_dn($newsubnetDN, $subnetDN);
- printf("<br>Subnet Name (IP) erfolgreich von %s zu %s ge&auml;ndert!<br>", $oldcn[0], $newcn[0]);
- # neue Subnetz-IP aus FIPBs entfernen
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
- # alte Subnetz-IP in FIPBs integrieren
- $entry ['FreeIPBlock'][] = $oldsubnetip;
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- merge_ipranges($auDN);
- update_dhcpmtime(array());
- echo "<br>FIPBs erfolgreich angepasst!<br>" ;
- return 1;
- }else{
- echo "<br>Fehler beim Anpassen der FIPBs!<br>" ;
- }
- }else{
- echo "<br>Fehler beim &auml;ndern des Subnet Namens (IP)!<br>" ;
- }
- }else{
- printf("<br>Neues Subnet %s nicht im verfuegbaren IP Bereich!<br>", $newcn[0] );
- return 0;
- }
-}
-
-# wird eigentlich nicht benötigt wenn host deklarationen nicht in subnet scope sind ...
-function cleanup_del_dhcpsubnet ($dhcpsubnetDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $filter = "(&(objectclass=dhcpHost)(dhcphlpcont=$dhcpsubnetDN))";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, $filter, array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $delentry ['dhcphlpcont'] = $dhcpsubnetDN;
- foreach ($result as $item){
- ldap_mod_del($ds, $item['dn'], $delentry);
- }
-}
-
-
-# wird eigentlich nicht benötigt wenn host deklarationen nicht in subnet scope sind ...
-function adjust_dhcpsubnet_dn ($newdhcpsubnetDN,$dhcpsubnetDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $filter = "(&(objectclass=dhcpHost)(dhcphlpcont=$dhcpsubnetDN))";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, $filter, array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $modentry ['dhcphlpcont'] = $newdhcpsubnetDN;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modentry);
- }
-}
-
-
-# Nach Änderung der Host IP Adresse, überprüfen ob neue IP noch mit Subnet übereinstimmt
-# Falls keine Übereinstimmung mehr, dann Subnetzuordnung aus Host löschen.
-# wird eigentlich nicht benötigt wenn host deklarationen nicht in subnet scope sind ...
-function adjust_hostip_dhcpsubnet($ip,$hostDN,$dhcphlpcont) {
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $subnet = ldap_explode_dn($dhcphlpcont, 1);
- $expsub = explode('.', $subnet[0]);
- print_r($expsub); echo "<br>";
- $expip = explode('.', $ip);
- print_r($expsip); echo "<br>";
- if ($expip[0] != $expsub[0] || $expip[1] != $expsub[1] || $expip[2] != $expsub[2]){
- $entrydhcp ['dhcphlpcont'] = array();
- ldap_mod_del($ds,$hostDN,$entrydhcp);
- echo "Host mit neuer IP <b>".$ip."</b> wurde aus DHCP Subnet <b>".$subnet[0]."</b> entfernt<br><br>";
- }
-}
-
-function check_ip_in_subnet($ip,$subnet) {
-
- global $ds, $suffix, $auDN, $ldapError;
- $ipchunks = explode('.',$ip);
- $netchunks = explode('.',$subnet);
- $return = 0;
- for ($i=1; $i<4; $i++){
- if ( $netchunks[$i] == "0" ){
- if ( $ipchunks[$i-1] == $netchunks[$i-1] ){
- $return = 1;
- }
- break;
- }
- }
- if ($return) { return 1; }else{ return 0; }
-}
-
-#########################
-# Pools
-function add_dhcppool ($dhcpsubnetdn,$range,$unknownclients,$dhcpservicedn,$rbssrvdn){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN,"(objectclass=*)", array("cn"), "dn", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
-
- $dhcpcn_array = array();
- foreach ($result as $item){
- $dhcpcn_array [] = $item['cn'];
- }
- print_r($dhcpcn_array);echo "<br><br>";
- for ($i=0;$i<100;$i++){
- if ( array_search ( "Pool".$i, $dhcpcn_array ) === false ){
- $cn = "Pool".$i;
- break;
- }
- }
- $dhcppoolDN = "cn=".$cn.",cn=dhcp,".$auDN;
-
- $entrydhcp ['objectclass'][0] = "dhcpPool";
- $entrydhcp ['objectclass'][1] = "dhcpOptions";
- $entrydhcp ['objectclass'][2] = "top";
- $entrydhcp ['cn'] = $cn;
- $entrydhcp ['dhcphlpcont'] = $dhcpsubnetdn;
- $entrydhcp ['dhcprange'] = $range;
- if ($unknownclients == "allow"){
- $entrydhcp ['dhcpoptallow'] = "unknown-clients";
- }elseif ($unknownclients == "ignore"){
- $entrydhcp ['dhcpoptignore'] = "unknown-clients";
- }else{
- $entrydhcp ['dhcpoptdeny'] = "unknown-clients";
- }
- if ( $rbssrvdn != "none" ){
- $entrydhcp ['hlprbservice'] = $rbssrvdn;
- }
-
- print_r($dhcppoolDN);echo "<br><br>";
- print_r($entrydhcp);echo "<br><br>";
-
- if ($result = ldap_add($ds,$dhcppoolDN,$entrydhcp)){
- return 1;
- }else{return 0;}
-
-}
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/host_management_functions.php b/ldap-site-mngmt/webinterface/lib/host_management_functions.php
deleted file mode 100644
index 502dccb2..00000000
--- a/ldap-site-mngmt/webinterface/lib/host_management_functions.php
+++ /dev/null
@@ -1,474 +0,0 @@
-<?php
-
-/**
-* host_management_functions.php - Rechner und Gruppen Management Funktions-Bibliothek
-* Diese Bibliothek enthält alle Funktionen für die Verwaltung von Rechnern und Rechnergruppen,
-* sowie von MachineConfig-Objekten
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Tarik Gasmi
-* @copyright Tarik Gasmi
-*/
-
-# Konfiguration laden
-require_once("config.inc.php");
-
-
-$ldapError = null;
-
-###################################################################################################
-
-###############################################################################
-# Funktionen zur Verwaltung von Rechnern
-#
-
-# Ändern des DN des Rechners, d.h. beim Ändern des Attributes 'hostname'
-function modify_host_dn($hostDN, $newhostDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- if (move_subtree($hostDN,$newhostDN)){
- adjust_dn_entries($hostDN,$newhostDN);
-
- # Gruppen anpassen in denen Host Member ist
- $groups = get_groups_member($auDN,array("dn","member"),$hostDN);
- # print_r($groups); echo "<br>";
- if (count($groups != 0)){
-
- foreach ($groups as $group){
- #$entry = array("member");
- if ( count($group['member']) > 1 ){
- for($i=0; $i<count($group['member']); $i++){
- if ($hostDN == $group['member'][$i]){
- $entry ['member'][$i] = $newhostDN;
- }else{
- $entry ['member'][$i] = $group['member'][$i];
- }
- }
- # print_r($entry); echo "<br>";
- ldap_mod_replace($ds,$group['dn'],$entry);
- }
- if ( count($group['member']) == 1 && $group['member'] == $hostDN ){
- $entry['member'] = $newhostDN;
- # print_r($entry); echo "";
- ldap_mod_replace($ds,$group['dn'],$entry);
- }
- }
- }
-
- }
-}
-
-
-# Rechner neu anlegen
-function add_host($hostDN,$hostname,$hostdesc,$mac,$ip,$atts,$dhcp){
-
- global $ds, $suffix, $auDN, $assocdom, $ldapError;
-
- $syntax = new Syntaxcheck;
-
- $entryhost ['objectclass'][0] = "Host";
- $entryhost ['objectclass'][1] = "dhcpHost";
- $entryhost ['objectclass'][2] = "dhcpOptions";
- $entryhost ['objectclass'][3] = "top";
- $entryhost ["hostname"] = $hostname;
- $entryhost ["domainname"] = $assocdom;
- if ($hostdesc != ""){$entryhost ["description"] = $hostdesc;}
- if ($mac != "" && $syntax->check_mac_syntax($mac) ){
- $entryhost ["hwaddress"] = $mac;
- if ($dhcp != "none" && $dhcp != ""){
- $entryhost ["dhcphlpcont"] = $dhcp;
- }
- }else{
- echo "Keine MAC Adresse angelegt. Kein Eintrag im DHCP.<br>";
- }
- foreach (array_keys($atts) as $key){
- if ($atts[$key] != ""){
- $entryhost[$key] = $atts[$key];
- }
- }
-
- print_r($entryhost); echo "<br>";
- if ($result = ldap_add($ds, $hostDN, $entryhost)){
-
- if($ip != ""){
- if( $syntax->check_ip_syntax($ip) ){
- $newip_array = array($ip,$ip);
- $newip = implode('_',$newip_array);
- print_r($newip); echo "<br><br>";
- if (new_ip_host($newip,$hostDN,$auDN)){
- echo "IP erfolgreich eingetragen<br><br>";
- if ($mac != "" && $dhcp != "none" && $dhcp != ""){
- $entryfa ["dhcpoptfixed-address"] = "ip";
- if (ldap_mod_add($ds,$hostDN,$entryfa)){
- echo "DHCP Fixed-Address erfolgreich auf IP gesetzt<br><br>";
- }else{
- echo "Fehler beim Setzen der DHCP Fixed-Address<br><br>";
- }
- }
- }else{
- echo "Fehler beim eintragen der IP<br><br>";
- }
- }else{
- echo "Falsche IP Syntax! IP nicht eingetragen<br><br>";
- }
- }
- echo "Rechner erfolgreich eingetragen";
- if ($mac != "" && $dhcp != "none" && $dhcp != ""){
- update_dhcpmtime(array());
- }
- return 1;
- }
- else{
- $mesg = "Fehler beim eintragen des neuen Rechners!";
- return 0;
- }
-}
-
-
-# Rechner löschen
-function delete_host($hostDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $hostdata = get_node_data($hostDN,array("hwaddress","ipaddress"));
-
- # IP Adresse freigeben
- if ($hostdata['ipaddress'] != ""){
- delete_ip_host($hostDN,$auDN);
- }
-
- if (dive_into_tree_del($hostDN,"")){
-
- # alle DN Objekte in denen Rechner stand ebenfalls löschen
- # Member in Groups
- $groups = get_groups_member($auDN,array("dn","cn"),$hostDN);
- # echo "Rechner aus den Gruppen entfernen: <br>"; print_r($groups); echo "<br>";
- if (count($groups) != 0){
- $entrydel ['member'] = $hostDN;
- foreach ($groups as $group){
- echo "Entferne gel&ouml;schten Rechner aus Gruppe <b>".$group['cn']."</b> <br>";
- $resultG = ldap_mod_del($ds, $group['dn'], $entrydel);
-
- # Filename in Gruppen-PXEs
- $pxes = get_pxeconfigs($group['dn'],array("dn","cn"));
- if ( count($pxes) != 0 && $hostdata['hwaddress'] != ""){
- foreach ($pxes as $pxe){
- $delfilename ['filename'] = "01-".$hostdata['hwaddress'];
- $resultP = ldap_mod_del($ds,$pxe['dn'],$delfilename);
- echo "Entferne MAC des gel&ouml;schten Rechners aus Gruppen-PXE <b>".$pxe['cn']."</b> <br>";
- }
- }
- }
- }
-
- # DHCP, DNS, RBS Server ... noch todo
- # ...
- return 1;
- }
- else{
- return 0;
- }
-}
-
-function check_hostname($hostname){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $brothercheck = 0;
- $brotherhosts = get_hosts($auDN,array("hostname"),"");
-
- foreach ($brotherhosts as $item){
- if( $item['hostname'] == $hostname ){
- $brothercheck = 1;
- break;
- }
- }
- return $brothercheck;
-}
-
-###############################################################################
-# Funktionen zur Verwaltung von Rechnergruppen
-#
-
-# Gruppen DN ändern
-function modify_group_dn($groupDN, $newgroupDN){
-
- global $ds, $suffix, $ldapError;
-
- if (move_subtree($groupDN,$newgroupDN)){
- adjust_dn_entries($groupDN,$newgroupDN);}
-}
-
-
-# Gruppe neu anlegen
-function add_group($groupDN,$groupcn,$groupdesc,$addmember){
-
- global $ds, $suffix, $auDN, $assocdom, $ldapError;
-
- $entrygroup ['objectclass'][0] = "groupOfComputers";
- $entrygroup ['objectclass'][1] = "top";
- $entrygroup ["cn"] = $groupcn;
- if ($groupdesc != ""){$entrygroup ["description"] = $groupdesc;}
-
- # Members anlegen (zuerst 'none' rausnehmen)
- $n = array_search('none',$addmember);
- if ($n === 0 ){array_splice($addmember, $n, 1);}
-
- if (count($addmember) != 0){
- $i = 0;
- foreach ($addmember as $member){
- $exp = explode('_',$member);
- $entrygroup['member'][$i] = $exp[0];
- $i++;
- }
- }
- print_r($entrygroup); echo "<br>";
-
- if ($result = ldap_add($ds, $groupDN, $entrygroup)){
- return 1;
- }
- else{
- return 0;
- }
-}
-
-
-# Gruppe löschen
-function delete_group($groupDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- if (dive_into_tree_del($groupDN,"")){
-
- # alle DN Objekte in denen Gruppe stand ebenfalls löschen
- # DHCP ... noch todo
-
- return 1;
- }
- else{
- return 0;
- }
-}
-
-
-function add_groupmember($groupDN,$member){
-
- global $ds, $suffix, $auDN, $ldapError;
-
-}
-
-
-function delete_groupmember($groupDN,$member){
-
- global $ds, $suffix, $auDN, $ldapError;
-
-}
-
-
-###############################################################################
-# Funktionen zur Verwaltung von MachineConfigs
-#
-
-function check_timerange($mcday,$mcbeg,$mcend,$nodeDN,$excepttimerange){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $brothers = get_machineconfigs($nodeDN,array("timerange"));
- # keine Ãœberschneidungen pro Spez.Ebene zulassen
- #print_r($brothers); echo "<br><br>";
- if (count($brothers) != 0){
-
- $intersect = 0;
- foreach ($brothers as $item){
-
- # Fall, dass Brother mehrere TimeRanges hat
- if (count($item['timerange']) > 1){
- foreach ($item['timerange'] as $tr){
-
- if($tr != $excepttimerange){
- $exptime = explode('_',$tr);
- $bmcday = $exptime[0];
- $bmcbeg = $exptime[1];
- $bmcend = $exptime[2];
- #echo "mcday:"; print_r($mcday); echo "<br>";
- #echo "bmcday:"; print_r($bmcday); echo "<br>";
- #echo "mcbeg:"; print_r($mcbeg); echo "<br>";
- #echo "bmcbeg:"; print_r($bmcbeg); echo "<br>";
- #echo "mcend:"; print_r($mcend); echo "<br>";
- #echo "bmcend:"; print_r($bmcend); echo "<br>";
-
- if ($mcday == $bmcday){
- if ( $mcbeg > $bmcend || $mcend < $bmcbeg ){
- # keine Ãœberschneidung in der Uhrzeit
- }else{
- # Uhrzeit Ãœberschneidung
- $intersect = 1;
- $intersecttr = $bmcday."_".$bmcbeg."_".$bmcend;
- break;
- }
- }
- }
-
- }
- }
- # Fall, dass Brother nur eine TimeRange hat
- elseif (count($item['timerange']) == 1){
-
- if($item['timerange'] != $excepttimerange){
- $exptime = explode('_',$item['timerange']);
- $bmcday = $exptime[0];
- $bmcbeg = $exptime[1];
- $bmcend = $exptime[2];
- #echo "mcday:"; print_r($mcday); echo "<br>";
- #echo "bmcday:"; print_r($bmcday); echo "<br>";
- #echo "mcbeg:"; print_r($mcbeg); echo "<br>";
- #echo "bmcbeg:"; print_r($bmcbeg); echo "<br>";
- #echo "mcend:"; print_r($mcend); echo "<br>";
- #echo "bmcend:"; print_r($bmcend); echo "<br>";
-
- if ($mcday == $bmcday){
- if ( $mcbeg > $bmcend || $mcend < $bmcbeg ){
- # keine Ãœberschneidung in der Uhrzeit
- }else{
- # Uhrzeit Ãœberschneidung
- $intersect = 1;
- $intersecttr = $bmcday."_".$bmcbeg."_".$bmcend;
- break;
- }
- }
- }
- }
- }
- #echo "intersect: "; print_r($intersect); echo "<br>";
- if ($intersect == 1){
- echo "<b>[".$mcday."_".$mcbeg."_".$mcend."]</b> &uuml;berschneidet sich mit der
- bereits existierende <b>Time Range [".$intersecttr."]</b> !";
- return 0;
- }else{
- return 1;
- }
- }else{
- return 1;
- }
-}
-
-
-
-function add_mc($mcDN,$mccn,$mctimerange,$mcdesc,$mcattribs){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $mcentry ['objectclass'][0] = "MachineConfig";
- $mcentry ['objectclass'][1] = "top";
- $mcentry ['cn'] = $mccn;
- if ($mctimerange != ""){$mcentry ['timerange'] = $mctimerange;}
- if ($mcdesc != ""){$mcentry ['description'] = $mcdesc;}
- if ($mcdesc == ""){$mcentry ['description'] = $mccn;}
- foreach (array_keys($mcattribs) as $key){
- if ($mcattribs[$key] != ""){
- $mcentry[$key] = $mcattribs[$key];
- }
- }
-
- #print_r($mcentry); echo "<br>";
- #print_r($mcDN); echo "<br>";
- if (ldap_add($ds,$mcDN,$mcentry)){
- return 1;
- }
- else{
- return 0;
- }
-}
-
-# MachineConfig CN (DN) ändern
-function modify_mc_dn($mcDN, $newmcDN){
-
- global $ds, $suffix, $ldapError;
-
- if (move_subtree($mcDN,$newmcDN)){
- return 1;
- }else{
- return 0;
- }
-}
-
-function change_mc_timerange($mcDN,$newmcDN,$mctimerange){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- # move tree
- if (move_subtree($mcDN,$newmcDN)){
- # timerange ändern
- $entrymc ['timerange'] = $mctimerange;
- if (ldap_mod_replace($ds,$newmcDN,$entrymc)){
- return 1;
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
-}
-
-#####################################################################
-# Natürliches Sortieren (x.x.4.9 vor x.x.4.11 ) von mehr-dim Arrays der Art:
-# Array (
-# [0] => Array (
-# [hostname] = client01
-# [ipaddress] = 132.230.4.11
-# )
-# [1] => Array (
-# [hostname] = client02
-# [ipaddress] = 132.230.4.9
-# )
-# )
-
-/**
- * @return Returns the array sorted as required
- * @param $aryData Array containing data to sort
- * @param $strIndex Name of column to use as an index
- * @param $strSortBy Column to sort the array by
- * @param $strSortType String containing either asc or desc [default to asc]
- * @desc Naturally sorts an array using by the column $strSortBy
- */
-function array_natsort($aryData, $strIndex, $strSortBy, $strSortType=false){
-
- // if the parameters are invalid
- if (!is_array($aryData) || !$strIndex || !$strSortBy){
- // return the array
- return $aryData;
- }
- // create our temporary arrays
- $arySort = $aryResult = array();
- // loop through the array
- foreach ($aryData as $aryRow){
- // set up the value in the array
- $arySort[$aryRow[$strIndex]] = $aryRow[$strSortBy];
- }
- // apply the natural sort
- natsort($arySort);
- // if the sort type is descending
- if ($strSortType=="desc"){
- // reverse the array
- arsort($arySort);
- }
- // loop through the sorted and original data
- foreach ($arySort as $arySortKey => $arySorted){
- foreach ($aryData as $aryOriginal){
- // if the key matches
- if ($aryOriginal[$strIndex]==$arySortKey){
- // add it to the output array
- array_push($aryResult, $aryOriginal);
- }
- }
- }
-
- return $aryResult;
-}
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/ip_management_functions.php b/ldap-site-mngmt/webinterface/lib/ip_management_functions.php
deleted file mode 100644
index e5c30eca..00000000
--- a/ldap-site-mngmt/webinterface/lib/ip_management_functions.php
+++ /dev/null
@@ -1,1553 +0,0 @@
-<?php
-
-/**
-* ip_management_functions.php - IP Management Funktions-Bibliothek
-* Diese Bibliothek enthält alle Funktionen für die Verwaltung der IP Adressen.
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Tarik Gasmi
-* @copyright Tarik Gasmi
-*/
-
-# Konfiguration laden
-require_once("config.inc.php");
-
-$ldapError = null;
-
-
-####################################################################################
-# Basisfunktionen zur Verarbeitung von IP Ranges
-
-/*PHP Funktionen ip2long(), long2ip() machen dasselbe und werden verwendet
-function ip_dot_to_long($ip_dot)
-{
- $ip_long = unpack('N*', pack('C*', preg_split('/\./',$ip_dot)));
- return $ip_long;
-}
-
-function ip_long_to_dot($ip_long)
-{
- $ip_dot = join('.',unpack('C*',pack('N',$ip_long)));
- return $ip_dot;
-}*/
-
-/**
-* check_ip_in_iprange($iprange1, $iprange2)
-* Prueft ob erste IP Range in zweiter IP Range enthalten ist.
-*
-* @param string iprange1 erste IP Range
-* @param string iprange2 zweite IP Range
-*
-* @return boolean Erfolg bzw. Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function check_ip_in_iprange($iprange1,$iprange2)
-{
- $ipr1exploded = explode('_',$iprange1);
- $ipr2exploded = explode('_',$iprange2);
- $ipr1s = ip2long($ipr1exploded[0]);
- $ipr1e = ip2long($ipr1exploded[1]);
- $ipr2s = ip2long($ipr2exploded[0]);
- $ipr2e = ip2long($ipr2exploded[1]);
-
- if( $ipr1s >= $ipr2s && $ipr1e <= $ipr2e ){ return 1;}
- else{ return 0;}
-}
-
-
-/**
-* split_iprange($iprange1, $iprange2)
-* Entnimmt erste IP Range aus der zweiten IP Range und gibt bei Erfolg Array verbleibender
-* IP Ranges zurueck.
-*
-* @param string iprange1 erste IP Range
-* @param string iprange2 zweite IP Range
-*
-* @return array bei Erfolg bzw. boolean 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function split_iprange($iprange1,$iprange2)
-{
- $iprange3;
- $iprange4;
- $ipranges = array();
-
- if (check_ip_in_iprange($iprange1,$iprange2) == 1)
- {
- $ipr1exploded = explode('_',$iprange1);
- $ipr2exploded = explode('_',$iprange2);
- $ipr1s = ip2long($ipr1exploded[0]);
- $ipr1e = ip2long($ipr1exploded[1]);
- $ipr2s = ip2long($ipr2exploded[0]);
- $ipr2e = ip2long($ipr2exploded[1]);
-
- $ipr3s = $ipr2s;
- $ipr3e = $ipr1s - 1;
- $ipr4s = $ipr1e + 1;
- $ipr4e = $ipr2e;
-
- if ($ipr3s <= $ipr3e){$iprange3 = long2ip($ipr3s)."_".long2ip($ipr3e); $ipranges[] = $iprange3;}
- if ($ipr4s <= $ipr4e){$iprange4 = long2ip($ipr4s)."_".long2ip($ipr4e); $ipranges[] = $iprange4;}
-
- #echo "MATCH!<br>";
- return $ipranges;
- }
- else
- {
- #echo "IPRange1 not in IPRange2: ";
- return 0;
- }
-}
-
-
-/**
-* intersect_ipranges($iprange1, $iprange2)
-* Bildet die Schnittmenge zweier IP Ranges.
-*
-* @param string iprange1 erste IP Range
-* @param string iprange2 zweite IP Range
-*
-* @return string iprange3 Schnitt-IP-Range
-*
-* @author Tarik Gasmi
-*/
-function intersect_ipranges($iprange1,$iprange2)
-{
- $ipr1exploded = explode('_',$iprange1);
- $ipr2exploded = explode('_',$iprange2);
- $ipr1s = ip2long($ipr1exploded[0]);
- $ipr1e = ip2long($ipr1exploded[1]);
- $ipr2s = ip2long($ipr2exploded[0]);
- $ipr2e = ip2long($ipr2exploded[1]);
-
- if ( $ipr1s >= $ipr2s ){$ipr3s = $ipr1s;}else{$ipr3s = $ipr2s;}
- if ( $ipr1e <= $ipr2e ){$ipr3e = $ipr1e;}else{$ipr3e = $ipr2e;}
-
- if ($ipr3s <= $ipr3e){
- $iprange3 = long2ip($ipr3s)."_".long2ip($ipr3e);
- return $iprange3;
- }
- else{
- return "";
- echo "No Intersection<br>";
- }
-}
-
-
-/**
-* merge_2_ipranges($iprange1, $iprange2)
-* Vereinigt 2 IP Ranges zu einer IP Range, falls sie adjazent sind oder sich ueberschneiden.
-*
-* @param string iprange1 erste IP Range
-* @param string iprange2 zweite IP Range
-*
-* @return string iprange3 bei Erfolg bzw. boolean 0 bei Misserfolg.
-*
-* @author Tarik Gasmi
-*/
-function merge_2_ipranges($iprange1,$iprange2)
-{
-
- $ipr1exploded = explode('_',$iprange1);
- $ipr2exploded = explode('_',$iprange2);
- $ipr1s = ip2long($ipr1exploded[0]);
- $ipr1e = ip2long($ipr1exploded[1]);
- $ipr2s = ip2long($ipr2exploded[0]);
- $ipr2e = ip2long($ipr2exploded[1]);
-
- if ( ($ipr1e + 1) >= $ipr2s && $ipr1s <= ($ipr2e + 1) ){
- if ($ipr1s <= $ipr2s){ $ipr3s = $ipr1s; }else{ $ipr3s = $ipr2s; }
- if ($ipr1e <= $ipr2e){ $ipr3e = $ipr2e; }else{ $ipr3e = $ipr1e; }
-
- if ($ipr3s <= $ipr3e){
- $iprange3 = long2ip($ipr3s)."_".long2ip($ipr3e);
- printf("Merging: %s and %s -> %s<br>",$iprange1,$iprange2,$iprange3);
- return $iprange3;
- }
- else{
- # printf("No Merging possible: %s and %s<br>",$iprange1,$iprange2);
- return 0; }
- }
- else{
- # printf("No Merging possible: %s and %s<br>",$iprange1,$iprange2);
- return 0;
- }
-}
-
-
-#########################################################################################
-# IP Management LDAP Grundfunktionen
-
-/**
-* get_freeipblocks_au($auDN)
-* Holt die FreeIPBlocks einer AU und gibt sie in einem Array zurueck.
-*
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return array fipb_array FreeIPBlocks der AU.
-*
-* @author Tarik Gasmi
-*/
-function get_freeipblocks_au($auDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $auDN, "objectclass=*", array("FreeIPBlock"), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "search problem";
- die;
- } else {
- $fipb_array = array();
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- if (count($item['freeipblock']) > 1){
- $fipb_array = $item['freeipblock'];
- }
- else{
- $fipb_array[] = $item['freeipblock'];
- }
- }
- }
- return $fipb_array;
-}
-
-/**
-* get_maxipblocks_au($auDN)
-* Holt die MaxIPBlocks einer AU und gibt sie in einem Array zurueck.
-*
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return array mipb_array MaxIPBlocks der AU.
-*
-* @author Tarik Gasmi
-*/
-function get_maxipblocks_au($auDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $auDN, "objectclass=*", array("MaxIPBlock"), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "search problem";
- die;
- } else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- if (count($item['maxipblock']) > 1){
- $mipb_array = $item['maxipblock'];
- }
- else{
- $mipb_array[] = $item['maxipblock'];
- }
- }
- }
- return $mipb_array;
-}
-
-# benutze IP Ranges (Rechner, Ranges, Delegs)
-function get_used_ipblocks_au($auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $host_ips = array();
- $dhcps_ips = array();
- $dhcpr_ips = array();
- $deleg_ips = array();
- # Rechner IPs
- if(!($result = uniLdapSearch($ds, "cn=computers,".$auDN, "(objectclass=Host)", array("IPAddress"), "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- } else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- if (count($item['ipaddress']) != 0){
- $host_ips [] = $item['ipaddress'];
- }
- }
- }
- echo "Rechner IPs:<br>"; print_r($host_ips); echo "<br><br>";
-
- # DHCP Subnets
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN, "(objectclass=dhcpSubnet)", array("cn"), "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- } else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- $dhcps_ips [] = $item['cn']."_".$item['cn'];
- }
- }
- echo "DHCP Subnets:<br>"; print_r($dhcps_ips); echo "<br><br>";
-
- # DHCP Pool Ranges
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN, "(objectclass=dhcpPool)", array("dhcpRange"), "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- } else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- if (count($item['dhcprange']) > 1){
- foreach ($item['dhcprange'] as $range){
- $dhcpr_ips [] = $range;
- }
- }
- elseif (count($item['dhcprange']) == 1){
- $dhcpr_ips [] = $item['dhcprange'];
- }
- }
- }
- echo "DHCP Pool Ranges:<br>"; print_r($dhcpr_ips); echo "<br><br>";
-
- # Delegierte IPs
- $childau_array = get_childau($auDN,array("dn","ou","maxipblock"));
- #print_r($childau_array);
- if (count($childau_array) != 0){
- foreach ($childau_array as $childau){
- if (count($childau['maxipblock']) > 1){
- foreach ($childau['maxipblock'] as $mipb){
- $deleg_ips [] = $mipb;
- }
- }elseif (count($childau['maxipblock']) == 1){
- $deleg_ips [] = $childau['maxipblock'];
- }
- }
- }
- echo "Delegiert IP Blocks:<br>"; print_r($deleg_ips); echo "<br><br>";
-
- $used_ips = array_merge($host_ips, $dhcps_ips, $dhcpr_ips, $deleg_ips);
- sort($used_ips);
- $used_ips = merge_ipranges_array($used_ips);
-
- return $used_ips;
-}
-
-
-/**
-* get_host_ip($hostDN)
-* Holt die IP Adressen eines Hosts und gibt sie in einem Array zurueck.
-*
-* @param string hostDN Distinguished Name des LDAP Host-Objektes
-*
-* @return array host_array IPs des Hosts.
-*
-* @author Tarik Gasmi
-*/
-function get_host_ip($hostDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $hostDN, "(objectclass=Host)", array("hostName","IPAddress","dhcpOptFixed-address"), "hostName", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- return 0;
- }
- else {
- $result = ldapArraySauber($result);
- $host_array = array();
-
- foreach ($result as $item){
- $host_array['hostname'] = $item['hostname'];
- $host_array['ipaddress'] = $item['ipaddress'];
- #if ( $item['dhcpoptfixed-address'] != "" ){
- $host_array['dhcpoptfixed-address'] = $item['dhcpoptfixed-address'];
- #}
- # $host_array = array('hostname' => $item['hostname'], 'ipaddress' => $item['ipaddress']);
- }
- return $host_array;
- }
-}
-
-
-/**
-* get_dhcp_range($dhcpobjectDN)
-* Holt die IP Ranges eines DHCP Subnets/Pools und gibt sie in einem Array zurueck.
-*
-* @param string dhcpobjectDN Distinguished Name des LDAP DHCP-Objektes
-*
-* @return array dhcp_array IP Ranges des Subnets/Pools.
-*
-* @author Tarik Gasmi
-*/
-function get_dhcp_range($dhcpobjectDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $dhcpobjectDN, "(objectclass=*)", array("cn","dhcpRange"), "cn", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- return 0;
- }
- else {
- $result = ldapArraySauber($result);
- $dhcp_array = array();
-
- foreach ($result as $item){
- $dhcp_array['cn'] = $item['cn'];
- $dhcp_array['dhcprange'] = $item['dhcprange'];
- }
- return $dhcp_array;
- }
-}
-
-function get_dhcp_range2($dhcpobjectDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $dhcpobjectDN, "(objectclass=*)", array("dhcpRange"), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- return 0;
- }
- else {
- $result = ldapArraySauber($result);
- $dhcp_array = array();
- foreach ($result as $item){
- if ( count($item['dhcprange']) == 1 ){
- $dhcp_array[] = $item['dhcprange'];
- }
- if ( count($item['dhcprange']) > 1 ){
- foreach ($item['dhcprange'] as $range){
- $dhcp_array[] = $range;
- }
- }
- }
- return $dhcp_array;
- }
-}
-
-
-/**
-* merge_ipranges($auDN)
-* Nimmt die Arrays von IP Ranges eines AU Objektes, MaxIPBlocks und FreeIPBlocks, und vereinigt
-* rekusriv alle adjazenten/sich ueberschneidenden IP Ranges zu einer IP Range.
-*
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @author Tarik Gasmi
-*/
-function merge_ipranges($auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $fipb_array = get_freeipblocks_au($auDN);
- $mipb_array = get_maxipblocks_au($auDN);
- if ( count($fipb_array) > 1) sort($fipb_array);
- if ( count($mipb_array) > 1) sort($mipb_array);
-
- $c = count($fipb_array);
- for ($i=0; $i < $c; $i++){
- for ($j=$i+1; $j < $c; $j++){
- if ( merge_2_ipranges($fipb_array[$i],$fipb_array[$j])){
- $fipb_array[$i] = merge_2_ipranges($fipb_array[$i],$fipb_array[$j]);
- array_splice($fipb_array, $j, 1);
- $c--;
- $i=-1;
- break;
- }
- }
- }
- #print_r($fipb_array);printf("<br>");
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results) echo "FIPBs erfolgreich zusammengefasst!<br>" ;
- else echo "Fehler beim eintragen der FIPBs!<br>";
-
- $d = count($mipb_array);
- for ($i=0; $i < $d; $i++){
- for ($j=$i+1; $j < $d; $j++){
- if ( merge_2_ipranges($mipb_array[$i],$mipb_array[$j])){
- $mipb_array[$i] = merge_2_ipranges($mipb_array[$i],$mipb_array[$j]);
- array_splice($mipb_array, $j, 1);
- $d--;
- $i=-1;
- break;
- }
- }
- }
- #print_r($mipb_array);printf("<br>");
- foreach ( $mipb_array as $item ){
- $entry2 ['MaxIPBlock'][] = $item;
- }
- $results = ldap_mod_replace($ds,$auDN,$entry2);
- if ($results) echo "MIPBs erfolgreich zusammengefasst!<br>" ;
- else echo "Fehler beim eintragen der MIPBs!<br>";
-}
-
-function merge_dhcpranges($dhcpobjectDN)
-{
- global $ds, $suffix, $ldapError;
-
- $dhcp_array = get_dhcp_range2($dhcpobjectDN);
- if ( count($dhcp_array) > 1) sort($dhcp_array);
-
- $c = count($dhcp_array);
- for ($i=0; $i < $c; $i++){
- for ($j=$i+1; $j < $c; $j++){
- if ( merge_2_ipranges($dhcp_array[$i],$dhcp_array[$j])){
- $dhcp_array[$i] = merge_2_ipranges($dhcp_array[$i],$dhcp_array[$j]);
- array_splice($dhcp_array, $j, 1);
- $c--;
- $i=-1;
- break;
- }
- }
- }
- foreach ( $dhcp_array as $item ){
- $entry ['dhcprange'][] = $item;
- }
- $results = ldap_mod_replace($ds,$dhcpobjectDN,$entry);
- if ($results) echo "<br>DHCP Ranges erfolgreich zusammengefasst!<br><br>" ;
- else echo "<br>Fehler beim eintragen der DHCP Ranges!<br><br>";
-}
-
-function merge_ipranges_array($ipranges_array)
-{
- global $ds, $suffix, $ldapError;
-
- sort($ipranges_array);
- $c = count($ipranges_array);
- for ($i=0; $i < $c; $i++){
- for ($j=$i+1; $j < $c; $j++){
- if ( merge_2_ipranges($ipranges_array[$i],$ipranges_array[$j])){
- $ipranges_array[$i] = merge_2_ipranges($ipranges_array[$i],$ipranges_array[$j]);
- array_splice($ipranges_array, $j, 1);
- $c--;
- $i=-1;
- break;
- }
- }
- }
- return $ipranges_array;
- # Rückgabewert ...
-}
-
-
-
-/**
-* new_ip_host($ip,$hostDN,$auDN)
-* Weist einem Host eine IP Adresse neu zu, falls sie vergeben werden darf (in den FreeIPBlocks
-* enthalten ist), und passt die FreeIPBlocks der AU an.
-*
-* @param string ip IP Adresse, die zugewiesen werden soll
-* @param string hostDN Distinguished Name des LDAP Host-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function new_ip_host($ip,$hostDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $fipb_array = get_freeipblocks_au($auDN);
-
- for ($i=0; $i < count($fipb_array); $i++){
- if ( split_iprange($ip,$fipb_array[$i]) != 0 ){
- $ipranges = split_iprange($ip,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- break;
- }
- }
-
- if ($i < count($fipb_array) ){
- # ldap_mod_replace -> Array fipb_array aktualisiert die FIPB in AU mit $auDN
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
-
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- echo "<br>Neue FIPBs erfolgreich eingetragen!<br>" ;
-
- # ldap_mod_add -> IPAddress = $ip , in Host mit $hostDN
- $ipentry ['IPAddress'] = $ip;
- $results = ldap_mod_add($ds,$hostDN,$ipentry);
- if ($results){
- echo "<br>IP Adresse erfolgreich eingetragen!<br>" ;
- return 1;
- }else{
- echo "<br>Fehler beim eintragen der IP Adresse!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim eintragen der FIPBs!<br>";
- return 0;
- }
- }
- else{
- printf("<br>IP Adresse %s nicht im verfuegbaren Bereich!<br>", $ip );
- return 0;
- }
-}
-
-/**
-* new_ip_dhcprange($ip,$dhcpobjectDN,$auDN)
-* Weist einem DHCP Subnet/Pool eine IP Range neu zu, falls sie vergeben werden darf (in den FreeIPBlocks
-* enthalten ist), und passt die FreeIPBlocks der AU an.
-*
-* @param string ip IP Range, die zugewiesen werden soll
-* @param string dhcpobjectDN Distinguished Name des LDAP DHCP-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function new_ip_dhcprange($ip,$dhcpobjectDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $fipb_array = get_freeipblocks_au($auDN);
-
- #print_r($fipb_array);
-
- for ($i=0; $i < count($fipb_array); $i++){
- if ( split_iprange($ip,$fipb_array[$i]) != 0 ){
- $ipranges = split_iprange($ip,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- break;
- }
- }
-
- if ($i < count($fipb_array) ){
- # ldap_mod_replace -> Array fipb_array aktualisiert die FIPB in AU mit $auDN
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
-
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- echo "<br>Neue FIPBs erfolgreich eingetragen!<br>" ;
-
- # ldap_mod_add -> IPAddress = $ip , in Host mit $hostDN
- $ipentry ['dhcpRange'] = $ip;
- $results = ldap_mod_add($ds,$dhcpobjectDN,$ipentry);
- if ($results){
- echo "<br>IP Adresse erfolgreich eingetragen!<br>" ;
- return 1;
- }else{
- echo "<br>Fehler beim eintragen der IP Adresse!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim eintragen der FIPBs!<br>";
- return 0;
- }
- }else{
- printf("<br>IP Range %s ist nicht im verfuegbaren Bereich!<br>", $ip );
- return 0;
- }
-}
-
-## Add Dhcprange in DHCP Pool
-function add_dhcprange($newrange,$pooldn) {
-
- global $ds, $auDN, $suffix, $ldapError;
-
- # Freie IP Bereiche testen
- $fipb_array = get_freeipblocks_au($auDN);
- $test = 0;
- for ($f=0; $f < count($fipb_array); $f++){
- if ( split_iprange($newrange,$fipb_array[$f]) != 0 ){
- $ipranges = split_iprange($newrange,$fipb_array[$f]);
- array_splice($fipb_array, $f, 1, $ipranges);
- $test = 1;
- break;
- }
- }
- if ( $test ){
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
- $result1 = ldap_mod_replace($ds,$auDN,$entry);
- if ($result1){
- echo "<br>Neue FIPBs erfolgreich eingetragen!<br>";
- $rangeentry ['dhcprange'] = $newrange;
- print_r($rangeentry);echo "<br><br>";
- $result2 = ldap_mod_add($ds,$pooldn,$rangeentry);
- if ($result2){
- merge_dhcpranges($pooldn);
- #printf("Neue dynamische IP Range %s - %s erfolgreich in Subnetz %s0 eingetragen!<br>",$addrange1[$i],$addrange2[$i],$net);
- return 1;
- }else{
- # echo "<br>Fehler beim eintragen des dynamischen DHCP Pools!<br>";
- # Range wieder in FIPBs aufnehmen.
- $entry2 ['FreeIPBlock'] = $newrange;
- ldap_mod_add($ds,$auDN,$entry2);
- merge_ipranges($auDN);
- return 0;
- }
- }else{
- echo "<br>Fehler beim eintragen der FIPBs!<br>";
- return 0;
- }
- }else{
- printf("<br>IP Range %s ist nicht im verfuegbaren Bereich!<br>", $range );
- return 0;
- }
-}
-
-
-/**
-* delete_ip_host($hostDN,$auDN)
-* Löscht die IP Adresse eines Hosts, und passt die FreeIPBlocks der AU an.
-*
-* @param string hostDN Distinguished Name des LDAP Host-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function delete_ip_host($hostDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $host_array = get_host_ip($hostDN);
- $old_ip = $host_array['ipaddress']; # oder IP aus dem Formular
- # print_r($host_array);printf("<br>");
- # printf($old_ip);
- $delentry ['ipaddress'] = $old_ip;
- if ( $host_array['dhcpoptfixed-address'] != "" ){
- $delentry ['dhcpoptfixed-address'] = array();
- }
- # print_r($delentry);printf("<br>");
-
- $results = ldap_mod_del($ds,$hostDN,$delentry);
- if ($results){
- echo "<br>IP Adresse erfolgreich geloescht!<br>";
- $modentry['FreeIPBlock'] = $old_ip;
- $results = ldap_mod_add($ds,$auDN,$modentry);
- if ($results){
- echo "<br>geloeschte IP Adresse erfolgreich als neuer FIPB in die AU eingetragen!<br>" ;
- merge_ipranges($auDN);
- return 1;
- }
- else{
- echo "<br>Fehler beim eintragen der geloeschten IP Adresse als neuen FIPB!<br>";
- return 0;
- }
- }
- else{
- echo "<br>Fehler beim loeschen der IP Adresse!<br>";
- return 0;
- }
-}
-
-/**
-* delete_ip_dhcprange($dhcpobjectDN,$auDN)
-* Loescht die IP Range eines DHCP Subnets/Pools, und passt die FreeIPBlocks der AU an.
-*
-* @param string dhcpobjectDN Distinguished Name des LDAP DHCP-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function delete_ip_dhcprange($dhcpobjectDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $dhcp_array = get_dhcp_range($dhcpobjectDN);
-
- if ( $dhcp_array['dhcprange'] != "" ){
- $old_ip = $dhcp_array['dhcprange']; # oder IP aus dem Formular besser da ja mehrere moeglich
- # print_r($dhcp_array);printf("<br>");
- # printf($old_ip);
- $delentry['dhcpRange'] = $old_ip;
- # print_r($delentry);printf("<br>");
-
- $results = ldap_mod_del($ds,$dhcpobjectDN,$delentry);
- if ($results){
- echo "<br>DHCP IP Range erfolgreich geloescht!<br>";
- $modentry['FreeIPBlock'] = $old_ip;
- $results = ldap_mod_add($ds,$auDN,$modentry);
- if ($results){
- echo "<br>geloeschte IP Range erfolgreich als neuer FIPB in die AU eingetragen!<br>" ;
- merge_ipranges($auDN);
- return 1;
- }
- else{
- echo "<br>Fehler beim eintragen der geloeschten IP Range als neuen FIPB!<br>";
- # Transaktion simulieren und alte Range wieder eintragen ??
- return 0;
- }
- }
- else{
- echo "<br>Fehler beim loeschen der DHCP IP Range!<br>";
- return 0;
- }
- }
-}
-
-/**
-* modify_ip_host($ip,$hostDN,$auDN)
-* Aendert die IP Adresse eines Hosts, falls neue IP verfuegbar, und passt die FreeIPBlocks der AU an.
-*
-* @param string ip IP Adresse, die neu zugewiesen werden soll
-* @param string hostDN Distinguished Name des LDAP Host-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function modify_ip_host($ip,$hostDN,$auDN,$fixadd)
-{
- global $ds, $suffix, $ldapError;
-
- if ( delete_ip_host($hostDN,$auDN) ){
- if ( new_ip_host($ip,$hostDN,$auDN) ){
- if ( $fixadd != ""){
- $fa_entry ['dhcpoptfixed-address'] = $fixadd;
- ldap_mod_add($ds,$hostDN,$fa_entry);
- }
- echo "<br>IP Adresse erfolgeich geaendert!<br>";
- return 1;
- }else{
- echo "<br>Fehler beim Aendern der IP Adresse!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim Aendern der IP Adresse!<br>";
- return 0;
- }
-}
-
-/**
-* modify_ip_dhcprange($ip,$dhcpobjectDN,$auDN)
-* Aendert IP Range eines DHCP Subnet/Pool, falls neue Range verfuegbar ist,
-* und passt die FreeIPBlocks der AU an.
-*
-* @param string ip IP Range, die neu zugewiesen werden soll
-* @param string dhcpobjectDN Distinguished Name des LDAP DHCP-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function modify_ip_dhcprange($ip,$dhcpobjectDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- if ( delete_ip_dhcprange($dhcpobjectDN,$auDN) ){
- if ( new_ip_dhcprange($ip,$dhcpobjectDN,$auDN) ){
- echo "<br>DHCP IP Range erfolgeich geaendert!<br>";
- return 1;
- }else{
- echo "<br>Fehler beim Aendern der DHCP IP Range!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim Aendern der DHCP IP Range!<br>";
- return 0;
- }
-}
-
-
-/**
-* new_ip_delegation($ip,$childauDN,$auDN)
-* Delegiert einen neuen IP Bereich an eine untergeordnete AU, falls dieser verfuegbar ist
-* (in den FreeIPBlocks enthalten ist), und passt die FreeIPBlocks der AU an.
-*
-* @param string ip IP Bereich, der zugewiesen werden soll
-* @param string childauDN Distinguished Name des untergeordneten (Child) LDAP AU-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function new_ip_delegation($ip,$childauDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $fipb_array = get_freeipblocks_au($auDN);
- #echo "<br>---<br>";print_r($fipb_array);echo "<br>---<br>";
- for ($i=0; $i < count($fipb_array); $i++){
- if ( split_iprange($ip,$fipb_array[$i]) != 0 ){
- $ipranges = split_iprange($ip,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- break;
- }
- }
-
- if ($i < count($fipb_array) ){
- # ldap_mod_replace -> Array fipb_array aktualisiert die FIPB in AU mit $auDN
- foreach ( $fipb_array as $item ){
- $entry ['FreeIPBlock'][] = $item;
- }
-
- $results = ldap_mod_replace($ds,$auDN,$entry);
- if ($results){
- echo "<br>Neue FIPBs erfolgreich eingetragen!<br>" ;
-
- # ldap_mod_add -> IPAddress = $ip , in Host mit $hostDN
- $mipbentry['MaxIPBlock'] = $ip;
- $mipbentry['FreeIPBlock'] = $ip;
- #print_r($mipbentry);
-
- $results = ldap_mod_add($ds,$childauDN,$mipbentry);
- if ($results){
- echo "<br>IP Adressblock erfolgreich delegiert!<br>" ;
- merge_ipranges($childauDN);
- return 1;
- }else{
- echo "<br>Fehler beim eintragen der IP Adresse!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim eintragen der FIPBs!<br>";
- return 0;
- }
- }
- else{
- printf("<br>Zu delegierende IP Range %s ist nicht im verfuegbaren Bereich!<br>", $ip );
- }
-}
-
-/**
-* delete_ip_delegation($oldmipb,$childauDN,$auDN)
-* Einen an eine untergeordnete AU delegierten IP Bereich zuruecknehmen. Diese Funktion wird rekursiv fuer
-* alle weiter-delegierten Teilbereiche abgearbeitet. FreeIPBlocks der AU und Child-AU, sowie MaxIPBlocks
-* der Child-AU werden angepasst.
-*
-* @param string oldmipb delegierter maximaler IP Bereich, der zurueckgenommen werden soll
-* @param string childauDN Distinguished Name des untergeordneten (Child) LDAP AU-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function delete_ip_delegation($oldmipb,$childauDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- # Durch Reduzierung zu loeschende IP Ranges (Array)
- $delip[] = $oldmipb;
- #print_r($delip);printf("<br><br>");
-
- # Finde unter allen Child-AUs diejenigen, die von Reduzierung betroffene Child-Child-AUs haben
- # Diese sind werden rekursiv abgearbeitet
- $cchild_array = get_childau($childauDN,array("dn","maxipblock"));
- # print_r($cchild_array);printf("<br><br>");
- $cchild_todo = array();
- foreach ($delip as $delipitem){
- foreach ($cchild_array as $item){
- if( count($item['maxipblock']) > 1 ){
- foreach ($item['maxipblock'] as $item2 ){
- if ( intersect_ipranges($delipitem,$item2) != false ){
- $cchild_todo[] = array('coldmipb' => $item2,
- 'ccauDN' => $item['dn'],
- 'childauDN' => $childauDN );
- }
- }
- }
- elseif ( count($item['maxipblock']) == 1 ){
- if ( intersect_ipranges($delipitem,$item['maxipblock']) != false ){
- $cchild_todo[] = array('coldmipb' => $item['maxipblock'],
- 'ccauDN' => $item['dn'],
- 'childauDN' => $childauDN );
- }
- }
- }
- }
- #print_r($cchild_todo);printf("<br><br>");
-
- ###################
- # Rekursionsaufruf (für jede Child-AU, die betroffene Child-Child-AU hat)
- foreach ($cchild_todo as $item){
- delete_ip_delegation($item['coldmipb'],$item['ccauDN'],$item['childauDN']);
- }
- ###################
-
- # Ab hier: alles was bei jedem Fkt.Aufruf zu machen ist (in Ebene AU und Child-AU)
-
- # in CAU Check ob RechnerIPs oder DhcpIPs betroffen:
- $del_objects = objects_to_delete($delip,$childauDN,$cchild_array);
- # print_r($del_objects);printf("<br><br>");
- if ( count($del_objects['hostips']) != 0 ){
- printf("<br>Host IP Addresses that will be deleted: <br>");
- foreach ($del_objects['hostips'] as $item){
- printf("HostDN: %s &nbsp;&nbsp; IP Address: %s <br>",$item['dn'],$item['ip']);
- }
- }
- if ( count($del_objects['dhcpranges']) != 0 ){
- printf("<br>Subnet IP Ranges that will be adjusted: <br>");
- foreach ($del_objects['dhcpranges'] as $item){
- printf("DhcpObjectDN: %s &nbsp;&nbsp; Zu loeschende IP Range: %s <br>",$item['dn'],$item['delrange']);
- }
- }
- # hier kommte Abfrage ob wirklich Aenderung ausfuehren, ja dann weiter mit loeschen
- # sonst Abbruch
- # momentan: einfach loeschen
- if ( count($del_objects['hostips']) != 0 ){
- foreach ($del_objects['hostips'] as $item){
- delete_ip_host($item['dn'],$item['auDN']);
- }
- }
- if ( count($del_objects['dhcpranges']) != 0 ){
- foreach ($del_objects['dhcpranges'] as $item){
- delete_ip_dhcprange($item['dn'],$item['auDN']);
- }
- }
-
- # in Child-AU: oldmipb loeschen
- $mipb_array = get_maxipblocks_au($childauDN);
- #print_r($mipb_array);printf("<br><br>");
- foreach ($delip as $delipitem){
- # if ( count($mipb_array) > 1 ){
- for ($i=0; $i < count($mipb_array); $i++){
- if ( intersect_ipranges($delipitem,$mipb_array[$i]) != 0 ){
- #$ipranges = intersect_ipranges($newmipb,$mipb_array[$i]);
- array_splice($mipb_array, $i, 1);
- }
- }
- # }else{
- # if ( intersect_ipranges($delipitem,$mipb_array) != 0 ){
- # # $ipranges = intersect_ipranges($newmipb,$mipb_array);
- # $mipb_array = array();
- # }
- # }
- }
- # print_r($mipb_array);printf("<br><br>");
- # for ($i=0; $i < count($mipb_array); $i++){
- # if ($mipb_array[$i] == false){array_splice($mipb_array, $i, 1);}
- # }
-
- #print_r($mipb_array);printf("<br><br>");
- if (count($mipb_array) == 0){
- $entry ['MaxIPBlock'] = array();
- #print_r($entry);printf("<br><br>");
- $results = ldap_mod_del($ds,$childauDN,$entry);
- }else{
- foreach ( $mipb_array as $item ){
- $entry ['MaxIPBlock'][] = $item;
- }
- #print_r($entry);printf("<br><br>");
- $results = ldap_mod_replace($ds,$childauDN,$entry);
- }
-
- if ($results){
- echo "<br>MIPBs in Child-AU erfolgreich geloescht!<br>" ;
-
- # in Child-AU: FIPBs anpassen
- $fipb_array = get_freeipblocks_au($childauDN);
- #print_r($fipb_array);printf("<br><br>");
- foreach ($delip as $delipitem){
- # if ( count($fipb_array) > 1 ){
- for ($i=0; $i < count($fipb_array); $i++){
- if ( intersect_ipranges($delipitem,$fipb_array[$i]) != 0 ){
- # $ipranges = intersect_ipranges($newmipb,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1);
- }
- }
- # }
- # else{
- # if ( intersect_ipranges($delipitem,$fipb_array) != 0 ){
- # # $ipranges = intersect_ipranges($newmipb,$fipb_array);
- # $fipb_array = array();
- # }
- # }
- }
- # print_r($fipb_array);printf("<br><br>");
- # for ($i=0; $i < count($fipb_array); $i++){
- # if ($fipb_array[$i] == false){array_splice($fipb_array, $i, 1);}
- # }
-
- #print_r($fipb_array);printf("<br><br>");
- if (count($fipb_array) == 0){
- $entry1 ['FreeIPBlock'] = array();
- #print_r($entry1);printf("<br><br>");
- $results = ldap_mod_del($ds,$childauDN,$entry1);
- }else{
- foreach ( $fipb_array as $item ){
- $entry1 ['FreeIPBlock'][] = $item;
- }
- #print_r($entry1);printf("<br><br>");
- $results = ldap_mod_replace($ds,$childauDN,$entry1);
- }
-
- if ($results){
- echo "FIPBs in Child-AU erfolgreich geloescht!<br>" ;
-
- # in AU: Geloeschte IP Bereiche als neue FIPBs aufnehmen
- foreach ($delip as $item){
- $entry2 ['FreeIPBlock'][] = $item;
- }
- #print_r($entry2);printf("<br><br>");
- $results = ldap_mod_add($ds,$auDN,$entry2);
- if ($results){
- echo "FIPBs in AU erfolgreich aktualisiert!<br>" ;
-
- # IP Bloecke aufraeumen in Child-AU und AU (Merging)
- merge_ipranges($auDN);
- merge_ipranges($childauDN);
- return 1;
- }else{
- echo "Fehler beim aktualisieren der FIPBs in AU!<br>";
- return 0;
- }
- }else{
- echo "Fehler beim loeschen der FIPBs in Child-AU!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim loeschen der MIPBs in Child-AU!<br>";
- return 0;
- }
-}
-
-
-/**
-* reduce_ip_delegation($oldmipb,$newmipb,$childauDN,$auDN)
-* Einen an eine untergeordnete AU delegierten IP Bereich verkleinern. Diese Funktion wird rekursiv fuer
-* alle weiter-delegierten Teilbereiche abgearbeitet. FreeIPBlocks der AU und Child-AU, sowie MaxIPBlocks
-* der Child-AU werden angepasst.
-*
-* @param string oldmipb delegierter maximaler IP Bereich, der verkleinert werden soll
-* @param string newmipb delegierter maximaler IP Bereich nach der Verkleinerung
-* @param string childauDN Distinguished Name des untergeordneten (Child) LDAP AU-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function reduce_ip_delegation($oldmipb,$newmipb,$childauDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- # Durch Reduzierung zu loeschende IP Ranges (Array)
- $delip = split_iprange($newmipb,$oldmipb);
- #print_r($delip);printf("<br><br>");
-
- # Finde unter allen Child-AUs diejenigen, die von Reduzierung betroffene Child-Child-AUs haben
- # Diese sind werden rekursiv abgearbeitet
- $cchild_array = get_childau($childauDN,array("dn","maxipblock"));
-
- $cchild_todo = array();
- foreach ($delip as $delipitem){
- foreach ($cchild_array as $item){
- if( count($item['maxipblock']) > 1 ){
- foreach ($item['maxipblock'] as $item2 ){
- if ( intersect_ipranges($delipitem,$item2) != false ){
- $cchild_todo[] = array('coldmipb' => $item2,
- 'cnewmipb' => intersect_ipranges($newmipb,$item2),
- 'ccauDN' => $item['dn'],
- 'childauDN' => $childauDN );
- }
- }
- }
- elseif ( count($item['maxipblock']) == 1 ){
- if ( intersect_ipranges($delipitem,$item['maxipblock']) != false ){
- $cchild_todo[] = array('coldmipb' => $item['maxipblock'],
- 'cnewmipb' => intersect_ipranges($newmipb,$item['maxipblock']),
- 'ccauDN' => $item['dn'],
- 'childauDN' => $childauDN );
- }
- }
- }
- }
- #print_r($cchild_todo);printf("<br><br>");
-
- ######################
- # Rekursionsaufruf (für jede Child-AU, die betroffene Child-Child-AU hat)
- foreach ($cchild_todo as $item){
- if ($item['cnewmipb'] == false ){
- delete_ip_delegation($item['coldmipb'],$item['ccauDN'],$item['childauDN']);
- }
- else{
- reduce_ip_delegation($item['coldmipb'],$item['cnewmipb'],$item['ccauDN'],$item['childauDN']);
- }
- }
- ######################
-
-
- # Ab hier: alles was bei jedem Fkt.Aufruf zu machen ist (auf Ebene AU und Child-AU)
-
- # in CAU Check ob RechnerIPs oder DhcpIPs betroffen:
- # - falls ja: nochmals Abfrage (Hammermethode: diese auch loeschen) ob diese zu loeschen sind
- # -> ja, betreffende IPs loeschen
- # -> nein, Abbruch.
- # - falls nein: fuer jedes FIPB in CAU intersect(FIPB,newmipb)-> Schnittmengen bilden die neuen FIPB
- $del_objects = objects_to_adjust($newmipb,$delip,$childauDN,$cchild_array);
- # print_r($del_objects);printf("<br><br>");
- if ( count($del_objects['hostips']) != 0 ){
- printf("<br>Host IP Addresses that will be deleted: <br>");
- foreach ($del_objects['hostips'] as $item){
- printf("HostDN: %s &nbsp;&nbsp; IP Address: %s <br>",$item['dn'],$item['ip']);
- }
- }
- if ( count($del_objects['dhcpranges']) != 0 ){
- printf("<br>Subnet IP Ranges that will be adjusted: <br>");
- foreach ($del_objects['dhcpranges'] as $item){
- printf("DhcpObjectDN: %s &nbsp;&nbsp; New IP Range: %s <br>",$item['dn'],$item['newrange']);
- }
- }
-
- # momentan wird einfach geloescht:
- if ( count($del_objects['hostips']) != 0 ){
- foreach ($del_objects['hostips'] as $item){
- delete_ip_host($item['dn'],$item['auDN']);
- }
- }
- if ( count($del_objects['dhcpranges']) != 0 ){
- foreach ($del_objects['dhcpranges'] as $item){
- if ( count($item['newrange']) >= 1 ){
- modify_ip_dhcprange($item['newrange'],$item['dn'],$item['auDN']);
- }else{
- delete_ip_dhcprange($item['dn'],$item['auDN']);
- }
- }
- }
-
- # in Child-AU: oldmipb -> newmipb
- $mipb_array = get_maxipblocks_au($childauDN);
- # print_r($mipb_array);printf("<br><br>");
- foreach ($delip as $delipitem){
- for ($i=0; $i < count($mipb_array); $i++){
- if ( intersect_ipranges($delipitem,$mipb_array[$i]) != 0 ){
- $ipranges = intersect_ipranges($newmipb,$mipb_array[$i]);
- array_splice($mipb_array, $i, 1, $ipranges);
- }
- }
- }
- # print_r($mipb_array);printf("<br><br>");
- for ($i=0; $i < count($mipb_array); $i++){
- if ($mipb_array[$i] == false){array_splice($mipb_array, $i, 1);}
- }
- #print_r($mipb_array);printf("<br><br>");
- if (count($mipb_array) == 0){
- $entry ['MaxIPBlock'] = array();
- #print_r($entry);printf("<br><br>");
- $results = ldap_mod_del($ds,$childauDN,$entry);
- }else{
- foreach ( $mipb_array as $item ){
- $entry ['MaxIPBlock'][] = $item;
- }
- #print_r($entry);printf("<br><br>");
- $results = ldap_mod_replace($ds,$childauDN,$entry);
- }
-
- if ($results){
- echo "<br>MIPBs in Child-AU erfolgreich aktualisiert!<br>" ;
-
- # in Child-AU: FIPBs anpassen
- $fipb_array = get_freeipblocks_au($childauDN);
- #print_r($fipb_array);printf("<br><br>");
- foreach ($delip as $delipitem){
- for ($i=0; $i < count($fipb_array); $i++){
- if ( intersect_ipranges($delipitem,$fipb_array[$i]) != 0 ){
- $ipranges = intersect_ipranges($newmipb,$fipb_array[$i]);
- array_splice($fipb_array, $i, 1, $ipranges);
- }
- }
- }
- # print_r($fipb_array);printf("<br><br>");
- for ($i=0; $i < count($fipb_array); $i++){
- if ($fipb_array[$i] == false){array_splice($fipb_array, $i, 1);}
- }
- #print_r($fipb_array);printf("<br><br>");
- if (count($fipb_array) == 0){
- $entry1 ['FreeIPBlock'] = array();
- #print_r($entry1);printf("<br><br>");
- $results = ldap_mod_del($ds,$childauDN,$entry1);
- }else{
- foreach ( $fipb_array as $item ){
- $entry1 ['FreeIPBlock'][] = $item;
- }
- #print_r($entry1);printf("<br><br>");
- $results = ldap_mod_replace($ds,$childauDN,$entry1);
- }
-
- if ($results){
- echo "FIPBs in Child-AU erfolgreich aktualisiert!<br>" ;
-
- # in AU: Geloeschte IP Bereiche als neue FIPBs aufnehmen
- foreach ($delip as $item){
- $entry2 ['FreeIPBlock'][] = $item;
- }
- #print_r($entry2);printf("<br><br>");
- $results = ldap_mod_add($ds,$auDN,$entry2);
- if ($results){
- echo "FIPBs in AU erfolgreich aktualisiert!<br>" ;
-
- # IP Bloecke aufraeumen in Child-AU und AU (Merging)
- merge_ipranges($auDN);
- merge_ipranges($childauDN);
-
- return 1;
- }else{
- echo "Fehler beim aktualisieren der FIPBs in AU!<br>";
- return 0;
- }
- }else{
- echo "Fehler beim aktualisieren der FIPBs in Child-AU!<br>";
- return 0;
- }
- }else{
- echo "<br>Fehler beim aktualisieren der MIPBs in Child-AU!<br>";
- return 0;
- }
-}
-
-
-/**
-* expand_ip_delegation($oldmipb,$newmipb,$childauDN,$auDN)
-* Einen an eine untergeordnete AU delegierten IP Bereich erweitern. Diese Funktion wird rekursiv fuer
-* alle weiter-delegierten Teilbereiche abgearbeitet. FreeIPBlocks der AU und Child-AU, sowie MaxIPBlocks
-* der Child-AU werden angepasst. Entspricht einer Neu-Delegierung des erweiterten IP Bereichs.
-*
-* @param string oldmipb delegierter maximaler IP Bereich, der erweitert werden soll
-* @param string newmipb delegierter maximaler IP Bereich nach der Erweiterung
-* @param string childauDN Distinguished Name des untergeordneten (Child) LDAP AU-Objektes
-* @param string auDN Distinguished Name des LDAP AU-Objektes
-*
-* @return boolean 1 bei Erfolg bzw. 0 bei Misserfolg
-*
-* @author Tarik Gasmi
-*/
-function expand_ip_delegation($oldmipb,$newmipb,$childauDN,$auDN)
-{
- global $ds, $suffix, $ldapError;
-
- $difference = split_iprange($oldmipb,$newmipb);
- if ( new_ip_delegation($difference[0],$childauDN,$auDN) ){
- return 1;
- }else{
- return 0;
- }
-}
-
-
-/**
-* objects_to_delete($delip,$childauDN,$cchild_array)
-* Liefert die durch eine Rücknahme einer IP Delegierung betroffenen Host/DHCP-Objekte der Child-AU
-* und Child-Child-AUs in einem Array. Dieses enthaelt fuer jedes Objekt dessen Distinguished Name,
-* dessen IP Adresse(n)/Range(s) und den Distinguished Name der AU der das Objekt angehoert. Parameter
-* die fuer die Funktionen delete_ip_host(), delete_ip_range() Benoetigt werden.
-*
-* @param string delip IP Bereich der geloescht wird
-* @param string childauDN Distinguished Name des untergeordneten (Child) LDAP AU-Objektes
-* @param array cchild_array Array von allen Child-Child-AUs (jedes Item enthaelt DN und MaxIPBlock)
-*
-* @return array objects_to_delete Array aller betroffenen Objekte (DN, IP, auDN)
-*
-* @author Tarik Gasmi
-*/
-function objects_to_delete($delip,$childauDN,$cchild_array)
-{
- global $ds, $suffix, $ldapError;
-
- # Hosts von child-AU, child-child-AU
- $chosts = get_hosts($childauDN,array("dn","ipaddress"));
- # print_r($chosts);printf("<br><br>");
- $cchosts = array();
- foreach ($cchild_array as $item){
- $cchostsitem = get_hosts($item['dn'],array("dn","ipaddress"));
- foreach ($cchostsitem as $item2){
- $cchosts[] = $item2;
- }
- }
- $chosts = array_merge($chosts,$cchosts);
- # print_r($chosts);printf("<br><br>");
-
- # Pools von child-AU, child-child-AU
- $csubnets = get_dhcppools($childauDN,array("dn","dhcprange"));
- # print_r($csubnets);printf("<br><br>");
- $ccsubnets = array();
- foreach ($cchild_array as $item){
- $ccsubnetsitem = get_hosts($item['dn'],array("dn","dhcprange"));
- foreach ($ccsubnetsitem as $item2){
- $ccsubnets[] = $item2;
- }
- }
- $csubnets = array_merge($csubnets,$ccsubnets);
- # print_r($csubnets);printf("<br><br>");
-
-
- # Zu loeschende Hosts bestimmen
- $chosts_todo = array();
- foreach ($delip as $delipitem){
- if ( count($chosts) != 0 ){
- foreach ($chosts as $item){
- if( count($item['ipaddress']) > 1 ){
- foreach ($item['ipaddress'] as $item2 ){
- if ( intersect_ipranges($delipitem,$item2) != false ){
- $chosts_todo[] = array('dn' => $item['dn'],
- 'ip' => $item['ipaddress'],
- 'auDN' => $item['auDN']);
- }
- }
- }
- elseif ( count($item['ipaddress']) == 1 ){
- if ( intersect_ipranges($delipitem,$item['ipaddress']) != false ){
- $chosts_todo[] = array('dn' => $item['dn'],
- 'ip' => $item['ipaddress'],
- 'auDN' => $item['auDN']);
- }
- }
- }
- }
- }
- # print_r($chosts_todo);printf("<br><br>");
-
- # Zu loeschende Pools bestimmen, und wie IP Range anzupassen ist
- $csubnets_todo = array();
- foreach ($delip as $delipitem){
- if ( count($csubnets) != 0 ){
- foreach ($csubnets as $item){
- if( count($item['dhcprange']) > 1 ){
- foreach ($item['dhcprange'] as $item2 ){
- # print_r(intersect_ipranges($delipitem,$item2));
- if ( intersect_ipranges($delipitem,$item2) != false ){
- $csubnets_todo[] = array('dn'=> $item['dn'],
- 'delrange' => $item2['dhcprange'],
- 'auDN' => $item['auDN']);
- }
- }
- }
- elseif ( count($item['dhcprange']) == 1 ){
- # print_r(intersect_ipranges($delipitem,$item['dhcprange']));
- if ( intersect_ipranges($delipitem,$item['dhcprange']) != false ){
- $csubnets_todo[] = array('dn'=> $item['dn'],
- 'delrange' => $item['dhcprange'],
- 'auDN' => $item['auDN']);
- }
- }
- }
- }
- }
- # print_r($csubnets_todo);printf("<br><br>");
-
- $objects_to_delete = array('hostips' => $chosts_todo,
- 'dhcpranges' => $csubnets_todo);
- return $objects_to_delete;
-}
-
-
-/**
-* objects_to_adjust($newmipb,$delip,$childauDN,$cchild_array)
-* Liefert die durch eine Reduzierung einer IP Delegierung betroffenen Host/DHCP-Objekte der Child-AU
-* und Child-Child-AUs in einem Array. Dieses enthaelt fuer jedes Objekt dessen Distinguished Name,
-* dessen IP Adresse(n)/Range(s) und den Distinguished Name der AU der das Objekt angehoert. Parameter
-* die fuer die Funktionen delete_ip_host(), delete_ip_dhcprange(), modify_ip_dhcprange() benoetigt werden.
-*
-* @param string newmipb IP Bereich der nach Reduzierung verbleibt
-* @param string delip IP Bereich der durch Reduzierung wegfaellt
-* @param string childauDN Distinguished Name des untergeordneten (Child) LDAP AU-Objektes
-* @param array cchild_array Array von allen Child-Child-AUs (jedes Item enthaelt DN und MaxIPBlock)
-*
-* @return array objects_to_adjust Array aller betroffenen Objekte (DN, IP, auDN)
-*
-* @author Tarik Gasmi
-*/
-function objects_to_adjust($newmipb,$delip,$childauDN,$cchild_array)
-{
- global $ds, $suffix, $ldapError;
-
- # Hosts von child-AU, child-child-AU
- $chosts = get_hosts($childauDN,array("dn","ipaddress"));
- # print_r($chosts);printf("<br><br>");
- $cchosts = array();
- foreach ($cchild_array as $item){
- $cchostsitem = get_hosts($item['dn'],array("dn","ipaddress"));
- foreach ($cchostsitem as $item2){
- $cchosts[] = $item2;
- }
- }
- $chosts = array_merge($chosts,$cchosts);
- # print_r($chosts);printf("<br><br>");
-
- # Pools von child-AU, child-child-AU
- $csubnets = get_dhcppools($childauDN,array("dn","dhcprange"));
- # print_r($csubnets);printf("<br><br>");
- $ccsubnets = array();
- foreach ($cchild_array as $item){
- $ccsubnetsitem = get_hosts($item['dn'],array("dn","dhcprange"));
- foreach ($ccsubnetsitem as $item2){
- $ccsubnets[] = $item2;
- }
- }
- $csubnets = array_merge($csubnets,$ccsubnets);
- # print_r($csubnets);printf("<br><br>");
-
-
- # Zu loeschende Hosts bestimmen
- $chosts_todo = array();
- foreach ($delip as $delipitem){
- if ( count($chosts) != 0 ){
- foreach ($chosts as $item){
- if( count($item['ipaddress']) > 1 ){
- foreach ($item['ipaddress'] as $item2 ){
- if ( intersect_ipranges($delipitem,$item2) != false ){
- $chosts_todo[] = array('dn' => $item['dn'],
- 'ip' => $item['ipaddress'],
- 'auDN' => $item['auDN']);
- }
- }
- }
- elseif ( count($item['ipaddress']) == 1 ){
- if ( intersect_ipranges($delipitem,$item['ipaddress']) != false ){
- $chosts_todo[] = array('dn' => $item['dn'],
- 'ip' => $item['ipaddress'],
- 'auDN' => $item['auDN']);
- }
- }
- }
- }
- }
- # print_r($chosts_todo);printf("<br><br>");
-
- # Zu loeschende Subnets bestimmen, und wie IP Range anzupassen ist
- $csubnets_todo = array();
- foreach ($delip as $delipitem){
- if ( count($csubnets) != 0 ){
- foreach ($csubnets as $item){
- if( count($item['dhcprange']) > 1 ){
- foreach ($item['dhcprange'] as $item2 ){
- # print_r(intersect_ipranges($delipitem,$item2));
- if ( intersect_ipranges($delipitem,$item2) != false ){
- $csubnets_todo[] = array('dn'=> $item['dn'],
- 'newrange' => intersect_ipranges($newmipb,$item2),
- 'auDN' => $item['auDN']);
- }
- }
- }
- elseif ( count($item['dhcprange']) == 1 ){
- # print_r(intersect_ipranges($delipitem,$item['dhcprange']));
- if ( intersect_ipranges($delipitem,$item['dhcprange']) != false ){
- $csubnets_todo[] = array('dn'=> $item['dn'],
- 'newrange' => intersect_ipranges($newmipb,$item['dhcprange']),
- 'auDN' => $item['auDN']);
- }
- }
- }
- }
- }
- # print_r($csubnets_todo);printf("<br><br>");
-
-
- $objects_to_adjust = array('hostips' => $chosts_todo,
- 'dhcpranges' => $csubnets_todo);
- return $objects_to_adjust;
-}
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/ldap.inc.php b/ldap-site-mngmt/webinterface/lib/ldap.inc.php
deleted file mode 100644
index 79d50e61..00000000
--- a/ldap-site-mngmt/webinterface/lib/ldap.inc.php
+++ /dev/null
@@ -1,1117 +0,0 @@
-<?php
-/**
-* ldap.inc.php - LDAP-Bibliothek
-* Diese Bibliothek enth�lt alle Funktionen f�r den Zugriff auf den LDAP-Server.
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Timothy Burk, Mahir Yildirim, Johannes Sprenger, Daniel H�fler
-* @copyright Timothy Burk, Mahir Yildirim, Johannes Sprenger, Daniel H�fler
-*/
-//Konfiguration laden
-require_once("config.inc.php");
-
-$ldapError = null;
-
-/**
-* uniLdapConnect($userRdn, $userPwd) - F�hrt den Bind am Gruppe1-LDAP-Server durch
-*
-* @param string userRdn UID f�r den Login
-* @param string userPwd Loginpasswort
-*
-* @return boolean Erfolg bzw. Misserfolg
-*
-* @author Timothy Burk
-*/
-function uniLdapConnect($userRdn = "", $userPwd = "") {
- global $ldapError, $suffix;
- if(!(defined("LDAP_HOST") && defined("LDAP_PORT"))) {
- $ldapError = "Hostname und/oder Port des LDAP-Servers wurden nicht angegeben!";
- return FALSE;
- }
- if($ds = ldap_connect(LDAP_HOST, LDAP_PORT)) {
- # Connect zum LDAP-Server OK
- if(ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3)) {
- # Optionen gesetzt
- #if (ldap_start_tls($ds)){
- if($userRdn != "" && $userPwd != "") {
- # Anmeldung als User.
- if($result = @ldap_bind($ds, "uid=".$userRdn.",ou=people,".$suffix, $userPwd)) {
- # Bind erfolgreich ausgef�hrt
- return $ds;
- } else {
- # Bind nicht erfolreich.
- if(ldap_error($ds) == "Invalid credentials") {
- $ldapError .= "Bind nicht erfolgreich: die Zugangsdaten sind nicht korrekt.<br>\n";
- } else {
- $ldapError .= "Bind als User nicht erfolgreich: ".ldap_error($ds)."<br>\n";
- }
- #print_r(ldap_error($ds));echo "<br><br>";
- return false;
- }
- } else {
- # Anonymer Bind.
- if($result = ldap_bind($ds)) {
- # Anonymer Bind erfolgreich ausgef�hrt
- return $ds;
- } else {
- # Anonymer Bind nicht erfolreich.
- $ldapError .= "Anonymer Bind nicht erfolgreich: ".ldap_error($ds)."<br>\n";
- return false;
- }
- }
- #} else {
- # # TLS starten fehlgeschlagen
- # $ldapError .= "TLS starten fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- #}
- } else {
- # Optionen setzen fehlgeschlagen
- $ldapError .= "Protokollversion setzen fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- }
- } else {
- # Connect fehlgeschlagen.
- $ldapError .= "Connect fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- }
-}
-
-
-/**
-* rzLdapConnect($userRdn, $userPwd) - F�hrt den Bind am RZ-LDAP-Server durch
-*
-* @param string userRdn UID f�r den Login
-* @param string userPwd Loginpasswort
-*
-* @return boolean Erfolg bzw. Misserfolg
-*
-* @author Timothy Burk
-*/
-function rzLdapConnect($userRdn = "", $userPwd = "") {
- global $ldapError, $suffix_rz;
- if(!(defined("LDAP_HOST_RZ") && defined("LDAP_PORT_RZ"))) {
- $ldapError = "Hostname und/oder Port des LDAP-Servers wurden nicht angegeben!";
- return FALSE;
- }
- if($ds = ldap_connect(LDAP_HOST_RZ, LDAP_PORT_RZ)) {
- # Connect zum LDAP-Server OK
- if(ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3)) {
- # Optionen gesetzt
- if($userRdn != "" && $userPwd != "") {
- # Anmeldung als User.
- if($result = @ldap_bind($ds, "uid=".$userRdn.",ou=people,".$suffix_rz, $userPwd)) {
- # Bind erfolgreich ausgef�hrt
- return $ds;
- } else {
- # Bind nicht erfolreich.
- if(ldap_error($ds) == "Invalid credentials") {
- $ldapError .= "Bind nicht erfolgreich: die Zugangsdaten sind nicht korrekt.<br>\n";
- } else {
- $ldapError .= "Bind als User nicht erfolgreich: ".ldap_error($ds)."<br>\n";
- }
- return false;
- }
- } else {
- # Anonymer Bind.
- if($result = ldap_bind($ds)) {
- # Anonymer Bind erfolgreich ausgef�hrt
- return $ds;
- } else {
- # Anonymer Bind nicht erfolreich.
- $ldapError .= "Anonymer Bind nicht erfolgreich: ".ldap_error($ds)."<br>\n";
- return false;
- }
- }
- } else {
- # Optionen setzen fehlgeschlagen
- $ldapError .= "Protokollversion setzen fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- }
- } else {
- # Connect fehlgeschlagen.
- $ldapError .= "Connect fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- }
-}
-
- /**
- * uniLdapSearch($ds, $base, $filter, $attributes, $sort, $mode, $resultLimit, $timeout)
- * Sucht Eintr�ge im LDAP-Server.
- *
- * Durchsucht den LDAP-Server vom Punkt $base ab nach Eintr�gen, die $filter entsprechen. Falls in $sort ein Feldname angegeben
- * wurde, so wird danach sortiert. (ACHTUNG: die Funktion ldap_sort() ist nicht dokumentiert! Ich wei� nicht ob sie Sortierung
- * nach mehreren Feldern zul�sst und wie sie sich verh�lt, wenn zu einem Attribut mehrere Werte existieren.) $mode definiert die
- * Art der Suche, wohingegen $resultLimit und $timeout die Anzahl der Ergebnis-Eintr�ge bzw. die maximalen Suchdauer einschr�nken.
- * Zur�ckgegeben werden die Attribute, die im Array $attributes aufgef�hrt sind. Im Erfolgsfalle wird ein multidimensionales Array
- * zur�ckgeliefert, im Fehlerfalle FALSE. Dann steht die Fehlermeldung in der Variablen $ldapError.
- *
- * @param string $base die DN, das Verzeichnis, in dem die Suche startet
- *
- * @param string $filter die Suchbedingungen
- *
- * @param array attributes die Attributnamen, deren Werte im Ergebnis enthalten sein sollen.
- *
- * @param string $sort Sortiert die Ergebnis-Eintr�ge nach dem angegebenen Feldnamen (undokumentiert! s.o.)
- *
- * @param string $mode Der Modus: "one" liefert einen Eintrag, "list" alle Eintr�ge des Verzeichnisses und "sub"
- * schlie�t alle Untervezeichnisse mit ein.
- *
- * @param int $resultLimit die maximale Anzahl zur�ckgegebener Eintr�ge
- *
- * @param int $timeout die maximale Suchzeit, bevor der LDAP-Server abbrechen soll
- *
- * @return mixed multidimensionales array mit den Eintr�gen im Erfolgsfall, FALSE wenn ein Fehler auftrat
- *
- * @see ldap_read()
- * @see ldap_list()
- * @see ldap_search()
- * @see ldap_sort()
- * @see ldap_get_entries()
- * @see ldap_free_result()
- *
- * @author Timothy Burk
- */
-function uniLdapSearch($ds, $base, $filter, $attributes, $sort, $mode, $resultLimit, $timeout) {
- global $ldapError;
- $abfrage = false;
- if($mode == "one") {
- if($resource = ldap_read($ds, $base, $filter, $attributes, 0, $resultLimit, $timeout)) {
- # Abfrage erfolgreich!
- $abfrage = true;
- } else {
- # Abfrage fehlgeschlagen.
- $ldapError .= "Abfrage mit Mode $mode ist fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- return false;
- }
- } else if($mode == "list") {
- if($resource = ldap_list($ds, $base, $filter, $attributes, 0, $resultLimit, $timeout)) {
- # Abfrage erfolgreich!
- ldap_sort($ds,$resource,$sort);
- $abfrage = true;
- } else {
- # Abfrage fehlgeschlagen.
- $ldapError .= "Abfrage mit Mode $mode ist fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- return false;
- }
- } else if($mode == "sub") {
- if($resource = ldap_search($ds, $base, $filter, $attributes, 0, $resultLimit, $timeout)) {
- # Abfrage erfolgreich!
- ldap_sort($ds,$resource,$sort);
- $abfrage = true;
- } else {
- # Abfrage fehlgeschlagen.
- $ldapError .= "Abfrage mit Mode $mode ist fehlgeschlagen: ".ldap_error($ds)."<br>\n";
- return false;
- }
- } else {
- # Kein g�ltiger Modus angegeben.
- $ldapError .= "Es wurde kein g�ltiger Modus angegeben.";
- return false;
- }
- if($abfrage && ($entries = ldap_get_entries($ds, $resource))) {
- # Auslesen des Verzeichnisses erfolgreich.
- ldap_free_result($resource);
- return $entries;
- } else {
- # Auslesen des Verzeichnisses nicht erfolgreich.
- $ldapError .= "Auslesen des Verzeichnisses nicht erfolgreich: ".ldap_error($ds)."<br>\n";
- return false;
- }
-}
-/**
-* uniLdapAdd($ds, $dn, $daten, [$objectclass])
-*
-* F�gt ein neues Objekt in die LDAP-Datenbank ein.
-*
-* @param resource $ds Datenbankhandler
-* @param string $dn Distinguished Name des neuen Eintrages
-* @param array $daten Assoziatives Array mit den gew�nschten Attributen
-* @param string $objectclass Objektklasse des neuen Eintrages (Standard = "")
-*
-* @return boolean TRUE wenn Eintrag erfolgreich, FALSE wenn ein Fehler aufgetreten ist.
-*
-* @see ldap_add()
-*
-* @author Timothy Burk
-*/
-function uniLdapAdd($ds, $dn, $daten, $objectclass = "") {
- if($objectclass != "") {
- $daten['objectclass'] = $objectclass;
- }
- if(ldap_add($ds, $dn, $daten)) {
- return true;
- } else {
- return false;
- }
-}
-
-/**
-* uniLdapModify($ds, $dn, $daten_alt, $daten_neu, [$i])
-*
-* Universalfunktion zum �ndern von Attributen und Werten.
-* Bei �nderungsskripten muss zuerst ein Formular mit den alten Daten gef�llt werden. Die hierf�r
-* durchgef�hrte Suche wird in einem unbehandelten Array in der SESSION gespeichert und wieder
-* ausgelesen, sobald die �nderungen gespeichert werden sollen. Es wird anschlie�end an diese Funktion
-* (als $daten_alt)gegeben, die das Array mit ldapArraySauber von allen unn�tigen Eintr�gen befreit.
-* $daten_alt entspricht dann strukturell dem POST-Array des �nderungsformulars ($daten_neu).
-* Letzteres wird nun durch laufen, alle Eintr�ge werden mit ihrer Entsprechnung aus $daten_alt verglichen
-* und ggf. werden dann Attribute ge�ndert, gel�scht oder hinzugef�gt.
-*
-* @param resource $ds Datenbankhandler
-* @param string $dn Distinguished Name des Eintrages
-* @param array $daten_alt Dreidimensionales mixed Array der Form $array[int][string][int], so wie es von uniLdapSearch zur�ckgeliefert wird.
-* @param array $daten_neu Zweidimensionales mixed Array der Form $array[string][int], so wie ein Formular in $_POST gespeichert ist.
-* @param int $i Gibt an, welcher Eintrag der ersten Dimension von $daten_alt verwendet werden soll. (Standard: $i=0)
-*
-* @return boolean TRUE wenn �nderung erfolgreich, FALSE wenn ein Fehler aufgetreten ist.
-*
-* @see ldap_mod_replace()
-* @see ldap_mod_add()
-* @see ldap_mod_del()
-* @see ldapArraySauber()
-* @see numArraySauber()
-*
-* @author Timothy Burk
-*/
-function uniLdapModify($ds, $dn, $daten_alt, $daten_neu, $i = 0) {
- $meldung = "";
- $daten_alt = ldapArraySauber($daten_alt, FALSE);
- $daten_alt = $daten_alt[$i];
- foreach($daten_neu as $key => $value_neu) {
- $key = strtolower($key);
- if(!(is_array($value_neu))) {
- # Wenn $value_neu ein Skalar ist...
- # (d.h., das Attribut $key darf nur einen Wert annehmen)
- $value_neu = htmlentities(str_replace(chr(160),"",trim($value_neu))); // ungewollte Leerzeichen und &nbsp; l�schen
- if (isset($daten_alt[$key])) {
- $daten_alt[$key] = str_replace(chr(160),"",trim($daten_alt[$key])); // ungewollte Leerzeichen und &nbsp; l�schen
- } else {
- $daten_alt[$key] = "";
- }
- if($daten_alt[$key] == "" && $value_neu != "") {
- # FALL 1:
- # Alter Wert ist leer, neuer Wert ist nicht leer.
- # F�ge neues Attribut hinzu.
- if(ldap_mod_add($ds, $dn, array($key => $value_neu))) {
- $meldung .= "Add successfull: ".$key." -> ".$value_neu."<br>";
- } else {
- $meldung .= "Add error: ".$key." -> ".$value_neu."<br>";
- }
-
- } else if($daten_alt[$key] != "" && $value_neu == "") {
- # FALL 2:
- # Alter Wert ist nicht leer, neuer Wert ist leer.
- # L�sche Attribut.
- if(ldap_mod_del($ds, $dn, array($key => $daten_alt[$key]))) {
- $meldung .= "Delete successfull: ".$key." -> ".$daten_alt[$key]."<br>";
- } else {
- $meldung .= "Delete error: ".$key." -> ".$daten_alt[$key]."<br>";
- }
-
- } else if($daten_alt[$key] != "" && $value_neu != "" && $daten_alt[$key] != $value_neu) {
- # FALL 3:
- # Alter und neuer Wert sind nicht leer und beide sind ungleich.
- # �ndere das Attribut. Der bisherige Wert wird �berschrieben.
- if(ldap_mod_replace($ds, $dn, array($key => $value_neu))) {
- $meldung .= "Replace successfull: ".$key." -> ".$value_neu."<br>";
- } else {
- $meldung .= "Replace error: ".$key." -> ".$value_neu."<br>";
- }
-
- } else {
- # In allen anderen F�llen ist keine �nderung n�tig
- }
- } else {
- # Wenn $value_neu ein Array ist...
- # (d.h., das Attribut $key darf mehrere Werte annehmen)
- $value_neu = numArraySauber($value_neu);
- if (isset($daten_alt[$key])) {
- $value_alt = numArraySauber($daten_alt[$key]);
- foreach($value_alt as $item) {
- #$item = htmlentities($item);
- # L�sche alle alten Werte des Attributes $key.
- if(ldap_mod_del($ds, $dn, array($key => $item))) {
- $meldung .= "Delete successfull: ".$key." -> ".$item."<br>";
- } else {
- $meldung .= "Delete error: ".$key." -> ".$item."<br>";
- }
- }
- }
- foreach($value_neu as $item) {
- $item = htmlentities($item);
- # F�ge alle neuen Werte des Attributes $key ein.
- if(ldap_mod_add($ds, $dn, array($key => $item))) {
- $meldung .= "Add successfull: ".$key." -> ".$item."<br>";
- } else {
- $meldung .= "Add error: ".$key." -> ".$item."<br>";
- }
-
- }
- }
- }
- #return $meldung;
- if(eregi("error",$meldung)) {
- return FALSE;
- } else {
- return TRUE;
- }
-}
-
-/**
-* uniLdapDelete l�scht beliebige Eintr�ge mit dessen Subtree aus der Datenbank.
-* Dabei wird der wird der Baum ab dem Eintrag $dn zu allen Bl�ttern durchlaufen (Es
-* k�nnen nur Bl�tter gel�scht werden!!) und die Eintr�ge von hinten her bis einschlie�lich
-* $dn gel�scht
-*
-* @param resource ds LDAP Directory Handle
-* @param string dn Distiguished Name
-*
-* @return boolean
-*
-* @author Daniel H�fler
-*/
-
-function uniLdapDelete($ds, $dn) {
- # �berpr�fung, ob zu l�schender Eintrag vorhanden ist
- if(!uniLdapSearch($ds, $dn, "objectclass=*", array("*"), "", "one", 0, 0)) {
- $ldapError .= "L�schen fehlgeschlagen: Eintrag nicht gefunden".ldap_error($ds)."<br>\n";
- return false;
- }
- # Auslesen der Daten unterhalb von $dn
- $daten = uniLdapSearch($ds, $dn, "objectclass=*", array("*"), "", "list", 0, 0);
- # for-Schleife wird nur ausgef�hrt, falls sich unterhalb von $dn Eintr�ge befinden
- for($i = 0; $i < $daten['count']; $i++){
- uniLdapDelete($ds, $daten[$i]['dn']);
- }
- # l�schen der Bl�tter
- if(ldap_delete($ds, $dn)) {
- return true;
- } else {
- $ldapError .= "L�schen fehlgeschlagen".ldap_error($ds)."<br>\n";
- return false;
- }
-}
-
-############################################################################################
-#
-# Ab hier LDAP Funktionen (Tarik Gasmi) nutzen die zuvor definierten Funktionen
-# von Timothy Burk, u.A.
-#
-############################################################################################
-# Weitere LDAP Funktionen
-
-#
-# LDAP Funktionen um alle Objekte der AU eines bestimmten Typs mit gew�hlten Attributen zu holen
-#
-function get_hosts($auDN,$attributes,$sortattr)
-{
- global $ds, $suffix, $ldapError;
-
- if ( $sortattr == ""){
- $sortattr = "hostname";
- }
-
- if(!($result = uniLdapSearch($ds, "cn=computers,".$auDN, "(objectclass=Host)", $attributes, $sortattr, "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $host_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $host_array[] = $atts;
- }
- if($attributes != false ){return $host_array;}
- else{return $result;}
- }
-}
-
-function get_groups($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=groups,".$auDN, "(objectclass=groupOfComputers)", $attributes, "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $group_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $group_array[] = $atts;
- }
- if($attributes != false ){return $group_array;}
- else{return $result;}
- }
-}
-
-function get_groups_member($auDN,$attributes,$member)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=groups,".$auDN, "(&(objectclass=groupOfComputers)(member=$member))", $attributes, "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $group_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $group_array[] = $atts;
- }
- if($attributes != false ){return $group_array;}
- else{return $result;}
- }
-}
-
-function get_machineconfigs($baseDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $baseDN, "(objectclass=MachineConfig)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $mc_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['baseDN'] = $baseDN;
- $atts['auDN'] = $auDN;
- $mc_array[] = $atts;
- }
- if($attributes != false ){return $mc_array;}
- else{return $result;}
- }
-}
-
-function get_pxeconfigs($baseDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $baseDN, "(objectclass=PxeConfig)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $pxe_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['baseDN'] = $baseDN;
- $atts['auDN'] = $auDN;
- $pxe_array[] = $atts;
- }
- if($attributes != false ){return $pxe_array;}
- else{return $result;}
- }
-}
-
-function get_pxeconfigs2($clientDN,$attributes)
-{
- global $auDN, $ds, $suffix, $ldapError;
-
- if ($clientDN == ""){
- $filter = "(objectclass=PxeConfig)";
- }else{
- $filter = "(&(objectclass=PxeConfig)(pxeclientdn=$clientDN))";
- }
-
- if(!($result = uniLdapSearch($ds, "cn=pxe,".$auDN, $filter, $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $pxe_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['baseDN'] = $baseDN;
- $atts['auDN'] = $auDN;
- $pxe_array[] = $atts;
- }
- if($attributes != false ){return $pxe_array;}
- else{return $result;}
- }
-}
-
-function get_menuentries($baseDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $baseDN, "(objectclass=MenuEntry)", $attributes, "menuposition", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $menent_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['baseDN'] = $baseDN;
- $atts['auDN'] = $auDN;
- $menent_array[] = $atts;
- }
- if($attributes != false ){return $menent_array;}
- else{return $result;}
- }
-}
-
-function get_rbservices($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=rbs,".$auDN, "(objectclass=RBService)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $rbs_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $rbs_array[] = $atts;
- }
- if($attributes != false ){return $rbs_array;}
- else{return $result;}
- }
-}
-
-function get_subnets($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN, "(objectclass=dhcpSubnet)", $attributes, "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
- $subnet_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $subnet_array[] = $atts;
- }
- if($attributes != false ){return $subnet_array;}
- else{return $result;}
- }
-}
-
-function get_dhcppools($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN, "(objectclass=dhcpPool)", $attributes, "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $pool_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $pool_array[] = $atts;
- }
- if($attributes != false ){return $pool_array;}
- else{return $result;}
- }
-}
-
-function get_dhcppools_subnet($subnetDN,$attributes)
-{
- global $ds, $suffix, $auDN, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $auDN, "(&(objectclass=dhcpPool)(dhcphlpcont=$subnetDN))", $attributes, "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $pool_array = array();
- foreach ($result as $item){
- $poolexpdn = ldap_explode_dn($item['dn'], 1);
- $poolau = $poolexpdn[2];
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['poolAU'] = $poolau;
- $pool_array[] = $atts;
- }
- if($attributes != false ){return $pool_array;}
- else{return $result;}
- }
-}
-
-function get_dhcppoolranges($poolDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $poolDN, "(objectclass=dhcpPool)", array("dhcprange"), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- $ranges_array = array();
- if ( count($result[0]['dhcprange']) == 1 ){
- $ranges_array [] = $result[0]['dhcprange'];
- }
- elseif ( count($result[0]['dhcprange']) > 1 ){
- foreach ($result[0]['dhcprange'] as $range){
- $ranges_array [] = $range;
- }
- }
- return $ranges_array;
- }
-}
-
-function get_childau($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $auDN, "(objectclass=AdministrativeUnit)", $attributes, "ou", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $childau_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $childau_array[] = $atts;
- }
- if($attributes != false ){return $childau_array;}
- else{return $result;}
- }
-}
-
-function get_all_aus($attributes)
-{
- global $ds, $auDN, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(objectclass=AdministrativeUnit)", $attributes, "ou", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $childau_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $childau_array[] = $atts;
- }
- if($attributes != false ){return $childau_array;}
- else{return $result;}
- }
-}
-
-function get_au_data($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $auDN, "(objectclass=AdministrativeUnit)", $attributes, "ou", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $au_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $au_array[] = $atts;
- }
- if($attributes != false ){return $au_array;}
- else{return $result;}
- }
-}
-
-function get_domain_data($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $suffix, "(&(objectclass=dnsdomain)(associatedname=$auDN))", $attributes, "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $domain_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $domain_array[] = $atts;
- }
- if($attributes != false ){return $domain_array;}
- else{return $result;}
- }
-}
-
-
-function get_roles($auDN)
-{
- global $ds, $suffix, $domDN, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=roles,".$auDN, "(|(objectclass=GroupOfNames)(objectclass=Admins))", array("cn","member"), "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- $roles_array = array();
- #print_r($result);
- foreach ($result as $item){
- if ( count($item['member']) > 1 ){
- foreach ($item['member'] as $member){
- $roles_array[$item['cn']][] = $member;
- }
- }
- if ( count($item['member']) == 1 ){
- $roles_array[$item['cn']][] = $item['member'];
- }
- }
- return $roles_array;
- }
-}
-
-function get_roles_dns($domDN)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=roles,".$domDN, "(objectclass=GroupOfNames)", array("cn","member"), "cn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- $roles_array = array();
- foreach ($result as $item){
- if ( count($item['member']) > 1){
- foreach ($item['member'] as $member){
- $roles_array[$item['cn']][] = $member;
- }
- }else{
- $roles_array[$item['cn']][] = $item['member'];
- }
- }
- return $roles_array;
- }
-}
-
-
-function get_users(){
-
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "ou=people,".$suffix, "(objectclass=inetOrgPerson)", array("dn","cn","sn","uid"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- $users_array = array();
- # foreach ($result as $item){
- # $users_array[$item['cn']] = $item['member'];
- # }
- # return $users_array;
- return $result;
- }
-}
-
-function get_user_data($userDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $userDN, "(objectclass=inetOrgPerson)", $attributes, "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $user_data = $atts;
- }
- if($attributes != false ){return $user_data;}
- else{return $result;}
- }
-}
-
-
-function get_dc_data($dcDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $dcDN, "(objectclass=dnsdomain)", $attributes, "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $dc_data = $atts;
- }
- if($attributes != false ){return $dc_data;}
- else{return $result;}
- }
-}
-
-function get_node_data($nodeDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- $node_data = array();
-
- if(!($result = uniLdapSearch($ds, $nodeDN, "(objectclass=*)", $attributes, "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
- foreach ($result as $item){
- foreach ($attributes as $att){
- $node_data[$att] = $item[$att];
- }
- }
- if($attributes != false ){return $node_data;}
- else{return $result;}
- }
-}
-
-
-
-function get_zone_entries($dcDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $dcDN, "(|(objectclass=dNSZone)(objectclass=dNSZoneIncludeDirective))", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $zone_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['dcDN'] = $dcDN;
- $zone_array[] = $atts;
- }
- if($attributes != false ){return $zone_array;}
- else{return $result;}
- }
-}
-
-
-function get_zone_entries_assocname($dcDN,$attributes,$assocname)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $dcDN, "(&(|(objectclass=dNSZone)(objectclass=dNSZoneIncludeDirective))(associatedname=$assocname))", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $zone_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['dcDN'] = $dcDN;
- $zone_array[] = $atts;
- }
- if($attributes != false ){return $zone_array;}
- else{return $result;}
- }
-}
-
-function get_dn_menuposition($pxeDN,$pos)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $pxeDN, "(menuposition=$pos)", array("dn"), "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
- return $result[0]['dn'];
- }
-}
-
-function get_dhcpservices($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN, "(objectclass=dhcpService)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $dhcp_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $dhcp_array[] = $atts;
- }
- if($attributes != false ){return $dhcp_array;}
- else{return $result;}
- }
-}
-
-function get_dhcpsubnets($auDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "cn=dhcp,".$auDN, "(objectclass=dhcpSubnet)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);printf("<br><br>");
- $dhcp_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $atts['auDN'] = $auDN;
- $dhcp_array[] = $atts;
- }
- if($attributes != false ){return $dhcp_array;}
- else{return $result;}
- }
-}
-
-function get_service_subnets($dhcpserviceDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- $filter = "(&(dhcphlpcont=".$dhcpserviceDN.")(objectclass=dhcpSubnet))";
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, $filter, $attributes, "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- elseif(count($result) == 0){return $result;}
- else{
- $result = ldapArraySauber($result);
- # print_r($result);
- $dhcpsubnets = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $expdn = ldap_explode_dn($item['dn'],1);
- $au = array_slice($expdn, 3, 1);
- $atts['auDN'] = implode ( ',', $au );
- $dhcpsubnets [] = $atts;
- }
- #print_r($dhcpsubnets);
- if($attributes != false ){
- return $dhcpsubnets;
- }
- else{return $result;}
- }
-}
-
-?>
diff --git a/ldap-site-mngmt/webinterface/lib/ldap2.inc.php b/ldap-site-mngmt/webinterface/lib/ldap2.inc.php
deleted file mode 100644
index 3d0b26d9..00000000
--- a/ldap-site-mngmt/webinterface/lib/ldap2.inc.php
+++ /dev/null
@@ -1,350 +0,0 @@
-<?php
-/**
-* ldap2.inc.php - LDAP-Bibliothek
-* Diese Bibliothek enthält weitere LDAP Hilfs-Funktionen
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Tarik Gasmi
-* @copyright Tarik Gasmi
-*/
-//Konfiguration laden
-require_once("config.inc.php");
-
-$ldapError = null;
-
-
-# Liefert Array aller Child-Knoten mit bestimmten ausgwählten Attributen
-function get_childs($baseDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $baseDN, "(objectclass=*)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $childau_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $childau_array[] = $atts;
- }
- if($attributes != false ){return $childau_array;}
- else{return $result;}
- }
-}
-
-# Liefert die RDNs aller Child-Knoten
-function get_childs_rdn($baseDN){
-
- $childs = get_childs($baseDN,array("dn"));
- # print_r($childs); echo "<br><br>";
-
- $childs_rdn = array();
- foreach ($childs as $item){
- $exp = explode(',',$item['dn']);
- $rdn = $exp[0];
- $childs_rdn[] = $rdn;
- }
-
- # print_r($childs_rdn);
- return $childs_rdn;
-}
-
-
-# Attribute eines Knotens (Vorsicht Array enthält noch DN und COUNT)
-# in einem Array wie er z.B. von ldap_add verwendet wird
-function get_node_attributes($nodeDN){
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $nodeDN, "(objectclass=*)", array(), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- # print_r($result);
- foreach ($result as $item){
- foreach (array_keys($item) as $merkmal)
- $attrs[$merkmal] = $item[$merkmal];
- }
- return $attrs;
-}
-
-# Rekursives Kopieren
-function dive_into_tree_cp($baseDN,$new_baseDN){
-
- global $ds, $suffix, $ldapError;
-
- $expldn = ldap_explode_dn($new_baseDN,0);
- $new_node_rdn = $expldn[0];
- $exp = explode('=',$new_node_rdn);
- $new_node_rdn_merk = $exp[0];
- $new_node_rdn_val = $exp[1];
- $new_node_rdn_merk = strtolower($new_node_rdn_merk);
-
- $childs_rdn = get_childs_rdn($baseDN);
-
- $attrs = get_node_attributes($baseDN);
- # print_r($attrs); echo "<br>";
- unset($attrs['dn']);
- unset($attrs['count']);
- $attrs["$new_node_rdn_merk"] = $new_node_rdn_val;
- # print_r($attrs); echo "<br>";
-
- $result = ldap_add($ds,$new_baseDN,$attrs);
-
-
- //recursivly do dive for each child
- foreach($childs_rdn as $rdn){
- dive_into_tree_cp( $rdn.",".$baseDN , $rdn.",".$new_baseDN);
- }
- return $result;
-}
-
-
-#
-# Rekursives Loeschen
-function dive_into_tree_del($baseDN,$except){
-
- global $ds, $suffix, $ldapError;
-
- $childs_rdn = get_childs_rdn($baseDN);
- //recursivly do dive for each child
- foreach($childs_rdn as $rdn){
- dive_into_tree_del( $rdn.",".$baseDN , $except);
- }
- if($baseDN != $except){
- $result = ldap_delete($ds,$baseDN);
- }
-
- return $result;
-}
-
-# Rekursives Verschieben
-function move_subtree($oldDN,$newDN){
-
- if(dive_into_tree_cp($oldDN,$newDN))
- {
- dive_into_tree_del($oldDN,"");
- echo "Moved subtree<br>";
- return 1;
- }
- else echo "Moving subtree not possible!!!<br>";
-}
-
-
-function adjust_dn_entries($oldDN,$newDN){
-
- global $ds, $suffix, $ldapError;
-
- # single Attributes:
- if(!($result = uniLdapSearch($ds, $newDN, "(objectclass=host)", array("dn","dhcphlpcont"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item){
- if (strpos($item['dhcphlpcont'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item['dhcphlpcont']);
- $entry['dhcphlpcont'] = $newvalue;
- ldap_mod_replace($ds,$item['dn'],$entry);
- }
- }
-
- if(!($result = uniLdapSearch($ds, $newDN, "(objectclass=PXEConfig)", array("dn","rbservicedn"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item2){
- if (strpos($item2['rbservicedn'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item2['rbservicedn']);
- $entry2['rbservicedn'] = $newvalue;
- ldap_mod_replace($ds,$item2['dn'],$entry2);
- }
- }
-
- if(!($result = uniLdapSearch($ds, $newDN, "(objectclass=dhcpService)", array("dn","dhcpprimarydn","dhcpsecondarydn"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item3){
- if (strpos($item3['dhcpprimarydn'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item3['dhcpprimarydn']);
- $entry3['dhcpprimarydn'] = $newvalue;
- ldap_mod_replace($ds,$item3['dn'],$entry3);
- }
- if (strpos($item3['dhcpsecondarydn'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item3['dhcpsecondarydn']);
- $entry4['dhcpsecondarydn'] = $newvalue;
- ldap_mod_replace($ds,$item3['dn'],$entry4);
- }
- }
-
- if(!($result = uniLdapSearch($ds, $newDN, "(objectclass=MenuEntry)", array("dn","genericmenuentrydn","ldapuri"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item4){
- if (strpos($item4['genericmenuentrydn'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item4['genericmenuentrydn']);
- $entry5['genericmenuentrydn'] = $newvalue;
- ldap_mod_replace($ds,$item4['dn'],$entry5);
- }
- if (strpos($item4['ldapuri'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item4['ldapuri']);
- $entry6['ldapuri'] = $newvalue;
- ldap_mod_replace($ds,$item4['dn'],$entry6);
- }
- }
-
- # Multi-Attribut member
- if(!($result = uniLdapSearch($ds, $newDN, "(objectclass=groupOfComputers)", array("dn","member","dhcphlpcont"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item5){
- for ($i=0; $i<count($item5['member']); $i++){
- if (strpos($item5['member'][$i],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item5['member'][$i]);
- $entry7['member'][$i] = $newvalue;
- }else{
- $entry7['member'][$i] = $item5['member'][$i];
- }
- ldap_mod_replace($ds,$item5['dn'],$entry7);
- }
- if (strpos($item5['dhcphlpcont'],$oldDN) != false){
- $newvalue = str_replace($oldDN,$newDN,$item5['dhcphlpcont']);
- $entry8['dhcphlpcont'] = $newvalue;
- ldap_mod_replace($ds,$item5['dn'],$entry8);
- }
-
- }
-
- # Attribut AssociatedName in DNS Teilbaum
- if(!($result = uniLdapSearch($ds, "ou=DNS,".$suffix , "(associatedname=$oldDN)", array("dn","associatedname"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item6){
- $newvalue = str_replace($oldDN,$newDN,$item6['associatedname']);
- $entry9['associatedname'] = $newvalue;
- ldap_mod_replace($ds,$item6['dn'],$entry9);
- }
-
- # Attribut RelativeDomainName in DNS Teilbaum ... noch nicht fertig
- $hostdnexpold = ldap_explode_dn($oldDN, 0);
- $hostdnexpnew = ldap_explode_dn($newDN, 0);
- $oldhostname = $hostdnexpold[0];
- $newhostname = $hostdnexpnew[0];
- if(!($result = uniLdapSearch($ds, "ou=DNS,".$suffix , "(relativedomainname=$oldhostname)", array("dn","relativedomainname"), "", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- foreach ($result as $item7){
- $newvalue = str_replace($oldhostname,$newhostname,$item7['relativedomainname']);
- $entry10['relativedomainname'] = $newvalue;
- ldap_mod_replace($ds,$item7['dn'],$entry10);
- }
-
-}
-
-
-
-function check_for_dc($dn, $dc){
- global $ds, $suffix, $ldapError;
- if(!($result = uniLdapSearch($ds, $dn, "(dc=$dc)", array("dc"), "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- if (count($result[0]['dc']) == 0 ) {return 0;}
- elseif ($result[0]['dc'] == $dc){return 1;}
-}
-
-
-function get_dc_childs($baseDN,$attributes)
-{
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $baseDN, "(objectclass=dnsdomain)", $attributes, "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else {
- $result = ldapArraySauber($result);
-
- $childau_array = array();
- foreach ($result as $item){
- foreach ($attributes as $att){
- $atts[$att] = $item[$att];
- }
- $childau_array[] = $atts;
- }
- if($attributes != false ){return $childau_array;}
- else{return $result;}
- }
-}
-
-# Liefert die RDNs aller dc-Child-Knoten
-function get_dc_childs_rdn($baseDN){
-
- global $ds, $suffix, $ldapError;
-
- $childs = get_dc_childs($baseDN,array("dn"));
- # print_r($childs); echo "<br><br>";
-
- $childs_rdn = array();
- foreach ($childs as $item){
- $exp = explode(',',$item['dn']);
- $rdn = $exp[0];
- $childs_rdn[] = $rdn;
- }
-
- # print_r($childs_rdn);
- return $childs_rdn;
-}
-
-function get_entry_number($entryDN,$entryobjectclass){
-
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, $entryDN, "(objectclass=machineconfig)", array("count"), "", "one", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- print_r ($result);
-
-}
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/rbs_management_functions.php b/ldap-site-mngmt/webinterface/lib/rbs_management_functions.php
deleted file mode 100644
index 2e7d5348..00000000
--- a/ldap-site-mngmt/webinterface/lib/rbs_management_functions.php
+++ /dev/null
@@ -1,685 +0,0 @@
-<?php
-
-/**
-* rbs_management_functions.php - Remote Boot Services Management Funktions-Bibliothek
-* Diese Bibliothek enthält alle Funktionen für die Verwaltung von RBS Diensten,
-* PXE Konfigurationsdateien ihren Menüeinträgen und ihren Genersichen Bootmenüeinträgen
-*
-* @param string ldapError
-* @param resource ds
-*
-* @author Tarik Gasmi
-* @copyright Tarik Gasmi
-*/
-
-
-# Konfiguration laden
-require_once("config.inc.php");
-
-$ldapError = null;
-
-
-#######################################################################
-# Funktionen zur Verwaltung von RBS Diensten
-#
-
-#
-# Neues RBS Dienst-Objekt anlegen
-#
-function add_rbs($rbsDN,$rbscn,$rbsoffer,$server,$atts){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $rbsentry ['objectclass'][0] = "RBService";
- $rbsentry ['objectclass'][1] = "top";
- $rbsentry ['cn'] = $rbscn;
- $rbsentry ['rbsofferdn'] = $rbsoffer;
- if (count($atts) != 0){
- foreach (array_keys($atts) as $key){
- if ($atts[$key] != ""){
- $rbsentry[$key] = $atts[$key];
- }
- }
- }
- if (count($server) != 0){
- if ($server['tftp'] != ""){$rbsentry ['tftpserverip'] = $server['tftp'];}
- if ($server['nfs'] != ""){$rbsentry ['nfsserverip'] = $server['nfs'];}
- if ($server['nbd'] != ""){$rbsentry ['nbdserverip'] = $server['nbd'];}
- }
- # print_r($rbsentry); echo "<br>";
- print_r($rbsDN); echo "<br>";
-
- # Standard Fallback Menü anlegen
- $pxecn = "PXE_Fallback-No-Config";
- $pxeDN = "cn=".$pxecn.",".$rbsDN;
- $filename = array("fallback-nopxe");
- $ldapuri = LDAP_HOST."/dn=cn=computers,".$auDN; # wirklich nötig??
- $mecn = "Fallback-Text";
- $meDN = "cn=".$mecn.",".$pxeDN;
- $meattribs = array("label" => "Keine PXE Boot-Konfiguration fuer die aktuelle Zeit definiert",
- "kernel" => "menu.c32",
- "submenulink" => "fallback-nopxe");
-
- if (ldap_add($ds,$rbsDN,$rbsentry)){
- if (add_pxe($pxeDN,$pxecn,$rbsDN,"",array(),$filename,$ldapuri)){
- if (add_me($meDN,$mecn,"","01",$meattribs,$pxeDN)){
- return 1;
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
-}
-
-#
-# "RBS-Angebote" im Verzeichnis suchen, die die AU ($auDN) nutzen darf,
-# Suche nach passenden RBS-Offer-DNs
-#
-function get_rbsoffers($auDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $attribs = array("dn","rbsofferdn");
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(objectclass=RBService)", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- #print_r($result);echo "<br><br>";
-
- $rbs_offers = array();
- foreach ($result as $rbs){
- #print_r(strpos($auDN, $rbs['rbsofferdn']));echo "<br>";
- if ( strpos($auDN, $rbs['rbsofferdn']) !== false )
- $rbs_offers [] = $rbs['dn'];
- }
- }
- #print_r($rbs_offers);echo "<br><br>";
- return $rbs_offers;
-}
-
-
-#
-# Beim Löschen von RBS-Objekten muss dafür gesorgt werden dass keine PXEs mehr auf
-# diese zeigen, Ref. Abhängigkeiten
-#
-function clean_up_del_rbs($rbsDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $attribs = array("dn");
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=PXEConfig)(rbservicedn=$rbsDN))", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- $delentry ['rbservicedn'] = $rbsDN;
- foreach ($result as $item){
- #print_r($item['dn']); echo "<br>";
- ldap_mod_del($ds, $item['dn'], $delentry);
- }
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=Host)(hlprbservice=$rbsDN))", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- $delentry2 ['hlprbservice'] = $rbsDN;
- foreach ($result as $item){
- #print_r($item['dn']); echo "<br>";
- ldap_mod_del($ds, $item['dn'], $delentry2);
- }
-
-}
-
-#
-# beim ändern des CN (DN) des RBS muss dieses in allen referenzierenden PXEConfig-Objekten
-# nachvollzogen werden, Ref. Abhängigkeiten
-#
-function adjust_rbs_dn($newrbsDN, $rbsDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=PXEConfig)(rbservicedn=$rbsDN))", array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $modentry ['rbservicedn'] = $newrbsDN;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modentry);
- }
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=Host)(hlprbservice=$rbsDN))", array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $modentry2 ['hlprbservice'] = $newrbsDN;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modentry2);
- }
-}
-
-function rbs_adjust_host($hostDN, $rbs){
-
- global $ds, $suffix, $ldapError;
-
- $modentry ['rbservicedn'] = $rbs;
-
- $pxearray = get_pxeconfigs($hostDN,array("dn"));
- if ( count($pxearray) != 0 ){
- foreach ( $pxearray as $item ){
- if ($result = ldap_mod_replace($ds,$item['dn'],$modentry)){
- return 1;
- }else{
- return 0;
- }
- }
- }
-}
-
-# Bei Änderung der TFTP Server IP eines RBS-Objekts entsprechend DHCP Option next-server
-# in den Hostobjekten anpassen und DHCP modify time in den AUs aktualisieren
-function adjust_dhcpnextserver($tftpIP, $rbsDN){
-
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(|(objectclass=Host)(objectclass=dhcpPool))(hlprbservice=$rbsDN))", array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $host_au = array();
- if ($tftpIP == ""){
- $deltftpentry ['dhcpoptnext-server'] = array();
- foreach ($result as $item){
- ldap_mod_del($ds, $item['dn'], array());
- $expdn = array_slice(ldap_explode_dn($item['dn'], 0), 3);
- $host_au [] = implode(",", $expdn);
- }
- }else{
- $modtftpentry ['dhcpoptnext-server'] = $tftpIP;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modtftpentry);
- $expdn = array_slice(ldap_explode_dn($item['dn'], 0), 3);
- $host_au [] = implode(",", $expdn);
- }
- }
- if ( count($host_au) != 0 ){
- $host_au = array_unique($host_au);
- update_dhcpmtime($host_au);
- }
-}
-
-# Bei Änderung des PXE Init Boot File eines RBS-Objekts entsprechend DHCP Option Filename
-# in den Hostobjekten anpassen
-function adjust_dhcpfilename($initbootfile, $rbsDN, $type){
-
- global $ds, $suffix, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=Host)(hlprbservice=$rbsDN))", array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $host_au = array();
- if ($type == "add"){
- $modentry ['dhcpoptfilename'] = $initbootfile;
- foreach ($result as $item){
- ldap_mod_add($ds, $item['dn'], $modentry);
- }
- }
- elseif ($type == "delete"){
- $modentry ['dhcpoptfilename'] = array();
- foreach ($result as $item){
- ldap_mod_del($ds, $item['dn'], $modentry);
- }
- }
- elseif ($type == "replace"){
- $modentry ['dhcpoptfilename'] = $initbootfile;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modentry);
- $expdn = array_slice(ldap_explode_dn($item['dn'], 0), 3);
- $host_au [] = implode(",", $expdn);
- }
- }
- if ( count($host_au) != 0 ){
- $host_au = array_unique($host_au);
- update_dhcpmtime($host_au);
- }
-}
-
-# IP Adresse eines Host ändern -> RBS TFTP Server IP anpassen (inkl. dhcpNext-server)
-function adjust_hostip_tftpserverip($oldip,$newip){
-
- global $ds, $suffix, $ldapError, $auDN;
-
- if(!($result = uniLdapSearch($ds, "cn=rbs,".$auDN, "(&(objectclass=RBService)(tftpserverip=$oldip))", array("dn","tftpserverip"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- if (count($result) != 0){
- foreach ($result as $item){
- if ($newip == ""){
- $delentry ['tftpserverip'] = array();
- ldap_mod_del($ds, $item['dn'], $delentry);
- adjust_dhcpnextserver("", $item['dn']);
- }else{
- $modentry ['tftpserverip'] = $newip;
- ldap_mod_replace($ds, $item['dn'], $modentry);
- adjust_dhcpnextserver($newip, $item['dn']);
- }
- }
- }
-}
-
-#
-# Sucht den Hostname zu einer IP im Rechnerteilbaum der AU
-# Verwaltung der am RBS beteiligten Server
-#
-function get_hostname_from_ip($ip){
-
- global $ds, $suffix, $ldapError, $auDN;
-
- $ipp = array($ip,$ip);
- $ipaddress = implode('_',$ipp);
- if(!($result = uniLdapSearch($ds, "cn=computers,".$auDN, "(&(objectclass=Host)(ipaddress=$ipaddress))", array("dn","hostname"), "", "list", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result);
- $host ['hostname'] = $result[0]['hostname'];
- $host ['dn'] = $result[0]['dn'];
- return $host;
-}
-
-
-###############################################################################
-# Funktionen zur Verwaltung von PXE Bootmenüs
-
-#
-# Überprüft, ob sich die angegebene Timerange auf einer der 4 Spezifikationsstufen mit anderen
-# Timeranges des Objkets überschneidet
-#
-function check_timerange_pxe($pxeday,$pxebeg,$pxeend,$nodeDN,$excepttimerange){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $brothers = get_pxeconfigs($nodeDN,array("timerange"));
- # keine Ãœberschneidungen pro Spez.Ebene zulassen
- # print_r($brothers); echo "<br><br>";
- if (count($brothers) != 0){
-
- $intersect = 0;
- foreach ($brothers as $item){
-
- # Fall das Brother mehrere TimeRanges hat
- if (count($item['timerange']) > 1){
- foreach ($item['timerange'] as $tr){
-
- if($tr != $excepttimerange){
- $exptime = explode('_',$tr);
- $bpxeday = $exptime[0];
- $bpxebeg = $exptime[1];
- $bpxeend = $exptime[2];
- #echo "pxeday:"; print_r($pxeday); echo "<br>";
- #echo "bpxeday:"; print_r($bpxeday); echo "<br>";
- #echo "pxebeg:"; print_r($pxebeg); echo "<br>";
- #echo "bpxebeg:"; print_r($bpxebeg); echo "<br>";
- #echo "pxeend:"; print_r($pxeend); echo "<br>";
- #echo "bpxeend:"; print_r($bpxeend); echo "<br>";
-
- if ($pxeday == $bpxeday){
- if ( $pxebeg > $bpxeend || $pxeend < $bpxebeg ){
- # keine Ãœberschneidung in der Uhrzeit
- }else{
- # Uhrzeit Ãœberschneidung
- $intersect = 1;
- $intersecttr = $bpxeday."_".$bpxebeg."_".$bpxeend;
- break;
- }
- }
- }
-
- }
- }
- # Fall das Brother nur eine TimeRange hat
- elseif (count($item['timerange']) == 1){
-
- if($item['timerange'] != $excepttimerange){
- $exptime = explode('_',$item['timerange']);
- $bpxeday = $exptime[0];
- $bpxebeg = $exptime[1];
- $bpxeend = $exptime[2];
- #echo "pxeday:"; print_r($pxeday); echo "<br>";
- #echo "bpxeday:"; print_r($bpxeday); echo "<br>";
- #echo "pxebeg:"; print_r($pxebeg); echo "<br>";
- #echo "bpxebeg:"; print_r($bpxebeg); echo "<br>";
- #echo "pxeend:"; print_r($pxeend); echo "<br>";
- #echo "bmcend:"; print_r($bpxeend); echo "<br>";
-
- if ($pxeday == $bpxeday){
- if ( $pxebeg > $bpxeend || $pxeend < $bpxebeg ){
- # keine Ãœberschneidung in der Uhrzeit
- }else{
- # Uhrzeit Ãœberschneidung
- $intersect = 1;
- $intersecttr = $bpxeday."_".$bpxebeg."_".$bpxeend;
- break;
- }
- }
- }
- }
- }
- #echo "intersect: "; print_r($intersect); echo "<br>";
- if ($intersect == 1){
- echo "<b>[".$pxeday."_".$pxebeg."_".$pxeend."]</b> &uuml;berschneidet sich mit der
- bereits existierende <b>Time Range [".$intersecttr."]</b> !<br><br>";
- return 0;
- }else{
- return 1;
- }
- }else{
- return 1;
- }
-}
-
-
-#
-# Neues PXE Bootmenü anlegen
-#
-function add_pxe($pxeDN,$pxecn,$rbsDN,$pxetimerange,$pxeattribs,$filenames,$conffile){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $pxeentry ['objectclass'][0] = "PXEConfig";
- $pxeentry ['objectclass'][1] = "top";
- $pxeentry ['cn'] = $pxecn;
- $pxeentry ['rbservicedn'] = $rbsDN;
- #$pxeentry ['ldapuri'] = $ldapuri;
- if ($conffile != ""){$pxeentry ['fileuri'] = $conffile;}
- if (count($filenames) > 1 ){
- for ($i=0; $i<count($filenames); $i++){
- $pxeentry ['filename'][$i] = $filenames[$i];
- }
- }
- if (count($filenames) == 1){
- $pxeentry ['filename'] = $filenames[0];
- }
- if ($pxetimerange != ""){$pxeentry ['timerange'] = $pxetimerange;}
- if (count($pxeattribs) != 0){
- foreach (array_keys($pxeattribs) as $key){
- if ($pxeattribs[$key] != ""){
- $pxeentry[$key] = $pxeattribs[$key];
- }
- }
- }
- print_r($pxeentry); echo "<br>";
- print_r($pxeDN); echo "<br>";
- if (ldap_add($ds,$pxeDN,$pxeentry)){
- return 1;
- }
- else{
- return 0;
- }
-}
-
-
-#
-# PXE CN (DN) ändern, Teilbaum verschieben
-#
-function modify_pxe_dn($pxeDN, $newpxeDN){
-
- global $ds, $suffix, $ldapError;
-
- if (move_subtree($pxeDN,$newpxeDN)){
- return 1;
- }else{
- return 0;
- }
-}
-
-
-#
-# Timerange eines PXEConfig-Objekts ändern
-#
-function change_pxe_timerange($pxeDN,$newpxeDN,$pxetimerange){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- # move tree
- if (move_subtree($pxeDN,$newpxeDN)){
- # timerange ändern
- $entrypxe ['timerange'] = $pxetimerange;
- if (ldap_mod_replace($ds,$newpxeDN,$entrypxe)){
- return 1;
- }
- else{
- return 0;
- }
- }
- else{
- return 0;
- }
-}
-
-#
-# nach dem Löschen von PXEConfig Menueinträgen müssen Menüpositionen in der PXEConfig
-# angepasst werden (Lücken schließen)
-#
-function cleanup_menupositions($pxeDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $me = get_menuentries($pxeDN,array("dn","menuposition"));
- if (count($me) != 0){
- foreach ($me as $item){
- $pos = $item['menuposition'];
- $pos = preg_replace ( '/0([0-9])/', '$1', $pos);
- $menpos[$pos] = $item['dn'];
- ksort($menpos);
- }
- $p = 1;
- foreach ($menpos as $item){
- if (strlen($p) == 1){
- $p = "0".$p;
- }
- $entry ['menuposition'] = $p;
- ldap_mod_replace($ds,$item,$entry);
- $p++;
- }
- }
-}
-
-#
-# Hilfsfunktion zur Verarbeitung von Menüpositionen in PXEConfigs
-#
-function increment_menupositions($pxeDN,$menpos){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- $meDN = get_dn_menuposition($pxeDN,$menpos);
- if ($meDN != ""){
- # zur Berechnung erst führende Nullen weg
- $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- $newpos = $menpos+1;
- increment_menupositions($pxeDN,$newpos);
- # zum Eintragen führenden Nullen wieder dazu
- if (strlen($newpos) == 1){
- $newpos = "0".$newpos;
- }
- $entry ['menuposition'] = $newpos;
- ldap_mod_replace($ds,$meDN,$entry);
- }
-}
-
-#
-# Neuen Menüeintrag anlegen
-#
-function add_me($meDN,$mecn,$gbmDN,$menpos,$meattribs,$pxeDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $mentry ['objectclass'][0] = "MenuEntry";
- $mentry ['objectclass'][1] = "top";
- $mentry ['cn'] = $mecn;
- if($gbmDN != ""){$mentry ['genericmenuentrydn'] = $gbmDN;}
- $mentry ['menuposition'] = $menpos;
- if (count($meattribs) != 0){
- foreach (array_keys($meattribs) as $key){
- if ($meattribs[$key] != ""){
- $mentry[$key] = $meattribs[$key];
- }
- }
- }
- print_r($mentry); echo "<br>";
- print_r($meDN); echo "<br>";
- increment_menupositions($pxeDN,$menpos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$mentry)){
- return 1;
- }
- else{
- return 0;
- }
-}
-
-
-#
-# Menu Entry CN (DN) ändern
-#
-function modify_me_dn($meDN, $newmeDN){
-
- global $ds, $suffix, $ldapError;
-
- if (move_subtree($meDN,$newmeDN)){
- return 1;
- }else{
- return 0;
- }
-}
-
-
-
-#####################################################################
-# Verwaltung von GBM
-#
-
-function add_gbm($gbmDN,$gbmcn,$attribs){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $gbmcn;
- if (count($attribs) != 0){
- foreach (array_keys($attribs) as $key){
- if ($attribs[$key] != ""){
- $entry[$key] = $attribs[$key];
- }
- }
- }
- print_r($entry); echo "<br>";
- print_r($gbmDN); echo "<br>";
- if (ldap_add($ds,$gbmDN,$entry)){
- return 1;
- }
- else{
- return 0;
- }
-}
-
-
-#
-# beim löschen von GBMs muss dafür gesorgt werden, dass keine MEs mehr auf diese zeigen,
-# Ref.Abhängigkeiten (sonst gibts Fehler beim PXE-Perlskript und die Nutzer wissen nicht dass ihr PXE Menü nicht
-# mehr funktioniert, so kann man durch Fehlen des gbmDN wissen das es kein GBM mehr zu diesem ME gibt
-#
-function clean_up_del_gbm($gbmDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $attribs = array("dn","genericmenuentrydn");
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=MenuEntry)(genericmenuentrydn=$gbmDN))", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- #print_r($result); echo "<br><br>";
- $delentry ['genericmenuentrydn'] = $gbmDN;
- foreach ($result as $item){
- #print_r($item['dn']); echo "<br>";
- ldap_mod_del($ds, $item['dn'], $delentry);
- }
-
-}
-
-
-#
-# beim ändern des CN (DN) des GBM, Meüeinträge anpassen, Ref. Abhängigkeiten
-#
-function adjust_gbm_dn($newgbmDN, $gbmDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=MenuEntry)(genericmenuentrydn=$gbmDN))", array("dn"), "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- $result = ldapArraySauber($result);
- $modentry ['genericmenuentrydn'] = $newgbmDN;
- foreach ($result as $item){
- ldap_mod_replace($ds, $item['dn'], $modentry);
- }
-}
-
-
-
-function alternative_rbservices($rbsDN){
-
- global $ds, $suffix, $auDN, $ldapError;
-
- $alt_rbs = array();
-
- $rbsarray = get_rbsoffers($auDN);
- # print_r($rbsarray); echo "<br>";
- if (count($rbsarray) != 0){
- for ($i=0; $i < count($rbsarray); $i++){
- if ($rbsarray[$i] != $rbsDN){
- $exp = ldap_explode_dn ( $rbsarray[$i], 1 );
- $alt = array ("dn" => $rbsarray[$i], "cn" => $exp[0], "au" => " / ".$exp[2]);
- $alt_rbs[] = $alt;
- }
- }
- }
-
- return $alt_rbs;
-}
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/lib/syntax_check.php b/ldap-site-mngmt/webinterface/lib/syntax_check.php
deleted file mode 100644
index 48926260..00000000
--- a/ldap-site-mngmt/webinterface/lib/syntax_check.php
+++ /dev/null
@@ -1,302 +0,0 @@
-<?php
-/*
- Syntaxcheck 1.2 2006/08/08
-
- A class for checking syntax of forms data
- Copyright (c) Tarik Gasmi, All Rights Reserved
-*/
-
-
-class Syntaxcheck
-{
-
- var $ERROR = "";
- var $CLEAR = false;
-
- function Syntaxcheck ()
- {
- return;
- }
-
- function clear_error ()
- {
- $this->ERROR = "";
- }
-
-
-
-
-
-# Ist "dotted quad IPAddress" in gueltigem Bereich? true or false
-# Ueberprueft Format, fuehrende Nullen, und Werte > 255
-#
-# Ueberprueft nicht nach reservierten oder nicht-route-baren IPs.
-#
-function check_ip_syntax($IP)
-{
- if($this->CLEAR) { $this->clear_error();}
-
- $len = strlen($IP);
- if( $len > 15 ){
- $this->ERROR = "check_ip_syntax: too long [$IP][$len]";
- return false;
- }
-
- $badcharacter = eregi_replace("([0-9\.]+)","",$IP);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in IP address [$badcharacter]";
- return false;
- }
-
- $chunks = explode(".",$IP);
- $count = count($chunks);
- if ($count != 4){
- $this->ERROR = "check_ip_syntax: not a dotted quad [$IP]";
- return false;
- }
-
- while ( list ($key,$val) = each ($chunks) ){
- if(ereg("^0",$val)){
- $this->ERROR = "check_ip_syntax: Invalid IP segment [$val]";
- return false;
- }
- $Num = $val;
- settype($Num,"integer");
- if($Num > 255){
- $this->ERROR = "check_ip_syntax: Segment out of range [$Num]";
- return false;
- }
- }
-
- return true;
-
-}
-
-# Netzwerkaddresse
-function check_netip_syntax($IP)
-{
- if($this->CLEAR) { $this->clear_error();}
-
- if ( !($this->check_ip_syntax($IP)) ){
- return false;
- }
- $chunks = explode(".",$IP);
- if ( $chunks[3] != "0" ){
- return false;
- }
- return true;
-}
-
-# MAC Adresse
-function check_mac_syntax($MAC)
-{
- if($this->CLEAR) { $this->clear_error();}
-
- $len = strlen($MAC);
- if( $len != 17 ){
- $this->ERROR = "check_mac_syntax: too long [$MAC][$len]";
- return false;
- }
-
- $badcharacter = eregi_replace("([0-9a-fA-F\:]+)","",$MAC);
- if(!empty($badcharacter)){
- $this->ERROR = "check_mac_syntax: Bad data in MAC address [$badcharacter]";
- return false;
- }
-
- $chunks = explode(":",$MAC);
- $count = count($chunks);
- if ($count != 6){
- $this->ERROR = "check_mac_syntax: not in format hx:hx:hx:hx:hx:hx [$MAC]";
- return false;
- }
- foreach ($chunks as $chunk){
- $chunklen = strlen($chunk);
- if( $len != 2 ){
- $this->ERROR = "check_mac_syntax: too long [$MAC][$len]";
- return false;
- }
- }
-
- return true;
-
-}
-
-
-# Domainname
-
-# Hostname
-function is_hostname ($hostname = ""){
-
- if($this->CLEAR) { $this->clear_error(); }
-
- $web = false;
-
- if(empty($hostname))
- {
- $this->ERROR = "is_hostname: No hostname submitted";
- return false;
- }
-
- // Only a-z, 0-9, and "-" or "." are permitted in a hostname
-
- // Patch for POSIX regex lib by Sascha Schumann sas@schell.de
- $Bad = eregi_replace("[-A-Z0-9\.]","",$hostname);
-
- if(!empty($Bad))
- {
- $this->ERROR = "is_hostname: invalid chars [$Bad]";
- return false;
- }
-
- // See if we're doing www.hostname.tld or hostname.tld
- if(eregi("^www\.",$hostname))
- {
- $web = true;
- }
-
- // double "." is a not permitted
- if(ereg("\.\.",$hostname))
- {
- $this->ERROR = "is_hostname: Double dot in [$hostname]";
- return false;
- }
- if(ereg("^\.",$hostname))
- {
- $this->ERROR = "is_hostname: leading dot in [$hostname]";
- return false;
- }
-
- $chunks = explode(".",$hostname);
-
- if( (gettype($chunks)) != "array")
- {
- $this->ERROR = "is_hostname: Invalid hostname, no dot seperator [$hostname]";
- return false;
- }
-
- $count = ( (count($chunks)) - 1);
-
- if($count < 1)
- {
- $this->ERROR = "is_hostname: Invalid hostname [$count] [$hostname]\n";
- return false;
- }
-
- // Bug that can't be killed without doing an is_host,
- // something.something will return TRUE, even if it's something
- // stupid like NS.SOMETHING (with no tld), because SOMETHING is
- // construed to BE the tld. The is_bigfour and is_country
- // checks should help eliminate this inconsistancy. To really
- // be sure you've got a valid hostname, do an is_host() on it.
-
- if( ($web) and ($count < 2) )
- {
- $this->ERROR = "is_hostname: Invalid hostname [$count] [$hostname]\n";
- return false;
- }
-
- $tld = $chunks[$count];
-
- if(empty($tld))
- {
- $this->ERROR = "is_hostname: No TLD found in [$hostname]";
- return false;
- }
-
- if(!$this->is_bigfour($tld))
- {
- if(!$this->is_country($tld))
- {
- $this->ERROR = "is_hostname: Unrecognized TLD [$tld]";
- return false;
- }
- }
-
-
- return true;
-}
-
-
-# Syntax Check für die Eingaben: Uhrzeit, Wochentag, Monatstag, Monatstag.Monat
-function check_timerange_syntax($mcday,$mcbeg,$mcend){
-
- if($this->CLEAR) { $this->clear_error();}
-
- $badcharacter = eregi_replace("([a-z0-9\.]+)","",$mcday);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in MC Day [$badcharacter]";
- return false;
- }
- $badcharacter = eregi_replace("([x0-9]+)","",$mcbeg);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in MC Begin [$badcharacter]";
- return false;
- }
- $badcharacter = eregi_replace("([x0-9]+)","",$mcend);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in MC End [$badcharacter]";
- return false;
- }
-
- $lenmcday = strlen($mcday);
- if (eregi("([a-z]+)",$mcday)){
- if ($lenmcday > 2){$this->ERROR = "WOTAG > 2"; return false;}
- if (eregi("([0-9\.]+)",$mcday)){$this->ERROR = "WOTAG enthaelt (0-9.)"; return false;}
- #if (!(eregi("[mdsfx][aiorx]",$mcday))){return false;}
- if (!(eregi("(m[io]|d[io]|s[ao]|fr|x)",$mcday))){$this->ERROR = "WOTAG falscher String"; return false;}
- }
- if (eregi("([0-9]+)",$mcday)){
- if (eregi("[\.]",$mcday)){
- preg_match("/[\.]/",$mcday,$treffer);
- if (count($treffer) > 1){$this->ERROR = "mehr als 2 Punkte"; return false;};
- $exp = explode('.',$mcday);
- $day = $exp[0];
- $lenday = strlen($day);
- if ($lenday > 2){$this->ERROR = "TAG > 2"; return false;}
- if (!(eregi("(0[1-9]|[0-2][0-9]|3[01])",$day))){$this->ERROR = "TAG nicht korrekt"; return false;}
- $month = $exp[1];
- $lenmonth = strlen($month);
- if ($lenmonth > 2){$this->ERROR = "MONAT > 2"; return false;}
- if (!(eregi("(0[0-9]|0[0-9]|1[0-2])",$month))){$this->ERROR = "Monat nicht korrekt"; return false;}
-
- }
- else{
- if ($lenmcday > 2){$this->ERROR = "TAG > 2"; return false;}
- if (!(eregi("(0[0-9]|[0-2][0-9]|3[01])",$mcday))){$this->ERROR = "Tag nicht korrekt"; return false;}
- }
- }
-
- $lenmcbeg = strlen($mcbeg);
- if ($lenmcbeg == 2){
- if (!(eregi("(0[0-9]|1[0-9]|2[0-3]|x)",$mcbeg))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
- if ($lenmcbeg == 1){
- if (!(eregi("([0-9]|x)",$mcbeg))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
- $lenmcend = strlen($mcend);
- if ($lenmcend == 2){
- if (!(eregi("(0[0-9]|1[0-9]|2[0-3]|x)",$mcend))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
- if ($lenmcend == 1){
- if (!(eregi("([0-9]|x)",$mcend))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
-
- return true;
-}
-
-
-# Überprüft ob Menuposition ein Zahl ist
-function check_menuposition($menpos){
-
- if($this->CLEAR) { $this->clear_error();}
-
- $badcharacter = eregi_replace("([0-9]+)","",$menpos);
- if(!empty($badcharacter)){
- $this->ERROR = "check_menupostion: Bad data in Menu Position [$badcharacter]";
- return false;
- }
-}
-
-}
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/login_form.inc.html b/ldap-site-mngmt/webinterface/login_form.inc.html
deleted file mode 100644
index f9e32891..00000000
--- a/ldap-site-mngmt/webinterface/login_form.inc.html
+++ /dev/null
@@ -1,29 +0,0 @@
-<form name="loginform" action="{PFAD}login_sicher.php" method="post">
- <table border="0" cellspacing="0" cellpadding="2">
- <!--<tr>
- <td colspan="2"><p><b>Benutzerlogin:</b></p></td>
- </tr>-->
- <tr>
- <td colspan="3">&nbsp;</td>
- </tr>
- <tr>
- <td><p class="small_loginform_text"><b>UserID:</b></p></td>
- <td><input type="Text" name="uid" size="15" class="small_loginform_field" select> </td>
- <td><p class="small_loginform_text">&nbsp;</p></td>
- </tr>
- <tr>
- <td><p class="small_loginform_text"><b>Passwort:</b></p></td>
- <td><input type="Password" name="userPassword" size="15" class="small_loginform_field"> </td>
- <td><p class="small_loginform_text">&nbsp;</p></td>
- </tr>
- <tr>
- <td><p class="small_loginform_text">&nbsp;</p></td>
- <td align="right"><input type="Submit" name="Login" value="Anmelden" class="small_loginform_button"></td>
- <td><p class="small_loginform_text">&nbsp;</p></td>
- </tr>
- </table>
-</form>
-
-<script type="text/javascript">
- document.loginform.uid.focus();
-</script> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/login_sicher.php b/ldap-site-mngmt/webinterface/login_sicher.php
deleted file mode 100644
index 307b7b92..00000000
--- a/ldap-site-mngmt/webinterface/login_sicher.php
+++ /dev/null
@@ -1,365 +0,0 @@
-<?php
-/**
-* login_sicher.php f�hrt einen Bind mit den eingegebenen Benutzerdaten durch.
-* Dabei erfolgt die Authetifizierung entsprechend der Ausf�hrung bei der Pr�sentation des Projektes
-* am RZ-LDAP. Das Passwort des Users wird aber nun nicht mehr auf dem Gruppe1 LDAP gespeichert. Dort
-* legt das Skript ein Standardpasswort an.
-* Im Fehlerfall wird eine Meldung ausgegeben und anschlie�end auf index.php weitergeleitet.
-* Bei erfolgreichem nicht anonymem Bind werden die Benutzerrechte ausgelesen und davon abh�ngig
-* die entsprechende Startseite aufgerufen. dn, uid, userPassword, cn und die Rechte werden in
-* einer Session gespeichert.
-*
-* DIESE VERSION IST AKTUELL IM EINSATZ!!!!
-*
-* @version V3.2
-* @author Timothy Burk
-*/
-session_cache_expire(30);
-session_start();
-
-# LDAP-Bibliothek einbinden
-include("lib/ldap.inc.php");
-# Standard-Bibliothek einbinden
-include("lib/commonlib.inc.php");
-
-$uid = $_POST['uid'];
-$userPassword = $_POST['userPassword'];
-# $userDn_rz = "uid=".$uid.",ou=people,".$suffix_rz;
-$userDN = "uid=".$uid.",ou=people,".$suffix;
-
-#echo "uid: "; print_r($uid); echo "<br>";
-#echo "pw: "; print_r($userPassword); echo "<br>";
-
-checkLogin($uid,$userPassword);
-
-/**
-* checkLogin($uid, $userPassword) - Authentifizierung am RZ-LDAP und Gruppe1-LDAP
-*
-* Wenn RZ-LDAP-Login UND Gruppe1-LDAP-Login erfolgreich sind, dann ist der User
-* bereits im Gruppe1-LDAP eingetragen.
-* -> Mache Datenabgleich und anschlie�enden Login am Gruppe1-LDAP
-* Wenn RZ-LDAP-Login erfolgreich, Gruppe1-LDAP-Login jedoch nicht erfolgreich ist,
-* dann unterscheide zwischen zwei M�glichkeiten:
-* 1. Der User ist im Gruppe1-LDAP nicht angelegt,
-* 2. Der User ist im Gruppe1-LDAP zwar angelegt, aber das Passwort wurde auf dem RZ-LDAP inzwischen ge�ndert.
-* -> Login als Dummy und Check, ob UID vorhanden
-* Wenn RZ-LDAP-Login nicht erfolgreich, Gruppe1-LDAP-Login jedoch erfolgreich ist,
-* dann ist der User auf dem RZ-LDAP nicht gespeichert.
-* -> Login am Gruppe1-LDAP
-* In anderen F�llen waren die Zugangsdaten nicht korrekt.
-* -> Redirect auf index.php.
-*
-* Schema siehe auch /home/gruppe1/Praesentation/Login und Personen.pps
-*
-* @param string UID
-* @param string Password
-*
-* @see userLogin()
-* @see datenabgleich()
-* @see dummyUidCheck()
-* @see userAnlegen()
-*
-* @author Timothy Burk
-*/
-function checkLogin($uid = "", $userPassword = "") {
- global $userDn_rz, $userDN, $suffix, $suffix_rz, $ldapError, $standardPassword;
- # Abfrage, ob das Loginformular Daten enth�lt
- if(!(($uid == "") || ($userPassword == ""))) {
- # UID und Passwort wurden eingegeben
- # Fallunterscheidung welche Logins m�glich sind
- /* if(($ds_rz = rzLdapConnect($uid,$userPassword)) && ($ds = uniLdapConnect($uid, $standardPassword))) {
- # Wenn RZ-LDAP-Login UND Gruppe1-LDAP-Login erfolgreich sind, dann ist der User
- # bereits im Gruppe1-LDAP eingetragen.
- # -> Mache Datenabgleich und anschlie�enden Login am Gruppe1-LDAP
- datenabgleich($uid, $userPassword, $ds_rz, $ds);
- ldap_unbind($ds);
- ldap_unbind($ds_rz);
- $userPassword = $standardPassword;
- userLogin($uid, $userPassword);
- } else if(($ds_rz = rzLdapConnect($uid,$userPassword)) && !($ds = uniLdapConnect($uid, $standardPassword))) {
- # Wenn RZ-LDAP-Login erfolgreich, Gruppe1-LDAP-Login jedoch nicht erfolgreich ist,
- # dann unterscheide zwischen zwei M�glichkeiten:
- # 1. Der User ist im Gruppe1-LDAP nicht angelegt,
- # 2. Der User ist im Gruppe1-LDAP zwar angelegt, aber das Passwort wurde auf dem RZ-LDAP
- # inzwischen ge�ndert.
- # -> Login als Dummy und Check, ob UID vorhanden
- if(dummyUidCheck($uid)) {
- #changePassword($uid,$userPassword);
- $userPassword = $standardPassword;
- } else {
- userAnlegen($uid,$userPassword,$ds_rz);
- }
- ldap_unbind($ds_rz);
- $userPassword = $standardPassword;
- checkLogin($uid, $userPassword);
- } else if(!($ds_rz = rzLdapConnect($uid,$userPassword)) && */ if ($ds = uniLdapConnect($uid,$userPassword)) {
- # Wenn RZ-LDAP-Login nicht erfolgreich, Gruppe1-LDAP-Login jedoch erfolgreich ist,
- # dann ist der User auf dem RZ-LDAP nicht gespeichert.
- # -> Login am Gruppe1-LDAP
- ldap_unbind($ds);
- userLogin($uid, $userPassword);
- } else {
- # In anderen F�llen waren die Zugangsdaten nicht korrekt.
- # -> Redirect auf index.php.
- redirect(3, "index.php", "<h3>Bitte geben Sie korrekte Zugangsdaten ein.<h3>".$ldapError, FALSE);
- die;
- }
-
- } else {
- # UID und/oder Passwort wurden NICHT eingegeben
- redirect(3, "index.php", "<h3>Bitte geben Sie User-Id und Passwort ein.</h3>".$ldapError, FALSE);
- die;
- }
-}
-
-/**
-* dummyUidCheck($uid) - �berpr�ft, ob UID im Gruppe1-LPAD vorhanden ist.
-*
-* �ber den Dummyuser wird eine Verbindung zum Gruppe1-LDAP aufgebaut und die angegebene
-* UID wird gesucht.
-*
-* @param string UID
-*
-* @return boolean TRUE = UID vorhanden, FALSE = UID nicht gefunden
-*
-* @author Timothy Burk
-*/
-function dummyUidCheck($uid) {
- global $userDn, $suffix, $suffix_rz, $ldapError, $dummyUid, $dummyPassword;
- # Bei Erfolg stellen wir eine Verbindung mit unserem LDAP her. Dazu nutzen wir den Dummy:
- if(!($ds_dummy = uniLdapConnect($dummyUid, $dummyPassword))) {
- redirect(5, "index.php", "Dummy-Login fehlgeschlagen!<br>".$ldapError, FALSE);
- die;
- }
- # Im n�chsten Schritt wird �berpr�ft, ob ein Eintrag mit der UID $uid schon vorliegt:
- if(!($person_daten = uniLdapSearch($ds_dummy, "ou=people,".$suffix, "uid=$uid", array("*"), "", "list", 0, 0))) {
- redirect(5, "index.php", $ldapError, FALSE);
- die;
- }
- if($person_daten['count'] == 0) {
- # Eintrag ist nicht vorhanden. -> Anlegen
- ldap_unbind($ds_dummy);
- return FALSE;
- } else {
- ldap_unbind($ds_dummy);
- return TRUE;
- }
-}
-
-/**
-* userAnlegen($uid,$userPassword,$ds_rz)
-*
-* Legt mithilfe des Dummyusers einen noch nicht bei uns gef�hrten User im Gruppe1-LDAP
-* mit den Daten des Rechenzentrums an. Das Passwort ist dabei f�r alle User in der config.inc.php festgelegt.
-*
-* @param string UID
-* @param string Password
-* @param resource RZ-LDAP Directory Handle
-*
-* @author Timothy Burk
-*/
-function userAnlegen($uid,$userPassword,$ds_rz) {
- global $userDn_rz, $userDn, $suffix, $suffix_rz, $ldapError, $dummyUid, $dummyPassword, $standardPassword;
- # Bei Erfolg stellen wir eine Verbindung mit unserem LDAP her. Dazu nutzen wir den Dummy:
- if(!($ds_dummy = uniLdapConnect($dummyUid, $dummyPassword))) {
- redirect(5, "index.php", "Dummy-Login fehlgeschlagen!<br>".$ldapError, FALSE);
- die;
- }
- # Im n�chsten Schritt wird �berpr�ft, ob ein Eintrag mit der UID $uid schon vorliegt:
- $ruffelder = array("uid", "sn", "givenname", "uidnumber", "gidnumber", "homedirectory", "loginshell", "rufnutzernummer", "rufanrede", "rufeinrichtung", "rufmatnr", "rufaccounttype", "ruffakultaet", "mail", "rufdienst");
-
- if(!($person_daten = uniLdapSearch($ds_rz, "ou=people,".$suffix_rz, "uid=$uid", $ruffelder, "", "list", 0, 0))) {
- redirect(5, "index.php", $ldapError, FALSE);
- die;
- }
- $person_daten = ldapArraySauber($person_daten);
- $person_daten = $person_daten[0];
- foreach($ruffelder as $ruffeld) {
- $ruffeld = str_replace("ruf","",$ruffeld);
- if($ruffeld == "accounttype") {
- $gruppe1felder[] = "employeetype";
- } else if($ruffeld == "anrede") {
- $gruppe1felder[] = "title";
- } else {
- $gruppe1felder[] = $ruffeld;
- }
- }
- $i = 0;
- $neuerEintrag = array();
- foreach($gruppe1felder as $gruppe1feld) {
- if (isset($person_daten[$ruffelder[$i]])) {
- $neuerEintrag[$gruppe1feld] = $person_daten[$ruffelder[$i]];
- } else {
- $neuerEintrag[$gruppe1feld] = '';
- }
- $i++;
- }
- if($neuerEintrag['employeetype'] != "student") {
- unset($neuerEintrag['employeetype']);
- } else {
- $neuerEintrag['employeetype'] = ucfirst($neuerEintrag['employeetype']);
- }
- $neuerEintrag['userPassword'] = $userPassword;
- # Ermitteln der Initialen: Erster Buchstabe des Vornamens und erster Buchstabe des Nachnamens
- $neuerEintrag['initials'] = substr($neuerEintrag['givenname'],0,1).".".substr($neuerEintrag['sn'],0,1).".";
-
- # CN erstellen
- $neuerEintrag['cn'] = $neuerEintrag['givenname']." ".$neuerEintrag['sn'];
-
- # Aktiv setzen
- $neuerEintrag['aktiv'] = "yes";
- $neuerEintrag = inputArraySauber($neuerEintrag);
-
- # Festes Sicherungspasswort setzen
- $neuerEintrag['userPassword'] = $standardPassword;
- if(!($add = uniLdapAdd($ds_dummy, $userDn, $neuerEintrag, "personen"))) {
- redirect(5, "index.php", "<b>Eintrag nicht erfolgreich</b><br>".$ldapError, FALSE);
- die;
- }
-}
-
-/**
-* datenabgleich($uid, $userPassword, $ds_rz, $ds) - �berschreibt bei jedem Login die Daten des
-* Gruppe1-LDAP mit denen des RZ-LDAP mithilfe des Dummyusers.
-*
-* @param string UID
-* @param string Password
-* @param resource ds_rz RZ-LDAP Directory Handle
-* @param resource ds Gruppe1-LDAP Directory Handle nach Bind mit Dummyuser
-*
-* @author Timothy Burk
-*/
-function datenabgleich($uid, $userPassword, $ds_rz, $ds) {
- global $userDn_rz, $userDn, $suffix, $suffix_rz, $ldapError, $dummyUid, $dummyPassword, $standardPassword;
- # Bei Erfolg stellen wir eine Verbindung mit unserem LDAP her. Dazu nutzen wir den Dummy:
- if(!($ds_dummy = uniLdapConnect($dummyUid, $dummyPassword))) {
- redirect(5, "index.php", "Dummy-Login fehlgeschlagen!<br>".$ldapError, FALSE);
- die;
- }
- # Im n�chsten Schritt wird �berpr�ft, ob ein Eintrag mit der UID $uid schon vorliegt:
- $ruffelder = array("uid", "sn", "givenname", "uidnumber", "gidnumber", "homedirectory", "loginshell", "rufnutzernummer", "rufanrede", "rufeinrichtung", "rufmatnr", "rufaccounttype", "ruffakultaet", "mail", "rufdienst");
-
- if(!($person_daten = uniLdapSearch($ds_rz, "ou=people,".$suffix_rz, "uid=$uid", $ruffelder, "", "list", 0, 0))) {
- redirect(5, "index.php", $ldapError, FALSE);
- die;
- }
- $person_daten = ldapArraySauber($person_daten);
- $person_daten = $person_daten[0];
- foreach($ruffelder as $ruffeld) {
- $ruffeld = str_replace("ruf","",$ruffeld);
- if($ruffeld == "accounttype") {
- $gruppe1felder[] = "employeetype";
- } else if($ruffeld == "anrede") {
- $gruppe1felder[] = "title";
- } else {
- $gruppe1felder[] = $ruffeld;
- }
- }
- $i = 0;
- $neuerEintrag = array();
- foreach($gruppe1felder as $gruppe1feld) {
- if (isset($person_daten[$ruffelder[$i]])) {
- $eintrag = $person_daten[$ruffelder[$i]];
- } else {
- $eintrag = '';
- }
- $neuerEintrag[$gruppe1feld] = $eintrag; //$person_daten[$ruffelder[$i]];
- $i++;
- }
-
- if($neuerEintrag['employeetype'] != "student") {
- unset($neuerEintrag['employeetype']);
- } else {
- $neuerEintrag['employeetype'] = ucfirst($neuerEintrag['employeetype']);
- }
- $neuerEintrag['userPassword'] = $userPassword;
- # Ermitteln der Initialen: Erster Buchstabe des Vornamens und erster Buchstabe des Nachnamens
- $neuerEintrag['initials'] = substr($neuerEintrag['givenname'],0,1).".".substr($neuerEintrag['sn'],0,1).".";
-
- # CN erstellen
- $neuerEintrag['cn'] = $neuerEintrag['givenname']." ".$neuerEintrag['sn'];
-
- # Aktiv setzen
- $neuerEintrag['aktiv'] = "yes";
- $neuerEintrag = inputArraySauber($neuerEintrag);
-
- # Festes Sicherungspasswort setzen
- $neuerEintrag['userPassword'] = $standardPassword;
-
- if(!($alteDaten = uniLdapSearch($ds_dummy, "ou=people,".$suffix, "uid=$uid", array("*"), "", "list", 0, 0))) {
- redirect(5, "index.php", $ldapError, FALSE);
- die;
- }
-
- if(uniLdapModify($ds_dummy, $userDn, $alteDaten, $neuerEintrag, 0)) {
- $meldung = "Daten abgeglichen";
- }
-
-}
-
-/**
-* userLogin($uid, $userPassword) - F�hrt den Login am Gruppe1-LDAP durch.
-*
-* Nach erfolgreicher Identifikation und ggf. neuem Anlegen oder Datenabgleich wird
-* mit userLogin() der Bind am Gruppe1-LDAP durchgef�hrt.
-* Die Rechte und der CN des Users werden ausgelesen und in der Session gespeichert.
-* Anschlie�end leitet das Skript auf die Startseite der Verwaltung (person_daten_show.php) weiter.
-*
-* @param string UID
-* @param string Password
-*
-* @author Timothy Burk
-*/
-function userLogin($uid, $userPassword) {
- global $userDN, $suffix, $ldapError;
- # Verbindung mit der Datenbank herstellen
- if(($uid == "") || ($userPassword == "") || !($ds = uniLdapConnect($uid,$userPassword))) {
- redirect(3, "index.php", "Falscher Login<br>".$ldapError, FALSE);
- die;
- }
-
- # cn abfragen
- $cn = "Gast";
- if(!($person_daten = uniLdapSearch($ds, "ou=people,".$suffix, "uid=$uid", array("cn"), "", "list", 0, 0))) {
- redirect(3, "index.php", $ldapError, FALSE);
- die;
- } else {
- $cn = str_replace('\"', '', $person_daten[0]['cn'][0]);
- }
-
- # Speichern der Sessionvariablen
- $_SESSION['uid'] = $uid;
- $_SESSION['userPassword'] = $userPassword;
- $_SESSION['dn'] = $userDN;
- $_SESSION['cn'] = $cn;
- $_SESSION['audn'] = "";
- $_SESSION['status'] = "in";
- $_SESSION['error'];
-
- # LDAP-Bind aufheben
- ldap_unbind($ds);
-
- $mesg = "<html>
- <head>
- <title>AdminUnit Management</title>
- <link rel='stylesheet' href='styles.css' type='text/css'>
- </head>
- <body>
- <table border='0' cellpadding='200' cellspacing='0' width='100%'>
- <tr valign='middle'><td align='center'>
- <h3>Bitte einen Moment Geduld, die Seite wird geladen ... <br>
- Falls nicht, klicken Sie bitte <a href='start.php'>hier</a>.<h3>
- </td></tr>
- </table>
- </body>
- </html>";
- # Aufruf der Startseite:
-
- redirect(0, "start.php", $mesg, TRUE);
-
- # nichtmehr ben�tigte CSV-Dateien im tmp-Verzeichnis l�schen
- # listen_sauber();
-}
-
-
-?>
diff --git a/ldap-site-mngmt/webinterface/logout_form.inc.dwt b/ldap-site-mngmt/webinterface/logout_form.inc.dwt
deleted file mode 100644
index 0c6ce597..00000000
--- a/ldap-site-mngmt/webinterface/logout_form.inc.dwt
+++ /dev/null
@@ -1,9 +0,0 @@
-<form action="{PFAD}index.php" method="post">
- <table border="0" cellspacing="0" cellpadding="3">
- <tr valign='top' align='right'>
- <td><p class="tiny_loginform_text">Eingeloggt als: </td>
- <td><b> {USERCN} </b></td>
- <td><input type="Submit" name="Logout" value="Logout" class="tiny_loginform_button"></p></td>
- </tr>
- </table>
-</form> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/pics/arrow.png b/ldap-site-mngmt/webinterface/pics/arrow.png
deleted file mode 100644
index f65dbf64..00000000
--- a/ldap-site-mngmt/webinterface/pics/arrow.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/branch.gif b/ldap-site-mngmt/webinterface/pics/branch.gif
deleted file mode 100644
index 32e0f683..00000000
--- a/ldap-site-mngmt/webinterface/pics/branch.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/branch2.gif b/ldap-site-mngmt/webinterface/pics/branch2.gif
deleted file mode 100644
index a693647c..00000000
--- a/ldap-site-mngmt/webinterface/pics/branch2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/branchbottom.gif b/ldap-site-mngmt/webinterface/pics/branchbottom.gif
deleted file mode 100644
index 55ceb453..00000000
--- a/ldap-site-mngmt/webinterface/pics/branchbottom.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/branchbottom2.gif b/ldap-site-mngmt/webinterface/pics/branchbottom2.gif
deleted file mode 100644
index a27a9c4c..00000000
--- a/ldap-site-mngmt/webinterface/pics/branchbottom2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/branchtop.gif b/ldap-site-mngmt/webinterface/pics/branchtop.gif
deleted file mode 100644
index f6bd127b..00000000
--- a/ldap-site-mngmt/webinterface/pics/branchtop.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/down.gif b/ldap-site-mngmt/webinterface/pics/down.gif
deleted file mode 100644
index 51095d1c..00000000
--- a/ldap-site-mngmt/webinterface/pics/down.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/down2.gif b/ldap-site-mngmt/webinterface/pics/down2.gif
deleted file mode 100644
index 4fb87681..00000000
--- a/ldap-site-mngmt/webinterface/pics/down2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/folder-expanded.gif b/ldap-site-mngmt/webinterface/pics/folder-expanded.gif
deleted file mode 100644
index f779acc7..00000000
--- a/ldap-site-mngmt/webinterface/pics/folder-expanded.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/folder.gif b/ldap-site-mngmt/webinterface/pics/folder.gif
deleted file mode 100644
index 842989f2..00000000
--- a/ldap-site-mngmt/webinterface/pics/folder.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/header.png b/ldap-site-mngmt/webinterface/pics/header.png
deleted file mode 100644
index 7155aa01..00000000
--- a/ldap-site-mngmt/webinterface/pics/header.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/header1.png b/ldap-site-mngmt/webinterface/pics/header1.png
deleted file mode 100644
index ccb676fb..00000000
--- a/ldap-site-mngmt/webinterface/pics/header1.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/headerlayer.xcf b/ldap-site-mngmt/webinterface/pics/headerlayer.xcf
deleted file mode 100644
index b906128f..00000000
--- a/ldap-site-mngmt/webinterface/pics/headerlayer.xcf
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/host.png b/ldap-site-mngmt/webinterface/pics/host.png
deleted file mode 100644
index 5741243e..00000000
--- a/ldap-site-mngmt/webinterface/pics/host.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/host1.png b/ldap-site-mngmt/webinterface/pics/host1.png
deleted file mode 100644
index 6cc7079d..00000000
--- a/ldap-site-mngmt/webinterface/pics/host1.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/hostfaulty.png b/ldap-site-mngmt/webinterface/pics/hostfaulty.png
deleted file mode 100644
index c011fb15..00000000
--- a/ldap-site-mngmt/webinterface/pics/hostfaulty.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/hostfaulty1.png b/ldap-site-mngmt/webinterface/pics/hostfaulty1.png
deleted file mode 100644
index 5c64ea02..00000000
--- a/ldap-site-mngmt/webinterface/pics/hostfaulty1.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/hostnoboot.png b/ldap-site-mngmt/webinterface/pics/hostnoboot.png
deleted file mode 100644
index e5351514..00000000
--- a/ldap-site-mngmt/webinterface/pics/hostnoboot.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/hostnoboot1.png b/ldap-site-mngmt/webinterface/pics/hostnoboot1.png
deleted file mode 100644
index 4325a841..00000000
--- a/ldap-site-mngmt/webinterface/pics/hostnoboot1.png
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/line.gif b/ldap-site-mngmt/webinterface/pics/line.gif
deleted file mode 100644
index a567ef9e..00000000
--- a/ldap-site-mngmt/webinterface/pics/line.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/line2.gif b/ldap-site-mngmt/webinterface/pics/line2.gif
deleted file mode 100644
index 659e20fe..00000000
--- a/ldap-site-mngmt/webinterface/pics/line2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/linebottom.gif b/ldap-site-mngmt/webinterface/pics/linebottom.gif
deleted file mode 100644
index a960f1ff..00000000
--- a/ldap-site-mngmt/webinterface/pics/linebottom.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/minus.gif b/ldap-site-mngmt/webinterface/pics/minus.gif
deleted file mode 100644
index a2bff127..00000000
--- a/ldap-site-mngmt/webinterface/pics/minus.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/minus2.gif b/ldap-site-mngmt/webinterface/pics/minus2.gif
deleted file mode 100644
index 4f31339e..00000000
--- a/ldap-site-mngmt/webinterface/pics/minus2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/minusbottom.gif b/ldap-site-mngmt/webinterface/pics/minusbottom.gif
deleted file mode 100644
index cc33192e..00000000
--- a/ldap-site-mngmt/webinterface/pics/minusbottom.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/minustop.gif b/ldap-site-mngmt/webinterface/pics/minustop.gif
deleted file mode 100644
index 9e8fc36d..00000000
--- a/ldap-site-mngmt/webinterface/pics/minustop.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/plus.gif b/ldap-site-mngmt/webinterface/pics/plus.gif
deleted file mode 100644
index 5bc24cfb..00000000
--- a/ldap-site-mngmt/webinterface/pics/plus.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/plus2.gif b/ldap-site-mngmt/webinterface/pics/plus2.gif
deleted file mode 100644
index 1fee2d74..00000000
--- a/ldap-site-mngmt/webinterface/pics/plus2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/plusbottom.gif b/ldap-site-mngmt/webinterface/pics/plusbottom.gif
deleted file mode 100644
index 4aa0bde9..00000000
--- a/ldap-site-mngmt/webinterface/pics/plusbottom.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/plustop.gif b/ldap-site-mngmt/webinterface/pics/plustop.gif
deleted file mode 100644
index 24e8a9ec..00000000
--- a/ldap-site-mngmt/webinterface/pics/plustop.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/up.gif b/ldap-site-mngmt/webinterface/pics/up.gif
deleted file mode 100644
index dfff04b4..00000000
--- a/ldap-site-mngmt/webinterface/pics/up.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/pics/up2.gif b/ldap-site-mngmt/webinterface/pics/up2.gif
deleted file mode 100644
index 48ac4a4b..00000000
--- a/ldap-site-mngmt/webinterface/pics/up2.gif
+++ /dev/null
Binary files differ
diff --git a/ldap-site-mngmt/webinterface/rbs/delete_confirm.php b/ldap-site-mngmt/webinterface/rbs/delete_confirm.php
deleted file mode 100644
index 11a04dfd..00000000
--- a/ldap-site-mngmt/webinterface/rbs/delete_confirm.php
+++ /dev/null
@@ -1,90 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$dn = $_POST['dn'];
-$name = $_POST['name'];
-$delurl = $_POST['delurl'];
-$backurl = $_POST['backurl'];
-$successurl = $_POST['successurl'];
-
-$type = $_POST['type'];
-$pxedn = $_POST['pxedn'];
-
-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>";
-
-
-if($type == "gbm"){
- $gbmDN = $dn;
- $attribs = array("dn");
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=MenuEntry)(genericmenuentrydn=$gbmDN))", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- if (count($result) > 0){
- echo "Folgende Men&uuml; Eintr&auml;ge sind davon betroffen: <br><br>";
- foreach ($result as $item){
- $exp = ldap_explode_dn($item['dn'], 1);
- echo "Men&uuml; Eintrag <b>".$exp[0]."</b> in PXE Bootmen&uuml; <b>".$exp[1]."</b> &nbsp;&nbsp;[ Abteilung: ".$exp[4]." ]<br>";
- }
- }
- else{
- echo "Keine Men&uuml; Eintr&auml;ge davon betroffen!<br>";
- }
- }
-}
-
-if($type == "rbs"){
- $rbsDN = $dn;
- $attribs = array("dn");
- if(!($result = uniLdapSearch($ds, "ou=RIPM,".$suffix, "(&(objectclass=PXEConfig)(rbservicedn=$rbsDN))", $attribs, "dn", "sub", 0, 0))) {
- # redirect(5, "", $ldapError, FALSE);
- echo "no search";
- die;
- }
- else{
- $result = ldapArraySauber($result);
- if (count($result) > 0){
- echo "Folgende PXE Boot Men&uuml;s sind davon betroffen: <br><br>";
- foreach ($result as $item){
- $exp = ldap_explode_dn($item['dn'], 1);
- echo "PXE Boot Men&uuml; <b>".$exp[0]."</b> an Objekt <b>".$exp[1]."</b> &nbsp;&nbsp;[ Abteilung: ".$exp[3]." ]<br>";
- }
- }
- else{
- echo "Keine PXE Boot Men&uuml;s davon betroffen!<br>";
- }
- }
-}
-
- echo "<br><br>
- 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='hidden' name='pxedn' value='".$pxedn."'>
- <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/rbs/gbm.dwt b/ldap-site-mngmt/webinterface/rbs/gbm.dwt
deleted file mode 100644
index 2c96ceaa..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm.dwt
+++ /dev/null
@@ -1,189 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td height='20'><h4><a href='gbm_overview.php?rbsdn={RBSDN}&mnr={MNR}&sbmnr={SBMNR}' class='headerlink'><< Zur&uuml;ck zur GBM &Uuml;bersicht</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
-
- <tr>
- <td colspan='2'><h3>Generisches Boot Image &nbsp;<code class='font_object'> {GBMCN} </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='gbm_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 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;'>
- <input type='Text' name='gbmcn' value='{GBMCN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldgbmcn' value='{GBMCN}'> &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>KERNEL und APPEND Parameter:</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>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>&nbsp;</b></td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>KERNEL</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+1'>{TFTPIP}::{TFTPROOT}/{TFTPKERNEL}</font>
- <input type='Text' name='attribs[kernel]' value='{KERNEL}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldattribs[kernel]' value='{KERNEL}'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>APPEND</td>
- <td align='right' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Initialram FS: </b></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <font size='+1'>initrd={TFTPIP}::{TFTPROOT}/{TFTPKERNEL}</font>
- <input type='Text' name='attribs[initrd]' value='{INITRD}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldattribs[initrd]' value='{INITRD}'>
- </td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Root Filesystem: </b></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <font size='+1'>rootfs={ROOTFS}</font>
- </td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'> <b>&Auml;ndern:</b><br>
- {FSURISELECT}
- </td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- bei NFS eventuell um spezifischen Pfad erweitern:<br>
- <input type='Text' name='rootfssuffix' value='' size='35' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Debug-Level: </b>&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <font size='+1'>debug=</font>
- <input type='Text' name='attribs[debug]' value='{DEBUG}' size='2' class='medium_form_field'>
- <input type='hidden' name='oldattribs[debug]' value='{DEBUG}'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Misc APPEND: </b><br>(wird hinten angef&uuml;gt)&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[appendmisc]' value='{MISC}' size='80' class='medium_form_field'>
- <input type='hidden' name='oldattribs[appendmisc]' value='{MISC}'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>IPAPPEND: </b>&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[ipappend]' value='{IPAPPEND}' size='2' class='medium_form_field'>
- <input type='hidden' name='oldattribs[ipappend]' value='{IPAPPEND}'>
- </td>
- </tr>
-
- <input type='hidden' name='gbmdn' value='{GBMDN}'>
- <input type='hidden' name='rbsdn' value='{RBSDN}'>
- <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='50'></td>
- </tr>
- <tr>
- <td colspan='2'><h3>Daraus ergibt sich folgender generischer Bootmen&uuml;eintrag</h3></td>
- </tr>
- <tr>
- <td colspan='2'>Diesen k&ouml;nnen Nutzer des Dienstes f&uuml;r ihre PXE-Configs verwenden und zu eigenen Men&uuml;eintr&auml;gen erweitern.</td>
- </tr>
- <tr>
- <td>
- <table cellpadding='20' cellspacing='0' border='0' align='left' width='80%' style='border-color: black; border-style: solid; border-width: 2 2 2 2;'>
-
- <tr>
- <td class='tab_d_ohne'>
- LABEL ..... <br>
- &nbsp;&nbsp;&nbsp; MENU LABEL ...... <br>
- &nbsp;&nbsp;&nbsp; KERNEL {TFTPIP}::/{TFTPKERNEL}{KERNEL} <br>
- &nbsp;&nbsp;&nbsp; APPEND initrd={TFTPIP}::/{TFTPKERNEL}{INITRD} rootfs={ROOTFS} debug={DEBUG} {MISC}<br>
- &nbsp;&nbsp;&nbsp; IPAPPEND {IPAPPEND}
- </td>
- </tr>
-
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Generisches Boot Image &nbsp;<code class='font_object'>{GBMCN}</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 generische Boot Image wird komplett gel&ouml;scht.
- </tr>
-
- <input type='hidden' name='dn' value='{GBMDN}'>
- <input type='hidden' name='name' value='{GBMCN}'>
- <input type='hidden' name='type' value='gbm'>
- <input type='hidden' name='delurl' value='gbm_delete.php'>
- <input type='hidden' name='backurl' value='gbm.php?dn={GBMDN}&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/rbs/gbm.php b/ldap-site-mngmt/webinterface/rbs/gbm.php
deleted file mode 100644
index 9f822840..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm.php
+++ /dev/null
@@ -1,134 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "gbm.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$gbmDN = $_GET['dn'];
-
-$template->assign(array("TFTPROOT" => "",
- "TFTPKERNEL" => "",
- "TFTPPXE" => "",
- "TFTPCLIENTCONF" => "",
- "NFS" => "",
- "NFSPATH" => "",
- "NBD" => ""));
-
-# rbservice und pxe daten (voerst nur ein rbs)
-$rbs_array = get_rbservices($auDN,array("dn","cn"));
-$rbsDN = $rbs_array[0]['dn'];
-# RBS Daten
-$rbs_data = get_node_data($rbsDN, array("cn","tftpserverip","tftproot","tftpkernelpath","tftpclientconfpath",
- "tftppxepath","nfsserverip","exportpath","nbdserverip","fileserveruri"));
-$template->assign(array("RBSCN" => $rbs_data['cn'],
- "TFTPIP" => $rbs_data['tftpserverip'],
- "TFTPROOT" => $rbs_data['tftproot'],
- "TFTPKERNEL" => $rbs_data['tftpkernelpath'],
- "TFTPPXE" => $rbs_data['tftppxepath'],
- "TFTPCLIENTCONF" => $rbs_data['tftpclientconfpath'],
- "NFS" => $rbs_data['nfsserverip'],
- "NFSPATH" => $rbs_data['exportpath'],
- "NBD" => $rbs_data['nbdserverip']));
-
-
-$template->assign(array("GBMDN" => $gbmDN,
- "GBMCN" => "",
- "LABEL" => "",
- "KERNEL" => "",
- "INITRD" => "",
- "FSTYPE" => "",
- "ROOTFS" => "",
- "DEBUG" => "",
- "MISC" => "",
- "IPAPPEND" => ""));
-
-# GBM Daten
-$attributes = array("dn","cn","label","kernel","initrd","rootfs","rootfstype","rootfspath","debug","appendmisc","ipappend");
-$gbm = get_node_data($gbmDN, $attributes);
-
-$selectboxmax = count($rbs_data['fileserveruri']) + 1;
-$fsuriselectbox = "<select name='rootfs' size='".$selectboxmax."' class='rootfs_form_selectbox'>
- <option value='none'>---------------------------------</option>";
-if ( $rbs_data['fileserveruri'] != "" ){
- foreach ($rbs_data['fileserveruri'] as $fsuri){
- $fsuriselectbox .= "<option value='".$fsuri."'>".$fsuri."</option>";
- }
-}
-$fsuriselectbox .= "</select>
- <input type='hidden' name='oldrootfs' value='".$gbm['rootfs']."'>";
-
-if ($gbm['rootfstype'] == 'nfs'){
- $options = "<select name='rootfstype' size='4' class='rootfs_form_selectbox'>
- <option value='nfs' selected><b>nfs://".$rbs_data['nfsserverip'].":/".$rbs_data['exportpath']."</b></option>
- <option value=''>---------------------------------</option>
- <option value='nbd'>nbd://".$rbs_data['nbdserverip'].":</option>
- <option value='dnbd'>dnbd://".$rbs_data['nbdserverip'].":</option>
- </select>
- <input type='hidden' name='oldrootfstype' value='".$gbm['rootfstype']."'>";
-}
-if ($gbm['rootfstype'] == 'nbd'){
- $options = "<select name='rootfstype' size='4' class='rootfs_form_selectbox'>
- <option value='nbd' selected><b>nbd://".$rbs_data['nbdserverip'].":</b></option>
- <option value=''>---------------------------------</option>
- <option value='nfs'>nfs://".$rbs_data['nfsserverip'].":/".$rbs_data['exportpath']."</option>
- <option value='dnbd'>dnbd://".$rbs_data['nbdserverip'].":</option>
- </select>
- <input type='hidden' name='oldrootfstype' value='".$gbm['rootfstype']."'>";
-}
-if ($gbm['rootfstype'] == 'dnbd'){
- $options = "<select name='rootfstype' size='4' class='rootfs_form_selectbox'>
- <option value='dnbd' selected><b>dnbd://".$rbs_data['nbdserverip'].":</b></option>
- <option value=''>---------------------------------</option>
- <option value='nfs'>nfs://".$rbs_data['nfsserverip'].":/".$rbs_data['exportpath']."</option>
- <option value='nbd'>nbd://".$rbs_data['nbdserverip'].":</option>
- </select>
- <input type='hidden' name='oldrootfstype' value='".$gbm['rootfstype']."'>";
-}
-#if ($gbm['rootfstype'] != 'nfs' && $gbm['rootfstype'] != 'nbd' && $gbm['rootfstype'] != 'dnbd'){
-if ($gbm['rootfstype'] == 'none' ){
- $options = "<select name='rootfstype' size='4' class='rootfs_form_selectbox'>
- <option value='' selected>---------------------------------</option>
- <option value='nfs'><b>nfs://".$rbs_data['nfsserverip'].":/".$rbs_data['exportpath']."</b></option>
- <option value='nbd'>nbd://".$rbs_data['nbdserverip'].":</option>
- <option value='dnbd'>dnbd://".$rbs_data['nbdserverip'].":</option>
- </select>
- <input type='hidden' name='oldrootfstype' value='".$gbm['rootfstype']."'>";
-}
-
-
-$template->assign(array("GBMCN" => $gbm['cn'],
- "LABEL" => $gbm['label'],
- "KERNEL" => $gbm['kernel'],
- "INITRD" => $gbm['initrd'],
- "FSURISELECT" => $fsuriselectbox,
- "SELECTOPTIONS" => $options,
- "ROOTFS" => $gbm['rootfs'],
- "DEBUG" => $gbm['debug'],
- "MISC" => $gbm['appendmisc'],
- "IPAPPEND" => $gbm['ipappend'],
- "RBSDN" => $rbsDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/gbm_add.php b/ldap-site-mngmt/webinterface/rbs/gbm_add.php
deleted file mode 100644
index 2202b4fb..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm_add.php
+++ /dev/null
@@ -1,68 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$gbmcn = $_POST['gbmcn']; $gbmcn = htmlentities($gbmcn);
-$rbsDN = $_POST['rbsdn'];
-
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-
-$attribs = $_POST['attribs'];
-if (count($attribs) != 0){
- foreach (array_keys($attribs) as $key){
- $atts[$key] = htmlentities($attribs[$key]);
- }
-}
-# print_r($meatts); echo "<br><br>";
-
-$seconds = 2;
-$get_gbmcn = str_replace ( " ", "_", $gbmcn );
-$url = "gbm.php?gbmcn=".$get_gbmcn."&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>";
-
-
-if ( $gbmcn != "" && $gbmcn != "Hier_NAME_eintragen" ){
-
- # Formulareingaben anpassen
- $expgbm = explode(" ",$gbmcn);
- foreach ($expgbm as $word){$expuc[] = ucfirst($word);}
- $gbmcn = implode(" ",$expuc);
- $gbmcn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $gbmcn);
-
- $gbmDN = "cn=".$gbmcn.",".$rbsDN;
-
- if (add_gbm($gbmDN,$gbmcn,$atts)){
- $mesg .= "<br>Neuen Generischen Men&uuml; Eintrag erfolgreich angelegt<br>";
- $url = "gbm_overview.php";
- }
- else{
- $mesg .= "<br>Fehler beim anlegen des Generischen Men&uuml; Eintrags!<br>";
- }
-}
-
-elseif ( $gbmcn == "" || $gbmcn == "Hier_NAME_eintragen" ){
-
- $mesg = "Sie haben den Namen des neuen Generischen Men&uuml; Eintrags nicht angegeben.
- Dies ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie sie an.<br><br>";
- $url = "new_gbm.php?gbmcn=Hier_NAME_eintragen&mnr=".$mnr."&sbmnr=".$sbmnr;
-}
-
-
-
-$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/rbs/gbm_change.php b/ldap-site-mngmt/webinterface/rbs/gbm_change.php
deleted file mode 100644
index ff01865d..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm_change.php
+++ /dev/null
@@ -1,236 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$gbmcn = $_POST['gbmcn']; $gbmcn = htmlentities($gbmcn);
-$oldgbmcn = $_POST['oldgbmcn'];
-
-$gbmDN = $_POST['gbmdn'];
-$rbsDN = $_POST['rbsdn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-
-$rootfs = $_POST['rootfs'];
-#$oldrootfs = $_POST['oldrootfs'];
-$rootfspath = $_POST['rootfspath'];
-$rootfssuffix = $_POST['rootfssuffix'];
-#$oldrootfstype = $_POST['oldrootfstype'];
-
-$attribs = $_POST['attribs'];
-if (count($attribs) != 0){
- foreach (array_keys($attribs) as $key){
- $atts[$key] = htmlentities($attribs[$key]);
- }
-}
-# print_r($meatts); 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>";
-
-
-$seconds = 2;
-$get_mecn = str_replace ( " ", "_", $mecn );
-$url = "gbm.php?dn=".$gbmDN."&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>";
-
-##############################################
-# GBM CN (DN)
-
-if ( $oldgbmcn == $gbmcn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldgbmcn != "" && $gbmcn != "" && $oldgbmcn != $gbmcn ){
- echo "Name Generisches Boot Men&uuml; aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $expgbm = explode(" ",$gbmcn);
- foreach ($expgbm as $word){$expuc[] = ucfirst($word);}
- $gbmcn = implode(" ",$expuc);
- $gbmcn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $gbmcn);
-
-
- $newgbmDN = "cn=".$gbmcn.",".$rbsDN;
- print_r($newgbmDN); echo "<br><br>";
-
- if(move_subtree($gbmDN, $newgbmDN)){
- adjust_gbm_dn($newgbmDN, $gbmDN);
- $mesg = "Name Generisches Bootmen&uuml; erfolgreich ge&auml;ndert<br><br>";
- $gbmDN = $newgbmDN;
- }else{
- $mesg = "Fehler beim &auml;ndern des Namen des Generischen Bootmen&uuml;s!<br><br>";
- }
-
- # newsubmenu holen...
- $url = "gbm.php?dn=".$newgbmDN."&mnr=".$mnr."&sbmnr=".$sbmnr;
-}
-
-if ( $oldgbmcn != "" && $gbmcn == "" ){
- echo "Name Generisches Bootmen&uuml; loeschen!<br>
- Dieses ist Teil des DN, Sie werden des Generische Boot Men&uuml; komplett l&ouml;schen<br><br>";
- echo "Wollen Sie das Generische Boot Men&uuml; <b>".$oldgbmcn."</b> wirklich l&ouml;schen?<br><br>
- <form action='gbm_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$gbmDN."'>
- <input type='hidden' name='name' value='".$oldgbmcn."'>
- <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;
-}
-
-###################################
-# RootFS
-if ( $rootfs != "" ){
- if ( $rootfs == "none" ){
- echo "Root FS l&ouml;schen!<br>";
- $entrydel ['rootfs'] = array();
- if(ldap_mod_del($ds,$gbmDN,$entrydel)){
- $mesg = "Attribut <b>RootFS</b> erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen des Attributs <b>RootFS</b><br><br>";
- }
-
- }else{
- echo "Root FS &auml;ndern!<br>";
- $entrymod ['rootfs'] = $rootfs.$rootfssuffix;
- if(ldap_mod_replace($ds,$gbmDN,$entrymod)){
- $mesg = "Attribut <b>RootFS</b> erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des Attributs <b>RootFS</b><br><br>";
- }
- }
-}
-
-###################################
-# RootFS Type
-
-#if ( $oldrootfstype == $rootfstype ){
-# # $mesg = "keine Aenderung<br>";
-#}
-
-#if ( $oldrootfstype == "" && $rootfstype != "" ){
-# $entryadd ['rootfstype'] = $rootfstype;
-# if(ldap_mod_add($ds,$gbmDN,$entryadd)){
-# $mesg = "Attribute <b>RootfsType</b> erfolgreich eingetragen<br><br>";
-# }else{
-# $mesg = "Fehler beim eintragen der Attribute <b>RootfsType</b><br><br>";
-# }
-#}
-
-
-#if ( $oldrootfstype != "" && $rootfstype != "" && $oldrootfstype != $rootfstype ){
-# echo "Root FS Type &auml;ndern<br>";
-# $entrymod ['rootfstype'] = $rootfstype;
-# if(ldap_mod_replace($ds,$gbmDN,$entrymod)){
-# $mesg = "Attribute <b>RootfsType</b> erfolgreich geaendert<br><br>";
-# }else{
-# $mesg = "Fehler beim aendern der Attribute <b>RootfsType</b><br><br>";
-# }
-#}
-
-
-#if ( $oldrootfstype != "" && $rootfstype == "" ){
-# echo "Root FS Type l&ouml;schen!<br>";
-# $entrydel ['rootfstype'] = array();
-# if(ldap_mod_del($ds,$gbmDN,$entrydel)){
-# $mesg = "Attribute <b>RootfsType</b> erfolgreich geloescht<br><br>";
-# }else{
-# $mesg = "Fehler beim loeschen der Attribute <b>RootfsType</b><br><br>";
-# }
-#}
-
-
-###################################
-# restliche Attribute
-
-$entryadd = array();
-$entrymod = array();
-$entrydel = array();
-
-foreach (array_keys($atts) as $key){
-
- if ( $oldatts[$key] == $atts[$key] ){
- # nix
- }
- 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,$gbmDN,$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,$gbmDN,$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,$gbmDN,$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/rbs/gbm_delete.php b/ldap-site-mngmt/webinterface/rbs/gbm_delete.php
deleted file mode 100644
index 8777981a..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm_delete.php
+++ /dev/null
@@ -1,40 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$gbmDN = $_POST['dn'];
-$gbmcn = $_POST['name'];
-
-$seconds = 1;
-$url = "gbm_overview.php?";
-
-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 ( $gbmDN != ""){
-
- clean_up_del_gbm($gbmDN);
- if ( dive_into_tree_del($gbmDN,"") ){
- clean_up_del_gbm($gbmDN);
- $mesg = "Generisches Bootmen&uuml; <b>".$gbmcn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen des Generischen Bootmen&uuml;s <b>".$gbmcn."</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/rbs/gbm_overview.dwt b/ldap-site-mngmt/webinterface/rbs/gbm_overview.dwt
deleted file mode 100644
index 794315e6..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm_overview.dwt
+++ /dev/null
@@ -1,29 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Generische Boot Images</h3>
- Diese Boot Images werden vom Remote Boot Service <code class='font_object'> {RBSCN} </code>
- angeboten. Sie k&ouml;nnen f&uuml;r jedes Image festlegen, wer dieses Angebot in Anspruch nehmen
- kann (Spektrum zwischen (a) ihrer Abteilung <code class='font_object'> {AU} </code> und ihrer Unterabteilungen, und (b) organisationsweit) </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='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Generisches Boot Men&uuml;</b></td>
- <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Netzwerk Dateisystem</b></td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Genericbm -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{GBMCN} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{FS}&nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Genericbm -->
-
- </table></td>
- </tr>
-
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/gbm_overview.php b/ldap-site-mngmt/webinterface/rbs/gbm_overview.php
deleted file mode 100644
index bd99cc55..00000000
--- a/ldap-site-mngmt/webinterface/rbs/gbm_overview.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "gbm_overview.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$rbsDN = $_GET['rbsdn'];
-
-$template->assign(array("GBMDN" => "",
- "GBMCN" => "Noch keine Generischen Boot Men&uuml;s angelegt",
- "KERNEL" => "",
- "FS" => ""));
-
-# Generic Bootmenüs
-$generic_bms = get_menuentries($rbsDN,array("dn","cn","label","kernel","nfsroot","nbdroot"));
-
-$template->define_dynamic("Genericbm", "Webseite");
-$template->define_dynamic("Offers", "Webseite");
-
-foreach ($generic_bms as $gbm){
- if ($gbm['nfsroot'] != ""){$fs = "NFS";}
- if ($gbm['nbdroot'] != ""){$fs = "NBD";}
-
- $gbmname = "<a href='gbm.php?dn=".$gbm['dn']."&mnr=".$mnr."&sbmnr=".$sbmnr."' class='headerlink'>".$gbm['cn']."</a>";
-
- $template->assign(array("GBMDN" => $gbm['dn'],
- "GBMCN" => $gbmname,
- "KERNEL" => $gbm['kernel'],
- "FS" => $fs,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "RBSDN" => $rbsDN));
- $template->parse("GENERICBM_LIST", ".Genericbm");
-}
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/rbs/menu.dwt b/ldap-site-mngmt/webinterface/rbs/menu.dwt
deleted file mode 100644
index fe37aeee..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menu.dwt
+++ /dev/null
@@ -1,31 +0,0 @@
-
-<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>
diff --git a/ldap-site-mngmt/webinterface/rbs/menuentry.dwt b/ldap-site-mngmt/webinterface/rbs/menuentry.dwt
deleted file mode 100644
index 07f71d95..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuentry.dwt
+++ /dev/null
@@ -1,247 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td height='20'><h4>Zur&uuml;ck zu &nbsp;<a href='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}' class='headerlink'>{PXECN}</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h3>Boot Men&uuml; Eintrag &nbsp;<code class='font_object'> {MECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='menuentry_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 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;'>
- <input type='Text' name='mecn' value='{MECN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldmecn' value='{MECN}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Label:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[label]' value='{LABEL}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[label]' value='{LABEL}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Generisches Boot Image: </b><br><br>(Angeboten von) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <h4>{GMECN}</h4> Abteilung: {GMEOU} [Remote Boot Dienst: {GMERBS}]
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Label:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menulabel]' value='{MELABEL}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menulabel]' value='{MELABEL}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Default:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menudefault]' value='{MEDEF}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menudefault]' value='{MEDEF}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Passwd:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menupasswd]' value='{MEPASSWD}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menupasswd]' value='{MEPASSWD}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Hide:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menuhide]' value='{MEHIDE}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menuhide]' value='{MEHIDE}'> &nbsp;
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Localboot:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[localboot]' value='{LOCALBOOT}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldattribs[localboot]' value='{LOCALBOOT}'> &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>APPEND Parameter:</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>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Client Konfiguration via: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[clientconfvia]' value='{CCV}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[clientconfvia]' value='{CCV}'> ( dhcp | file | ldap )
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vga: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vga]' value='{VGA}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[vga]' value='{VGA}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>splash: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[splash]' value='{SPLASH}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[splash]' value='{SPLASH}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vci: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vci]' value='{VCI}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[vci]' value='{VCI}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>no ldsc: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noldsc]' value='{NOLDSC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[noldsc]' value='{NOLDSC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>elevator: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[elevator]' value='{ELEVATOR}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[elevator]' value='{ELEVATOR}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>apic: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[apic]' value='{APIC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[apic]' value='{APIC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Union FS: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[unionfs]' value='{UNIONFS}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[unionfs]' value='{UNIONFS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>cowloop: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[cowloop]' value='{COWLOOP}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[cowloop]' value='{COWLOOP}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Debug Level: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[debug]' value='{DEBUG}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[debug]' value='{DEBUG}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Men&uuml; Position: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='menpos' value='{MENPOS}' size='2' class='medium_form_field'>
- <input type='hidden' name='oldmenpos' value='{MENPOS}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Submen&uuml; Verweis: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[submenulink]' value='{SUBMENULINK}' size='50' class='medium_form_field'>
- <br>
- Dieses Feld sollte nur bei Verweisen auf Submen&uuml;s den vollst&auml;ndigen Link zu diesen enthalten
- <br>(d.h. &lt;TFTP-Server-IP&gt;::/&lt;TFTP-PXE-Pfad&gt;/&lt;Timerange&gt;/&lt;PXE-Dateiname&gt;). <br>
- Bei Textzeilen und Leerzeilen muss hier <b>"self"</b> stehen. <br>
- Bei normalen Men&uuml;eintr&auml;gen (inklusive Localboot) muss diese Feld <b>leer</b> sein.
- <input type='hidden' name='oldattribs[submenulink]' value='{SUBMENULINK}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Kernel: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[kernel]' value='{KERNEL}' size='50' class='medium_form_field'>
- <br>
- Angabe hier nur sinnvoll bei Leer-, Textzeilen oder Submen&uuml;verweisen, <br>
- denn Eingabe wird, wenn der Men&uuml;eintrag auf ein generisches Boot Image verweist (siehe oben) <br>
- bei der PXE Datei Generierung &uuml;berschrieben.
- <input type='hidden' name='oldattribs[kernel]' value='{KERNEL}'> &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='medn' value='{MEDN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
-
- </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>Boot Men&uuml; Eintrag &nbsp;<code class='font_object'>{MECN}</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 generische Boot Image wird komplett gel&ouml;scht.
- </tr>
-
- <input type='hidden' name='dn' value='{MEDN}'>
- <input type='hidden' name='name' value='{MECN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='delurl' value='menuentry_delete.php'>
- <input type='hidden' name='successurl' value='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
- <input type='hidden' name='backurl' value='menuentry.php?dn={MEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
-
- </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/rbs/menuentry.php b/ldap-site-mngmt/webinterface/rbs/menuentry.php
deleted file mode 100644
index 44eb17d9..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuentry.php
+++ /dev/null
@@ -1,153 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "menuentry.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = 3;
-$sbmnr = -1;
-$mcnr = -1;
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$meDN = $_GET['dn'];
-
-$attributes = array("cn","genericmenuentrydn","label","menulabel","menudefault","menupasswd","vga","splash",
- "noldsc","elevator","clientconfvia","apic",
- "cowloop","unionfs","debug","vci","menuhide","menuposition","localboot","kernel","submenulink");
-$me = get_node_data($meDN,$attributes);
-#print_r($me);
-
-# PXE DN
-$exp = explode(',',$meDN);
-$node = array_slice($exp,1);
-$exppxecn = explode('=',$node[0]);
-$pxecn = $exppxecn[1];
-$pxeDN = implode(',',$node);
-
-# Generic Menu Entry
-$expgbm = ldap_explode_dn ($me['genericmenuentrydn'],1);
-$gmecn = $expgbm[0];
-$gmerbs = $expgbm[1];
-$gmeou = $expgbm[3];
-
-# RBS Daten
-$pxe = get_node_data($pxeDN,array("rbservicedn"));
-$rbsDN = $pxe['rbservicedn'];
-$exp = explode(',',$rbsDN);
-$exprbsau = explode('=',$exp[2]); $rbsau = $exprbsau[1];
-$rbsdata = get_node_data($rbsDN,array("cn","nfsserverip","exportpath","tftpserverip","tftppath"));
-
-# Bootmenu Daten
-$template->assign(array("MEDN" => $meDN,
- "MECN" => $me['cn'],
- "GMECN" => $gmecn,
- "GMEOU" => $gmeou,
- "GMERBS" => $gmerbs,
- "LABEL" => $me['label'],
- "MELABEL" => $me['menulabel'],
- "MEDEF" => $me['menudefault'],
- "MEPASSWD" => $me['menupasswd'],
- "MEHIDE" => $me['menuhide'],
- "VGA" => $me['vga'],
- "SPLASH" => $me['splash'],
- "NOLDSC" => $me['noldsc'],
- "ELEVATOR" => $me['elevator'],
- "VCI" => $me['vci'],
- "CCV" => $me['clientconfvia'],
- "APIC" => $me['apic'],
- "COWLOOP" => $me['cowloop'],
- "UNIONFS" => $me['unionfs'],
- "DEBUG" => $me['debug'],
- "MENPOS" => $me['menuposition'],
- "LOCALBOOT" => $me['localboot'],
- "KERNEL" => $me['kernel'],
- "SUBMENULINK" => $me['submenulink'],
- "PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-# Alternative RB Dienste holen
-$altrbs = get_rbservices($auDN,array("dn","cn"));
-if (count($altrbs) != 0){
- for ($i=0; $i < count($altrbs); $i++){
- if ($rbsDN == $altrbs[$i]['dn']){
- array_splice($altrbs, $i, 1);
- }
- }
-}
-
-
-if (count($altrbs) != 0){
-$template->define_dynamic("Altrbs", "Webseite");
- foreach ($altrbs as $item){
- $altrbsexp = explode(',',$item['dn']);
- $altrbsau = explode('=',$altrebsexp[2]);
- $template->assign(array("ALTRBSDN" => $item['dn'],
- "ALTRBSCN" => $item['cn'],
- "ALTRBSAU" => "[ ".$altrbsau[1]." ]"));
- $template->parse("ALTRBS_LIST", ".Altrbs");
- }
-}else{
- $template->assign(array("ALTRBSDN" => "",
- "ALTRBSCN" => "",
- "ALTRBSAU" => ""));
-}
-
-################################################
-# Bootmenü Einträge
-
-$menuentries = get_menuentries($pxeDN,array("dn","menuposition","label","menulabel"));
-#print_r($menuentries); echo "<br>";
-
-$template->define_dynamic("Bootmenu", "Webseite");
-
-foreach ($menuentries as $me){
- $template->assign(array("MENDN" => $me['dn'],
- "MENULABEL" => $me['menulabel'],
- "POSITION" => $me['menuposition'],
- "AUDN" => $auDN));
- $template->parse("BOOTMENU_LIST", ".Bootmenu");
-}
-
-
-################################################
-# PXE kopieren
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/rbs/menuentry_add.php b/ldap-site-mngmt/webinterface/rbs/menuentry_add.php
deleted file mode 100644
index 8b0c4368..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuentry_add.php
+++ /dev/null
@@ -1,258 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mecn = $_POST['mecn']; $mecn = htmlentities($mecn);
-$gbmDN = $_POST['gbm'];
-$menpos = $_POST['menpos'];
-$maxpos = $_POST['maxpos'];
-
-$typ = $_POST['typ'];
-$pxeDN = $_POST['pxedn'];
-$timespan = $_POST['timerange'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-
-$meattribs = $_POST['attribs'];
-if (count($meattribs) != 0){
- foreach (array_keys($meattribs) as $key){
- $meatts[$key] = htmlentities($meattribs[$key]);
- }
-}
-# print_r($meatts); echo "<br><br>";
-
-$seconds = 2;
-$get_mecn = str_replace ( " ", "_", $mecn );
-$url = "pxe.php?dn=".$pxeDN."&mecn=".$get_mecn."&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>";
-# switch wäre besser ...
-if ($typ == "newme" && $typ != "local" && $typ != "text" && $typ != "leer" && $typ != "submenu" ){
-
- if ( $mecn != "" && $mecn != "Hier_NAME_eintragen" && $gbmDN != "none" ){
-
- # Formulareingaben anpassen
- $expme = explode(" ",$mecn);
- foreach ($expme as $word){$expuc[] = ucfirst($word);}
- $mecn = implode(" ",$expuc);
- $mecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mecn);
-
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- $meDN = "cn=".$mecn.",".$pxeDN;
-
- if (add_me($meDN,$mecn,$gbmDN,$menpos,$meatts,$pxeDN)){
- $mesg .= "<br>Neuen Men&uuml; Eintrag erfolgreich angelegt<br>";
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- }
- else{
- $mesg .= "<br>Fehler beim anlegen des Men&uuml; Eintrags!<br>";
- }
- }
-
- elseif ( $mecn == "" || $mecn == "Hier_NAME_eintragen" || $gbmDN == "none" ){
-
- $mesg = "Sie haben den Namen des neuen Men&uuml; Eintrags nicht angegeben oder kein
- Generisches Boot Image ausgew&auml;hlt. Beide sind aber ein notwendige Attribute.<br>
- Bitte geben Sie sie an.<br><br>";
- $url = "new_menuentry.php?mecn=Hier_NAME_eintragen&mnr=".$mnr."&sbmnr=".$sbmnr;
- }
-}
-
-# Localboot Zeile hinzufügen
-elseif ($typ == "local" && $typ != "newme" && $typ != "text" && $typ != "leer" && $typ != "submenu" ){
-
- # Menu Position
- $menpos = $_POST['localpos'];
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- # CN bilden
- $brothers = get_menuentries($pxeDN,array("dn","cn"));
- $i=1;
- $localcn = "localboot".$i;
- if(count($brothers) != 0){
- for ($c=0; $c<count($brothers); $c++){
- foreach ($brothers as $item){
- if ($localcn == strtolower($item['cn'])){
- $i++;
- $localcn = "localboot".$i;
- }
- }
- }
- }
- $meDN = "cn=".$localcn.",".$pxeDN;
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $localcn;
- $entry ['menuposition'] = $menpos;
- $entry ['label'] = $localcn;
- $entry ['menulabel'] = $_POST['locallabel'];
- $entry ['menupasswd'] = $_POST['localpasswd'];
- $entry ['localboot'] = "level 0";
- $pos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- increment_menupositions($pxeDN,$pos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$entry)){
- $mesg .= "Localboot Zeile erfolgeich an Position ".$menpos." eingetragen";
- }else{
- $mesg .= "Fehler beim eintragen der Localboot Zeile!";
- }
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-# Text Zeile hinzufügen
-elseif ($typ == "text" && $typ != "newme" && $typ != "local" && $typ != "leer" && $typ != "submenu" ){
-
- # Menu Position
- $menpos = $_POST['textpos'];
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- $text = $_POST['text'];
- if($text != "" && $text != "TEXT"){
- $brothers = get_menuentries($pxeDN,array("dn","cn"));
- $i=1;
- $textcn = "textzeile".$i;
- if(count($brothers) != 0){
- for ($c=0; $c<count($brothers); $c++){
- foreach ($brothers as $item){
- if ($textcn == strtolower($item['cn'])){
- $i++;
- $textcn = "textzeile".$i;
- }
- }
- }
- }
- $meDN = "cn=".$textcn.",".$pxeDN;
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $textcn;
- $entry ['menuposition'] = $menpos;
- $entry ['label'] = $text;
- $entry ['kernel'] = "menu.c32";
- # Submenulink auf sich selbst
- $pxedata = get_node_data($pxeDN,array("filename"));
- $entry ['submenulink'] = "self";
-
- $pos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- increment_menupositions($pxeDN,$pos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$entry)){
- $mesg .= "Textzeile erfolgeich an Position ".$menpos." eingetragen";
- }else{
- $mesg .= "Fehler beim eintragen der Textzeile!";
- }
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- }
-}
-
-
-elseif ($typ == "leer" && $typ != "newme" && $typ != "local" && $typ != "text" && $typ != "submenu" ){
-
- # Menu Position
- $menpos = $_POST['leerpos'];
- if ($menpos != ""){
- # Syntaxcheck Menüposition
- #$syntax = new Syntaxcheck;
- #if (!($syntax->check_menuposition($menpos))){
- # $menpos = $maxpos;
- #}
- }else{
- $menpos = $maxpos;
- }
- if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
- }
- # nun doch führende Nullen erzwingen
- # also obsolet: $menpos = preg_replace ( '/0([0-9])/', '$1', $menpos);
-
- # CN bilden
- $brothers = get_menuentries($pxeDN,array("dn","cn"));
- $i=1;
- $leercn = "leerzeile".$i;
- if(count($brothers) != 0){
- for ($c=0; $c<count($brothers); $c++){
- foreach ($brothers as $item){
- if ($leercn == strtolower($item['cn'])){
- $i++;
- $leercn = "leerzeile".$i;
- }
- }
- }
- }
- $meDN = "cn=".$leercn.",".$pxeDN;
- $entry ['objectclass'][0] = "MenuEntry";
- $entry ['objectclass'][1] = "top";
- $entry ['cn'] = $leercn;
- $entry ['menuposition'] = $menpos;
- $entry ['kernel'] = "menu.c32";
- # Submenulink auf sich selbst
- $pxedata = get_node_data($pxeDN,array("filename"));
- $entry ['submenulink'] = "self";
-
- # wieder führende Nullen weg für increment_menpos
- $pos = preg_replace ( '/0([0-9])/', '$1', $menpos);
- increment_menupositions($pxeDN,$pos); # andere jeweils um 1 erhöhen
- if (ldap_add($ds,$meDN,$entry)){
- $mesg .= "Leerzeile erfolgeich an Position ".$menpos." eingetragen";
- }else{
- $mesg .= "Fehler beim eintragen der Leerzeile!";
- }
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-elseif ($typ == "submenu" && $typ != "newme" && $typ != "local" && $typ != "text" && $typ != "leer" ){
-}
-
-$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/rbs/menuentry_change.php b/ldap-site-mngmt/webinterface/rbs/menuentry_change.php
deleted file mode 100644
index 40d5d60d..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuentry_change.php
+++ /dev/null
@@ -1,207 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$mecn = $_POST['mecn']; $mecn = htmlentities($mecn);
-$oldmecn = $_POST['oldmecn'];
-
-$menpos = $_POST['menpos'];
-if (strlen($menpos) == 1){
- $menpos = "0".$menpos;
-}
-$oldmenpos = $_POST['oldmenpos'];
-if (strlen($oldmenpos) == 1){
- $oldmenpos = "0".$oldmenpos;
-}
-
-$meDN = $_POST['medn'];
-$pxeDN = $_POST['pxedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-
-$attribs = $_POST['attribs'];
-if (count($attribs) != 0){
- foreach (array_keys($attribs) as $key){
- $atts[$key] = htmlentities($attribs[$key]);
- }
-}
-# print_r($meatts); 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>";
-
-
-
-$seconds = 2;
-$get_mecn = str_replace ( " ", "_", $mecn );
-$url = "menuentry.php?dn=".$meDN."&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>";
-
-##############################################
-# ME CN (DN)
-
-if ( $oldmecn == $mecn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldmecn != "" && $mecn != "" && $oldmecn != $mecn ){
- echo "Men&uuml; Eintrag Name aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $expme = explode(" ",$mecn);
- foreach ($expme as $word){$expuc[] = ucfirst($word);}
- $mecn = implode(" ",$expuc);
- $mecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $mecn);
-
-
- $newmeDN = "cn=".$mecn.",".$pxeDN;
- print_r($newmeDN); echo "<br><br>";
-
- if(modify_me_dn($meDN, $newmeDN)){
- $mesg = "Men&uuml; Eintrag Name erfolgreich ge&auml;ndert<br><br>";
- $meDN = $newmeDN;
- }else{
- $mesg = "Fehler beim &auml;ndern des PMen&uuml; Eintrag Namen!<br><br>";
- }
-
-
- # newsubmenu holen...
- $url = "menuentry.php?dn=".$newmeDN."&mnr=".$mnr."&sbmnr=".$sbmnr;
-}
-
-if ( $oldmecn != "" && $mecn == "" ){
- echo "Men&uuml; Eintrag Name loeschen!<br>
- Dieses ist Teil des DN, Sie werden den Men&uuml; Eintrag komplett l&ouml;schen<br><br>";
- echo "Wollen Sie den Men&uuml; Eintrag <b>".$oldmecn."</b> wirklich l&ouml;schen?<br><br>
- <form action='menuentry_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$meDN."'>
- <input type='hidden' name='name' value='".$oldmecn."'>
- <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;
-}
-
-
-###################################
-# Menu Position
-
-if ( $menpos == $oldmenpos || $menpos == "" ){
- # keine Änderung
-}
-
-if ( $menpos != "" && $oldmenpos != $menpos ){
- echo "Men&uuml; Position &auml;ndern<br><br>";
- # Syntax Check fehlt noch
-
- # switch partner finden
- $secmeDN = get_dn_menuposition($pxeDN,$menpos);
- $entrysec ['menuposition'] = $oldmenpos;
- if (ldap_mod_replace($ds,$secmeDN,$entrysec)){
- $entry ['menuposition'] = $menpos;
- if (ldap_mod_replace($ds,$meDN,$entry)){
- #cleanup_menupositions($pxeDN);
- $mesg .= "Men&uuml; Position erfolgeich nach <b>".$menpos."</b> ge&auml;ndert";
- }else{
- $mesg .= "Fehler beim &auml;ndern der Men&uuml; Position!";
- }
- }else{
- $mesg .= "Fehler beim &auml;ndern der Men&uuml; Position!";
- }
-}
-
-###################################
-# restliche Attribute
-
-$entryadd = array();
-$entrymod = array();
-$entrydel = array();
-
-foreach (array_keys($atts) as $key){
-
- if ( $oldatts[$key] == $atts[$key] ){
- # nix
- }
- 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,$meDN,$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,$meDN,$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,$meDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
- }
-}
-
-###################################
-# Ende, noch Redirect
-
-
-$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/rbs/menuentry_delete.php b/ldap-site-mngmt/webinterface/rbs/menuentry_delete.php
deleted file mode 100644
index ba06eb55..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuentry_delete.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$meDN = $_POST['dn'];
-$mecn = $_POST['name'];
-
-$pxeDN = $_POST['pxedn'];
-
-$seconds = 1;
-$url = $_POST['successurl'];
-
-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 ( $meDN != ""){
-
- if ( dive_into_tree_del($meDN,"") ){
- cleanup_menupositions($pxeDN);
- $mesg = "Bootmen&uuml; Eintrag <b>".$mecn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen des Bootmen&uuml; Eintrags <b>".$mecn."</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/rbs/menuposition_down.php b/ldap-site-mngmt/webinterface/rbs/menuposition_down.php
deleted file mode 100644
index d7b235ce..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuposition_down.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$meDN = $_GET['dn'];
-$oldpos = $_GET['pos'];
-
-$pxeDN = $_GET['pxedn'];
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-$me = get_menuentries($pxeDN,array("cn"));
-$maxpos = count($me);
-
-$oldpos = preg_replace ( '/0([0-9])/', '$1', $oldpos);
-if ($oldpos < $maxpos){
-
- $newpos = $oldpos +1;
- if (strlen($newpos) == 1){
- $newpos = "0".$newpos;
- }
- if (strlen($oldpos) == 1){
- $oldpos = "0".$oldpos;
- }
-
- if ($secmeDN = get_dn_menuposition($pxeDN,$newpos)){
- #echo "other meDN:"; print_r($secmeDN); echo "<br>";
- $entrysec ['menuposition'] = $oldpos;
- if ($result = ldap_mod_replace($ds,$secmeDN,$entrysec)){
- $entrymenu ['menuposition'] = $newpos;
- $result = ldap_mod_replace($ds,$meDN,$entrymenu);
- }
- }
-}
-$seconds = 0;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&#menu";
-$mesg = "";
-#$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);
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/menuposition_up.php b/ldap-site-mngmt/webinterface/rbs/menuposition_up.php
deleted file mode 100644
index c2611651..00000000
--- a/ldap-site-mngmt/webinterface/rbs/menuposition_up.php
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$meDN = $_GET['dn'];
-$oldpos = $_GET['pos'];
-
-$pxeDN = $_GET['pxedn'];
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-$oldpos = preg_replace ( '/0([0-9])/', '$1', $oldpos);
-if ($oldpos != 1){
-
- $newpos = $oldpos-1;
- if (strlen($newpos) == 1){
- $newpos = "0".$newpos;
- }
- if (strlen($oldpos) == 1){
- $oldpos = "0".$oldpos;
- }
-
- if ($secmeDN = get_dn_menuposition($pxeDN,$newpos)){
- #echo "other meDN:"; print_r($secmeDN); echo "<br>";
- $entrysec ['menuposition'] = $oldpos;
- if ($result = ldap_mod_replace($ds,$secmeDN,$entrysec)){
- $entrymenu ['menuposition'] = $newpos;
- $result = ldap_mod_replace($ds,$meDN,$entrymenu);
- }
-
- }
-}
-$seconds = 0;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&#menu";
-$mesg = "";
-#$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);
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/new_gbm.dwt b/ldap-site-mngmt/webinterface/rbs/new_gbm.dwt
deleted file mode 100644
index d5d21dc2..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_gbm.dwt
+++ /dev/null
@@ -1,91 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Neues generisches Boot Image f&uuml;r Dienst &nbsp;<code class='font_object'> {RBSCN} </code>&nbsp; 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='gbm_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 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;'>
- <input type='Text' name='gbmcn' value='{GBMCN}' size='50' class='medium_form_field'>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>KERNEL und APPEND Parameter:</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>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Server Pfad</b></td>
- <td width='15%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- <td width='30%' 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>KERNEL Image: &nbsp;</td>
- <td align='right' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+1'>{TFTP}::{TFTPPATH}</font></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[kernel]' value='' size='45' class='medium_form_field'>
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Initrd (APPEND): </b>&nbsp;</td>
- <td align='right' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+1'>{TFTP}::{TFTPPATH}</font></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[initrd]' value='' size='45' class='medium_form_field'>
-
- </td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Root Filesystem <br>(APPEND rootfs=..): </b></td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <select name='attribs[rootfstype]' size='4' class='rootfs_form_selectbox'>
- {SELECTOPTIONS}
- </select></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[rootfspath]' value='{ROOTFS}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>IPAPPEND: </b>&nbsp;</td>
- <td align='right' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[ipappend]' value='1' size='2' class='medium_form_field'>
- </td>
- </tr>
-
- <input type='hidden' name='rbsdn' value='{RBSDN}'>
- <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/rbs/new_gbm.php b/ldap-site-mngmt/webinterface/rbs/new_gbm.php
deleted file mode 100644
index 0e674399..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_gbm.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_gbm.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$rbsDN = $_GET['rbsdn'];
-
-$gbmcn = str_replace ( "_", " ", $_GET['gbmcn']);
-
-# RBS Daten
-$rbs_data = get_node_data($rbsDN, array("cn","nfsserverip","exportpath","tftpserverip","tftppath","nbdserverip"));
-$template->assign(array("RBSCN" => $rbs_data['cn'],
- "TFTP" => $rbs_data['tftpserverip'],
- "TFTPPATH" => $rbs_data['tftppath'],
- "NFS" => $rbs_data['nfsserverip'],
- "NFSPATH" => $rbs_data['exportpath'],
- "NBD" => $rbs_data['nbdserverip']));
-
-
-$options = "<option value='none' selected>----------------------------</option>
- <option value='nfs'><b>nfs://".$rbs_data['nfsserverip'].":/".$rbs_data['exportpath']."</b></option>
- <option value='nbd'>nbd://".$rbs_data['nbdserverip'].":</option>
- <option value='dnbd'>dnbd://".$rbs_data['nbdserverip'].":</option>";
-
-$template->assign(array("GBMCN" => $gbmcn,
- "LABEL" => "",
- "KERNEL" => "",
- "INITRD" => "",
- "SELECTOPTIONS" => $options,
- "ROOTFS" => "",
- "IPAPPEND" => "",
- "RBSDN" => $rbsDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/new_menuentry.dwt b/ldap-site-mngmt/webinterface/rbs/new_menuentry.dwt
deleted file mode 100644
index 2b0e7860..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_menuentry.dwt
+++ /dev/null
@@ -1,188 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td height='20'><h4>Zur&uuml;ck zu &nbsp;<a href='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}' class='headerlink'>{PXECN}</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h3>Neuen Boot Men&uuml; Eintrag anlegen:</h3></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Notwendige Attribute:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='menuentry_add.php' method='post'>
-
- <tr>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='65%' 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 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;'>
- <input type='Text' name='mecn' value='{MECN}' size='60' class='medium_form_field'>
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Label:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[label]' value='{LABEL}' size='60' 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>Generische Boot Images: </b><br>(W&auml;hlen Sie eines aus) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <select name='gbm' size='5' class='large_form_selectbox'>
- <option selected value='none'>----------</option>
- <!-- BEGIN DYNAMIC BLOCK: Gbms -->
- <option value='{GBMDN}'>{GBMCN} &nbsp;[Abt.: {RBSAU}]</option>
- <!-- END DYNAMIC BLOCK: Gbms -->
- </select>
- </td>
- </tr>
- <tr height='50'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Men&uuml; Position: </b><br>
- (Bitte ohne f&uuml;hrende Null)&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='menpos' value='{MAXPOS}' size='2' class='medium_form_field'>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Optionale Attribute:</h4></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='35%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='65%' 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>Menu Label:</b> <br>(Wird im Bootmen&uuml; statt Label angezeigt) &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menulabel]' value='{MELABEL}' 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>Menu Passwd:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menupasswd]' value='{MEPASSWD}' 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>Menu Hide:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menuhide]' value='{MEHIDE}' 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>Localboot:</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[localboot]' value='{LOCALBOOT}' size='50' class='medium_form_field'>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>APPEND Parameter:</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>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Client Konfiguration via: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[clientconfvia]' value='{CCV}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vga: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vga]' value='{VGA}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>splash: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[splash]' value='{SPLASH}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>vci: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[vci]' value='{VCI}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>no ldsc: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noldsc]' value='{NOLDSC}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>elevator: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[elevator]' value='{ELEVATOR}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>apic: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[apic]' value='{APIC}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Union FS: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[unionfs]' value='{UNIONFS}' size='30' class='medium_form_field'>
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>cowloop: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[cowloop]' value='{COWLOOP}' size='30' class='medium_form_field'>
- </td>
- </tr>
-
- <input type='hidden' name='typ' value='newme'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
-
- </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/rbs/new_menuentry.php b/ldap-site-mngmt/webinterface/rbs/new_menuentry.php
deleted file mode 100644
index a77f1129..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_menuentry.php
+++ /dev/null
@@ -1,161 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_menuentry.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = 3;
-$sbmnr = -1;
-$mcnr = -1;
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$mecn = str_replace ( "_", " ", $_GET['mecn']);
-
-$pxeDN = $_GET['dn'];
-$dnexp = ldap_explode_dn($pxeDN, 1);
-$pxecn = $dnexp[0];
-
-# RBS Daten
-$pxe = get_node_data($pxeDN,array("rbservicedn"));
-$rbsDN = $pxe['rbservicedn'];
-$exp = explode(',',$rbsDN);
-$exprbsau = explode('=',$exp[2]); $rbsau = $exprbsau[1];
-$rbsdata = get_node_data($rbsDN,array("cn","nfsserverip","exportpath","tftpserverip","tftppath"));
-
-# Anzahl Menüeinträge
-$menens = get_menuentries($pxeDN,array("dn"));
-$maxpos = count($menens)+1;
-
-# Bootmenu Daten
-$template->assign(array("MECN" => $mecn,
- "LABEL" => "",
- "MELABEL" => "",
- "MEDEF" => "",
- "MEPASSWD" => "",
- "MEHIDE" => "",
- "VGA" => "",
- "SPLASH" => "",
- "NOLDSC" => "",
- "ELEVATOR" => "",
- "VCI" => "",
- "CCV" => "",
- "APIC" => "",
- "COWLOOP" => "",
- "UNIONFS" => "",
- "DEBUG" => "",
- "LOCALBOOT" => "",
- "SUBMENULINK" => "",
- "MENPOS" => "",
- "MAXPOS" => $maxpos,
- "PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-
-# verwendbare GBMs holen
-# eigene AU (andere noch über "offer" Attribut in RBS suchen)
-$attributes = array("dn","cn","label","kernel","initrd","nfsroot","nbdroot","ipappend");
-$gbm_array = get_menuentries($rbsDN,$attributes);
-if (count($gbm_array) != 0){
-$template->define_dynamic("Gbms", "Webseite");
- foreach ($gbm_array as $item){
- $template->assign(array("GBMDN" => $item['dn'],
- "GBMCN" => $item['cn'],
- "GBMLABEL" => $item['label'],
- "RBSAU" => $rbsau));
- $template->parse("GBMS_LIST", ".Gbms");
- }
-}else{
- $template->assign(array("GBMDN" => "",
- "GBMCN" => "Keine generischen Boot Images verf&uuml;gbar",
- "GBMLABEL" => "Keine generischen Boot Images verf&uuml;gbar",
- "RBSAU" => ""));
-}
-
-
-# Alternative RB Dienste holen
-$altrbs = get_rbservices($auDN,array("dn","cn"));
-if (count($altrbs) != 0){
- for ($i=0; $i < count($altrbs); $i++){
- if ($rbsDN == $altrbs[$i]['dn']){
- array_splice($altrbs, $i, 1);
- }
- }
-}
-
-
-if (count($altrbs) != 0){
-$template->define_dynamic("Altrbs", "Webseite");
- foreach ($altrbs as $item){
- $altrbsexp = explode(',',$item['dn']);
- $altrbsau = explode('=',$altrebsexp[2]);
- $template->assign(array("ALTRBSDN" => $item['dn'],
- "ALTRBSCN" => $item['cn'],
- "ALTRBSAU" => "[ ".$altrbsau[1]." ]"));
- $template->parse("ALTRBS_LIST", ".Altrbs");
- }
-}else{
- $template->assign(array("ALTRBSDN" => "",
- "ALTRBSCN" => "",
- "ALTRBSAU" => ""));
-}
-
-################################################
-# Bootmenü Einträge
-
-$menuentries = get_menuentries($pxeDN,array("dn","menuposition","label","menulabel"));
-#print_r($menuentries); echo "<br>";
-
-$template->define_dynamic("Bootmenu", "Webseite");
-
-foreach ($menuentries as $me){
- $template->assign(array("MENDN" => $me['dn'],
- "MENULABEL" => $me['menulabel'],
- "POSITION" => $me['menuposition'],
- "AUDN" => $auDN));
- $template->parse("BOOTMENU_LIST", ".Bootmenu");
-}
-
-
-################################################
-# PXE kopieren
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/rbs/new_pxe.dwt b/ldap-site-mngmt/webinterface/rbs/new_pxe.dwt
deleted file mode 100644
index 3418d674..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_pxe.dwt
+++ /dev/null
@@ -1,144 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Neue PXE Config (DEFAULT) f&uuml;r Dienst &nbsp;<code class='font_object'> {RBSCN} </code>&nbsp; anlegen:</h3></td>
- </tr>
- <tr>
- <td height='10'>&nbsp;</td>
- </tr>
- <tr>
- <td colspan='2'><h4>Allgemein:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='pxe_add.php' method='post'>
- <tr>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- <font size='+2'><b>PXE_</b></font><input type='Text' name='pxecn' value='{PXECN}' size='50' class='medium_form_field'>
- </td>
- </tr>
- <tr valign='top'>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>G&uuml;ltigkeitsdauer <br>(Time Range): </b>&nbsp;</td>
- <td width='40%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='pxeday' value='{PXEDAY}' size='5' maxlength='5' class='medium_form_field'>
- &nbsp;<br>
- Eines der folgenden:<br>
-
- - <b>Datum</b> &nbsp;(Format: dd.mm, z.B. 21.03/01.11) <br>
- - <b>Monatstag</b> &nbsp;(Format: dd, z.B. 01 oder 25) <br>
- - <b>Wochentag</b> &nbsp;(Format: MO, DI, ... , SO) <br>
- - <b>X</b> f&uuml;r <b>t&auml;glich</b>
-
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='pxebeg' value='{PXEBEG}' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='pxeend' value='{PXEEND}' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:59</b> Uhr</font><br>
- - <b>Uhrzeit</b> &nbsp;(Format: hh, z.B. 07-19)<br>
- - <b>X</b> f&uuml;r rund um die Uhr
- </td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Globale PXE Parameter:</h4></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='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='70%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[default]' value='{DEFAULT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[default]' value='{DEFAULT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Title: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menutitle]' value='{MENTIT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menutitle]' value='{MENTIT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Master Passwd: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menumasterpasswd]' value='{MENMPW}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menumasterpasswd]' value='{MENMPW}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Timeout: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[timeout]' value='{TIMEOUT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[timeout]' value='{TIMEOUT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>No Escape: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noescape]' value='{NOESC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[noescape]' value='{NOESC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Prompt: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[prompt]' value='{PROMPT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[prompt]' value='{PROMPT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Allow Options: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[allowoptions]' value='{ALLOW}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[allowoptions]' value='{ALLOW}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>On Error: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[onerror]' value='{ONERR}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[onerror]' value='{ONERR}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>ON Timeout: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[ontimeout]' value='{ONTIME}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[ontimeout]' value='{ONTIME}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Client-Conf Dateiname <br>(File URI): &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='conffile' value='{FILEURI}' size='50' class='medium_form_field'>
- &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='oldpxecn' value='{PXECN}'>
- <input type='hidden' name='rbsdn' value='{RBSDN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </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/rbs/new_pxe.php b/ldap-site-mngmt/webinterface/rbs/new_pxe.php
deleted file mode 100644
index e51d21ec..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_pxe.php
+++ /dev/null
@@ -1,72 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_pxe.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$rbsDN = $_GET['rbsdn'];
-$rbsdnexp = ldap_explode_dn($rbsDN, 1);
-
-$pxecn = str_replace ( "_", " ", $_GET['pxecn']);
-$pxeday = str_replace ( "_", " ", $_GET['pxeday']);
-$pxebeg = str_replace ( "_", " ", $_GET['pxebeg']);
-$pxeend = str_replace ( "_", " ", $_GET['pxeend']);
-
-$template->assign(array("PXECN" => $pxecn,
- "PXEDAY" => $pxeday,
- "PXEBEG" => $pxebeg,
- "PXEEND" => $pxeend,
- "LDAPURI" => "",
- "FILEURI" => "",
- "RBSDN" => $rbsDN,
- "RBSCN" => $rbsdnexp[0],
- "RBSAU" => "",
- "NFS" => "",
- "NFSROOT" => "",
- "TFTP" => "",
- "TFTPROOT" => "",
- "FILE" => "",
- "ALLOW" => "",
- "CONSOLE" => "",
- "DEFAULT" => "menu.c32",
- "DISPLAY" => "",
- "FONT" => "",
- "IMPLICIT" => "",
- "KBDMAP" => "",
- "MENMPW" => "",
- "MENTIT" => "",
- "NOESC" => "1",
- "ONERR" => "",
- "ONTIME" => "",
- "PROMPT" => "0",
- "SAY" => "",
- "SERIAL" => "",
- "TIMEOUT" => "600",
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/new_rbservice.dwt b/ldap-site-mngmt/webinterface/rbs/new_rbservice.dwt
deleted file mode 100644
index 52e693b5..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_rbservice.dwt
+++ /dev/null
@@ -1,117 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Remote Boot Service 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='rbservice_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 RBS 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>RBS_</b></font><input type='Text' name='rbscn' value='{RBSCN}' size='40' 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='rbsoffer' size='4' class='medium_form_selectbox'>
- <option selected value='{OFFERSELF}'>------ {SELFOU} ------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Rbsoffers -->
- <option value='{RBSOFFER}'>{RBSOFFEROU}</option>
- <!-- END DYNAMIC BLOCK: Rbsoffers -->
-
- </select>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Boot Server System:</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='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Server</b></td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>IP Adresse eingeben</b> oder<br><b>Rechner ausw&auml;hlen</b></td>
- <td width='50%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Pfad</b> <br>(auf dem jeweiligen Server)</td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>TFTP Server: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='tftpserverip' value='' size='20' class='medium_form_field'>
- <select name='tftpserver' size='4' class='small_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <!-- BEGIN DYNAMIC BLOCK: TftpHosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: TftpHosts -->
- </select>
- </td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- Initial Boot File <input type='Text' name='attribs[initbootfile]' value='{INITBOOTFILE}' size='25' class='medium_form_field'><br>
- Kernel Path <input type='Text' name='attribs[tftpkernelpath]' value='{TFTPKERNEL}' size='25' class='medium_form_field'><br>
- PXE Path<input type='Text' name='attribs[tftppxepath]' value='{TFTPPXE}' size='25' class='medium_form_field'><br>
- Clientconf Path<input type='Text' name='attribs[tftpclientconfpath]' value='{TFTPCLIENTCONF}' size='25' class='medium_form_field'>
- </td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NFS Server: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='nfsserverip' value='' size='20' class='medium_form_field'>
- <select name='nfsserver' size='4' class='small_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <!-- BEGIN DYNAMIC BLOCK: NfsHosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: NfsHosts -->
- </select>
- </td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[exportpath]' value='{NFSPATH}' size='25' class='medium_form_field'>
- </td>
- </tr>
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>NBD Server: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='nbdserverip' value='' size='20' class='medium_form_field'>
- <select name='nbdserver' size='4' class='small_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <!-- BEGIN DYNAMIC BLOCK: NbdHosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: NbdHosts -->
- </select>
- </td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</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/rbs/new_rbservice.php b/ldap-site-mngmt/webinterface/rbs/new_rbservice.php
deleted file mode 100644
index 29d6a947..00000000
--- a/ldap-site-mngmt/webinterface/rbs/new_rbservice.php
+++ /dev/null
@@ -1,94 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "new_rbservice.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = 0;
-$sbmnr = -1;
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-# nochmal zur Sicherheit: falls doch RBS angelegt
-
-$rbscn = str_replace ( "_", " ", $_GET['rbscn']);
-$template->assign(array("RBSCN" => $rbscn,
- "TFTP" => "",
- "TFTPIP" => "",
- "INITBOOTFILE" => "",
- "TFTPKERNEL" => "",
- "TFTPPXE" => "",
- "TFTPCLIENTCONF" => "",
- "NFS" => "",
- "NFSIP" => "",
- "NFSPATH" => "",
- "NBD" => "",
- "NBDIP" => "",
- "HDN" => "",
- "HN" => "",
- "IP" => "",
- "OFFERSELF" => $auDN,
- "SELFOU" => $au_ou,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-
-# RBS 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++){
- $rbsoffers[$i]['ou'] = $expou[$i];
- $rbsoffers[$i]['dn'] = implode(',',$expdn);
- $expdn = array_slice($expdn, 1);
-}
-#print_r($rbsoffers);
-
-$template->define_dynamic("Rbsoffers", "Webseite");
-foreach ($rbsoffers as $offer){
- $template->assign(array("RBSOFFER" => $offer['dn'],
- "RBSOFFEROU" => $offer['ou'],));
- $template->parse("RBSOFFERS_LIST", ".Rbsoffers");
-}
-
-### 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");
-}
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/no_rbservice.dwt b/ldap-site-mngmt/webinterface/rbs/no_rbservice.dwt
deleted file mode 100644
index 2d7c1a87..00000000
--- a/ldap-site-mngmt/webinterface/rbs/no_rbservice.dwt
+++ /dev/null
@@ -1,22 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Remote Boot Service </h3>
-
- <p>Sie haben noch keinen <b>Remote Boot Service</b> eingerichtet.</p>
-
- <p>Um</p>
-
- <ul>
- <li><p><b>Generische Boot Men&uuml;s</b></p></li>
- <li><p><b>Default PXE Bootmen&uuml;s</b></p></li>
- </ul>
-
- <p>anlegen zu k&ouml;nnen muss erst ein Remote Boot Service eingerichtet werden.</p>
-
- <p>Verwenden sie daf&uuml;r den Link <b>"Remote Boot Service"</b> im Navigationsmen&uuml; links, um
- zur Eingabemaske zu gelangen.</p>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/no_rbservice.php b/ldap-site-mngmt/webinterface/rbs/no_rbservice.php
deleted file mode 100644
index 5c527bab..00000000
--- a/ldap-site-mngmt/webinterface/rbs/no_rbservice.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "no_rbservice.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = 1;
-$sbmnr = -1;
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/pxe.dwt b/ldap-site-mngmt/webinterface/rbs/pxe.dwt
deleted file mode 100644
index ae1c112a..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe.dwt
+++ /dev/null
@@ -1,461 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
-
- <tr>
- <td height='20'><h4><a href='pxeconfig_default.php?rbsdn={RBSDN}&mnr={MNR}&sbmnr={SBMNR}' class='headerlink'><< Zur&uuml;ck zur PXE &Uuml;bersicht</a></h4></td>
- </tr>
- <tr>
- <td height='20'>&nbsp;</td>
- </tr>
-
- <tr>
- <td colspan='2'><h3>PXE Boot Men&uuml; &nbsp;<code class='font_object'> {PXECN} </code> </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
-
- <tr>
- <td colspan='2'>Klicken Sie auf einen Men&uuml;eintrag um zur Detailansicht zu gelangen und den Eintrag bearbeiten zu k&ouml;nnen</td>
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='80%' style='border-color: black; border-style: solid; border-width: 2 2 2 2;'>
-
- <tr>
- <td width='8%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>#</td>
- <td width='8%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Flags</td>
- <td width='64%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Menu Label&nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='15%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Bootmenu -->
- <form action='delete_confirm.php' method='post'>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>{BACKLINK}{POSITION}</a></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>{MEDEF} {MEPWD} {MEHIDE}&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'><font size='+1'>{ANZEIGE}&nbsp;</font></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>
- <a href='menuposition_up.php?dn={MENDN}&pos={POSITION}&pxedn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'><img style='border-width:0;border-style=none;' src='../pics/up2.gif' height='15'></a> <br>
- <a href='menuposition_down.php?dn={MENDN}&pos={POSITION}&pxedn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'><img style='border-width:0;border-style=none;' src='../pics/down2.gif' height='15'></a></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;{BGCDEF}'>
- <input type='hidden' name='dn' value='{MENDN}'>
- <input type='hidden' name='name' value='{ANZEIGENAME}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='delurl' value='menuentry_delete.php'>
- <input type='hidden' name='successurl' value='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
- <input type='hidden' name='backurl' value='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
- <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
- </tr>
- </form>
- <!-- END DYNAMIC BLOCK: Bootmenu -->
-
- </table></td>
- </tr>
- <tr>
- <td><h4>Flags:</h4></font>
- <ul>
- <li><b>D</b> -> Default Men&uuml;eintrag</li>
- <li><b>P</b> -> Passwort gesch&uuml;tzt</li>
- <li><b>H</b> -> Hidden</li>
- </ul>
- </td>
- </tr>
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Neuen Men&uuml;eintrag anlegen: &nbsp;&nbsp;</h4>
- <a href='new_menuentry.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}' style='color:#FFFFFF;' class='small_loginform_button'>&nbsp; zur Eingabemaske &nbsp;</a> </td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Standard Men&uuml;eintr&auml;ge anlegen:</h4></td>
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
-
- <tr>
- <td width='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Typ &nbsp;</td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='10%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>Position</td>
- <td width='10%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Localboot</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- Menu Label<br><input type='Text' name='locallabel' value='' size='20' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- Passwort (optional)<br><input type='Text' name='localpasswd' value='' size='20' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='localpos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='local'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Textzeile</b> &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='text' value='TEXT' size='50' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='textpos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='text'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Leerzeile</b> &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='leerpos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='leer'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
- <tr valign='top'>
- <form action='menuentry_add.php' method='post'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Verweis zu Submen&uuml;</b> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>Submen&uuml; Name<br>
- <input type='Text' name='submenu' value='' size='20' class='medium_form_field'></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>Remote Boot Service
- <select name='subrbs' size='3' class='small_form_selectbox'>
- <option selected value='none'>----------</option>
- <!-- BEGIN DYNAMIC BLOCK: Subrbs -->
- <option value='{SUBRBSDN}'>{SUBRBSCN} {SUBRBSAU}</option>
- <!-- END DYNAMIC BLOCK: Subrbs -->
- </select>
- </td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Text' name='submenupos' value='{MAXPOS}' size='2' class='medium_form_field'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><input type='Submit' name='apply' value='anlegen' class='small_loginform_button'></td>
- <input type='hidden' name='typ' value='submenu'>
- <input type='hidden' name='maxpos' value='{MAXPOS}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='timerange' value='{TIMERANGE}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- </form>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Allgemeine Parameter:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='7' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
-
- <form action='pxe_change.php' method='post'>
- <tr>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- <font size='+2'><b>PXE_</b></font><input type='Text' name='pxecn' value='{PXECN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldpxecn' value='{PXECN}'> &nbsp;
- </td>
- </tr>
-
- <tr valign='top'>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>G&uuml;ltigkeitsdauer <br>(Time Range(s)): </b><br>
- Zum L&ouml;schen einer Time Range<br>H&auml;kchen setzen&nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- Eines der folgenden:<br>
-
- - <b>Datum</b> &nbsp;(dd.mm, z.B. 21.03/01.11) <br>
- - <b>Monatstag</b> &nbsp;(dd, z.B. 01 oder 25) <br>
- - <b>Wochentag</b> &nbsp;(MO, DI, ... , SO) <br>
- - <b>X</b> f&uuml;r <b>t&auml;glich</b>
-
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- - <b>Uhrzeit</b> &nbsp;(Format: hh, z.B. 07-19)<br>
- - <b>X</b> f&uuml;r rund um die Uhr
-
- </td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: TRanges -->
- <tr valign='top'>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='checkbox' name='deltr[]' value='{PXEDAY}_{PXEBEG}_{PXEEND}'>
- &nbsp;</td>
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='pxeday[]' value='{PXEDAY}' size='5' maxlength='5' class='medium_form_field'>
- <input type='hidden' name='oldpxeday[]' value='{PXEDAY}'> &nbsp;<br>
-
-
- <td width='35%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>
- <input type='Text' name='pxebeg[]' value='{PXEBEG}' size='2' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldpxebeg[]' value='{PXEBEG}'> <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='pxeend[]' value='{PXEEND}' size='2' maxlength='2' class='medium_form_field'>
- <input type='hidden' name='oldpxeend[]' value='{PXEEND}'> <b><font size='+1'>:59</b> Uhr</font><br>
- </td>
- </tr>
- <!-- END DYNAMIC BLOCK: TRanges -->
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>Neue Time Range hinzuf&uuml;gen&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='newpxeday' value='' size='5' maxlength='5' class='medium_form_field'>
-
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='newpxebeg' value='' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:00</b> &nbsp;- &nbsp;</font>
- <input type='Text' name='newpxeend' value='' size='2' maxlength='2' class='medium_form_field'>
- <b><font size='+1'>:59</b> Uhr</font><br>
-
- </td>
- </tr>
-
- </table></td>
- </tr>
-
-
-
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Globale PXE Parameter:</h4></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='20%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Attribut</b></td>
- <td width='80%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Wert</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Default: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[default]' value='{DEFAULT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[default]' value='{DEFAULT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Title: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menutitle]' value='{MENTIT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menutitle]' value='{MENTIT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Menu Master Passwd: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[menumasterpasswd]' value='{MENMPW}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[menumasterpasswd]' value='{MENMPW}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Timeout: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[timeout]' value='{TIMEOUT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[timeout]' value='{TIMEOUT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>No Escape: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[noescape]' value='{NOESC}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[noescape]' value='{NOESC}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Prompt: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[prompt]' value='{PROMPT}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[prompt]' value='{PROMPT}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Allow Options: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[allowoptions]' value='{ALLOW}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[allowoptions]' value='{ALLOW}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>On Error: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[onerror]' value='{ONERR}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[onerror]' value='{ONERR}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>ON Timeout: </b>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='Text' name='attribs[ontimeout]' value='{ONTIME}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[ontimeout]' value='{ONTIME}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>File URI: &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+1'>tftp://{TFTP}/{TFTPFILE}</font><input type='Text' name='attribs[fileuri]' value='{FILEURI}' size='30' class='medium_form_field'>
- <input type='hidden' name='oldattribs[fileuri]' value='{FILEURI}'>
- &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='20'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>PXE Dateiname:</h4>
- Achtung: &Auml;nderungen hier k&ouml;nnen zu nicht verwendeten PXE Dateien f&uuml;hren!<br>
- Sie sollten hier nur &Auml;nderungen vornehmen, wenn der PXE Datei offensichtlich ein falscher Name zugewiesen ist.<br>
- Wird z.B. vom betroffenen Rechner die MAC Adresse ge&auml;ndert, so wird dies vom System automatisch an dieser Stelle nachvollzogen.
- Diese Feld dient daher prim&auml;r der Kontrolle.</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: 3 0 1 0;'>
- <b>PXE Dateiname(n): </b><br>
- Bei PXE von Gruppen ist f&uuml;r jeden Mitgliedsrechner<br>
- der PXE Dateiname aufgelistet.
- </td>
- <td style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- <!-- BEGIN DYNAMIC BLOCK: Filenames -->
- <input type='Text' name='filename[]' value='{FILE}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldfilename[]' value='{FILE}'> &nbsp;
- <!-- END DYNAMIC BLOCK: Filenames -->
- <input type='Text' name='newfilename' value='' size='40' class='medium_form_field'>
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td>
- <input type='hidden' name='nodedn' value='{NODEDN}'>
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='oldpxecn' value='{PXECN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- <input type='Submit' name='apply' value='anwenden' class='small_loginform_button'>
- </form></td>
- </tr>
-
-
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>PXE Boot Men&uuml; &nbsp;<code class='font_object'>{PXECN}</code>&nbsp; kopieren:</h4>
- Beachten Sie, dass die Time Ranges des PXE Boot Men&uuml;s nicht kopiert werden. Sie m&uuml;ssen diese anschlie&szlig;end
- neu setzen. <br>
- Geben Sie bitte den eindeutigen Namen des neuen PXE Boot Men&uuml;s an.</td>
- </tr>
- <tr>
- <td>
- <table cellpadding='7' cellspacing='0' border='0' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <form action='pxe_copy.php' method='post'>
-
- <tr valign='top'>
- <td style='border-color: black; border-style: solid; border-width: 3 0 1 0;'><b>Ziel Objekt:</b><br>
- (Mehrfachauswahl m&ouml;glich)&nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
-
- <select name='copytargets[]' size='10' multiple class='medium_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <option value='{DEFDN}'>DEFAULT</option>
-
- <option value='none'>---- RECHNER -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Hosts -->
- <option value='{HDN}'>{HN}</option>
- <!-- END DYNAMIC BLOCK: Hosts -->
-
- <option value='none'>---- GRUPPEN -----</option>
- <!-- BEGIN DYNAMIC BLOCK: Groups -->
- <option value='{GDN}'>{GN}</option>
- <!-- END DYNAMIC BLOCK: Groups -->
- </select>
- </td>
- </tr>
- <tr>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><b>Eindeutiger Name (cn):</b><br>(Bitte ohne Leerzeichen eingeben) &nbsp;</td>
- <td colspan='2' style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <font size='+2'><b>PXE_</b></font><input type='Text' name='pxecncp' value='{PXECN}' size='50' class='medium_form_field'>
- <input type='hidden' name='oldpxecncp' value='{PXECN}'> &nbsp;
- </td>
- </tr>
-
- <input type='hidden' name='pxedn' value='{PXEDN}'>
- <input type='hidden' name='oldpxecn' value='{PXECN}'>
- <input type='hidden' name='mnr' value='{MNR}'>
- <input type='hidden' name='sbmnr' value='{SBMNR}'>
- <input type='hidden' name='mcnr' value='{MCNR}'>
- <input type='hidden' name='deltr' value='{DELTR}'>
-
- </table></td>
- </tr><tr><td>
- <input type='Submit' name='apply' value='kopieren' class='small_loginform_button'>
- </form></td></tr>
-
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>PXE Boot Men&uuml; &nbsp;<code class='font_object'>{PXECN}</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;'>
- Die MachineConfig wird komplett gel&ouml;scht.
- </tr>
-
- <input type='hidden' name='dn' value='{PXEDN}'>
- <input type='hidden' name='name' value='{PXECN}'>
- <input type='hidden' name='delurl' value='pxe_delete.php'>
- <input type='hidden' name='successurl' value='pxeconfig_default.php?&mnr={MNR}'>
- <input type='hidden' name='backurl' value='pxe.php?dn={PXEDN}&mnr={MNR}&sbmnr={SBMNR}&mcnr={MCNR}'>
-
- </table></td>
- </tr><tr><td>
- <input type='Submit' name='apply' value='l&ouml;schen' class='small_loginform_button'>
- </form></td></tr>
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/rbs/pxe.php b/ldap-site-mngmt/webinterface/rbs/pxe.php
deleted file mode 100644
index d1785081..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe.php
+++ /dev/null
@@ -1,219 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "pxe.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-# $mcnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-$mcnr = $_GET['mcnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$pxeDN = $_GET['dn'];
-#$rbsDN = $_GET['rbsdn'];
-
-$attributes = array("dn","cn","rbservicedn","filename","timerange","allowoptions","console","default",
- "display","font","implicit","kbdmap","menumasterpasswd","menutitle",
- "noescape","onerror","ontimeout","prompt","say","serial","timeout","ldapuri","fileuri");
-$pxe = get_node_data($pxeDN,$attributes);
-#print_r($pxe);
-
-$exp = explode(',',$pxeDN);
-$node = array_slice($exp,1);
-$nodeDN = implode(',',$node);
-
-# RBS Daten
-$rbsDN = $pxe['rbservicedn'];
-$exp = explode(',',$rbsDN);
-$exprbsau = explode('=',$exp[2]); $rbsau = $exprbsau[1];
-$rbsdata = get_node_data($rbsDN,array("cn","nfsserverip","exportpath","tftpserverip","tftppath","tftpclientconfpath"));
-
-# Timerange Komponenten
-$template->define_dynamic("TRanges", "Webseite");
-if (count($pxe['timerange']) > 1){
- foreach($pxe['timerange'] as $tr){
- $exptime = explode('_',$tr);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
- }
-}else{
- $exptime = explode('_',$pxe['timerange']);
- $template->assign(array("PXEDAY" => $exptime[0],
- "PXEBEG" => $exptime[1],
- "PXEEND" => $exptime[2]));
- $template->parse("TRANGES_LIST", ".TRanges");
-}
-
-# Filenames
-$template->define_dynamic("Filenames", "Webseite");
-if (count($pxe['filename']) > 1){
- foreach($pxe['filename'] as $fi){
- $template->assign(array("FILE" => $fi));
- $template->parse("FILENAMES_LIST", ".Filenames");
- }
-}else{
- $exptime = explode('_',$pxe['filename']);
- $template->assign(array("FILE" => $pxe['filename']));
- $template->parse("FILENAMES_LIST", ".Filenames");
-}
-
-$expcn = explode('_',$pxe['cn']);
-$name = array_slice($expcn,1);
-$pxecn = implode('_',$name);
-
-# Bootmenü Einträge
-$menuentries = get_menuentries($pxeDN,array("dn","menuposition","label","menulabel","menudefault","menupasswd","menuhide"));
-#print_r($menuentries); echo "<br>";
-$maxpos = count($menuentries)+1;
-
-# Globale Parameter
-$template->assign(array("PXEDN" => $pxeDN,
- "PXECN" => $pxecn,
- "TIMERANGE" => $pxe['timerange'],
- "RBSDN" => $rbsDN,
- "RBS" => $rbsdata['cn'],
- "RBSAU" => $rbsau,
- "NFS" => $rbsdata['nfsserverip'],
- "NFSROOT" => $rbsdata['exportpath'],
- "TFTP" => $rbsdata['tftpserverip'],
- "TFTPROOT" => $rbsdata['tftppath'],
- "TFTPFILE" => $rbsdata['tftpclientconfpath'],
- #"LDAP" => LDAP_HOST,
- #"LDAPURI" => $pxe['ldapuri'],
- "FILEURI" => $pxe['fileuri'],
- "FILE" => $pxe['filename'],
- "ALLOW" => $pxe['allowoptions'],
- "CONSOLE" => $pxe['console'],
- "DEFAULT" => $pxe['default'],
- "DISPLAY" => $pxe['display'],
- "FONT" => $pxe['font'],
- "IMPLICIT" => $pxe['implicit'],
- "KBDMAP" => $pxe['kbdmap'],
- "MENMPW" => $pxe['menumasterpasswd'],
- "MENTIT" => $pxe['menutitle'],
- "NOESC" => $pxe['noescape'],
- "ONERR" => $pxe['onerror'],
- "ONTIME" => $pxe['ontimeout'],
- "PROMPT" => $pxe['prompt'],
- "SAY" => $pxe['say'],
- "SERIAL" => $pxe['serial'],
- "TIMEOUT" => $pxe['timeout'],
- "MAXPOS" => $maxpos,
- "NODEDN" => $nodeDN,
- "DEFDN" => $rbsDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "MCNR" => $mcnr));
-
-# RB Dienste für Submenüeinträge holen
-# kommt wohl wieder raus (->Submenüs nur im eigenen RBS Bereich)
-$subrbs = get_rbsoffers($auDN);
-
-# Für Submenü Einträge
-$template->assign(array("SUBRBSDN" => "",
- "SUBRBSCN" => "",
- "SUBRBSAU" => ""));
-if (count($subrbs) != 0){
-$template->define_dynamic("Subrbs", "Webseite");
- foreach ($subrbs as $item){
- $rbsdnexp = ldap_explode_dn($item,1);
- $subrbscn = $rbsdnexp[0];
- $subrbsau = $rbsdnexp[2];
- #$subrbsexp = explode(',',$item['dn']);
- #$subrbsau = explode('=',$subrbsexp[2]);
- $template->assign(array("SUBRBSDN" => $item,
- "SUBRBSCN" => $subrbscn,
- "SUBRBSAU" => "[ ".$subrbsau." ]"));
- $template->parse("SUBRBS_LIST", ".Subrbs");
- }
-}
-
-
-################################################
-# Bootmenü Einträge
-
-$template->define_dynamic("Bootmenu", "Webseite");
-$template->assign(array("MENDN" => "",
- "MENULABEL" => "",
- "ANZEIGE" => "Noch kein Bootmen&uuml; Eintrag angelegt",
- "MEDEF" => "",
- "MEPWD" => "",
- "MEHIDE" => "",
- "BGCDEF" => "",
- "POSITION" => ""));
-foreach ($menuentries as $me){
- $anzeige = "";
- if ($me['label'] != "" && $me['menulabel'] == ""){$anzeige .= $me['label'];}
- if ($me['menulabel'] != ""){$anzeige .= $me['menulabel'];}
- if ($me['menudefault'] == 1){$medef = "<b>D</b>"; $bgcdef = "background-color:#EEDD82;";}
- if ($me['menupasswd'] != ""){$mepwd = "<b>P</b>";}
- if ($me['menuhide'] == 1){$mehide = "<b>H</b>"; $bgcdef = "background-color:#A0A0A0;";}
- $template->assign(array("MENDN" => $me['dn'],
- "BACKLINK" => "<a href='menuentry.php?dn=".$me['dn']."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr."' class='headerlink'>",
- "ANZEIGE" => "<a href='menuentry.php?dn=".$me['dn']."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr."' class='headerlink'>".$anzeige."</a>",
- "ANZEIGENAME" => $anzeige,
- "POSITION" => $me['menuposition'],
- "MEDEF" => $medef,
- "MEPWD" => $mepwd,
- "MEHIDE" => $mehide,
- "BGCDEF" => $bgcdef,
- "AUDN" => $auDN));
- $template->parse("BOOTMENU_LIST", ".Bootmenu");
- $medef = "";
- $bgcdef = "";
-}
-
-
-
-################################################
-# PXE kopieren
-
-$hostorgroup = $exp[0];
-$hgexp = explode('=',$exp[0]);
-
-$hosts_array = get_hosts($auDN,array("dn","hostname"));
-$groups_array = get_groups($auDN,array("dn","cn"));
-
-$template->define_dynamic("Hosts", "Webseite");
-foreach ($hosts_array as $item){
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname']));
- $template->parse("HOSTS_LIST", ".Hosts");
-}
-$template->define_dynamic("Groups", "Webseite");
-foreach ($groups_array as $item){
- $template->assign(array("GDN" => $item['dn'],
- "GN" => $item['cn']));
- $template->parse("GROUPS_LIST", ".Groups");
-}
-
-
-# falls TR vorhanden dann soll sie gelöscht werden (flag deltr setzen)
-if (count($pxe['timerange']) != 0){
- $template->assign(array("DELTR" => "1"));
-}
-else{
- $template->assign(array("DELTR" => "0"));
-}
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/rbs/pxe_add.php b/ldap-site-mngmt/webinterface/rbs/pxe_add.php
deleted file mode 100644
index 793cb34f..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe_add.php
+++ /dev/null
@@ -1,118 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxecn = $_POST['pxecn']; $pxecn = htmlentities($pxecn);
-$rbsDN = $_POST['rbsdn'];
-#print_r($rbsDN);
-$pxeday = $_POST['pxeday']; $pxeday = htmlentities($pxeday);
-$pxebeg = $_POST['pxebeg']; $pxebeg = htmlentities($pxebeg);
-$pxeend = $_POST['pxeend']; $pxeend = htmlentities($pxeend);
-
-$conffile = $_POST['conffile']; $conffile = htmlentities($conffile);
-
-$pxeattribs = $_POST['pxeattribs'];
-if (count($pxeattribs) != 0){
- foreach (array_keys($pxeattribs) as $key){
- $pxeatts[$key] = htmlentities($pxeattribs[$key]);
- }
-}
-# print_r($pxeatts); echo "<br><br>";
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-
-$seconds = 2;
-$get_pxecn = str_replace ( " ", "_", $pxecn );
-$get_pxeday = str_replace ( " ", "_", $pxeday );
-$get_pxebeg = str_replace ( " ", "_", $pxebeg );
-$get_pxeend = str_replace ( " ", "_", $pxeend );
-$url = "new_pxe.php?pxecn=".$get_pxecn."&pxeday=".$get_pxeday."&pxebeg=".$get_pxebeg."&pxeend=".$get_pxeend."&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>";
-
-if ( $pxecn != "" && $pxecn != "Hier_PXE_NAME_eintragen" && $rbsDN != "none" ){
-
- $pxecn = "PXE_".$pxecn;
- # Formulareingaben anpassen
- $exppxe = explode(" ",$pxecn);
- foreach ($exppxe as $word){$expuc[] = ucfirst($word);}
- $pxecn = implode(" ",$expuc);
- $pxecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $pxecn);
-
- $pxetimerange = "";
-
- if ( $pxeday != "" && $pxebeg != "" && $pxeend != "" && $pxebeg <= $pxeend ){
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($pxeday,$pxebeg,$pxeend)){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$pxeday)){$pxeday = strtoupper($pxeday);}
- if (preg_match("/([a-z]+)/",$pxebeg)){$pxebeg = strtoupper($pxebeg);}
- if (preg_match("/([a-z]+)/",$pxeend)){$pxeend = strtoupper($pxeend);}
-
- # führende Nullen weg
- $pxebeg = preg_replace ( '/0([0-9])/', '$1', $pxebeg);
- $pxeend = preg_replace ( '/0([0-9])/', '$1', $pxeend);
-
- # TimeRange auf Ãœberschneidung mit vorhandenen checken
- if(check_timerange_pxe($pxeday,$pxebeg,$pxeend,$rbsDN,"")){
- $pxetimerange = $pxeday."_".$pxebeg."_".$pxeend;
- }
- else{
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml;, das sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Das neue PXE Boot Men&uuml; wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschließend ein.<br><br>";
- }
- }
- else{
- $mesg = "Falsche Syntax in der Time-Range-Eingabe! Das neue PXE Boot Men&uuml; wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschließend ein.<br><br>";
- }
- }
- else{
- $mesg = "Keine vollst&auml;ndige Time-Range-Eingabe! Das neue PXE Boot Men&uuml; wird ohne Time Range angelegt.<br>
- Bitte geben Sie diese anschließend ein.<br><br>";
- }
-
- $pxeDN = "cn=".$pxecn.",".$rbsDN;
- $filename = array("default");
- #$ldapuri = LDAP_HOST."/dn=cn=computers,".$auDN;
-
- if (add_pxe($pxeDN,$pxecn,$rbsDN,$pxetimerange,$pxeattribs,$filename,$conffile)){
- $mesg .= "<br>Neues PXE Boot Men&uuml; erfolgreich angelegt<br>";
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- }
- else{
- $mesg .= "<br>Fehler beim anlegen des PXE Boot Men&uuml;s!<br>";
- }
-}
-
-elseif ( $pxecn == "" || $pxecn == "Hier_PXE_NAME_eintragen" || $rbsDN == "none" ){
-
- $mesg = "Sie haben den Namen des neuen PXE Boot Men&uuml;s nicht angegeben oder den
- Remote Boot Dienst nicht ausgew&auml;hlt. Beide sind aber ein notwendige Attribute.<br>
- Bitte geben Sie sie an.<br><br>";
- $url = "new_pxe.php?pxecn=Hier_PXE_NAME_eintragen&pxeday=".$get_pxeday."&pxebeg=".$get_pxebeg."&pxeend=".$get_pxeend."&mnr=".$mnr."&sbmnr=".$sbmnr;
-}
-
-
-
-$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/rbs/pxe_change.php b/ldap-site-mngmt/webinterface/rbs/pxe_change.php
deleted file mode 100644
index d122a830..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe_change.php
+++ /dev/null
@@ -1,434 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxecn = "PXE_".$_POST['pxecn'];
-
-$pxeday = $_POST['pxeday'];
-$pxebeg = $_POST['pxebeg'];
-$pxeend = $_POST['pxeend'];
-foreach (array_keys($pxeday) as $key){
- $pxeday[$key] = htmlentities($pxeday[$key]);
-}
-foreach (array_keys($pxebeg) as $key){
- $pxebeg[$key] = htmlentities($pxebeg[$key]);
-}
-foreach (array_keys($pxeend) as $key){
- $pxeend[$key] = htmlentities($pxeend[$key]);
-}
-
-$deltr = $_POST['deltr'];
-
-$newpxeday = $_POST['newpxeday']; $newpxeday = htmlentities($newpxeday);
-$newpxebeg = $_POST['newpxebeg']; $newpxebeg = htmlentities($newpxebeg);
-$newpxeend = $_POST['newpxeend']; $newpxeend = htmlentities($newpxeend);
-
-$oldpxeday = $_POST['oldpxeday'];
-$oldpxebeg = $_POST['oldpxebeg'];
-$oldpxeend = $_POST['oldpxeend'];
-
-$pxeDN = $_POST['pxedn'];
-$oldpxecn = "PXE_".$_POST['oldpxecn'];
-
-$rbs = $_POST['rbs'];
-$filename = $_POST['filename'];
-if (count($filename) != 0){
- foreach (array_keys($filename) as $key){
- $file[$key] = htmlentities($filename[$key]);
- }
-}
-$oldfilename = $_POST['oldfilename'];
-if (count($oldfilename) != 0){
- foreach (array_keys($oldfilename) as $key){
- $oldfile[$key] = htmlentities($oldfilename[$key]);
- }
-}
-$newfilename = $_POST['newfilename']; $newfilename = htmlentities($newfilename);
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-# 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>";
-
-
-$seconds = 2;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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>";
-
-##############################################
-# PXE CN (DN)
-
-if ( $oldpxecn == $pxecn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldpxecn != "" && $pxecn != "" && $oldpxecn != $pxecn ){
- echo "PXE Name aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $exppxe = explode(" ",$pxecn);
- foreach ($exppxe as $word){$expuc[] = ucfirst($word);}
- $pxecn = implode(" ",$expuc);
- $pxecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $pxecn);
-
- $newpxeDN = "cn=".$pxecn.",".$nodeDN;
- print_r($newpxeDN); echo "<br><br>";
-
- if(modify_pxe_dn($pxeDN, $newpxeDN)){
- $mesg = "PXE Name erfolgreich ge&auml;ndert<br><br>";
- $pxeDN = $newpxeDN;
- }else{
- $mesg = "Fehler beim &auml;ndern des PXE Namen!<br><br>";
- }
-
-
- # newsubmenu holen...
- $url = "pxe.php?dn=".$newpxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-if ( $oldpxecn != "" && $pxecn == "" ){
- echo "Gruppenname loeschen!<br>
- Dieses ist Teil des DN, Sie werden das PXE Boot Men&uuml; komplett l&ouml;schen<br><br>";
- echo "Wollen Sie das PXE Boot Men&uuml; <b>".$oldpxecn."</b> wirklich l&ouml;schen?<br><br>
- <form action='pxe_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$pxeDN."'>
- <input type='hidden' name='name' value='".$oldpxecn."'>
- <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;
-}
-
-##########################################
-# Remote Boot Dienst
-
-if ($rbs != "none"){
- $exp = explode(',',$rbs);
- $exprbscn = explode('=',$exp[0]);
- $rbscn = $exprbscn[1];
- $exprbsau = explode('=',$exp[2]);
- $rbsau = $exprbsau[1];
-
- $entryrbs ['rbservicedn'] = $rbs;
- if ($result = ldap_mod_replace($ds,$pxeDN,$entryrbs)){
- $mesg = "Remote Boot Service erfolgreich zu <b>".$rbscn."[Abt.: ".$rbsau."]</b> ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des Remote Boot Services zu <b>".$rbscn."</b>!<br><br>";
- }
-}
-
-
-##########################################
-# bereits vorhandene TimeRange(s) bearbeiten
-
-$entrymodtr = array();
-$modtr = 0;
-# TimeRanges zusammensetzen
-# $t = 0; # Laufvariable für $entrymodtr, da nicht jede Timerange ok sein muss
-for ($i=0; $i<count($pxeday); $i++){
-
-$oldpxetimerange = $oldpxeday[$i]."_".$oldpxebeg[$i]."_".$oldpxeend[$i];
-
-if ( ($pxebeg[$i] <= $pxeend[$i]) && ( ($pxeday[$i] != $oldpxeday[$i] && $pxeday[$i] != "") || ($pxebeg[$i] != $oldpxebeg[$i] && $pxebeg[$i] != "") || ($pxeend[$i] != $oldpxeend[$i] && $pxeend[$i] != "")) ){
-
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($pxeday[$i],$pxebeg[$i],$pxeend[$i])){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$pxeday[$i])){$pxeday[$i] = strtoupper($pxeday[$i]);}
- if (preg_match("/([a-z]+)/",$pxebeg[$i])){$pxebeg[$i] = strtoupper($pxebeg[$i]);}
- if (preg_match("/([a-z]+)/",$pxeend[$i])){$pxeend[$i] = strtoupper($pxeend[$i]);}
-
- # führende Nullen weg
- $pxebeg[$i] = preg_replace ( '/0([0-9])/', '$1', $pxebeg[$i]);
- $pxeend[$i] = preg_replace ( '/0([0-9])/', '$1', $pxeend[$i]);
-
- # TimeRange auf Überschneidung mit vorhandenen checken außer mit eigener alter TR da diese
- # ja geändert werden soll
- if(check_timerange_pxe($pxeday[$i],$pxebeg[$i],$pxeend[$i],$nodeDN,$oldpxetimerange)){
-
- $pxetimerange = $pxeday[$i]."_".$pxebeg[$i]."_".$pxeend[$i];
- $entrymodtr ['timerange'][$i] = $pxetimerange;
- $modtr = 1;
-
- }
- else{
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml;, das sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Bitte geben Sie eine andere Time Range ein.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldpxetimerange;
- }
- }
- else{
- $mesg = "Falsche Syntax in der Timerange-Eingabe!<br>
- Bitte geben Sie die erneut Time Range ein.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldpxetimerange;
- }
-
-}
-
-
-elseif ( $pxeday[$i] == "" || $pxebeg[$i] == "" || $pxeend[$i] == "" || $pxebeg[$i] > $pxeend[$i]){
-
- $mesg = "Sie haben die Time Range <b>Nr.".$i."</b> nicht vollst&auml;ndig angegeben. Diese ist aber ein notwendiges Attribut.<br>
- Diese Time Range wird nicht bearbeitet.<br><br>";
- $entrymodtr ['timerange'][$i] = $oldpxetimerange;
-}
-
-else{$entrymodtr ['timerange'][$i] = $oldpxetimerange;}
-} # Ende for-Schleife für jede Timerange
-# jetzt noch alle gesammelten Änderungen Durchführen ...
-if ($modtr == 1){
- # erst ändern
- echo "&Auml;ndern: "; print_r($entrymodtr); echo "<br>";
- if($result = ldap_mod_replace($ds,$pxeDN,$entrymodtr)){
- $mesg = "TimeRanges erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern der TimeRanges!<br><br>";
- }
-}
-
-
-if ( count($deltr) != 0 && $modtr == 0 ){
- # Time Range löschen
- $j = 0;
- foreach ($deltr as $delrange){
- $entrydeltr ['timerange'][$j] = $delrange;
- $j++;
- }
- # dann löschen
- echo "L&ouml;schen: "; print_r($entrydeltr); echo "<br>";
- if($result = ldap_mod_del($ds,$pxeDN,$entrydeltr)){
- $mesg = "TimeRanges erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen der TimeRanges!<br><br>";
- }
-}elseif(count($deltr) != 0 && $modtr == 1){
- echo "Nur &Auml;ndern (gleichzeitig L&ouml;schen und &Auml;ndern geht nicht)";
-}
-
-#####################################
-# TimeRange hinzufügen
-
-if ( $newpxeday != "" && $newpxebeg != "" && $newpxeend != "" && $newpxebeg <= $newpxeend ){
-
- # TimeRange Syntax checken
- $syntax = new Syntaxcheck;
- if ($syntax->check_timerange_syntax($newpxeday,$newpxebeg,$newpxeend)){
-
- # in Grossbuchstaben
- if (preg_match("/([a-z]+)/",$newpxeday)){$newpxeday = strtoupper($newpxeday);}
- if (preg_match("/([a-z]+)/",$newpxebeg)){$newpxebeg = strtoupper($newpxebeg);}
- if (preg_match("/([a-z]+)/",$newpxeend)){$newpxeend = strtoupper($newpxeend);}
-
- # führende Nullen weg
- $newpxebeg = preg_replace ( '/0([0-9])/', '$1', $newpxebeg);
- $newpxeend = preg_replace ( '/0([0-9])/', '$1', $newpxeend);
-
- # TimeRange auf Ãœberschneidung mit vorhandenen checken
- if(check_timerange_pxe($newpxeday,$newpxebeg,$newpxeend,$nodeDN,"")){
-
- $newpxetimerange = $newpxeday."_".$newpxebeg."_".$newpxeend;
- $entrytr ['timerange'] = $newpxetimerange;
- if($result = ldap_mod_add($ds,$pxeDN,$entrytr)){
- $mesg = "Zus&auml;tzliche TimeRange erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der zus&auml;tzlichen TimeRange!<br><br>";
- }
- }else{
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml;, das sich mit der eingegebenen Time Range
- &uuml;berschneidet!<br>
- Bitte geben Sie eine andere Time Range ein.<br><br>";
- }
- }else{
- $mesg = "Falsche Syntax in der Timerange-Eingabe!<br>
- Bitte geben Sie die erneut Time Range ein.<br><br>";
- }
-}
-
-
-#####################################
-# PXE Filename(s)
-
-$filemod = array();
-$modfi = 0;
-$filedel = array();
-$delfi = 0;
-$j = 0;
-
-if (count($file) != 0){
-
-for ($i=0; $i<count($file); $i++){
-
- if ( $oldfile[$i] == $file[$i] ){
- $filemod ['filename'][$i] = $oldfile[$i];
- # $mesg = "keine Aenderung<br>";
- }
-
- if ( $oldfile[$i] != "" && $file[$i] != "" && $oldfile[$i] != $file[$i] ){
- echo "PXE Dateinamen aendern<br>
- Vorsicht dies kann eine nicht verwendbare PXE Datei zur Folge haben!<br><br>";
- # hier noch Syntaxcheck
- $filemod ['filename'][$i] = $file[$i];
- $modfi = 1;
- }
-
- if ( $oldfile[$i] != "" && $file[$i] == "" ){
- echo "PXE Dateinamen loeschen!<br>
- Achtung: aus ihren PXE Daten wird keine PXE Datei mehr generiert.<br>
- Sie sind solange nicht mehr f&uuml;r den PXE Bootvorgang verwendbar bis Sie einen neuen Dateinamen anlegen!<br><br>";
- $filemod ['filename'][$i] = $oldfile[$i];
- $filedel ['filename'][$j] = $oldfile[$i];
- $j++;
- $delfi = 1;
- $seconds = 4;
- }
-}
-#erst ändern
-if ($modfi == 1){
- echo "&Auml;ndern: "; print_r($filemod); echo "<br>";
- if(ldap_mod_replace($ds,$pxeDN,$filemod)){
- $mesg = "PXE Dateiname(n) erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des(r) PXE Dateinamens!<br><br>";
- }
- $modfi = 0;
-}
-# dann löschen
-if ($delfi == 1){
- echo "L&ouml;schen: "; print_r($filedel); echo "<br>";
- if(ldap_mod_del($ds,$pxeDN,$filedel)){
- $mesg = "PXE Dateiname(n) erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen des PXE Dateinamens !<br><br>";
- }
- $delfi = 0;
-}
-
-}
-
-# PXE Dateiname neu anlegen
-if ($newfilename == ""){
-}
-if ($newfilename != ""){
- echo "PXE Dateiname hinzuf&uuml;gen";
- $fileadd ['filename'] = $newfilename;
- if(ldap_mod_add($ds,$pxeDN,$fileadd)){
- $mesg = "PXE Dateiname <b>".$newfilename."</b> erfolgreich angelegt<br><br>";
- }else{
- $mesg = "Fehler beim anlegen des PXE Dateinamens ".$newfilename." !<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,$pxeDN,$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,$pxeDN,$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,$pxeDN,$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/rbs/pxe_copy.php b/ldap-site-mngmt/webinterface/rbs/pxe_copy.php
deleted file mode 100644
index 92e6ba0b..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe_copy.php
+++ /dev/null
@@ -1,189 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxeDN = $_POST['pxedn'];
-$pxecn = "PXE_".$_POST['pxecncp'];
-$oldpxecn = "PXE_".$_POST['oldpxecncp'];
-
-$deltr = $_POST['deltr'];
-
-$oldpxeday = $_POST['oldpxedaycp']; $oldpxeday = htmlentities($oldpxeday);
-$oldpxebeg = $_POST['oldpxebegcp']; $oldpxebeg = htmlentities($oldpxebeg);
-$oldpxeend = $_POST['oldpxeendcp']; $oldpxeend = htmlentities($oldpxeend);
-
-$nodeDN = $_POST['nodedn'];
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$copytargets = $_POST['copytargets'];
-#print_r($copytargets); echo "<br>";
-$n = array_keys($copytargets,'none');
-#print_r($n); echo "<br>";
-for ($i=0; $i<count($n); $i++){
- $match = array_search('none',$copytargets);
- array_splice($copytargets, $match, 1);
-}
-#print_r($copytargets); echo "<br>";
-
-
-$seconds = 2;
-$url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-
-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 ( $pxecn != ""){
-
- # Formulareingaben anpassen
- $exppxe = explode(" ",$pxecn);
- foreach ($exppxe as $word){$expuc[] = ucfirst($word);}
- $pxecn = implode(" ",$expuc);
- $pxecn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $pxecn);
-
- $nomac = 0;
-
- if (count($copytargets) != 0){
- foreach ($copytargets as $targetDN){
-
- $exptargetdn = ldap_explode_dn($targetDN, 1);
- $targetcn = $exptargetdn[0];
- $targettype = $exptargetdn[1];
-
- # falls Target keine MAC hat dann kann keine PXE angelegt werden
- if ($targettype == "computers"){
- $macdata = get_node_data($targetDN, array("hwaddress"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Ziel-Rechner ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst eine MAC ein!<br><br>";
- }
- }
- if ($targettype == "groups"){
- $members = get_node_data($targetDN, array("member"));
- if (count($members) > 1){
- foreach ($members['member'] as $hostDN){
- $macdata = get_node_data($hostDN, array("hwaddress","hostname"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Gruppen-Rechner <b>".$macdata['hostname']."</b> ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; f&uuml;r die Gruppe wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst bei Rechner <b>".$macdata['hostname']."</b> eine MAC ein!<br><br>";
- }
- }
- }
- if (count($members) == 1){
- $macdata = get_node_data($members['member'], array("hwaddress"));
- if ($macdata['hwaddress'] == ""){
- $nomac = 1;
- echo "F&uuml;r den Gruppen-Rechner <b>".$macdata['hostname']."</b> ist keine MAC Adresse eingetragen <br>
- Das PXE Bootmen&uuml; f&uuml;r die Gruppe wird nicht angelegt. <br>
- <br>
- Tragen Sie zuerst bei Rechner <b>".$macdata['hostname']."</b> eine MAC ein!<br><br>";
- }
- }
- }
-
- $brothers = get_pxeconfigs($targetDN,array("cn"));
- $brother = 0;
- foreach ($brothers as $item){
- if( $item['cn'] == $pxecn ){
- $mesg = "Es existiert bereits ein PXE Boot Men&uuml; mit dem eingegebenen Namen!<br>
- Bitte geben Sie einen anderen Namen ein.<br><br>";
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
- $brother = 1;
- break;
- }
- }
- if ($brother == 0 && $nomac == 0){
-
- $exptargetdn = ldap_explode_dn($targetDN, 1);
- $target = $exptargetdn[0];
- $targettype = $exptargetdn[1];
-
- $oldpxetimerange = $oldpxeday."_".$oldpxebeg."_".$oldpxeend;
- $newpxeDN = "cn=".$pxecn.",".$targetDN;
- print_r($newpxeDN); echo "<br>";
-
- if (dive_into_tree_cp($pxeDN,$newpxeDN)){
-
- $delfileuri = 0;
- # Filename anpassen
- if ($targettype == "rbs"){
- $entrymod ['filename'] = "default";
- }
- if ($targettype == "computers"){
- $macdata = get_node_data($targetDN, array("hwaddress"));
- $entrymod ['filename'] = "01-".$macdata['hwaddress'];
- $delfileuri = 1;
- #$entrymod ['fileuri'] = "01-".$macdata['hwaddress'].".tgz";
- }
- if ($targettype == "groups"){
- $members = get_node_data($targetDN, array("member"));
- if (count($members) != 0){
- foreach ($members['member'] as $hostDN){
- $macdata = get_node_data($hostDN, array("hwaddress"));
- $entrymod ['filename'][] = "01-".$macdata['hwaddress'];
- $delfileuri = 1;
- #$entrymod ['fileuri'] = $target.".tgz";
- }
- }
- }
- if(ldap_mod_replace($ds,$newpxeDN,$entrymod)){
- if($deltr == 1){
- # Timeranges und FileURI im neuen Objekt löschen
- $entrydel ['timerange'] = array();
- if ($delfileuri == 1){
- $entrydel ['fileuri'] = array();
- }
- if ( ldap_mod_del($ds,$newpxeDN,$entrydel) ){
- $mesg .= "<br>PXE Boot Men&uuml; erfolgreich nach ".$target[1]." kopiert<br>";
- }
- else{
- ldap_delete($ds,$newpxeDN);
- $mesg .= "<br>Fehler beim kopieren des PXE Boot Men&uuml;s nach <b>".$target[1]."</b><br>";
- }
- }
- }
- else{
- ldap_delete($ds,$newpxeDN);
- $mesg .= "<br>Fehler beim kopieren des PXE Boot Men&uuml;s nach <b>".$target[1]."</b><br>";
- }
- }
- else{
- $mesg .= "<br>Fehler beim kopieren des PXE Boot Men&uuml;s nach <b>".$target[1]."</b><br>";
- }
- }
- }
- }
- else{
- $mesg .= "<br>Sie haben kein Ziel angegeben!<br>";
- }
-}
-
-elseif ( $pxecn == ""){
-
- $mesg = "Sie haben den Namen des neuen PXE Boot Men&uuml;s nicht angegeben. Dieser ist aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "pxe.php?dn=".$pxeDN."&mnr=".$mnr."&sbmnr=".$sbmnr."&mcnr=".$mcnr;
-}
-
-
-
-$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/rbs/pxe_delete.php b/ldap-site-mngmt/webinterface/rbs/pxe_delete.php
deleted file mode 100644
index a1b7a060..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe_delete.php
+++ /dev/null
@@ -1,42 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$pxeDN = $_POST['dn'];
-$oldpxecn = $_POST['name'];
-
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-$seconds = 1;
-$url = $_POST['successurl'];
-
-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 ( $pxeDN != ""){
-
- if ( dive_into_tree_del($pxeDN,"") ){
- $mesg = "PXE Boot Men&uuml; <b>".$pxecn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen des PXE Boot Men&uuml;s <b>".$pxecn."</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/rbs/pxe_wochenplan.php b/ldap-site-mngmt/webinterface/rbs/pxe_wochenplan.php
deleted file mode 100644
index 7cb4d394..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxe_wochenplan.php
+++ /dev/null
@@ -1,154 +0,0 @@
-<?php
-
-#####################################
-# Wochenübersicht
-
-$template->assign(array("A0" => "","B0" => "","C0" => "","D0" => "","E0" => "","F0" => "","G0" => "",
- "A1" => "","B1" => "","C1" => "","D1" => "","E1" => "","F1" => "","G1" => "",
- "A2" => "","B2" => "","C2" => "","D2" => "","E2" => "","F2" => "","G2" => "",
- "A3" => "","B3" => "","C3" => "","D3" => "","E3" => "","F3" => "","G3" => "",
- "A4" => "","B4" => "","C4" => "","D4" => "","E4" => "","F4" => "","G4" => "",
- "A5" => "","B5" => "","C5" => "","D5" => "","E5" => "","F5" => "","G5" => "",
- "A6" => "","B6" => "","C6" => "","D6" => "","E6" => "","F6" => "","G6" => "",
- "A7" => "","B7" => "","C7" => "","D7" => "","E7" => "","F7" => "","G7" => "",
- "A8" => "","B8" => "","C8" => "","D8" => "","E8" => "","F8" => "","G8" => "",
- "A9" => "","B9" => "","C9" => "","D9" => "","E9" => "","F9" => "","G9" => "",
- "A10" => "","B10" => "","C10" => "","D10" => "","E10" => "","F10" => "","G10" => "",
- "A11" => "","B11" => "","C11" => "","D11" => "","E11" => "","F11" => "","G11" => "",
- "A12" => "","B12" => "","C12" => "","D12" => "","E12" => "","F12" => "","G12" => "",
- "A13" => "","B13" => "","C13" => "","D13" => "","E13" => "","F13" => "","G13" => "",
- "A14" => "","B14" => "","C14" => "","D14" => "","E14" => "","F14" => "","G14" => "",
- "A15" => "","B15" => "","C15" => "","D15" => "","E15" => "","F15" => "","G15" => "",
- "A16" => "","B16" => "","C16" => "","D16" => "","E16" => "","F16" => "","G16" => "",
- "A17" => "","B17" => "","C17" => "","D17" => "","E17" => "","F17" => "","G17" => "",
- "A18" => "","B18" => "","C18" => "","D18" => "","E18" => "","F18" => "","G18" => "",
- "A19" => "","B19" => "","C19" => "","D19" => "","E19" => "","F19" => "","G19" => "",
- "A20" => "","B20" => "","C20" => "","D20" => "","E20" => "","F20" => "","G20" => "",
- "A21" => "","B21" => "","C21" => "","D21" => "","E21" => "","F21" => "","G21" => "",
- "A22" => "","B22" => "","C22" => "","D22" => "","E22" => "","F22" => "","G22" => "",
- "A23" => "","B23" => "","C23" => "","D23" => "","E23" => "","F23" => "","G23" => ""));
-
-#print_r($timeranges); echo "<br>";
-
-# vom spezifischsten zum unspezifischsten :
-# FR_0_7 -> FR_X_X -> X_0_7 -> X_X_X
-$daytime = array();
-$timex = array();
-$dayx = array();
-$allx = array();
-$legend = array();
-if(count($timeranges) != 0){
-foreach ($timeranges as $tr){
- if (count($tr[0]) > 1){
- foreach ($tr as $item){
- if ($item[0] != "X" && $item[1] != "X" && $item[2] != "X" && ($item[0] == "MO" || $item[0] == "DI" || $item[0] == "MI" || $item[0] == "DO" || $item[0] == "FR" || $item[0] == "SA" || $item[0] == "SO")){
- $daytime[] = $item;
- }
- if ($item[0] != "X" && $item[1] == "X" && $item[2] == "X"){
- $timex[] = $item;
- }
- if ($item[0] == "X" && $item[1] != "X" && $item[2] != "X"){
- $dayx[] = $item;
- }
- if ($item[0] == "X" && $item[1] == "X" && $item[2] == "X"){
- $allx[] = $item;
- }
- }
- }else{
- if ($tr[0] != "X" && $tr[1] != "X" && $tr[2] != "X" && ($tr[0] == "MO" || $tr[0] == "DI" || $tr[0] == "MI" || $tr[0] == "DO" || $tr[0] == "FR" || $tr[0] == "SA" || $tr[0] == "SO")){
- $daytime[] = $tr;
- }
- if ($tr[0] != "X" && $tr[1] == "X" && $tr[2] == "X"){
- $timex[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] != "X" && $tr[2] != "X"){
- $dayx[] = $tr;
- }
- if ($tr[0] == "X" && $tr[1] == "X" && $tr[2] == "X"){
- $allx[] = $tr;
- }
- }
-}
-
-#print_r($daytime); echo "<br>";
-#print_r($timex); echo "<br>";
-#print_r($dayx); echo "<br>";
-#print_r($allx); echo "<br>";
-
-$daycode = array("MO" => "A", "DI" => "B", "MI" => "C", "DO" => "D", "FR" => "E", "SA" => "F", "SO" => "G");
-$allxcolors = array("#BEBEBE","A0A0A0","#696969","#EEDFCC","#D8BFD8","#505050");
-$dayxcolors = array("#483D8B","#7B68EE","#191970","#8470FF","#708090","#6A5ACD");
-$timexcolors = array("#CDC673","#A2CD5A","#BDB76B","#8B864E","#6B8E23","#CDBE70");
-$daytimecolors = array("880000","#CD6839","#CC3300","#CC6600","#993300","#8B4C39");
-
-
-if (count($allx) != 0){
- $c = 0;
- foreach ($allx as $range){
- foreach ($daycode as $dc){
- for ($i = 0; $i <= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$allxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$allxcolors[$c]);
- $c++;
- }
-}
-
-if (count($dayx) != 0){
- $c = 0;
- foreach ($dayx as $range){
- foreach ($daycode as $dc){
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$dayxcolors[$c].";"));
- }
- }
- $legend[] = array($range ,$dayxcolors[$c]);
- $c++;
- }
-}
-
-if (count($timex) != 0){
- $c = 0;
- foreach ($timex as $range){
- $dc = $daycode[$range[0]];
- for ($i = 0; $i<= 23; $i++){
- $template->assign(array($dc.$i => "background-color:".$timexcolors[$c].";"));
- }
- $legend[] = array($range ,$timexcolors[$c]);
- $c++;
- }
-}
-
-if (count($daytime) != 0){
- $c = 0;
- foreach ($daytime as $range){
- $dc = $daycode[$range[0]];
- for ($i = $range[1]; $i<= $range[2]; $i++){
- $template->assign(array($dc.$i => "background-color:".$daytimecolors[$c].";"));
- }
- $legend[] = array($range ,$daytimecolors[$c]);
- $c++;
- }
-}
-
-}
-
-$template->assign(array("DESCRIPTION" => ""));
-#print_r($legend);
-if (count($legend) != 0){
- $template->define_dynamic("Legende", "Webseite");
- foreach ($legend as $item){
- # Timerange Komponente
- $color = $item[1];
- $template->assign(array("TR1" => $item[0][0],
- "TR2" => $item[0][1],
- "TR3" => $item[0][2],
- "CN" => $item[0][3],
- "COLOR" => $color));
- $template->parse("LEGENDE_LIST", ".Legende");
- }
-}
-
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/pxeconfig_default.dwt b/ldap-site-mngmt/webinterface/rbs/pxeconfig_default.dwt
deleted file mode 100644
index bb630723..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxeconfig_default.dwt
+++ /dev/null
@@ -1,323 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Default PXE Boot Men&uuml;s &nbsp;<code class='font_object'> {AU} </code> </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='40%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>PXE Boot Men&uuml;</b></td>
- <td width='60%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>G&uuml;ltigkeitsdauer (Time Range)</b></td>
- </tr>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Pxeconf -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{PXECN} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{TRANGES} &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Pxeconf -->
-
- </table></td>
- </tr>
- <tr>
- <td height='50'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Wochen &Uuml;bersicht:</h4></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr><td>
- <table cellpadding='0' cellspacing='0' border='1' align='left' width='90%' style='border-width: 0 0 0 0;'>
- <tr align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 2 0 2 2;'><b>Uhrzeit</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Montag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Dienstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Mittwoch</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Donnerstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Freitag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 0 2 1;'><b>Samstag</b></td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 2 2 2 1;'><b>Sonntag</b></td>
- </tr>
- <tr heigth='2' align='center'>
- <td width='9%' style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>0</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F0}'>&nbsp;</td>
- <td width='13%' style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G0}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F1}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G1}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>2</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F2}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G2}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F3}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G3}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>4</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F4}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G4}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F5}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G5}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>6</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F6}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G6}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F7}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G7}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>8</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F8}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G8}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F9}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G9}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>10</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F10}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G10}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F11}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G11}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>12</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F12}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G12}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F13}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G13}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>14</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F14}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G14}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F15}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G15}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>16</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F16}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G16}'>&nbsp;&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F17}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G17}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>18</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F18}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G18}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F19}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G19}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>20</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F20}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G20}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{A21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{B21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{C21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{D21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{E21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 1;{F21}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 0 1;{G21}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 2;'>22</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{A22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{B22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{C22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{D22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{E22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 0 0 1;{F22}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 2 0 1;{G22}'>&nbsp;</td>
- </tr>
- <tr heigth='2' align='center'>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 2;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{A23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{B23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{C23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{D23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{E23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 2 1;{F23}'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 2 2 1;{G23}'>&nbsp;</td>
- </tr>
-
- </table></td>
- </tr>
-
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>Legende:</h4></td>
- </tr>
- <tr><td>
- <table cellpadding='3' cellspacing='3' border='1' align='left' width='50%' style='border-width: 0 0 0 0;'>
- <tr>
- <td width='65%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>PXE Boot Men&uuml;</b></td>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td width='30%' style='border-color: black; border-style: solid; border-width: 0 0 0 0;'><b>Farbe</b></td>
- </tr>
-
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>Keine PXE Definition &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>&nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;'>&nbsp;</td>
- </tr>
-
- <!-- BEGIN DYNAMIC BLOCK: Legende -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'>{CN} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 0 0;'> &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 1 1 1 1;background-color:{COLOR};'>&nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Legende -->
-
- </table></td>
- </tr>
-
-</table>
diff --git a/ldap-site-mngmt/webinterface/rbs/pxeconfig_default.php b/ldap-site-mngmt/webinterface/rbs/pxeconfig_default.php
deleted file mode 100644
index b6d495d9..00000000
--- a/ldap-site-mngmt/webinterface/rbs/pxeconfig_default.php
+++ /dev/null
@@ -1,77 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "pxeconfig_default.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-$mcnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$rbsDN = $_GET['rbsdn'];
-
-$template->assign(array("PXEDN" => "",
- "PXECN" => "Noch kein Default PXE Boot Men&uuml; angelegt",
- "TRANGES" => "",
- "RBS" => "",
- "CN" => ""));
-
-$pxe_array = get_pxeconfigs($rbsDN,array("dn","cn","timerange","rbservicedn"));
-# print_r($pxe_array);
-
-$template->define_dynamic("Pxeconf", "Webseite");
-
-for ($i=0; $i<count($pxe_array); $i++){
- # Timerange Komponenten
- $trange = "";
- if (count($pxe_array[$i]['timerange']) > 1 ){
- foreach ($pxe_array[$i]['timerange'] as $tr){
- $exptime = array_merge(explode('_',$tr),$pxe_array[$i]['cn']);
- $timeranges[$i][] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59 / ";
- }
- }else{
- $exptime = array_merge(explode('_',$pxe_array[$i]['timerange']), array($pxe_array[$i]['cn']));
- $timeranges[$i] = $exptime; # Für grafische Wo-Ansicht
- if ($exptime[0] == "X"){$exptime[0]="t&auml;glich";}
- # if ($exptime[1] == "X" && $exptime[2] == "X"){$exptime[1] = ""; $exptime[2]= "";}
- $trange .= $exptime[0].", von ".$exptime[1].":00 bis ".$exptime[2].":59";
- }
-
- $pxename = "<a href='pxe.php?dn=".$pxe_array[$i]['dn']."&mnr=".$mnr."&sbmnr=".$sbmnr."' class='headerlink'>".$pxe_array[$i]['cn']."</a>";
-
-
- $template->assign(array("PXEDN" => $pxe_array[$i]['dn'],
- "PXECN" => $pxename,
- "TRANGES" => $trange,
- "RBS" => $rbsDN,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr,
- "AUDN" => $auDN));
- $template->parse("PXECONF_LIST", ".Pxeconf");
-}
-
-include("pxe_wochenplan.php");
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/rbs/rbs.dwt b/ldap-site-mngmt/webinterface/rbs/rbs.dwt
deleted file mode 100644
index 31f62a70..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbs.dwt
+++ /dev/null
@@ -1,76 +0,0 @@
-<html>
-
-<head>
- <title>{SEITENTITEL}</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'></head>
-<body>
-
-<table cellpadding='0' cellspacing='0' border='0' width='100%' style='background-color: #F0F0F0;border-color: #505050; border-style: solid; border-width: 0 0 1 0;'>
- <tr>
- <td width='30%'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr valign='top'>
- <td width='1'></td>
- <td><h2>Client / IP Management</h2></td>
- </tr>
- </table>
- </td>
-
- <td width='45%'>
- <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>
- <tr>
- <td colspan='3'>{MAINMENU}</td>
- </tr>
-</table>
-
-<!--<hr align='center' width='98%' noshade>-->
-<br>
-
-
-<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/rbs/rbs.php b/ldap-site-mngmt/webinterface/rbs/rbs.php
deleted file mode 100644
index ce1553e2..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbs.php
+++ /dev/null
@@ -1,25 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "rbs_start.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = -1;
-$sbmnr = -1;
-
-$mnr = $_GET['mnr'];
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/rbs_footer.inc.php b/ldap-site-mngmt/webinterface/rbs/rbs_footer.inc.php
deleted file mode 100644
index 311721c5..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbs_footer.inc.php
+++ /dev/null
@@ -1,18 +0,0 @@
-<?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/rbs/rbs_header.inc.php b/ldap-site-mngmt/webinterface/rbs/rbs_header.inc.php
deleted file mode 100644
index b663a2e4..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbs_header.inc.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?php
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "Remote Boot Service Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 3;
-
-
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$definedTemplates = array("Vorlage" => "rbs.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));
-
-
-include("rbs_menu.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/rbs_menu.php b/ldap-site-mngmt/webinterface/rbs/rbs_menu.php
deleted file mode 100644
index 63b3fa52..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbs_menu.php
+++ /dev/null
@@ -1,194 +0,0 @@
-<?php
-
-function createRBSMenu($rollen, $mnr, $auDN, $sbmnr) {
- global $template;
- global $START_PATH;
-
- # rbservices (momentan nur für einen RBS konzipiert)
- $rbs_array = get_rbservices($auDN,array("dn","cn"));
-
- # Struktur der Registerkartenleiste
- $hauptmenu = array(array("link" => "rbs.php?mnr=0",
- "text" => "&Uuml;bersicht",
- "zugriff" => "alle"));
- $submenu = array(array());
-
- $n = 1;
- if (count($rbs_array) != 0){
- for ($i=0;$i<count($rbs_array);$i++){
-
- $hauptmenu [] = array("link" => "rbservice.php?rbsdn=".$rbs_array[$i]['dn']."&mnr=".$n,
- "text" => $rbs_array[$i]['cn'],
- "zugriff" => array("MainAdmin","RbsAdmin"));
- $submenu [] = array(
- array("link" => "gbm_overview.php?rbsdn=".$rbs_array[$i]['dn']."&mnr=".$n."&sbmnr=0",
- "text" => "Generische Bootmen&uuml;s",
- "zugriff" => array("MainAdmin","RbsAdmin")),
- array("link" => "pxeconfig_default.php?rbsdn=".$rbs_array[$i]['dn']."&mnr=".$n."&sbmnr=1",
- "text" => "Default PXE Configs",
- "zugriff" => array("MainAdmin","RbsAdmin")),
- array("link" => "new_gbm.php?rbsdn=".$rbs_array[$i]['dn']."&mnr=".$n."&sbmnr=2",
- "text" => "Neues GBM anlegen",
- "zugriff" => array("MainAdmin","RbsAdmin")),
- array("link" => "new_pxe.php?rbsdn=".$rbs_array[$i]['dn']."&mnr=".$n."&sbmnr=3",
- "text" => "Neue PXE Config anlegen",
- "zugriff" => array("MainAdmin","RbsAdmin")),
- );
- $n++;
- }
- }
- $hauptmenu [] = array("link" => "new_rbservice.php?&mnr=".$n,
- "text" => "Neuen RBS anlegen",
- "zugriff" => array("MainAdmin","RbsAdmin"));
-
- $submenu [] = array();
- #print_r($hauptmenu); echo "<br><br>";
- #print_r($submenu);
-
-
- # 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");
- }
- 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/rbs/rbs_start.dwt b/ldap-site-mngmt/webinterface/rbs/rbs_start.dwt
deleted file mode 100644
index 3436b4ee..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbs_start.dwt
+++ /dev/null
@@ -1,41 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - Remote Boot Services (PXE) Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung ihres <b>Remote Boot Services (RBS)</b><br>
- Benutzen Sie die Navigation links, um die einzelnen Verwaltungsbereiche anzusteuern:</p>
- <ul>
- <li><p><b>Remote Boot Service</b></p>
- Allgemeine Einstellungen Ihres Remote Boot Service.<br>
- Falls Sie noch keinen RBS angelegt haben, k&ouml;nnen Sie dies hier tun. <br>
- Daneben k&ouml;nnen Sie hier ihr RBS Bootserver-System (TFTP-, NFS-, NBD-Server) verwalten.
- </li>
- <li><p><b>Generische Boot Men&uuml;s</b></p>
- Generische Boot Menues die Sie Nutzern ihres RBS anbieten wollen.<br>
- Hier verwalten Sie Generische Boot Menues (GBM) oder legen neue an.<br><br>
- GBMs enthalten alle Komponenten eines PXE Bootmen&uuml;s, welche
- auf ihrem Bootserver-System gespeichert und von Ihnen verwaltet werden, d.h.
- Kernel-Images, Initial-Ramdisks (initrd), usw. Diese sind unabh&auml;ngig
- von den PXE-Parametern, die das eigentliche Aussehen eines PXE Bootmen&uuml;s bestimmen,
- wie z.B. Menu-Zeilen, oder PXE Parametern welche zur Bootclient Konfiguration verwendet
- werden.<br>
- Nutzer ihres RBS k&ouml;nnen aus diesen GBMs dann ihre individuellen PXE Boot
- Men&uuml;s zusammenstellen.
-
- </li>
- <li><p><b>Default PXE</b></p>
- Default PXE Boot Konfigurationen, fuer die bootende Rechner ohne spezifische
- PXEs.<br>
- Hier k&ouml;nnen Sie Default PXEs anlegen und verwalten.
- </li>
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/rbservice.dwt b/ldap-site-mngmt/webinterface/rbs/rbservice.dwt
deleted file mode 100644
index e738d990..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbservice.dwt
+++ /dev/null
@@ -1,228 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>Remote Boot Service &nbsp;<code class='font_object'> {RBSCN} </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='rbservice_change.php' method='post'>
-
- <tr>
- <td width='40%' class='tab_h'><b>Attribut</b></td>
- <td width='60%' class='tab_h'><b>Wert</b></td>
- </tr>
-
- <tr height='50'>
- <td class='tab_d'><b>Eindeutiger RBS Name (cn):</b><br>(Teil des dn, ohne Leerzeichen eingeben) &nbsp;</td>
- <td class='tab_d'>
- <font size='+2'><b>RBS_</b></font><input type='Text' name='rbscn' value='{RBSCN}' size='40' class='medium_form_field'>
- <input type='hidden' name='oldrbscn' value='{RBSCN}'> &nbsp;
- </td>
- </tr>
- <tr>
- <td class='tab_d_ohne'><b>Dienst kann momentan genutzt werden von:</b><br></td>
- <td class='tab_d_ohne'>Abteilung<b> {RBSOFFERNOW}</b> &nbsp;(und allen Unterabteilungen)
- </td>
- </tr>
- <tr height='50' valign='top'>
- <td class='tab_d'><b>&Auml;ndern:</b><br>(W&auml;hlen Sie eine andere Abteilung)</td>
- <td class='tab_d'>
- <select name='rbsoffer' size='5' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Rbsoffers -->
- <option value='{RBSOFFER}'>{RBSOFFEROU}</option>
- <!-- END DYNAMIC BLOCK: Rbsoffers -->
-
- <option value='off'>------ NIEMAND ------</option>
-
- </select>
- <input type='hidden' name='oldrbsoffer' value='{RBSOFFERNOWDN}'> &nbsp;
- </td>
- </tr>
-
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>TFTP Boot Server:</h4></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='15%' class='tab_h'>&nbsp;</td>
- <td width='35%' class='tab_h'>&nbsp;</td>
- <td colspan='2' class='tab_h'>&nbsp;</td>
- </tr>
-
- <tr valign='top'>
- <td class='tab_d_ohne'><b>TFTP Server: &nbsp;</td>
- <td class='tab_d_ohne'>
- <!--<input type='Text' name='tftpserverip' value='{TFTPIP}' size='15' class='medium_form_field'>-->
- <input type='hidden' name='oldtftpserverip' value='{TFTPIP}'><font size='+1'>Hostname: <b>{TFTP}</b> &nbsp;[IP: <b>{TFTPIP}</b>]</font></td>
- <td width='15%' class='tab_d_ohne'>TFTP Root</td>
- <td width='30%' class='tab_d_ohne'>
- <input type='Text' name='attribs[tftproot]' value='{TFTPROOT}' size='20' class='medium_form_field'>
- <input type='hidden' name='oldattribs[tftproot]' value='{TFTPROOT}'></td>
- </tr>
- <tr valign='top'>
- <td class='tab_d_ohne'>&auml;ndern:</td>
- <td rowspan='2' class='tab_d_ohne'>
- <select name='tftpserver' size='6' class='tftp_form_selectbox'>
- <option selected value='none'>----------------------------</option>
- <!-- BEGIN DYNAMIC BLOCK: TftpHosts -->
- <option value='{HDN}'>{HN} &nbsp;[IP: {IP}]</option>
- <!-- END DYNAMIC BLOCK: TftpHosts -->
- </select></td>
- <td class='tab_d_ohne'>PXE Path</td>
- <td class='tab_d_ohne'>{TFTPROOT}/
- <input type='Text' name='attribs[tftppxepath]' value='{TFTPPXE}' size='20' class='medium_form_field'>
- <input type='hidden' name='oldattribs[tftppxepath]' value='{TFTPPXE}'></td>
- </tr>
- <tr valign='top'>
- <td class='tab_d_ohne'>&nbsp;</td>
- <td class='tab_d_ohne'>Kernel Path</td>
- <td class='tab_d_ohne'>{TFTPROOT}/
- <input type='Text' name='attribs[tftpkernelpath]' value='{TFTPKERNEL}' size='20' class='medium_form_field'>
- <input type='hidden' name='oldattribs[tftpkernelpath]' value='{TFTPKERNEL}'></td>
- </tr>
- <tr valign='top'>
- <td class='tab_d'>Initial Boot File</td>
- <td class='tab_d'>
- <input type='Text' name='initbootfile' value='{INITBOOTFILE}' size='25' class='medium_form_field'>
- <input type='hidden' name='oldinitbootfile' value='{INITBOOTFILE}'></td>
- <td class='tab_d'>Clientconf Path</td>
- <td class='tab_d'>{TFTPROOT}/
- <input type='Text' name='attribs[tftpclientconfpath]' value='{TFTPCLIENTCONF}' size='20' class='medium_form_field'>
- <input type='hidden' name='oldattribs[tftpclientconfpath]' value='{TFTPCLIENTCONF}'></td>
- <input type='hidden' name='oldtftpserverdn' value='{TFTPDN}'>
- </tr>
- </table></td>
- </tr>
- <tr>
- <td height='40'></td>
- </tr>
- <tr>
- <td colspan='2'><h4>File Server URIs:</h4>
- Diese sind in Generischen Boot Images als RootFS verwendbar.</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='20%' class='tab_h'>&nbsp;</td>
- <td width='15%' class='tab_h'>&nbsp;</td>
- <td width='25%' class='tab_h'>&nbsp;</td>
- <td width='40%' class='tab_h'>&nbsp;</td>
- </tr>
-
- <tr valign='top'>
- <td class='tab_d'><b>Vorhandene URIs zu Root-Filesystemen: </b><br>(Zum L&ouml;schen einer URI H&auml;kchen setzen)</td>
- <td colspan='2' class='tab_d'>
- <!-- BEGIN DYNAMIC BLOCK: Fsuris -->
- <input type='checkbox' name='delfsuri[]' value='{FSURI}' size='10' class='medium_form_field'> &nbsp;&nbsp; <b>{FSURI}</b><br>
- <!-- END DYNAMIC BLOCK: Fsuris -->
- <td class='tab_d'>&nbsp;</td>
- </tr>
- <tr valign='top'>
- <td class='tab_d_ohne'><b>Neue URI anlegen</b></td>
- <td class='tab_d_ohne'>Filesystemtyp</td>
- <td class='tab_d_ohne'>Fileserver IP</td>
- <td class='tab_d_ohne'>NFS Export-Root bzw. (D)NBD &lt;:Port[/Filesystem]&gt;</td>
- </tr>
- <tr valign='top'>
- <td class='tab_d'>&nbsp;</td>
- <td class='tab_d'>
- <select name='addfsuri[]' size='5' class='tiny_form_selectbox'>
- <option selected value='nfs'>nfs://</option>
- <option value='nbd'>nbd://</option>
- <option value='dnbd'>dnbd://</option>
- <option value='dnbd2'>dnbd2://</option>
- <option value='afs'>afs://</option>
- </select> </td>
- <td class='tab_d'><input type='Text' name='addfsuri[]' value='' size='15' class='medium_form_field'></td>
- <td class='tab_d'><input type='Text' name='addfsuri[]' value='' size='25' class='medium_form_field'></td>
- </tr>
-
- <input type='hidden' name='rbsdn' value='{RBSDN}'>
- <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='50'></td>
- </tr>
- <tr>
- <td colspan='2'><h3>Config File f&uuml;r PXE Generator Script</h3></td>
- </tr>
- <tr>
- <td colspan='2'>Speichern Sie dieses als <b>pxegen.conf.pl</b> im gleichen Verzeichnis wie ihr PXE Generator Skript <b>pxe_generator.pl</b></td>
- </tr>
- <tr>
- <td>
- <table cellpadding='20' cellspacing='0' border='0' align='left' width='80%' style='border-color: black; border-style: solid; border-width: 2 2 2 2;'>
-
- <tr>
- <td class='tab_d_ohne'>
- $ldaphost= "{PXEGENLDAP}"; <br>
- $basedn= "{PXEGENBASE}"; <br>
- $userdn= "{PXEGENUDN}"; <br>
- $passwd= "{PXEGENPW}"; <br>
- $rbsdn= "{PXEGENRBS}";
- </td>
- </tr>
-
-
- </table></td>
- </tr>
-
-
-
- <tr>
- <td height='60'></td>
- </tr>
-
- <tr>
- <td colspan='2'><h4>Remote Boot Service &nbsp;<code class='font_object'>{RBSCN}</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 class='tab_d_ohne'>
- Der Remote Boot Dienst wird komplett gel&ouml;scht, <br>
- d.h. inklusive aller angelegten Generischen PXE Bootmen&uuml;s und Default PXEs.
- </tr>
-
- <input type='hidden' name='dn' value='{RBSDN}'>
- <input type='hidden' name='name' value='{RBSCN}'>
- <input type='hidden' name='type' value='rbs'>
- <input type='hidden' name='delurl' value='rbservice_delete.php'>
- <input type='hidden' name='backurl' value='rbservice.php?dn={RBSDN}&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/rbs/rbservice.php b/ldap-site-mngmt/webinterface/rbs/rbservice.php
deleted file mode 100644
index e3df1efb..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbservice.php
+++ /dev/null
@@ -1,152 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "rbservice.dwt";
-
-include('rbs_header.inc.php');
-
-###################################################################################
-
-$mnr = 0;
-$sbmnr = -1;
-
-$mnr = $_GET['mnr'];
-
-# Menuleisten erstellen
-createMainMenu($rollen, $mainnr);
-createRBSMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-$rbsDN = $_GET['rbsdn'];
-
-$template->assign(array("RBSDN" => "",
- "CN" => "",
- "TFTP" => "",
- "TFTPIP" => "",
- "TFTPROOT" => "",
- "INITBOOTFILE" => "",
- "TFTPKERNEL" => "",
- "TFTPPXE" => "",
- "TFTPCLIENTCONF" => "",
- "FSURI" => "",
- "NFS" => "",
- "NFSIP" => "",
- "NFSPATH" => "",
- "NBD" => "",
- "NBDIP" => "",
- "RBSOFFERNOWDN" => "",
- "RBSOFFERNOW" => "",
- "HDN" => "",
- "HN" => "",
- "IP" => ""));
-
-# RBS Daten
-$attributes = array("dn","cn","rbsofferdn","tftpserverip","tftproot","tftpkernelpath","tftpclientconfpath",
- "tftppxepath","nfsserverip","exportpath","nbdserverip","initbootfile","fileserveruri");
-$rbs_data = get_node_data($rbsDN, $attributes);
-
-# RBS Anbieten
-# momentanes Offer
-$offerexp = ldap_explode_dn($rbs_data['rbsofferdn'], 1);
-$rbsoffernow = $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++){
- $rbsoffers[$i]['ou'] = $expou[$i];
- $rbsoffers[$i]['dn'] = implode(',',$expdn);
- $expdn = array_slice($expdn, 1);
-}
-#print_r($rbsoffers);
-
-$expcn = explode('_',$rbs_data['cn']);
-$name = array_slice($expcn,1);
-$rbscn = implode('_',$name);
-
-# Server Hostnamen holen
-$tftpserver = get_hostname_from_ip($rbs_data['tftpserverip']);
-#print_r($tftpserver);
-
-$template->assign(array("RBSDN" => $rbs_data['dn'],
- "RBSCN" => $rbscn,
- "TFTP" => $tftpserver['hostname'],
- "TFTPDN" => $tftpserver['dn'],
- "TFTPIP" => $rbs_data['tftpserverip'],
- "TFTPROOT" => $rbs_data['tftproot'],
- "INITBOOTFILE" => $rbs_data['initbootfile'],
- "TFTPKERNEL" => $rbs_data['tftpkernelpath'],
- "TFTPPXE" => $rbs_data['tftppxepath'],
- "TFTPCLIENTCONF" => $rbs_data['tftpclientconfpath'],
- "NFS" => $nfsserver['hostname'],
- "NFSDN" => $nfsserver['dn'],
- "NFSIP" => $rbs_data['nfsserverip'],
- "NFSPATH" => $rbs_data['exportpath'],
- "NBD" => $nbdserver['hostname'],
- "NBDDN" => $nbdserver['dn'],
- "NBDIP" => $rbs_data['nbdserverip'],
- "RBSOFFERNOWDN" => $rbs_data['rbsofferdn'],
- "RBSOFFERNOW" => $rbsoffernow,
- "MNR" => $mnr,
- "SBMNR" => $sbmnr));
-
-# RBS Offers
-$template->define_dynamic("Rbsoffers", "Webseite");
-foreach ($rbsoffers as $offer){
- $template->assign(array("RBSOFFER" => $offer['dn'],
- "RBSOFFEROU" => $offer['ou'],));
- $template->parse("RBSOFFERS_LIST", ".Rbsoffers");
-}
-
-
-# Fileserver URIs
-$template->define_dynamic("Fsuris", "Webseite");
-if ( count($rbs_data['fileserveruri']) > 1 ){
- foreach ($rbs_data['fileserveruri'] as $fsuri){
- $template->assign(array("FSURI" => $fsuri));
- $template->parse("FSURIS_LIST", ".Fsuris");
- }
-}else{
- $template->assign(array("FSURI" => $rbs_data['fileserveruri']));
- $template->parse("FSURIS_LIST", ".Fsuris");
-}
-
-### Rechner
-$hostorgroup = $exp[0];
-$hosts_array = get_hosts($auDN,array("dn","hostname","ipaddress"));
-
-$template->define_dynamic("TftpHosts", "Webseite");
-foreach ($hosts_array as $item){
- if ($item['ipaddress'] != "" && $item['hostname'] != $tftpserver['hostname']){
- $hostip = explode("_",$item['ipaddress']);
- $template->assign(array("HDN" => $item['dn'],
- "HN" => $item['hostname'],
- "IP" => $hostip[0]));
- $template->parse("TFTPHOSTS_LIST", ".TftpHosts");
- }
-}
-
-################################################
-# PXE Generator Skript Config
-$pxegen_ldap = LDAP_HOST;
-$pxegen_base = "ou=RIPM,".$suffix;
-$pxegen_udn = $userDN;
-$pxegen_pw = $userPassword;
-$pxegen_rbsdn = $rbsDN;
-$template->assign(array("PXEGENLDAP" => $pxegen_ldap,
- "PXEGENBASE" => $pxegen_base,
- "PXEGENUDN" => $pxegen_udn,
- "PXEGENPW" => $pxegen_pw,
- "PXEGENRBS" => $pxegen_rbsdn));
-
-
-###################################################################################
-
-include("rbs_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/rbs/rbservice_add.php b/ldap-site-mngmt/webinterface/rbs/rbservice_add.php
deleted file mode 100644
index 8c47a076..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbservice_add.php
+++ /dev/null
@@ -1,141 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-$syntax = new Syntaxcheck;
-
-$rbscn = $_POST['rbscn']; $rbscn = htmlentities($rbscn);
-
-$nodeDN = "cn=rbs,".$auDN;
-
-$rbsoffer = $_POST['rbsoffer'];
-
-$tftpserverip = $_POST['tftpserverip'];
-$nfsserverip = $_POST['nfsserverip'];
-$nbdserverip = $_POST['nbdserverip'];
-
-$tftpserver = $_POST['tftpserver'];
-$nfsserver = $_POST['nfsserver'];
-$nbdserver = $_POST['nbdserver'];
-
-$host_array = get_hosts($auDN,array("dn","hostname","ipaddress"));
-
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-# sosntige 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>";
-
-
-$get_rbscn = str_replace ( " ", "_", $rbscn );
-$seconds = 300;
-$url = "new_rbservice.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 ( $rbscn != "" && $rbscn != "Hier_RBS_NAME_eintragen" ){
-
- $rbscn = "RBS_".$rbscn;
-
- # Formulareingaben anpassen
- $exprbs = explode(" ",$rbscn);
- foreach ($exprbs as $word){$expuc[] = ucfirst($word);}
- $rbscn = implode(" ",$expuc);
- $rbscn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $rbscn);
-
- $rbsDN = "cn=".$rbscn.",".$nodeDN;
- print_r($rbsDN); echo "<br><br>";
-
- # Server_array zusammenstellen
- $server = array();
- # TFTP Server
- if ($tftpserverip != ""){
- if ($syntax->check_ip_syntax($tftpserverip)){
- $tftpserverip = htmlentities($tftpserverip);
- $mesg .= "Suche nach dem Rechner mit IP ".$tftpserverip." :<br>";
- foreach ($host_array as $host){
- $hostipexp = explode('_',$host['ipaddress']);
- $hostip = $hostipexp[0];
- if ($tftpserverip == $hostip){
- $server ['tftp'] = $tftpserverip;
- break;
- }else{
- $mesg .= "Rechner ".$host['hostname'].": keine &Uuml;bereinstimmung mit eingegebener IP ".$tftpserverip."!<br>";
- }
- }
- }else{$mesg .= "Falsche IP Syntax!<br>";}
- }
- # NFS Server
- if ( $nfsserverip != "" ){
- if ($syntax->check_ip_syntax($nfsserverip)){
- $nfsserverip = htmlentities($nfsserverip);
- $mesg .= "Suche nach dem Rechner mit IP ".$nfsserverip." :<br>";
- foreach ($host_array as $host){
- $hostipexp = explode('_',$host['ipaddress']);
- $hostip = $hostipexp[0];
- if ($nfsserverip == $hostip){
- $server ['nfs'] = $nfsserverip;
- break;
- }else{
- $mesg .= "Rechner ".$host['hostname'].": keine &Uuml;bereinstimmung mit eingegebener IP ".$nfsserverip."!<br>";
- }
- }
- }else{$mesg .= "Falsche IP Syntax!<br>";}
- }
- # NBD Server
- if ( $nbdserverip != "" ){
- if ($syntax->check_ip_syntax($nbdserverip)){
- $nbdserverip = htmlentities($nbdserverip);
- $mesg .= "Suche nach dem Rechner mit IP ".$nbdserverip." :<br>";
- foreach ($host_array as $host){
- $hostipexp = explode('_',$host['ipaddress']);
- $hostip = $hostipexp[0];
- if ($nbdserverip == $hostip){
- $server ['nbd'] = $nbdserverip;
- break;
- }else{
- $mesg .= "Rechner ".$host['hostname'].": keine &Uuml;bereinstimmung mit eingegebener IP ".$nbdserverip."!<br>";
- }
- }
- }else{$mesg .= "Falsche IP Syntax!<br>";}
- }
- echo "Server Array: ";print_r($server); echo "<br>";
-
- if (add_rbs($rbsDN,$rbscn,$rbsoffer,$server,$atts)){
- $mesg .= "<br>Remote Boot Service erfolgreich angelegt<br>";
- $url = "rbservice.php?mnr=1";
- }else{
- $mesg .= "<br>Fehler beim anlegen des Remote Boot Services!<br>";
- }
-}
-
-elseif ( $rbscn == "" || $rbscn == "Hier_RBS_NAME_eintragen" ){
-
- $mesg = "Sie haben den Namen des neuen Remote Boot Service nicht angegeben. Dieser ist
- aber ein notwendiges Attribut.<br>
- Bitte geben Sie ihn an.<br><br>";
- $url = "new_rbservice.php?rbscn=Hier_RBS_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/rbs/rbservice_change.php b/ldap-site-mngmt/webinterface/rbs/rbservice_change.php
deleted file mode 100644
index b39478ba..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbservice_change.php
+++ /dev/null
@@ -1,394 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-$syntax = new Syntaxcheck;
-
-$rbscn = "RBS_".$_POST['rbscn'];
-$oldrbscn = "RBS_".$_POST['oldrbscn'];
-$rbsoffer = $_POST['rbsoffer'];
-$oldrbsoffer = $_POST['oldrbsoffer'];
-
-$tftpserverip = $_POST['tftpserverip'];
-$oldtftpserverip = $_POST['oldtftpserverip'];
-#$nfsserverip = $_POST['nfsserverip'];
-#$oldnfsserverip = $_POST['oldnfsserverip'];
-#$nbdserverip = $_POST['nbdserverip'];
-#$oldnbdserverip = $_POST['oldnbdserverip'];
-
-$tftpserver = $_POST['tftpserver'];
-#$nfsserver = $_POST['nfsserver'];
-#$nbdserver = $_POST['nbdserver'];
-$oldtftpserverdn = $_POST['oldtftpserverdn'];
-#$oldnfsserverdn = $_POST['oldnfsserverdn'];
-#$oldnbdserverdn = $_POST['oldnbdserverdn'];
-
-$initbootfile = $_POST['initbootfile'];
-$oldinitbootfile = $_POST['oldinitbootfile'];
-
-$delfsuri = $_POST['delfsuri'];
-$addfsuri = $_POST['addfsuri'];
-$fstype = $_POST['fstype'];
-$fsip = $_POST['fsip'];
-$fspath = $_POST['fspath'];
-
-$host_array = get_hosts($auDN,array("dn","hostname","ipaddress"));
-
-$rbsDN = $_POST['rbsdn'];
-$nodeDN = "cn=rbs,".$auDN;
-
-$mnr = $_POST['mnr'];
-$sbmnr = $_POST['sbmnr'];
-$mcnr = $_POST['mcnr'];
-
-# sosntige 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>";
-
-
-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>";
-
-##############################################
-# RBS CN (DN)
-
-if ( $oldrbscn == $rbscn ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $oldrbscn != "" && $rbscn != "" && $oldrbscn != $rbscn ){
- echo "RBS Name aendern<br>";
- # hier noch Syntaxcheck
- # Formulareingaben anpassen
- $exprbs = explode(" ",$rbscn);
- foreach ($exprbs as $word){$expuc[] = ucfirst($word);}
- $rbscn = implode(" ",$expuc);
- $rbscn = preg_replace ( '/\s+([0-9A-Z])/', '$1', $rbscn);
-
- $newrbsDN = "cn=".$rbscn.",".$nodeDN;
- print_r($newrbsDN); echo "<br><br>";
-
- if(move_subtree($rbsDN, $newrbsDN)){
- adjust_rbs_dn($newrbsDN, $rbsDN);
- $rbsDN = $newrbsDN;
- $mesg = "RBS Name erfolgreich ge&auml;ndert<br><br>";
- }else{
- $mesg = "Fehler beim &auml;ndern des RBS Namen!<br><br>";
- }
-}
-
-if ( $oldrbscn != "" && $rbscn == "" ){
- echo "Gruppenname loeschen!<br>
- Dieses ist Teil des DN, Sie werden den RBS komplett l&ouml;schen<br><br>";
- echo "Wollen Sie den RBS Dienst <b>".$oldrbscn."</b> wirklich l&ouml;schen?<br><br>
- <form action='rbservice_delete.php' method='post'>
- Falls ja:<br><br>
- <input type='hidden' name='dn' value='".$pxeDN."'>
- <input type='hidden' name='name' value='".$oldrbscn."'>
- <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 ( $rbsoffer != "none" && $rbsoffer == $oldrbsoffer ){
- $mesg = "Sie haben die gleiche Abteilung ausgew&auml;hlt<br>
- Keine &Auml;nderung!";
-}
-
-if ( $rbsoffer != "none" && $rbsoffer != $oldrbsoffer ){
- $entryoffer ['rbsofferdn'] = $rbsoffer;
- if(ldap_mod_replace($ds,$rbsDN,$entryoffer)){
- $mesg = "RBS Offer erfolgreich ge&auml;ndert<br><br>";
- }
- else{
- $mesg = "Fehler beim &auml;ndern des RBS Offers!<br><br>";
- }
-}
-
-/*if ( $rbsoffer == "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>";
- }
-}*/
-
-
-#####################################
-# TFTP Server ändern
-
-# über IP Feld
-/*if ( $tftpserverip == $oldtftpserverip ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $tftpserverip != "" && $oldtftpserverip == "" ){
- if ($syntax->check_ip_syntax($tftpserverip)){
- $tftpserverip = htmlentities($tftpserverip);
-
- $mesg .= "Suche nach dem Rechner mit IP ".$tftpserverip." :<br>";
- foreach ($host_array as $host){
- $hostipexp = explode('_',$host['ipaddress']);
- $hostip = $hostipexp[0];
- if ($tftpserverip == $hostip){
- $entrytftp ['tftpserverip'] = $tftpserverip;
- if (ldap_mod_add($ds,$rbsDN,$entrytftp)){
- adjust_dhcpnextserver($tftpserverip, $rbsDN);
- $mesg .= "Treffer: Rechner ".$host['hostname']."<br>TFTP Server erfolgreich eingetragen<br>";
- }else{
- $mesg .= "Fehler beim Eintragen des TFTP Servers!<br>";
- }
- break;
- }else{
- $mesg .= "Rechner ".$host['hostname'].": keine &Uuml;bereinstimmung mit eingegebener IP ".$tftpserverip."!<br>";
- }
- }
- }
- else{
- $mesg .= "Falsche IP Syntax!<br>";
- }
-}
-
-if ( $tftpserverip != "" && $tftpserverip != $oldtftpserverip ){
-
- if ($syntax->check_ip_syntax($tftpserverip)){
- $tftpserverip = htmlentities($tftpserverip);
-
- $mesg .= "Suche nach dem Rechner mit IP ".$tftpserverip." :<br>";
- foreach ($host_array as $host){
- $hostipexp = explode('_',$host['ipaddress']);
- $hostip = $hostipexp[0];
- if ($tftpserverip == $hostip){
- $entrytftp ['tftpserverip'] = $tftpserverip;
- if (ldap_mod_replace($ds,$rbsDN,$entrytftp)){
- adjust_dhcpnextserver($tftpserverip, $rbsDN);
- $mesg .= "Treffer: Rechner ".$host['hostname']."<br>TFTP Server erfolgreich ge&auml;ndert<br>";
- }else{
- $mesg .= "Fehler beim &auml;ndern des TFTP Servers!<br>";
- }
- break;
- }else{
- $mesg .= "Rechner ".$host['hostname'].": keine &Uuml;bereinstimmung mit eingegebener IP ".$tftpserverip."!<br>";
- }
- }
- }
- else{
- $mesg .= "Falsche IP Syntax!<br>";
- }
-}
-
-if ( $tftpserverip == "" && $oldtftpserverip != "" ){
- $entrytftp ['tftpserverip'] = array();
- if (ldap_mod_del($ds,$rbsDN,$entrytftp)){
- adjust_dhcpnextserver($tftpserverip, $rbsDN);
- $mesg .= "Treffer: Rechner ".$host['hostname']."<br>TFTP Server erfolgreich gel&ouml;scht<br>";
- }else{
- $mesg .= "Fehler beim l&ouml;schen des TFTP Servers!<br>";
- }
-}*/
-
-#über Selectbox an verfügbaren alternativen Rechnern mit IPs
-if ($tftpserver != "none" && $tftpserver != $oldtftpserverdn){
- $host = get_host_ip($tftpserver);
- $hostipexp = explode('_',$host['ipaddress']);
- $entrytftp ['tftpserverip'] = $hostipexp[0];
- if (ldap_mod_replace($ds,$rbsDN,$entrytftp)){
- adjust_dhcpnextserver($hostipexp[0], $rbsDN);
- $mesg .= "TFTP Server erfolgreich ge&auml;ndert<br>";
- }else{
- $mesg .= "Fehler beim &auml;ndern des TFTP Servers!<br>";
- }
-}
-
-
-#####################################
-# Init Boot File
-
-if ( $initbootfile == $oldinitbootfile ){
- # $mesg = "keine Aenderung<br>";
-}
-
-if ( $initbootfile != "" && $oldinitbootfile == "" ){
- $entrydelibf ['initbootfile'] = $initbootfile;
- if(ldap_mod_add($ds,$rbsDN,$entrydelibf)){
- adjust_dhcpfilename($initbootfile, $rbsDN, "add");
- $mesg = "Initial Boot File erfolgreich eingetragen<br><br>";
- }
- else{
- $mesg = "Fehler beim eintragen von Initial Boot File!<br><br>";
- }
-}
-
-if ( $initbootfile == "" && $oldinitbootfile != "" ){
- $entrydelibf ['initbootfile'] = array();
- if(ldap_mod_del($ds,$rbsDN,$entrydelibf)){
- adjust_dhcpfilename($initbootfile, $rbsDN, "delete");
- $mesg = "Initial Boot File erfolgreich gel&ouml;scht<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen von Initial Boot File!<br><br>";
- }
-}
-
-if ( $initbootfile != "" && $initbootfile != $oldinitbootfile ){
- $entryibf ['initbootfile'] = $initbootfile;
- if(ldap_mod_replace($ds,$rbsDN,$entryibf)){
- adjust_dhcpfilename($initbootfile, $rbsDN, "replace");
- $mesg = "Initial Boot File erfolgreich ge&auml;ndert<br><br>";
- }
- else{
- $mesg = "Fehler beim &auml;ndern des Initial Boot Files!<br><br>";
- }
-}
-
-
-#######################################
-# Fileserver URI anlegen
-
-if ( $addfsuri[1] != "" ){
- # tests: ipsyntax, und spezifische URI-Syntax-Checks...
- if( $syntax->check_ip_syntax($addfsuri[1]) ){
-
- $newfsuri = $addfsuri[0]."://".$addfsuri[1].$addfsuri[2];
- echo "FS URI <b>".$newfsuri."</b> anlegen<br>";
-
- $entryfsadd ['fileserveruri'] = $newfsuri;
- if(ldap_mod_add($ds,$rbsDN,$entryfsadd)){
- $mesg = "FS URI erfolgreich eingetragen<br><br>";
- }else{
- $mesg = "Fehler beim eintragen der FS URI<br><br>";
- }
- }
- else{echo "Falsche IP Syntax<br><br>";}
-}
-
-#####################################
-# Fileserver URIs löschen
-
-if ( count($delfsuri) != 0 ){
- echo "Fileserver URI l&ouml;schen<br>";
-
- $i = 0;
- foreach ($delfsuri as $fsuri){
- $entry['fileserveruri'][$i] = $fsuri;
- $i++;
- }
- #print_r($entry); echo "<br><br>";
-
- if ($result = ldap_mod_del($ds,$rbsDN,$entry)){
- $mesg = "Zu l&ouml;schende Fileserver URIs erfolgreich gel&ouml;scht<br><br>";
- }else{
- $mesg = "Fehler beim l&ouml;schen der Fileserver URIs<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,$rbsDN,$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,$rbsDN,$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,$rbsDN,$entrydel)){
- $mesg = "Attribute ".$delatts." erfolgreich geloescht<br><br>";
- }else{
- $mesg = "Fehler beim loeschen der Attribute ".$delatts."<br><br>";
- }
-}
-
-
-$url = "rbservice.php?rbsdn=".$rbsDN."&mnr=".$mnr;
-$seconds = 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/rbs/rbservice_delete.php b/ldap-site-mngmt/webinterface/rbs/rbservice_delete.php
deleted file mode 100644
index 919987bd..00000000
--- a/ldap-site-mngmt/webinterface/rbs/rbservice_delete.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-$rbsDN = $_POST['dn'];
-$rbscn = $_POST['name'];
-
-$seconds = 100;
-$url = 'rbs.php';
-
-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 ( $rbsDN != ""){
-
- if ( dive_into_tree_del($rbsDN,"") ){
- clean_up_del_rbs($rbsDN);
- $mesg = "Remote Boot Service <b>".$rbscn."</b> erfolgreich gel&ouml;scht!<br><br>";
- }
- else{
- $mesg = "Fehler beim l&ouml;schen des Remote Boot Services <b>".$rbscn."</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/roles/menu.dwt b/ldap-site-mngmt/webinterface/roles/menu.dwt
deleted file mode 100644
index 9aadc1c5..00000000
--- a/ldap-site-mngmt/webinterface/roles/menu.dwt
+++ /dev/null
@@ -1,22 +0,0 @@
-
-<table cellpadding='5' cellspacing='0' border='0' width='100%'>
-
-
-
- <!-- BEGIN DYNAMIC BLOCK: Hauptmenu -->
-
- <tr valign='middle' align='left'>
-
- <td width='8%' align='right' style="border-style=none;">&nbsp;</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>
- <tr height='5'></tr>
- <!-- END DYNAMIC BLOCK: Hauptmenu -->
-
-
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/role_add.php b/ldap-site-mngmt/webinterface/roles/role_add.php
deleted file mode 100644
index f4b80506..00000000
--- a/ldap-site-mngmt/webinterface/roles/role_add.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-
-$adduser = $_POST['adduser'];
-$role = $_POST['role'];
-$menr = $_POST['menr'];
-
-$exp = explode('_',$adduser);
-$adduserDN = $exp[0];
-$adduserUID = $exp[1];
-
-echo "
-<html>
-<head>
- <title>Roles Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-# print_r($adduser);echo "<br>";
-# print_r($adduserDN);echo "<br>";
-# print_r($adduserUID);echo "<br>";
-# print_r($role);echo "<br>";
-# print_r($menr);echo "<br><br>";
-
-$url = 'role_show.php?role='.$role.'&sbmnr='.$menr;
-
-if ($adduser != 'none'){
- $res = new_role_member($adduserDN,$role,$auDN,$domDN);
- if ($res == 1){
- $mesg = "Der Benutzer <b>".$adduserUID."</b> wurde erfolgreich als neuer <b>".$role."</b> aufgenommen.<br><br>";
- }else{
- $mesg = "Fehler! Der Benutzer <b>".$adduserUID."</b> konnte nicht aufgenommen werden<br><br>";
- }
- $mesg .= "Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-}
-
-else {
- $mesg = "Sie haben keinen Benutzer ausgew&auml;hlt<br><br>
- Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-}
-
-echo "</td></tr></table></body>
-</html>";
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/role_delete.php b/ldap-site-mngmt/webinterface/roles/role_delete.php
deleted file mode 100644
index 7a585331..00000000
--- a/ldap-site-mngmt/webinterface/roles/role_delete.php
+++ /dev/null
@@ -1,57 +0,0 @@
-<?php
-
-include('../standard_header.inc.php');
-
-
-$deluser = $_POST['deluser'];
-$role = $_POST['role'];
-$menr = $_POST['menr'];
-
-echo "
-<html>
-<head>
- <title>Roles Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
-</head>
-<body>
-<table border='0' cellpadding='30' cellspacing='0'>
-<tr><td>";
-
-if (isset($_POST['deluser'])){
-
- # print_r($deluser);echo "<br>";
- # print_r($role);echo "<br>";
- # print_r($menr);echo "<br>";
-
- $url = 'role_show.php?role='.$role.'&sbmnr='.$menr;
- $mesg = "";
-
- foreach ($deluser as $item){
- $exp = explode('_',$item);
- $deluserDN = $exp[0];
- $deluserUID = $exp[1];
- # print_r($deluserDN);echo "<br>";
- # print_r($deluserUID);echo "<br>";
- $res = delete_role_member($deluserDN,$role,$auDN,$domDN);
- if ($res == 1){
- $mesg .= "Der Benutzer <b>".$deluserUID."</b> wurde erfolgreich aus der Rolle <b>".$role."</b> entfernt.<br>";
- }else{
- $mesg .= "<br><b>Fehler!</b> Der Benutzer <b>".$deluserUID."</b> konnte nicht entfernt werden<br>";
- }
- }
- $mesg .= "<br>Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a><br><br>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-
-}
-
-else {
- $mesg .= "<br>Sie haben keinen Benutzer ausgew&auml;hlt<br><br>
- Sie werden automatisch auf die vorherige Seite zur&uuml;ckgeleitet. <br>
- Falls nicht, klicken Sie hier <a href='role_show.php?role=$role&sbmnr=$menr' style='publink'>back</a>";
- redirect(3, $url, $mesg, $addSessionId = TRUE);
-}
-
-echo "</td></tr></table></body>
-</html>";
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/role_show.dwt b/ldap-site-mngmt/webinterface/roles/role_show.dwt
deleted file mode 100644
index 3eb05b79..00000000
--- a/ldap-site-mngmt/webinterface/roles/role_show.dwt
+++ /dev/null
@@ -1,70 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='100%'>
- <tr>
- <td colspan='2'><h3>{ROLE_DESC}</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;'>
- <tr>
- <td width='5%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'>&nbsp;</td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Benutzer</b></td>
- <td width='25%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>UID</b></td>
- <td width='45%' style='border-color: black; border-style: solid; border-width: 0 0 3 0;'><b>Email</b></td>
- </tr>
-
- <form action='role_delete.php' method='post'>
-
- <!-- BEGIN DYNAMIC BLOCK: Members -->
- <tr>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>
- <input type='checkbox' name='deluser[]' value='{VALUE}_{UID}' size='15' class='medium_form_checkbox'></td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{USERNAME} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'>{UID} &nbsp;</td>
- <td style='border-color: black; border-style: solid; border-width: 0 0 1 0;'><a href'mailto:{MAIL}' style='publink'>{MAIL}</a> &nbsp;</td>
- </tr>
- <!-- END DYNAMIC BLOCK: Members -->
- <input type='hidden' name='role' value='{ROLE}'>
- <input type='hidden' name='menr' value='{MENR}'>
-
-
- <tr>
- <td colspan='3' style='border-width: 0 0 0 0;'><input type='Submit' name='delete' value='entfernen' class='small_loginform_button'></td>
-
- </form>
- </tr>
- </table></td>
- </tr>
-
- <tr height='30'></tr>
- <tr>
- <td colspan='2'><h4>Neuen Administrator anlegen:</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>
-
- <form action='role_add.php' method='post'>
-
- <td width='60%' style='border-color: black; border-style: solid; border-width: 3 0 1 0;'>
- W&auml;hlen Sie einen Benutzer aus <br>
- <select name='adduser' size='1' class='medium_form_selectbox'>
- <option selected value='none'>----------</option>
-
- <!-- BEGIN DYNAMIC BLOCK: Users -->
- <option value='{UDN}_{USER}'>{USER}</option>
- <!-- END DYNAMIC BLOCK: Users -->
-
- </select>
- <input type='hidden' name='role' value='{ROLE}'>
- <input type='hidden' name='menr' value='{MENR}'>
- </td>
- </tr>
- <tr>
- <td style='border-width: 0 0 0 0;'><input type='Submit' name='add' value='anlegen' class='small_loginform_button'></td>
-
- </form>
- </tr>
- </table></td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/role_show.php b/ldap-site-mngmt/webinterface/roles/role_show.php
deleted file mode 100644
index c60b7fb2..00000000
--- a/ldap-site-mngmt/webinterface/roles/role_show.php
+++ /dev/null
@@ -1,123 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "Roles Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-$mnr = 1;
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "role_show.dwt";
-$role = "MainAdmin";
-
-include("../class.FastTemplate.php");
-
-#include("roles_header.inc.php");
-include("au_header.inc.php");
-
-###############################################################################
-
-#$mnr = $_GET['mnr'];
-$mnr = 3;
-
-$sbmnr = $_GET['sbmnr'];
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-####################################
-# Admins anzeigen und loeschen
-
-$role = $_GET['role'];
-$roles_array = get_roles($auDN);
-# print_r($roles_array);
-
-# jeder Rolle entsprechend Members holen und Ãœberschrift setzen
-switch ($role){
-case 'MainAdmin':
- $template->assign(array("ROLE" => "MainAdmin","ROLE_DESC" => "Haupt Administratoren","MENR" => $sbmnr));
- $members = $roles_array['MainAdmin'];
- break;
-case 'HostAdmin':
- $template->assign(array("ROLE" => "HostAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;Rechner, Rechnergruppen, Remote Boot Services (PXE)","MENR" => $sbmnr));
- $members = $roles_array['HostAdmin'];
- break;
-case 'DhcpAdmin':
- $template->assign(array("ROLE" => "DhcpAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;DHCP","MENR" => $sbmnr));
- $members = $roles_array['DhcpAdmin'];
- break;
-case 'RbsAdmin':
- $template->assign(array("ROLE" => "RbsAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;Remote Boot Services","MENR" => $sbmnr));
- $members = $roles_array['RbsAdmin'];
- break;
-case 'ZoneAdmin':
- $template->assign(array("ROLE" => "ZoneAdmin","ROLE_DESC" => "Administratoren &nbsp;- &nbsp;DNS Zone &nbsp;[ {DOM} ]","MENR" => $sbmnr));
- $members = $roles_array['ZoneAdmin'];
- break;
-}
-
-# print_r($members); echo "<br><br>";
-
-# für jedes Member Daten holen (Benutzername, UID)
-if ( count($members) != 0 ){
- $members_data = array();
- foreach ($members as $item){
- $members_data[] = get_user_data($item,array("dn","cn","uid","mail"));
- # print_r(get_user_data($item,array("dn","cn","uid"))); echo "<br>";
- }
-}
-# echo "<br>";
-# print_r($members_data); echo "<br><br>";
-
-if (count($members_data) != 0){
- $template->define_dynamic("Members", "Webseite");
- foreach ($members_data as $item){
- $template->assign(array("VALUE" => $item['dn'],
- "USERNAME" => $item['cn'],
- "UID" => $item['uid'],
- "MAIL" => $item['mail']));
- $template->parse("MEMBERS_LIST", ".Members");
- }
-}else{
- $template->assign(array("VALUE" => "","USERNAME" => "","UID" => "","MAIL" => ""));
-}
-
-
-##############################################
-# Admin anlegen ...
-$users_array = get_users();
-# print_r($users_array); echo "<br><br>";
-
-if (count($members_data) != 0){
-for ($i=0; $i < count($users_array); $i++){
- foreach ($members_data as $item){
- if ($users_array[$i]['uid'] == $item['uid']){
- array_splice($users_array, $i, 1);
- # break;
- }
- }
-}
-# print_r($users_array); echo "<br><br>";
-}
-
-# if (count($users_array) != 0){
- $template->define_dynamic("Users", "Webseite");
- foreach ($users_array as $item){
- $template->assign(array("UDN" => $item['dn'],
- "USER" => $item['uid']));
- $template->parse("USERS_LIST", ".Users");
- }
-#}else{
-# $template->assign(array("UDN" => "","USER" => ""));
-# }
-
-
-
-
-
-###############################################################################
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/roles.dwt b/ldap-site-mngmt/webinterface/roles/roles.dwt
deleted file mode 100644
index 48e8fe14..00000000
--- a/ldap-site-mngmt/webinterface/roles/roles.dwt
+++ /dev/null
@@ -1,79 +0,0 @@
-<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>Client / 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/roles/roles.php b/ldap-site-mngmt/webinterface/roles/roles.php
deleted file mode 100644
index 8d418add..00000000
--- a/ldap-site-mngmt/webinterface/roles/roles.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-include('../standard_header.inc.php');
-
-# 1. Seitentitel - wird in der Titelleiste des Browser angezeigt.
-$titel = "Roles Management";
-# 2. Nummer des zugehörigen Hauptmenus (Registerkarte) beginnend bei 0, siehe Dokumentation.doc.
-$mainnr = 1;
-$mnr = 0;
-# 3. Dateiname und evtl. Pfad des Templates für die Webseite
-$webseite = "roles_start.dwt";
-
-include("../class.FastTemplate.php");
-
-#include("roles_header.inc.php");
-include("au_header.inc.php");
-
-###################################################################################
-
-$mnr = 3;
-$sbmnr = -1;
-
-# Menuleiste erstellen
-createMainMenu($rollen, $mainnr);
-createAUMenu($rollen, $mnr, $auDN, $sbmnr);
-
-###################################################################################
-
-include("au_footer.inc.php");
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/roles_footer.inc.php b/ldap-site-mngmt/webinterface/roles/roles_footer.inc.php
deleted file mode 100644
index 311721c5..00000000
--- a/ldap-site-mngmt/webinterface/roles/roles_footer.inc.php
+++ /dev/null
@@ -1,18 +0,0 @@
-<?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/roles/roles_header.inc.php b/ldap-site-mngmt/webinterface/roles/roles_header.inc.php
deleted file mode 100644
index 74c96f74..00000000
--- a/ldap-site-mngmt/webinterface/roles/roles_header.inc.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-include("roles_menu.php");
-
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$definedTemplates = array("Vorlage" => "roles.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, "AU" => $au_ou, "DOMAIN" => $assocdom, "USERCN" => $usercn));
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/roles/roles_menu.php b/ldap-site-mngmt/webinterface/roles/roles_menu.php
deleted file mode 100644
index 246601e8..00000000
--- a/ldap-site-mngmt/webinterface/roles/roles_menu.php
+++ /dev/null
@@ -1,95 +0,0 @@
-<?php
-
-
-function createRolesMenu($rollen , $mnr, $assocdom) {
- global $template;
- global $START_PATH;
- # Struktur der Registerkartenleiste
- if ($assocdom != ""){
- $hauptmenu = array(array("link" => "roles.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- array("link" => "role_show.php?role=MainAdmin&mnr=1",
- "text" => "Main Admins",
- "zugriff" => array("MainAdmin")),
- array("link" => "role_show.php?role=DhcpAdmin&mnr=2",
- "text" => "DHCP Admins",
- "zugriff" => array("MainAdmin")),
- array("link" => "role_show.php?role=HostAdmin&mnr=3",
- "text" => "Host Admins",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- array("link" => "role_show.php?role=RbsAdmin&mnr=4",
- "text" => "RBS Admins",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- #array("link" => "role_show.php?role=ZoneAdmin&mnr=4",
- # "text" => "DNS Admins",
- # "zugriff" => array("MainAdmin"))
- );
- }else{
- $hauptmenu = array(array("link" => "roles.php",
- "text" => "&Uuml;bersicht",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- array("link" => "role_show.php?role=MainAdmin&mnr=1",
- "text" => "Main Admins",
- "zugriff" => array("MainAdmin")),
- array("link" => "role_show.php?role=DhcpAdmin&mnr=2",
- "text" => "DHCP Admins",
- "zugriff" => array("MainAdmin")),
- array("link" => "role_show.php?role=HostAdmin&mnr=3",
- "text" => "Host Admins",
- "zugriff" => array("MainAdmin","DhcpAdmin")),
- array("link" => "role_show.php?role=RbsAdmin&mnr=4",
- "text" => "RBS Admins",
- "zugriff" => array("MainAdmin","DhcpAdmin"))
- );
- }
- # $rollen = array_keys($roles);
-
- # Zusammenstellen der Menuleiste
- $template->define_dynamic("Hauptmenu", "Menu");
- $i=0;
- foreach($hauptmenu as $item) {
- if($item['zugriff'] === "alle" || vergleicheArrays($rollen , $item['zugriff'])) {
- if ($i==0) {
- if ($mnr==0) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $zwisch="";
- $farb="#A0A0A0";
- $lastaktive=false;
- }
- }
- else {
- if ($mnr==$i) {
- $zwisch="";
- $lastaktive=true;
- $farb="#505050";
- }
- else {
- $farb="#A0A0A0";
- if ($lastaktive) {$zwisch="";}
- else {$zwisch="";}
- $lastaktive=false;
- }
- }
- $template->assign(array("ZWISCHEN" => $zwisch,
- "FARBE" => $farb,
- "LINK_M" => $item["link"],
- "TEXT_M" => $item["text"]));
- $template->parse("HAUPTMENU_LIST", ".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/roles/roles_start.dwt b/ldap-site-mngmt/webinterface/roles/roles_start.dwt
deleted file mode 100644
index 665bed3f..00000000
--- a/ldap-site-mngmt/webinterface/roles/roles_start.dwt
+++ /dev/null
@@ -1,37 +0,0 @@
-<table border='0' cellpadding='5' cellspacing='0' width='90%'>
- <tr>
- <td colspan='2'><h3>Modul - Administratoren Rollen Management: </h3></td>
- </tr>
- <tr>
- <td height='10'></td>
- </tr>
- <tr>
- <td>
- <p>Dieses Modul dient der Verwaltung von Administratoren Rollen in ihrer Abteilung.
- Benutzen Sie die Navigation links, um die Verwaltungsbereiche der einzelnen Rollen anzusteuern.
- Dort koennen Sie dann Benutzer den Rollen zuweisen oder wieder entziehen.</p>
- <p>Folgende administrative Rollen stehen zur Verfuegung:</p>
- <ul>
- <li><p><b>Main Admins</b></p>
- Hauptadministratoren, der AU mit uneingeschraenkten Rechten. Sie verwalten: u.a.
- untergeordnete AUs (anlegen/loeschen/im DNS anmelden),
- Rollen, IP Adressen und deren Delegierung, Rechner (Gruppen), deren Hardware-Profile und
- PXE Boot Konfigurationen, sowie die Dienste DHCP und DNS.
- </li>
- <!-- <li><p><b>Host Admins</b></p>
- Diese verwalten Rechner (Gruppen), deren Hardware-Profile und PXE Boot Konfigurationen,
- und koennen diese im DHCP und DNS anmelden (verwalten im DNS nur deren Namenseintraege).
- </li>
- <li><p><b>DHCP Admins</b></p>
- Verwalten den DHCP Dienst, d.h. Subnetz-, Pool-, Class-Objekte.
- </li>
- <li><p><b>DNS Admins</b></p>
- Sind die Administratoren der mit der AU assozierten DNS Zone. D.h. sie verwalten SOA,
- Include Direktiven untergeordneter Include Files, sowie alle Nameneintraege der Zone.
- </li> -->
- </ul>
-
- </td>
- </tr>
-
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/standard_footer.inc.php b/ldap-site-mngmt/webinterface/standard_footer.inc.php
deleted file mode 100644
index afaf5a35..00000000
--- a/ldap-site-mngmt/webinterface/standard_footer.inc.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?
-
-echo "
-</td>
- <td width='2%'></td>
- </tr>
-</table>
-
-</body>
-
-</html>
-";
-
-echo "<br /><b>php_errormsg:</b> $php_errormsg";
-#$_SESSION['error'] .= $php_errormsg;
-
-#echo "Errors:<br>$_SESSION['error']";
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/standard_header.inc.php b/ldap-site-mngmt/webinterface/standard_header.inc.php
deleted file mode 100644
index 21483eee..00000000
--- a/ldap-site-mngmt/webinterface/standard_header.inc.php
+++ /dev/null
@@ -1,86 +0,0 @@
-<?php
-session_cache_expire(30);
-session_start();
-
-
-include('lib/config.inc.php');
-include('lib/ldap.inc.php');
-include('lib/ldap2.inc.php');
-include('lib/commonlib.inc.php');
-include('syntax_check.php');
-include('lib/au_management_functions.php');
-include('lib/ip_management_functions.php');
-include('lib/host_management_functions.php');
-include('lib/dhcp_management_functions.php');
-include('lib/rbs_management_functions.php');
-include("class.FastTemplate.php");
-
-//print_r($_SESSION['status']);
-if ( !isset($_SESSION['status']) ){
- redirect(0,"../index.php","",$addSessionId = FALSE);
- exit;
-}
-if ( $_SESSION['status'] != "in" ){
- //$_SESSION['status'] != "out";
- redirect(0,"../index.php","",$addSessionId = FALSE);
- exit;
-}
-
- // Fehlerausgabe im Browser anschalten
-ini_set('display_errors', 0);
-// nur Laufzeitfehler ausgeben
-error_reporting(E_ALL ^ E_NOTICE | E_STRICT);
-
-$uid = $_SESSION['uid'];
-$userPassword = $_SESSION['userPassword'];
-$userDN = $_SESSION['dn'];
-$usercn = $_SESSION['cn'];
-$auDN = $_SESSION['audn'];
-#echo "auDN: "; print_r($auDN); echo "<br>";
-$rollen = $_SESSION['rollen'];
-#echo "rollen: "; print_r($rollen); echo "<br>";
-
-
-if (!($ds = uniLdapConnect($uid,$userPassword))){
- echo "<html>
- <head>
- <title>Zentrales Rechner / IP Management</title>
- <link rel='stylesheet' href='../styles.css' type='text/css'>
- </head>
- <body>
- <table border='0' cellpadding='30' cellspacing='0'>
- <tr valign='middle'><td align='center'>
- <h3>Es konnte keine Verbindung zum LDAP Server hergestellt werden!</h3>
- </td></tr></table></body>
- </html>
- ";
- die;
-}
-
-if ($auDN != ""){
-
- # AU Daten holen
- $attributes = array("ou","associateddomain","maxipblock","freeipblock","cn","description");
- $au_data = get_au_data($auDN,$attributes);
- $assocdom = $au_data[0]['associateddomain'];
- $au_ou = $au_data[0]['ou'];
- $au_cn = $au_data[0]['cn'];
- $au_desc = $au_data[0]['description'];
- $au_mipb = $au_data[0]['maxipblock'];
- $au_fipb = $au_data[0]['freeipblock'];
-
- # AU Domain Daten holen
- $domain_data = get_domain_data($auDN,array("dn"));
-
- $expAuDn = explode(",",$auDN);
- if ($expAuDn[1] == "ou=RIPM"){
- $domDN = "ou=DNS,".$suffix;
- }
- else{$domDN = $domain_data[0]['dn']; }
-
- $domprefix = str_replace('.'.$domsuffix,'',$assocdom);
- # print_r($domprefix);
-
-}
-
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/start.dwt b/ldap-site-mngmt/webinterface/start.dwt
deleted file mode 100644
index 526d8ce4..00000000
--- a/ldap-site-mngmt/webinterface/start.dwt
+++ /dev/null
@@ -1,57 +0,0 @@
-
-<br><br>
-<hr align='center' size='3' width='98%' noshade>
-
-<table cellpadding='5' cellspacing='0' border='0' width='100%' height='30%'>
-
- <tr valign='middle' height='100%'>
- <td width='100%' align='center'>
- <table cellpadding='5' cellspacing='0' border='0' width='100%'>
- <tr><td align='center'>
-
- <h1>Zentrales Client / IP Management</h1>
-
- <h3>
- <code class='font_object'><br> Registrierung / Administration von Rechnern in den zentralen RZ Diensten <br>
- <font size=+3> DHCP, Remote Boot (PXE/TFTP) </font></code>
- </h3>
- </td></tr>
- </table>
- </td>
-
- </tr>
-</table>
-
-<hr align='center' size='3' width='98%' noshade>
-
-<table cellpadding='5' cellspacing='0' border='0' width='100%' height='48%'>
-
-
- <tr valign='middle'>
- <td width='100%' align='center'>
- <table cellspacing='0' cellpadding='5' border='0' width='30%' style='border-color: #505050; border-style: solid; border-width: 2 2 2 2;'>
- <tr height="50"><td align='center' style='border-color: #505050; border-style: solid; border-width: 0 0 2 0;background-color: #808080; color: white;'>
- <font size="+2"> LOGIN&nbsp; - &nbsp;Client / IP Management </font>
- </td></tr>
- <tr><td align='center'>
-
- {LOGIN}
-
- </td></tr>
- </table>
- </td>
-
- </tr>
-</table>
-
-
-
-<table cellpadding='5' cellspacing='0' border='0' width='100%' height='10%'>
- <tr valign='bottom'>
- <td><hr align='center' size='1' width='100%' noshade></td>
- </tr>
- <tr valign='top'>
- <td align='right'> Rechenzentrum Universit&auml;t Freiburg
- </td></tr>
- </tr>
-</table> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/start.php b/ldap-site-mngmt/webinterface/start.php
deleted file mode 100644
index d0d34320..00000000
--- a/ldap-site-mngmt/webinterface/start.php
+++ /dev/null
@@ -1,83 +0,0 @@
-<?php
-
-#Pfad festlegen wo die Dateien sich befinden
-include('standard_header.inc.php');
-
-$titel = "Rechner und IP Management Startseite";
-$webseite = "home.dwt";
-
-# neues Template-Objekt erstellen
-$template = new FastTemplate(".");
-# dem erstellten Template-Objekt eine Vorlage zuweisen
-$template->define(array("Vorlage" => "index.dwt",
- "Login" => "logout_form.inc.dwt",
- "Webseite" => $webseite));
-
-$template->assign(array("SEITENTITEL" => $titel,"USERCN" => $usercn));
-
-############################################################
-
-$template->define_dynamic("Aus", "Webseite");
-#$template->define_dynamic("Roles", "Webseite");
-
-$roles = getRoles($ds, $userDN);
-#print_r($roles); echo "<br><br>";
-if (count($roles) == 1 ){
- $mesg = "";
- $rollenurlstring = implode('_',$roles[0]['role']);
- $url = "zwischen.php?audn=".$roles[0]['au']."&rollen=".$rollenurlstring;
- redirect(0, $url, $mesg, $addSessionId = TRUE);
- die;
-}
-
-
-foreach ($roles as $item){
-
- $auDN = $item['au'];
- $expDN = explode(',',$auDN);
- $expOU = explode('=',$expDN[0]);
- $au = $expOU[1];
- $audata = get_au_data($auDN,array("cn","description"));
-
- $template->assign(array( "CN" => "","MA" => "", "HA" => "", "DA" => "", "ZA" => "", "RA" => ""));
- $template->assign(array( "AU" => $au, "AUDN" => $auDN, "CN" => $audata[0]['cn'], "ROLLEN" => implode('_',$item['role'])));
-
- $rollen = "";
- foreach ($item['role'] as $role){
- $rollen .= $role." &nbsp;";
- $template->assign(array( "MA" => $rollen));
-
- /*if ($role == MainAdmin){
- $template->assign(array( "MA" => $role));
- }
- if ($role == HostAdmin){
- $template->assign(array( "HA" => $role));
- }
- if ($role == DhcpAdmin){
- $template->assign(array( "DA" => $role));
- }
- if ($role == ZoneAdmin){
- $template->assign(array( "ZA" => $role));
- }
- if ($role == RbsAdmin){
- $template->assign(array( "RA" => $role));
- }*/
- }
- $template->parse("AUS_LIST", ".Aus");
- $template->clear_dynamic("Aus");
-}
-
-
-#############################################################
-
-# Daten in die Vorlage parsen
-$template->assign(array("PFAD" => $START_PATH));
-
-$template->parse("LOGIN", "Login");
-$template->parse("HAUPTFENSTER", "Webseite");
-$template->parse("PAGE", "Vorlage");
-
-# Fertige Seite an den Browser senden
-$template->FastPrint("PAGE");
-
-?>
diff --git a/ldap-site-mngmt/webinterface/styles.css b/ldap-site-mngmt/webinterface/styles.css
deleted file mode 100644
index aec22d79..00000000
--- a/ldap-site-mngmt/webinterface/styles.css
+++ /dev/null
@@ -1,369 +0,0 @@
-p {
- font-family: Arial;
- font-size: 10pt;
- color: #000000;
-}
-a:link {
- color: #006BB6;
- text-decoration:none;
-}
-a:visited {
- color: #006BB6;
- text-decoration:none;
-}
-a:hover {
- color: #006BB6;
- text-decoration:underline;
-}
-a:active {
- color: #B9D9F0;
- text-decoration:underline;
-}
-body {
- font-family: helvetica, arial, sans-serif;
- font-size: 10pt;
- color: #000000;
- background-color: #FFFFFF;
- margin-top:0px;
- margin-left:0px;
-}
-h1 {
- font-family: arial, helvetica, sans-serif;
- font-size: 25pt;
- font-weight: bold;
- color: #000000;
-}
-h2 {
- font-family: arial, helvetica, sans-serif;
- font-size: 15pt;
- font-weight: bold;
- color: #000000;
-}
-h3 {
- font-family: arial, helvetica, sans-serif;
- font-size: 12pt;
- font-weight: bold;
- color: #000000;
-}
-h4 {
- font-family: arial, helvetica, sans-serif;
- font-size: 10pt;
- font-weight: bold;
- color: #000000;
-}
-.font_object {
- font-family: arial, helvetica, sans-serif;
- font-weight: bold;
- color: #505050;
-}
-.balken {
- font-family: arial, helvetica, sans-serif;
- font-size: 12pt;
- font-weight: bold;
- color: #FFFFFF;
- background-color: #006BB6;
-}
-.balken_mit_pd {
- font-family: arial, helvetica, sans-serif;
- font-size: 12pt;
- font-weight: bold;
- color: #FFFFFF;
- background-color: #006BB6;
- padding: 5;
-}
-.balken_kl {
- font-family: arial, helvetica, sans-serif;
- font-size: 10pt;
- color: #FFFFFF;
- background-color: #006BB6;
-}
-.small_loginform_field {
- font-family: arial, helvetica, sans-serif;
- font-size: 10pt;
- color: #000000;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- background-color: #C0C0C0;
- padding: 3px;
- margin: 3px;
-}
-.small_loginform_button {
- font-family: arial, helvetica, sans-serif;
- font-size: 10pt;
- width: 80px;
- color: #FFFFFF;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- background-color: #880000;
- margin: 3px;
-}
-.small_loginform_text {
- font-family: arial, helvetica, sans-serif;
- font-size: 10pt;
- color: #000000;
-}
-.tiny_loginform_button {
- font-family: Arial;
- font-size: 8pt;
- width: 60px;
- color: #FFFFFF;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- background-color: #880000;
-}
-.tiny_loginform_text {
- font-family: arial, helvetica, sans-serif;
- font-size: 8pt;
- color: #000000;
-}
-.small_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 150;
- padding-left: 10px;
- margin: 5px;
-}
-.medium_form_field {
- font-family: Arial;
- font-size: 10pt;
- color: #000000;
- padding-left: 5px;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- background-color: #FFFFFF;
- margin: 5px;
-}
-.medium_form_field_err {
- font-family: Arial;
- font-size: 10pt;
- color: #000000;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- background-color: #FFFFFF;
-}
-.medium_form_button {
- font-family: Arial;
- font-size: 10pt;
- color: #FFFFFF;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- background-color: #600000;
- width: 50px;
-}
-.medium_form_text {
- font-family: Arial;
- font-size: 10pt;
- color: #000000;
-}
-.medium_form_checkbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
-}
-.medium_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 300;
- padding-left: 10px;
- margin: 5px;
-}
-.tftp_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 250;
- padding-left: 10px;
- margin: 5px;
-}
-.rootfs_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 250;
- padding-left: 5px;
- margin: 5px;
-}
-.100_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 100;
- padding-left: 10px;
- margin: 5px;
-}
-.tiny_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 80;
- padding-left: 10px;
- margin: 5px;
-}
-.large_form_selectbox {
- font-family: Arial;
- font-size: 10pt;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #000000;
- width: 430;
- padding-left: 10px;
- margin: 5px;
-}
-
-.tabellen_platzhalter{
- font-size: 0pt;
-}
-.standard_schrift {
- font-family: Arial;
- font-size: 10pt;
- color: #FFFFFF;
-}
-.menue_schrift {
- font-family: Arial;
- font-size: 11pt;
- color: #FFFFFF;
-}
-.submenue_schrift {
- font-family: Arial;
- font-size: 10pt;
- color: #FFFFFF;
-}
-.tabellenzeile_hell {
- background-color: #E7F5FE;
-}
-.tabellenzeile_dunkel {
- background-color: #B9D9F0;
-}
-.warnung {
- color: #C40000;
-}
-.Textfeld {
- font-family: Arial;
- font-size: 10pt;
- color: #000000;
- border-style: solid;
- border-width: 1px 1px;
- border-color: #006BB6;
- background-color: #E7F5FE;
-}
-.tab_h {
- border-color: black;
- border-style: solid;
- border-width: 0px 0px 3px 0px;
-}
-.tab_d {
- border-color: black;
- border-style: solid;
- border-width: 0px 0px 1px 0px;
-}
-.tab_d_ohne {
- border-color: black;
- border-style: solid;
- border-width: 0px 0px 0px 0px;
-}
-.headerlink:link {
- color: #000000;
- text-decoration:underline;
-}
-.headerlink:visited {
- color: #000000;
- text-decoration:underline;
-}
-.headerlink:hover {
- color: #505050;
- text-decoration:none;
-}
-.headerlink:active {
- color: #505050;
- text-decoration:underline;
-}
-.publink:link {
- color: #001B56;
- text-decoration:none;
-}
-.publink:visited {
- color: #001B56;
- text-decoration:none;
-}
-.publink:hover {
- color: #001B56;
- text-decoration:underline;
-}
-.publink:active {
- color: #B9D9F0;
- text-decoration:underline;
-}
-.publink_leit:link {
- color: #FFFFDF;
- text-decoration:none;
-}
-.publink_leit:visited {
- color: #FFFFDF;
- text-decoration:none;
-}
-.publink_leit:hover {
- color: #FFFFDF;
- text-decoration:underline;
-}
-.publink_leit:active {
- color: #FFFFDF;
- text-decoration:underline;
-}
-.maillink:link {
- color: #001B56;
- text-decoration:none;
-}
-.maillink:visited {
- color: #001B56;
- text-decoration:none;
-}
-.maillink:hover {
- color: #001B56;
- text-decoration:underline;
-}
-.maillink:active {
- color: #B9D9F0;
- text-decoration:underline;
-}
-.formlink:link {
- color: #FFFFFF;
- text-decoration:none;
-}
-.formlink:visited {
- color: #FFFFFF;
- text-decoration:none;
-}
-.formlink:hover {
- color: #FFFFFF;
- text-decoration:none;
-}
-.formlink:active {
- color: #FFFFFF;
- text-decoration:none;
-}
-.no_size {
- font-family: Arial;
- font-size: 1pt;
-} \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/syntax_check.php b/ldap-site-mngmt/webinterface/syntax_check.php
deleted file mode 100644
index 5d714122..00000000
--- a/ldap-site-mngmt/webinterface/syntax_check.php
+++ /dev/null
@@ -1,304 +0,0 @@
-<?php
-/*
- Syntaxcheck 1.2 2006/08/08
-
- A class for checking syntax of forms data
- Copyright (c) Tarik Gasmi, All Rights Reserved
-*/
-
-
-class Syntaxcheck
-{
-
- var $ERROR = "";
- var $CLEAR = false;
-
- function Syntaxcheck ()
- {
- return;
- }
-
- function clear_error ()
- {
- $this->ERROR = "";
- }
-
-
-
-
-
-# Ist "dotted quad IPAddress" in gueltigem Bereich? true or false
-# Ueberprueft Format, fuehrende Nullen, und Werte > 255
-#
-# Ueberprueft nicht nach reservierten oder nicht-route-baren IPs.
-#
-function check_ip_syntax($IP)
-{
- if($this->CLEAR) { $this->clear_error();}
-
- $len = strlen($IP);
- if( $len > 15 ){
- $this->ERROR = "check_ip_syntax: too long [$IP][$len]";
- return false;
- }
-
- $badcharacter = eregi_replace("([0-9\.]+)","",$IP);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in IP address [$badcharacter]";
- return false;
- }
-
- $chunks = explode(".",$IP);
- $count = count($chunks);
- if ($count != 4){
- $this->ERROR = "check_ip_syntax: not a dotted quad [$IP]";
- return false;
- }
-
- while ( list ($key,$val) = each ($chunks) ){
- if(ereg("^0",$val) && strlen($val) != 1){
- $this->ERROR = "check_ip_syntax: Invalid IP segment [$val]";
- return false;
- }
- $Num = $val;
- settype($Num,"integer");
- if($Num > 255){
- $this->ERROR = "check_ip_syntax: Segment out of range [$Num]";
- return false;
- }
- }
-
- return true;
-
-}
-
-# Netzwerkaddresse
-function check_netip_syntax($IP)
-{
- if($this->CLEAR) { $this->clear_error();}
-
- if ( !($this->check_ip_syntax($IP)) ){
- return false;
- }
- $chunks = explode(".",$IP);
- if ( $chunks[3] != "0" ){
- return false;
- }
- return true;
-}
-
-# MAC Adresse
-function check_mac_syntax($MAC)
-{
- if($this->CLEAR) { $this->clear_error();}
-
- $len = strlen($MAC);
- if( $len != 17 ){
- $this->ERROR = "check_mac_syntax: too long [$MAC][$len]";
- return false;
- }
-
- $badcharacter = eregi_replace("([0-9a-fA-F\:]+)","",$MAC);
- #echo "badcharacter: ".$badcharacter."<br>";
- if(!empty($badcharacter)){
- $this->ERROR = "check_mac_syntax: Bad data in MAC address [$badcharacter]";
- return false;
- }
-
- $chunks = explode(":",$MAC);
- #print_r($chunks)."<br>";
- $count = count($chunks);
- if ($count != 6){
- $this->ERROR = "check_mac_syntax: not in format hx:hx:hx:hx:hx:hx [$MAC]";
- return false;
- }
- foreach ($chunks as $chunk){
- $chunklen = strlen($chunk);
- if( $chunklen != 2 ){
- $this->ERROR = "check_mac_syntax: too long [$MAC][$len]";
- return false;
- }
- }
-
- return true;
-
-}
-
-
-# Domainname
-
-# Hostname
-function is_hostname ($hostname = ""){
-
- if($this->CLEAR) { $this->clear_error(); }
-
- $web = false;
-
- if(empty($hostname))
- {
- $this->ERROR = "is_hostname: No hostname submitted";
- return false;
- }
-
- // Only a-z, 0-9, and "-" or "." are permitted in a hostname
-
- // Patch for POSIX regex lib by Sascha Schumann sas@schell.de
- $Bad = eregi_replace("[-A-Z0-9\.]","",$hostname);
-
- if(!empty($Bad))
- {
- $this->ERROR = "is_hostname: invalid chars [$Bad]";
- return false;
- }
-
- // See if we're doing www.hostname.tld or hostname.tld
- if(eregi("^www\.",$hostname))
- {
- $web = true;
- }
-
- // double "." is a not permitted
- if(ereg("\.\.",$hostname))
- {
- $this->ERROR = "is_hostname: Double dot in [$hostname]";
- return false;
- }
- if(ereg("^\.",$hostname))
- {
- $this->ERROR = "is_hostname: leading dot in [$hostname]";
- return false;
- }
-
- $chunks = explode(".",$hostname);
-
- if( (gettype($chunks)) != "array")
- {
- $this->ERROR = "is_hostname: Invalid hostname, no dot seperator [$hostname]";
- return false;
- }
-
- $count = ( (count($chunks)) - 1);
-
- if($count < 1)
- {
- $this->ERROR = "is_hostname: Invalid hostname [$count] [$hostname]\n";
- return false;
- }
-
- // Bug that can't be killed without doing an is_host,
- // something.something will return TRUE, even if it's something
- // stupid like NS.SOMETHING (with no tld), because SOMETHING is
- // construed to BE the tld. The is_bigfour and is_country
- // checks should help eliminate this inconsistancy. To really
- // be sure you've got a valid hostname, do an is_host() on it.
-
- if( ($web) and ($count < 2) )
- {
- $this->ERROR = "is_hostname: Invalid hostname [$count] [$hostname]\n";
- return false;
- }
-
- $tld = $chunks[$count];
-
- if(empty($tld))
- {
- $this->ERROR = "is_hostname: No TLD found in [$hostname]";
- return false;
- }
-
- if(!$this->is_bigfour($tld))
- {
- if(!$this->is_country($tld))
- {
- $this->ERROR = "is_hostname: Unrecognized TLD [$tld]";
- return false;
- }
- }
-
-
- return true;
-}
-
-
-# Syntax Check für die Eingaben: Uhrzeit, Wochentag, Monatstag, Monatstag.Monat
-function check_timerange_syntax($mcday,$mcbeg,$mcend){
-
- if($this->CLEAR) { $this->clear_error();}
-
- $badcharacter = eregi_replace("([a-z0-9\.]+)","",$mcday);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in MC Day [$badcharacter]";
- return false;
- }
- $badcharacter = eregi_replace("([x0-9]+)","",$mcbeg);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in MC Begin [$badcharacter]";
- return false;
- }
- $badcharacter = eregi_replace("([x0-9]+)","",$mcend);
- if(!empty($badcharacter)){
- $this->ERROR = "check_ip_syntax: Bad data in MC End [$badcharacter]";
- return false;
- }
-
- $lenmcday = strlen($mcday);
- if (eregi("([a-z]+)",$mcday)){
- if ($lenmcday > 2){$this->ERROR = "WOTAG > 2"; return false;}
- if (eregi("([0-9\.]+)",$mcday)){$this->ERROR = "WOTAG enthaelt (0-9.)"; return false;}
- #if (!(eregi("[mdsfx][aiorx]",$mcday))){return false;}
- if (!(eregi("(m[io]|d[io]|s[ao]|fr|x)",$mcday))){$this->ERROR = "WOTAG falscher String"; return false;}
- }
- if (eregi("([0-9]+)",$mcday)){
- if (eregi("[\.]",$mcday)){
- preg_match("/[\.]/",$mcday,$treffer);
- if (count($treffer) > 1){$this->ERROR = "mehr als 2 Punkte"; return false;};
- $exp = explode('.',$mcday);
- $day = $exp[0];
- $lenday = strlen($day);
- if ($lenday > 2){$this->ERROR = "TAG > 2"; return false;}
- if (!(eregi("(0[1-9]|[0-2][0-9]|3[01])",$day))){$this->ERROR = "TAG nicht korrekt"; return false;}
- $month = $exp[1];
- $lenmonth = strlen($month);
- if ($lenmonth > 2){$this->ERROR = "MONAT > 2"; return false;}
- if (!(eregi("(0[0-9]|0[0-9]|1[0-2])",$month))){$this->ERROR = "Monat nicht korrekt"; return false;}
-
- }
- else{
- if ($lenmcday > 2){$this->ERROR = "TAG > 2"; return false;}
- if (!(eregi("(0[0-9]|[0-2][0-9]|3[01])",$mcday))){$this->ERROR = "Tag nicht korrekt"; return false;}
- }
- }
-
- $lenmcbeg = strlen($mcbeg);
- if ($lenmcbeg == 2){
- if (!(eregi("(0[0-9]|1[0-9]|2[0-3]|x)",$mcbeg))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
- if ($lenmcbeg == 1){
- if (!(eregi("([0-9]|x)",$mcbeg))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
- $lenmcend = strlen($mcend);
- if ($lenmcend == 2){
- if (!(eregi("(0[0-9]|1[0-9]|2[0-3]|x)",$mcend))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
- if ($lenmcend == 1){
- if (!(eregi("([0-9]|x)",$mcend))){$this->ERROR = "Uhrzeit nicht korrekt"; return false;}
- }
-
- return true;
-}
-
-
-# Überprüft ob Menuposition ein Zahl ist
-function check_menuposition($menpos){
-
- if($this->CLEAR) { $this->clear_error();}
-
- $badcharacter = eregi_replace("([0-9]+)","",$menpos);
- if(!empty($badcharacter)){
- $this->ERROR = "check_menupostion: Bad data in Menu Position [$badcharacter]";
- return false;
- }
-}
-
-}
-?> \ No newline at end of file
diff --git a/ldap-site-mngmt/webinterface/zwischen.php b/ldap-site-mngmt/webinterface/zwischen.php
deleted file mode 100644
index 21e5137a..00000000
--- a/ldap-site-mngmt/webinterface/zwischen.php
+++ /dev/null
@@ -1,16 +0,0 @@
-<?php
-session_cache_expire(30);
-session_start();
-
-$_SESSION['audn'] = $_GET['audn'];
-
-$rollen_string = $_GET['rollen'];
-$_SESSION['rollen'] = explode('_',$rollen_string);
-
-include('lib/commonlib.inc.php');
-
-$url = "au/au.php";
-$mesg = "";
-redirect(0, $url, $mesg, $addSessionId = TRUE);
-
-?> \ No newline at end of file