X7ROOT File Manager
Current Path:
/usr/libexec/webmin/lpadmin
usr
/
libexec
/
webmin
/
lpadmin
/
📁
..
📄
CHANGELOG
(1.16 KB)
📄
acl_security.pl
(4.4 KB)
📄
aix-lib.pl
(9.45 KB)
📄
ascii.txt
(4.19 KB)
📄
base_coas_driver
(560 B)
📄
bw.fig
(2.75 KB)
📄
bw.ps
(6.46 KB)
📄
caldera-driver.pl
(12.31 KB)
📄
cancel_all.cgi
(535 B)
📄
catalog.devices
(12.34 KB)
📄
cgi_args.pl
(284 B)
📄
cluster.cgi
(2.06 KB)
📄
cluster_add.cgi
(2.13 KB)
📄
cluster_delete.cgi
(529 B)
📄
colour.fig
(2.91 KB)
📄
colour.ps
(6.63 KB)
📄
config-AlmaLinux-7.0-ALL
(323 B)
📄
config-Amazon-Linux-2-ALL
(323 B)
📄
config-CentOS-Linux-7.0-ALL
(323 B)
📄
config-CentOS-Stream-Linux-8.0-ALL
(323 B)
📄
config-Oracle-Linux-8.0-ALL
(323 B)
📄
config-Redhat-Enterprise-Linux-7.0-ALL
(323 B)
📄
config-Rocky-Linux-7.0-ALL
(323 B)
📄
config-Scientific-Linux-7.0-ALL
(323 B)
📄
config-aix
(281 B)
📄
config-coherent-linux
(323 B)
📄
config-corel-linux
(228 B)
📄
config-debian-linux
(228 B)
📄
config-debian-linux-3.1-3.9
(327 B)
📄
config-debian-linux-4.0-ALL
(333 B)
📄
config-freebsd
(230 B)
📄
config-generic-linux
(228 B)
📄
config-gentoo-linux
(248 B)
📄
config-hpux
(323 B)
📄
config-irix
(213 B)
📄
config-macos
(230 B)
📄
config-mandrake-linux
(245 B)
📄
config-mandrake-linux-8.0-ALL
(276 B)
📄
config-msc-linux
(228 B)
📄
config-netbsd
(230 B)
📄
config-open-linux
(309 B)
📄
config-open-linux-3.1e
(239 B)
📄
config-openbsd
(230 B)
📄
config-openmamba-linux
(229 B)
📄
config-pardus-linux
(228 B)
📄
config-redhat-linux
(228 B)
📄
config-redhat-linux-24.0-ALL
(339 B)
📄
config-redhat-linux-7.0
(283 B)
📄
config-redhat-linux-7.1
(286 B)
📄
config-redhat-linux-7.2-8.1
(394 B)
📄
config-redhat-linux-9.0-23.0
(337 B)
📄
config-slackware-linux
(228 B)
📄
config-slackware-linux-8.1-ALL
(246 B)
📄
config-solaris
(304 B)
📄
config-solaris-10-ALL
(330 B)
📄
config-solaris-9
(296 B)
📄
config-suse-linux
(226 B)
📄
config-suse-linux-8.2-ALL
(322 B)
📄
config-trustix-linux
(313 B)
📄
config-turbo-linux
(228 B)
📄
config-united-linux
(322 B)
📄
config-unixware
(302 B)
📄
config.info
(1.31 KB)
📄
config.info.ca
(1.53 KB)
📄
config.info.cs
(1.25 KB)
📄
config.info.de
(1.43 KB)
📄
config.info.es
(1.17 KB)
📄
config.info.fr
(1.63 KB)
📄
config.info.hu
(707 B)
📄
config.info.ja
(823 B)
📄
config.info.nl
(1.41 KB)
📄
config.info.no
(1.37 KB)
📄
config.info.pl
(1.45 KB)
📄
config.info.pt_BR
(1.58 KB)
📄
config.info.ru
(1.74 KB)
📄
config.info.sv
(651 B)
📄
config.info.tr
(1.39 KB)
📄
config.info.uk
(1.81 KB)
📄
config.info.zh
(573 B)
📄
config.info.zh_TW
(539 B)
📄
cups-driver.pl
(6.37 KB)
📄
cups-lib.pl
(8.67 KB)
📄
defaultacl
(73 B)
📄
delete_printer.cgi
(690 B)
📄
delete_printers.cgi
(839 B)
📄
drivers
(18.34 KB)
📄
edit_printer.cgi
(10.08 KB)
📄
freebsd-lib.pl
(7.26 KB)
📄
hpux-driver.pl
(3.13 KB)
📄
hpux-lib.pl
(9.83 KB)
📁
images
📄
index.cgi
(5.83 KB)
📄
irix-driver.pl
(3.13 KB)
📄
irix-lib.pl
(10.68 KB)
📁
lang
📄
linux-lib.pl
(8.97 KB)
📄
list_jobs.cgi
(2.25 KB)
📄
log_parser.pl
(1021 B)
📄
lpadmin-lib.pl
(19.89 KB)
📄
lprng-lib.pl
(10.26 KB)
📄
module.info
(494 B)
📄
module.info.af
(0 B)
📄
module.info.af.auto
(159 B)
📄
module.info.ar
(0 B)
📄
module.info.ar.auto
(223 B)
📄
module.info.be
(0 B)
📄
module.info.be.auto
(290 B)
📄
module.info.bg
(0 B)
📄
module.info.bg.auto
(306 B)
📄
module.info.ca
(167 B)
📄
module.info.ca.auto
(16 B)
📄
module.info.cs
(31 B)
📄
module.info.cs.auto
(155 B)
📄
module.info.da
(0 B)
📄
module.info.da.auto
(168 B)
📄
module.info.de
(148 B)
📄
module.info.de.auto
(16 B)
📄
module.info.el
(0 B)
📄
module.info.el.auto
(362 B)
📄
module.info.es
(38 B)
📄
module.info.es.auto
(157 B)
📄
module.info.eu
(0 B)
📄
module.info.eu.auto
(217 B)
📄
module.info.fa
(0 B)
📄
module.info.fa.auto
(246 B)
📄
module.info.fi
(0 B)
📄
module.info.fi.auto
(168 B)
📄
module.info.fr
(39 B)
📄
module.info.fr.auto
(176 B)
📄
module.info.he
(0 B)
📄
module.info.he.auto
(205 B)
📄
module.info.hr
(0 B)
📄
module.info.hr.auto
(188 B)
📄
module.info.hu
(19 B)
📄
module.info.hu.auto
(173 B)
📄
module.info.it
(0 B)
📄
module.info.it.auto
(177 B)
📄
module.info.ja
(27 B)
📄
module.info.ja.auto
(213 B)
📄
module.info.ko
(25 B)
📄
module.info.ko.auto
(176 B)
📄
module.info.lt
(0 B)
📄
module.info.lt.auto
(219 B)
📄
module.info.lv
(0 B)
📄
module.info.lv.auto
(189 B)
📄
module.info.ms
(152 B)
📄
module.info.ms.auto
(16 B)
📄
module.info.mt
(0 B)
📄
module.info.mt.auto
(196 B)
📄
module.info.nl
(33 B)
📄
module.info.nl.auto
(133 B)
📄
module.info.no
(31 B)
📄
module.info.no.auto
(137 B)
📄
module.info.pl
(160 B)
📄
module.info.pl.auto
(16 B)
📄
module.info.pt
(39 B)
📄
module.info.pt.auto
(149 B)
📄
module.info.pt_BR
(42 B)
📄
module.info.pt_BR.auto
(155 B)
📄
module.info.ro
(0 B)
📄
module.info.ro.auto
(199 B)
📄
module.info.ru
(25 B)
📄
module.info.ru.auto
(245 B)
📄
module.info.sk
(0 B)
📄
module.info.sk.auto
(184 B)
📄
module.info.sl
(0 B)
📄
module.info.sl.auto
(192 B)
📄
module.info.sv
(30 B)
📄
module.info.sv.auto
(141 B)
📄
module.info.th
(0 B)
📄
module.info.th.auto
(393 B)
📄
module.info.tr
(27 B)
📄
module.info.tr.auto
(166 B)
📄
module.info.uk
(0 B)
📄
module.info.uk.auto
(281 B)
📄
module.info.ur
(0 B)
📄
module.info.ur.auto
(304 B)
📄
module.info.vi
(0 B)
📄
module.info.vi.auto
(189 B)
📄
module.info.zh
(24 B)
📄
module.info.zh.auto
(136 B)
📄
module.info.zh_TW
(30 B)
📄
module.info.zh_TW.auto
(142 B)
📄
old-caldera-driver.pl
(9.74 KB)
📄
openbsd-lib.pl
(7.26 KB)
📄
prefs.info
(40 B)
📄
printconf-driver.pl
(9.52 KB)
📄
rbac-mapping
(248 B)
📄
redhat-driver.pl
(12.42 KB)
📄
restart.cgi
(301 B)
📄
save_printer.cgi
(5.85 KB)
📄
solaris-driver.pl
(4.03 KB)
📄
solaris-lib.pl
(12.17 KB)
📄
sortdrivers-by-drv.pl
(222 B)
📄
sortdrivers.pl
(242 B)
📄
start.cgi
(377 B)
📄
stop.cgi
(374 B)
📄
stp
(2.45 KB)
📄
suse-driver.pl
(10.62 KB)
📄
test_form.cgi
(887 B)
📄
test_print.cgi
(1.19 KB)
📄
unixware-lib.pl
(7.81 KB)
📄
view_job.cgi
(909 B)
📄
webmin-driver.pl
(1.04 KB)
Editing: edit_printer.cgi
#!/usr/bin/perl # edit_printer.cgi # Edit or create a printer require './lpadmin-lib.pl'; &ReadParse(); if ($in{'new'}) { $access{'add'} || &error($text{'edit_eadd'}); &ui_print_header(undef, $text{'edit_add'}, ""); $prn{'accepting'}++; $prn{'enabled'}++; $prn{'allow_all'}++; $prn{'dev'} = $device_files[0]; $prn{'ctype'} = [ "postscript" ]; } else { &can_edit_printer($in{'name'}) || &error($text{'edit_eedit'}); &ui_print_header(undef, $text{'edit_edit'}, ""); local $prn = &get_printer($in{'name'}); $prn || &error(&text('save_egone', $in{'name'})); %prn = %$prn; } print "<form action=save_printer.cgi method=post>\n"; print "<table border width=100%>\n"; print "<tr $tb> <td><b>$text{'edit_conf'}</b></td> </tr>\n"; print "<tr $cb> <td><table width=100%>\n"; print "<tr> <td><b>$text{'edit_name'}</b></td>\n"; if ($in{'new'}) { print "<td><input name=name size=15></td>\n"; print "<input type=hidden name=new value=1>\n"; } else { print "<td>$prn{'name'}</td>\n"; print "<input type=hidden name=name value=\"$prn{'name'}\">\n"; } print "<td align=right><b>$text{'edit_acc'}</b></td>\n"; printf "<td><input type=radio name=accepting value=1 %s> $text{'yes'}\n", $prn{'accepting'} ? "checked" : ""; if (&printer_support('why')) { printf "<input type=radio name=accepting value=0 %s> %s\n", $prn{'accepting'} ? "" : "checked", $text{'edit_why'}; printf "<input name=accepting_why size=15 value=\"%s\"></td> </tr>\n", $prn{'accepting_why'}; } else { printf "<input type=radio name=accepting value=0 %s> $text{'no'}\n", $prn{'accepting'} ? "" : "checked"; } if (&printer_support('desc')) { print "<tr> <td><b>$text{'edit_desc'}</b></td>\n"; print "<td><input name=desc size=20 value=\"", &html_escape($prn{'desc'}),"\"></td>\n"; } else { print "<tr> <td colspan=2></td>\n"; } print "<td align=right><b>$text{'edit_ena'}</b></td>\n"; printf "<td><input type=radio name=enabled value=1 %s> $text{'yes'}\n", $prn{'enabled'} ? "checked" : ""; if (&printer_support('why')) { printf "<input type=radio name=enabled value=0 %s> %s\n", $prn{'enabled'} ? "" : "checked", $text{'edit_why'}; printf "<input name=enabled_why size=15 value=\"%s\"></td> </tr>\n", $prn{'enabled_why'}; } else { printf "<input type=radio name=enabled value=0 %s> $text{'no'}\n", $prn{'enabled'} ? "" : "checked"; } if (&printer_support('allow')) { print "<tr> <td valign=top><b>$text{'edit_acl'}</b></td>\n"; print "<td colspan=3><table><tr><td valign=top>\n"; printf "<input type=radio name=access value=0 %s> %s<br>\n", $prn{'allow_all'} ? "checked" : "", $text{'edit_allow'}; printf "<input type=radio name=access value=1 %s> %s<br>\n", $prn{'deny_all'} ? "checked" : "", $text{'edit_deny'}; printf "<input type=radio name=access value=2 %s> %s<br>\n", $prn{'allow'} ? "checked" : "", $text{'edit_allowu'}; printf "<input type=radio name=access value=3 %s> %s\n", $prn{'deny'} ? "checked" : "", $text{'edit_denyu'}; print "</td> <td valign=top>\n"; print "<textarea wrap=auto name=users rows=5 cols=30>", join(" ", (@{$prn{'allow'}}, @{$prn{'deny'}})), "</textarea></td>\n"; print "<td valign=top>",&user_chooser_button("users",1),"</td>\n"; print "</tr></table></td> </tr>\n"; } if (&printer_support('banner')) { print "<tr> <td valign=top><b>$text{'edit_banner'}</b></td> ", "<td valign=top>\n"; printf "<input type=radio name=prbanner value=1 %s> $text{'yes'}\n", $prn{'banner'} ? "checked" : ""; printf "<input type=radio name=prbanner value=0 %s> %s</td>\n", $prn{'banner'} ? "" : "checked", $text{'edit_opt'}; } else { print "<tr>\n"; } if (&printer_support('default')) { print "<td align=right><b>$text{'edit_default'}</b></td> <td>\n"; if (!$prn{'default'}) { printf "<input type=radio name=default value=1 %s> $text{'yes'}\n", $prn{'default'} ? "checked" : ""; printf "<input type=radio name=default value=0 %s> $text{'no'}</td></tr>\n", $prn{'default'} ? "" : "checked"; } else { print "<i>$text{'edit_already'}</i> </td> </tr>\n"; } } elsif (&printer_support('msize')) { print "<td align=right><b>$text{'edit_max'}</b></td> <td>\n"; printf "<input type=radio name=msize_def value=1 %s> %s\n", defined($prn{'msize'}) ? "" : "checked", $text{'default'}; printf "<input type=radio name=msize_def value=2 %s> %s\n", $prn{'msize'} eq '0' ? "checked" : "", $text{'edit_unlimited'}; printf "<input type=radio name=msize_def value=0 %s>\n", $prn{'msize'} ? "checked" : ""; printf "<input name=msize size=6 value=\"%s\"> %s</td> </tr>\n", $prn{'msize'} ? $prn{'msize'} : "", $text{'blocks'}; } else { print "<td colspan=2></tr>\n"; } if (&printer_support('ctype')) { @ctype = @{$prn{'ctype'}}; print "<tr> <td><b>$text{'edit_dacc'}</b></td> <td colspan=3>\n"; printf "<input type=checkbox name=ctype_simple %s> %s \n", &indexof("simple", @ctype) < 0 ? "" : "checked", $text{'edit_dtext'}; printf "<input type=checkbox name=ctype_postscript %s> %s \n", &indexof("postscript", @ctype) < 0 ? "" : "checked", $text{'edit_dpost'}; @ctypeo = grep { !/^(simple|postscript)$/ } @ctype; printf "<input type=checkbox name=ctype_other %s> %s\n", @ctypeo ? "checked" : "", $text{'edit_dother'}; printf "<input name=ctype_olist size=20 value=\"%s\">\n", join(' ', @ctypeo); print "</td> </tr>\n"; } if (&printer_support('alias')) { @alias = @{$prn{'alias'}}; print "<tr> <td><b>$text{'edit_alt'}</b></td> <td colspan=3>\n"; printf "<input name=alias size=40 value=\"%s\"></td> </tr>\n", join(' ', @alias); } print "</table></td></tr></table><p>\n"; if ($in{'new'} || &printer_support('editdest')) { print "<table border width=100%>\n"; print "<tr $tb> <td><b>$text{'edit_dest'}</b></td> </tr>\n"; print "<tr $cb> <td><table>\n"; $isdev = &indexof($prn{'dev'}, @device_files) >= 0; if (!$webmin_windows_driver) { $wdrv = &is_webmin_windows_driver($prn{'iface'}, \%prn); $webmin++ if ($wdrv); } $wdrv = &is_windows_driver($prn{'iface'}, \%prn) if (!$wdrv); $hdrv = &is_hpnp_driver($prn{'iface'}, \%prn); if ($wdrv) { $prn{'iface'} = $wdrv->{'program'}; } elsif ($hdrv) { $prn{'iface'} = $hdrv->{'program'}; } printf "<tr> <td><input type=radio name=dest value=0 %s> %s</td>\n", $prn{'dev'} && $isdev && !$wdrv && !$hdrv ? "checked" : "", $text{'edit_dev'}; print "<td><select name=dev>\n"; for($i=0; $i<@device_files; $i++) { $d = $device_files[$i]; printf "<option value=\"$d\" %s>$device_names[$i]\n", $d eq $prn{'dev'} ? "selected" : ""; } print "</select></td> </tr>\n"; printf "<tr> <td><input type=radio name=dest value=1 %s> %s</td>\n", $prn{'dev'} && !$isdev && !$wdrv && !$hdrv ? "checked" : "", $text{'edit_file'}; printf "<td><input name=file size=25 value=\"%s\"></td> </tr>\n", $isdev || $wdrv || $hdrv ? "" : $prn{'dev'}; printf "<tr> <td><input type=radio name=dest value=2 %s>\n", $prn{'rhost'} ? "checked" : ""; print "$text{'edit_remote'}</td>\n"; print "<td><input name=rhost size=25 value=\"$prn{'rhost'}\"></td>\n"; print "<td>$text{'edit_rqueue'} ", "<input name=rqueue size=15 value=\"$prn{'rqueue'}\">\n"; if (defined(&remote_printer_types)) { @rtypes = &remote_printer_types(); } elsif (&printer_support('sysv')) { @rtypes = ( [ 'bsd', 'BSD' ], [ 's5', 'SysV' ] ); } elsif (&printer_support('ipp')) { @rtypes = ( [ 'bsd', 'BSD' ], [ 'ipp', 'IPP' ] ); } if (@rtypes) { print "$text{'edit_type'} <select name=rtype>\n"; foreach $t (@rtypes) { printf "<option value=%s %s>%s\n", $t->[0], $prn{'rtype'} eq $t->[0] ? "selected" : "", $t->[1]; } print "</select>\n"; } print "</td> </tr>\n"; if (&printer_support("direct")) { printf "<tr> <td><input type=radio name=dest value=5 %s>\n", $prn{'dhost'} ? "checked" : ""; print "$text{'edit_direct'}</td>\n"; print "<td><input name=dhost size=25 ", "value=\"$prn{'dhost'}\"></td>\n"; print "<td>$text{'edit_dport'} ", "<input name=dport size=5 value=\"$prn{'dport'}\">\n"; print "</td> </tr>\n"; } if (&has_smbclient()) { printf "<tr> <td><input type=radio name=dest value=3 %s>\n", $wdrv ? "checked" : ""; printf "$text{'edit_smb'}</td> ". "<td><input name=server size=25 value=\"%s\"></td>\n", $wdrv->{'server'}; printf "<td>$text{'edit_share'} ". "<input name=share size=15 value=\"%s\"></td>\n", $wdrv->{'share'}; print "</tr><tr> <td align=right>$text{'edit_user'}</td>\n"; printf "<td colspan=2><input name=suser size=10 value='%s'>\n", $wdrv->{'user'}; printf "$text{'edit_pass'} ". "<input type=password name=spass size=10 value='%s'>\n", $wdrv->{'pass'}; printf "$text{'edit_wgroup'} ". "<input name=wgroup size=10 value=\"%s\">\n", $wdrv->{'workgroup'}; print "</td> </tr>\n"; } if (&has_hpnp()) { printf "<tr> <td><input type=radio name=dest value=4 %s>\n", $hdrv ? "checked" : ""; print "$text{'edit_hpnp'}</td>\n"; printf "<td><input name=hpnp size=25 value=\"%s\"></td>\n", $hdrv->{'server'}; printf "<td>$text{'edit_port'} ". "<input name=port size=15 value=\"%s\"></td> </tr>\n", $hdrv->{'port'}; } print "<tr> <td> ", "<input type=checkbox name=check value=1> ", "$text{'edit_check'}</td> </tr>\n"; print "</table></td></tr></table><p>\n"; print "<table border width=100%>\n"; print "<tr $tb> <td><b>$text{'edit_driver'}</b></td> </tr>\n"; print "<tr $cb> <td><table width=100%>\n"; if (!$webmin_print_driver) { $drv = &is_webmin_driver($prn{'iface'}, \%prn); } if ($drv->{'mode'} != 0 && $drv->{'mode'} != 2 || $webmin) { $webmin++; $after = &webmin_driver_input(\%prn, $drv); } else { $drv = &is_driver($prn{'iface'}, \%prn); $after = &driver_input(\%prn, $drv); } print "</table></td></tr></table><p>\n"; } print "<input type=hidden name=webmin value=\"$webmin\">\n"; if ($in{'new'}) { print "<input type=submit value=\"$text{'create'}\"><p>\n"; } else { print "<table width=100%><tr>\n"; print "<td><input type=submit value=\"$text{'save'}\"></td>\n"; if ($access{'delete'}) { print "<td align=right><input type=submit name=delete ", "value=\"$text{'delete'}\"></td>\n"; } print "</tr></table>\n"; } print "</form>\n"; print $after; &ui_print_footer("", $text{'index_return'});
Upload File
Create Folder