Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64
Apache
: 172.26.7.228 | : 3.14.249.191
Cant Read [ /etc/named.conf ]
5.6.40-24+ubuntu18.04.1+deb.sury.org+1
www-data
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
HASH IDENTIFIER
README
+ Create Folder
+ Create File
/
usr /
share /
perl5 /
Mail /
[ HOME SHELL ]
Name
Size
Permission
Action
Field
[ DIR ]
drwxr-xr-x
Mailer
[ DIR ]
drwxr-xr-x
Address.pm
6.66
KB
-rw-r--r--
Address.pod
3.71
KB
-rw-r--r--
Cap.pm
6.17
KB
-rw-r--r--
Cap.pod
3.74
KB
-rw-r--r--
Field.pm
4.68
KB
-rw-r--r--
Field.pod
4.9
KB
-rw-r--r--
Filter.pm
1.23
KB
-rw-r--r--
Filter.pod
2.79
KB
-rw-r--r--
Header.pm
14.02
KB
-rw-r--r--
Header.pod
7.72
KB
-rw-r--r--
Internet.pm
12
KB
-rw-r--r--
Internet.pod
10.31
KB
-rw-r--r--
Mailer.pm
4.73
KB
-rw-r--r--
Mailer.pod
3.88
KB
-rw-r--r--
Send.pm
1.13
KB
-rw-r--r--
Send.pod
2.8
KB
-rw-r--r--
Util.pm
3.14
KB
-rw-r--r--
Util.pod
3.08
KB
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : Cap.pm
# Copyrights 1995-2016 by [Mark Overmeer <perl@overmeer.net>]. # For other contributors see ChangeLog. # See the manual pages for details on the licensing terms. # Pod stripped from pm file by OODoc 2.02. package Mail::Cap; use vars '$VERSION'; $VERSION = '2.18'; use strict; sub Version { our $VERSION } our $useCache = 1; # don't evaluate tests every time my @path; if($^O eq "MacOS") { @path = split /\,/, $ENV{MAILCAPS} || "$ENV{HOME}mailcap"; } else { @path = split /\:/ , ( $ENV{MAILCAPS} || (defined $ENV{HOME} ? "$ENV{HOME}/.mailcap:" : '') . '/etc/mailcap:/usr/etc/mailcap:/usr/local/etc/mailcap' ); # this path is specified under RFC1524 appendix A } sub new { my $class = shift; unshift @_, 'filename' if @_ % 2; my %args = @_; my $take_all = $args{take} && uc $args{take} eq 'ALL'; my $self = bless {_count => 0}, $class; $self->_process_file($args{filename}) if defined $args{filename} && -r $args{filename}; if(!defined $args{filename} || $take_all) { foreach my $fname (@path) { -r $fname or next; $self->_process_file($fname); last unless $take_all; } } unless($self->{_count}) { # Set up default mailcap $self->{'audio/*'} = [{'view' => "showaudio %s"}]; $self->{'image/*'} = [{'view' => "xv %s"}]; $self->{'message/rfc822'} = [{'view' => "xterm -e metamail %s"}]; } $self; } sub _process_file { my $self = shift; my $file = shift or return; local *MAILCAP; open MAILCAP, $file or return; $self->{_file} = $file; local $_; while(<MAILCAP>) { next if /^\s*#/; # comment next if /^\s*$/; # blank line $_ .= <MAILCAP> # continuation line while s/(^|[^\\])((?:\\\\)*)\\\s*$/$1$2/; chomp; s/\0//g; # ensure no NULs in the line s/(^|[^\\]);/$1\0/g; # make field separator NUL my ($type, $view, @parts) = split /\s*\0\s*/; $type .= "/*" if $type !~ m[/]; $view =~ s/\\;/;/g; $view =~ s/\\\\/\\/g; my %field = (view => $view); foreach (@parts) { my($key, $val) = split /\s*\=\s*/, $_, 2; if(defined $val) { $val =~ s/\\;/;/g; $val =~ s/\\\\/\\/g; $field{$key} = $val; } else { $field{$key} = 1; } } if(my $test = $field{test}) { unless ($test =~ /\%/) { # No parameters in test, can perform it right away system $test; next if $?; } } # record this entry unless(exists $self->{$type}) { $self->{$type} = []; $self->{_count}++; } push @{$self->{$type}}, \%field; } close MAILCAP; } sub view { my $self = shift; $self->_run($self->viewCmd(@_)) } sub compose { my $self = shift; $self->_run($self->composeCmd(@_)) } sub edit { my $self = shift; $self->_run($self->editCmd(@_)) } sub print { my $self = shift; $self->_run($self->printCmd(@_)) } sub _run($) { my ($self, $cmd) = @_; defined $cmd or return 0; system $cmd; 1; } sub viewCmd { shift->_createCommand(view => @_) } sub composeCmd { shift->_createCommand(compose => @_) } sub editCmd { shift->_createCommand(edit => @_) } sub printCmd { shift->_createCommand(print => @_) } sub _createCommand($$$) { my ($self, $method, $type, $file) = @_; my $entry = $self->getEntry($type, $file); $entry && exists $entry->{$method} or return undef; $self->expandPercentMacros($entry->{$method}, $type, $file); } sub makeName($$) { my ($self, $type, $basename) = @_; my $template = $self->nametemplate($type) or return $basename; $template =~ s/%s/$basename/g; $template; } sub field($$) { my($self, $type, $field) = @_; my $entry = $self->getEntry($type); $entry->{$field}; } sub description { shift->field(shift, 'description'); } sub textualnewlines { shift->field(shift, 'textualnewlines'); } sub x11_bitmap { shift->field(shift, 'x11-bitmap'); } sub nametemplate { shift->field(shift, 'nametemplate'); } sub getEntry { my($self, $origtype, $file) = @_; return $self->{_cache}{$origtype} if $useCache && exists $self->{_cache}{$origtype}; my ($fulltype, @params) = split /\s*;\s*/, $origtype; my ($type, $subtype) = split m[/], $fulltype, 2; $subtype ||= ''; my $entry; foreach (@{$self->{"$type/$subtype"}}, @{$self->{"$type/*"}}) { if(exists $_->{'test'}) { # must run test to see if it applies my $test = $self->expandPercentMacros($_->{'test'}, $origtype, $file); system $test; next if $?; } $entry = { %$_ }; # make copy last; } $self->{_cache}{$origtype} = $entry if $useCache; $entry; } sub expandPercentMacros { my ($self, $text, $type, $file) = @_; defined $type or return $text; defined $file or $file = ""; my ($fulltype, @params) = split /\s*;\s*/, $type; ($type, my $subtype) = split m[/], $fulltype, 2; my %params; foreach (@params) { my($key, $val) = split /\s*=\s*/, $_, 2; $params{$key} = $val; } $text =~ s/\\%/\0/g; # hide all escaped %'s $text =~ s/%t/$fulltype/g; # expand %t $text =~ s/%s/$file/g; # expand %s { # expand %{field} local $^W = 0; # avoid warnings when expanding %params $text =~ s/%\{\s*(.*?)\s*\}/$params{$1}/g; } $text =~ s/\0/%/g; $text; } # This following procedures can be useful for debugging purposes sub dumpEntry { my($hash, $prefix) = @_; defined $prefix or $prefix = ""; print "$prefix$_ = $hash->{$_}\n" for sort keys %$hash; } sub dump { my $self = shift; foreach (keys %$self) { next if /^_/; print "$_\n"; foreach (@{$self->{$_}}) { dumpEntry($_, "\t"); print "\n"; } } if(exists $self->{_cache}) { print "Cached types\n"; print "\t$_\n" for keys %{$self->{_cache}}; } } 1;
Close