Uname:Linux server2.hostofiraq.site 5.15.0-186-generic #196-Ubuntu SMP Sat Jun 20 16:09:34 UTC 2026 x86_64

Base Dir : /home/iscmbt-kufa-atu/public_html

User : iscmbt-kufa-atu


403WebShell
403Webshell
Server IP : 89.117.53.150  /  Your IP : 216.73.216.11
Web Server : Apache
System : Linux server2.hostofiraq.site 5.15.0-186-generic #196-Ubuntu SMP Sat Jun 20 16:09:34 UTC 2026 x86_64
User : iscmbt-kufa-atu ( 1014)
PHP Version : 8.2.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/usermin/ssh/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/share/usermin/ssh/save_auth.cgi
#!/usr/bin/perl
# save_auth.cgi
# Save, create or delete an authorized key

require './ssh-lib.pl';
&ReadParse();
@auths = &list_auths();
if ($in{'new'}) {
	$auth = { 'type' => $in{'type'} };
	}
else {
	$auth = $auths[$in{'idx'}];
	}

if ($in{'delete'}) {
	# Just delete this authorized key
	&delete_auth($auth);
	}
else {
	# Validate inputs
	&error_setup($text{'auth_err'});
	$in{'name'} =~ /^\S+$/ || &error($text{'auth_ename'});
	$auth->{'name'} = $in{'name'};
	if ($auth->{'type'} == 1) {
		$in{'bits'} =~ /^\d+$/ || &error($text{'auth_ebits'});
		$auth->{'bits'} = $in{'bits'};
		$in{'exp'} =~ /^\d+$/ || &error($text{'auth_eexp'});
		$auth->{'exp'} = $in{'exp'};
		}
	else {
		$auth->{'keytype'} = $in{'keytype'};
		}
	$in{'key'} =~ s/\s//g;
	if ($auth->{'type'} == 1) {
		$in{'key'} =~ /^\d+$/ || &error($text{'auth_ekey'});
		}
	else {
		$in{'key'} =~ /^[a-z0-9\+\/=]+$/i || &error($text{'auth_ekey2'});
		}
	$auth->{'key'} = $in{'key'};

	# Validate option inputs
	&parse_options($auth->{'opts'}, \%opts);
	if ($in{'from_def'}) {
		delete($opts{'from'});
		}
	else {
		$opts{'from'} = [ join(",", split(/\s+/, $in{'from'})) ];
		}
	if ($in{'command'}) {
		$opts{'command'} = [ $in{'command'} ];
		}
	else {
		delete($opts{'command'});
		}
	if ($in{'noport'}) { $opts{'no-port-forwarding'} = [ undef ]; }
	else { delete($opts{'no-port-forwarding'}); }
	if ($in{'nox11'}) { $opts{'no-x11-forwarding'} = [ undef ]; }
	else { delete($opts{'no-x11-forwarding'}); }
	if ($in{'noagent'}) { $opts{'no-agent-forwarding'} = [ undef ]; }
	else { delete($opts{'no-agent-forwarding'}); }
	if ($in{'nopty'}) { $opts{'no-pty'} = [ undef ]; }
	else { delete($opts{'no-pty'}); }
	$auth->{'opts'} = &join_options(\%opts);

	# Create or save the authorized key
	if ($in{'new'}) {
		&create_auth($auth);
		}
	else {
		&modify_auth($auth);
		}
	}
&redirect("list_auths.cgi");


Youez - 2016 - github.com/yon3zu
LinuXploit