!C99Shell v. 1.0 pre-release build #13!

Software: Apache/2.0.54 (Unix) mod_perl/1.99_09 Perl/v5.8.0 mod_ssl/2.0.54 OpenSSL/0.9.7l DAV/2 FrontPage/5.0.2.2635 PHP/4.4.0 mod_gzip/2.0.26.1a 

uname -a: Linux snow.he.net 4.4.276-v2-mono-1 #1 SMP Wed Jul 21 11:21:17 PDT 2021 i686 

uid=99(nobody) gid=98(nobody) groups=98(nobody) 

Safe-mode: OFF (not secure)

/usr/local/webmail2/class/deliver/   drwxr-xr-x
Free 318.26 GB of 458.09 GB (69.48%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     Deliver_SendMail.class.php (4.56 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

/**
 * Deliver_SendMail.class.php
 *
 * Delivery backend for the Deliver class.
 *
 * @author Marc Groot Koerkamp
 * @copyright &copy; 1999-2006 The SquirrelMail Project Team
 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
 * @version $Id: Deliver_SendMail.class.php,v 1.26 2006/01/23 18:39:32 tokul Exp $
 * @package squirrelmail
 */

/** @ignore */
if (!defined('SM_PATH')) define('SM_PATH','../../');

/** This of course depends upon Deliver */
require_once(SM_PATH 'class/deliver/Deliver.class.php');

/**
 * Delivers messages using the sendmail binary
 * @package squirrelmail
 */
class Deliver_SendMail extends Deliver {
    
/**
     * Extra sendmail arguments
     *
     * Parameter can be set in class constructor function.
     *
     * WARNING: Introduction of this parameter broke backwards compatibility 
     * with workarounds specific to qmail-inject.
     *
     * If parameter needs some security modifications, it should be set to 
     * private in PHP 5+ in order to prevent uncontrolled access.
     * @var string
     * @since 1.5.1
     */
    
var $sendmail_args '-i -t';

    
/**
     * Stores used sendmail command
     * Private variable that is used to inform about used sendmail command.
     * @var string
     * @since 1.5.1
     */
    
var $sendmail_command '';

    
/**
     * Constructor function
     * @param array configuration options. array key = option name, 
     * array value = option value.
     * @return void
     * @since 1.5.1
     */
    
function Deliver_SendMail($params=array()) {
        if (!empty(
$params) && is_array($params)) {
            
// set extra sendmail arguments
            
if (isset($params['sendmail_args'])) {
                
$this->sendmail_args $params['sendmail_args'];
            }
        }
    }

   
/**
    * function preWriteToStream
    *
    * Sendmail needs LF's as line endings instead of CRLF.
    * This function translates the line endings to LF and should be called
    * before each line is written to the stream.
    *
    * @param string $s Line to process
    * @return void
    * @access private
    */
    
function preWriteToStream(&$s) {
       if (
$s) {
           
$s str_replace("\r\n""\n"$s);
       }
    }

   
/**
    * function initStream
    *
    * Initialise the sendmail connection.
    *
    * @param Message $message Message object containing the from address
    * @param string $sendmail_path Location of sendmail binary
    * @return resource
    * @access public
    */
    
function initStream($message$sendmail_path) {
        
$rfc822_header $message->rfc822_header;
        
$from $rfc822_header->from[0];
        
$envelopefrom trim($from->mailbox.'@'.$from->host);
        
$envelopefrom str_replace(array("\0","\n"),array('',''),$envelopefrom);
        
// save executed command for future reference
        
$this->sendmail_command "$sendmail_path $this->sendmail_args -f$envelopefrom";
        
// open process handle for writing
        
$stream popen (escapeshellcmd($this->sendmail_command), "w");
        return 
$stream;
    }

   
/**
    * Closes process handle.
    *
    * @param resource $stream
    * @return boolean
    * @access public
    */
    
function finalizeStream($stream) {
        
$ret true;
        
$status pclose($stream);
        
// check pclose() status.
        
if ($status!=0) {
            
$ret false;
            
$this->dlv_msg=_("Email delivery error");
            
$this->dlv_ret_nr=$status;
            
// we can get better error messsage only if we switch to php 4.3+ and proc_open().
            
$this->dlv_server_msg=sprintf(_("Can't execute command '%s'."),$this->sendmail_command);
        }
        return 
$ret;
    }

   
/**
    * function getBcc
    *
    * In case of sendmail, the rfc822header must contain the bcc header.
    *
    * @return boolean true if rfc822header should include the bcc header.
    * @access private
    */
    
function getBcc() {
       return 
true;
    }

   
/**
    * function clean_crlf
    *
    * Cleans each line to only end in a LF
    * Returns the length of the line including a CR,
    * so that length is correct when the message is saved to imap
    * Implemented to fix sendmail->postfix rejection of messages with
    * attachments because of stray LF's
    *
    * @param string $s string to strip of CR's
    * @return integer length of string including a CR for each LF
    * @access private
    */
    
function clean_crlf(&$s) {
        
$s str_replace("\r\n""\n"$s);
        
$s str_replace("\r""\n"$s);
        
$s2 str_replace("\n""\r\n"$s);
        return 
strlen($s2);
    }


}
?>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 1.0 pre-release build #13 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0045 ]--