!C99Shell v.2.1 [PHP 7 Update] [1.12.2019]!

Software: Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/5.4.16. PHP/5.4.16 

uname -a: Linux roko-bkp 3.10.0-1160.102.1.el7.x86_64 #1 SMP Tue Oct 17 15:42:21 UTC 2023 x86_64 

uid=48(apache) gid=48(apache) groups=48(apache),1003(webmaster) 

Safe-mode: OFF (not secure)

/var/www/html/admin/webmail/program/steps/addressbook/   drwxr-xr-x
Free 9.19 GB of 93.48 GB (9.83%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     save.inc (4.21 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

/*
 +-----------------------------------------------------------------------+
 | program/steps/addressbook/save.inc                                    |
 |                                                                       |
 | This file is part of the RoundCube Webmail client                     |
 | Copyright (C) 2005-2009, RoundCube Dev. - Switzerland                 |
 | Licensed under the GNU GPL                                            |
 |                                                                       |
 | PURPOSE:                                                              |
 |   Save a contact entry or to add a new one                            |
 |                                                                       |
 +-----------------------------------------------------------------------+
 | Author: Thomas Bruederli <roundcube@gmail.com>                        |
 +-----------------------------------------------------------------------+

 $Id: save.inc 2889 2009-08-29 18:41:17Z alec $

*/

$cid get_input_value('_cid'RCUBE_INPUT_POST);
$return_action = empty($cid) ? 'add' 'show';

// cannot edit record
if ($CONTACTS->readonly)
{
  
$OUTPUT->show_message('contactreadonly''error');
  
rcmail_overwrite_action($return_action);
  return;
}

// check input
if ((!get_input_value('_name'RCUBE_INPUT_POST) || !get_input_value('_email'RCUBE_INPUT_POST)))
{
  
$OUTPUT->show_message('formincomplete''warning');
  
rcmail_overwrite_action($return_action);
  return;
}


// setup some vars we need
$a_save_cols = array('name''firstname''surname''email');
$a_record = array();

// read POST values into hash array
foreach ($a_save_cols as $col)
{
  
$fname '_'.$col;
  if (isset(
$_POST[$fname]))
    
$a_record[$col] = get_input_value($fnameRCUBE_INPUT_POST);
}

// update an existing contact
if (!empty($cid))
{
  
$plugin $RCMAIL->plugins->exec_hook('save_contact', array('id' => $cid'record' => $a_record'source' => get_input_value('_source'RCUBE_INPUT_GPC)));
  
$a_record $plugin['record'];
  
  if (!
$plugin['abort'] && ($result $CONTACTS->update($cid$a_record)))
  {
    
// LDAP DN change
    
if (is_string($result) && strlen($result)>1) {
      
$newcid $result;
      
// change cid in POST for 'show' action
      
$_POST['_cid'] = $newcid;
    }
    
    
// define list of cols to be displayed
    
$a_js_cols = array();
    
$record $CONTACTS->get_record($newcid $newcid $cidtrue);

    foreach (array(
'name''email') as $col)
      
$a_js_cols[] = (string)$record[$col];

    
// update the changed col in list
    
$OUTPUT->command('parent.update_contact_row'$cid$a_js_cols$newcid);
      
    
// show confirmation
    
$OUTPUT->show_message('successfullysaved''confirmation'nullfalse);
    
rcmail_overwrite_action('show');
  }
  else
  {
    
// show error message
    
$OUTPUT->show_message('errorsaving''error'nullfalse);
    
rcmail_overwrite_action('show');
  }
}

// insert a new contact
else
{
  
// check for existing contacts
  
$existing $CONTACTS->search('email'$a_record['email'], truefalse);
  
  
// show warning message
  
if ($existing->count)
  {
    
$OUTPUT->show_message('contactexists''warning'nullfalse);
    
rcmail_overwrite_action('add');
    return;
  }

  
$plugin $RCMAIL->plugins->exec_hook('create_contact', array('record' => $a_record'source' => get_input_value('_source'RCUBE_INPUT_GPC)));
  
$a_record $plugin['record'];

  
// insert record and send response
  
if (!$plugin['abort'] && ($insert_id $CONTACTS->insert($a_record)))
  {
    
// add contact row or jump to the page where it should appear
    
$CONTACTS->reset();
    
$result $CONTACTS->search($CONTACTS->primary_key$insert_id);

    
rcmail_js_contacts_list($result'parent.');
    
$OUTPUT->command('parent.contact_list.select'$insert_id);

    
// update record count display
    
$CONTACTS->reset();
    
$OUTPUT->command('parent.set_rowcount'rcmail_get_rowcount_text());

    
// show confirmation
    
$OUTPUT->show_message('successfullysaved''confirmation'nullfalse);
    
rcmail_overwrite_action('show');
    
$_GET['_cid'] = $insert_id;
  }
  else
  {
    
// show error message
    
$OUTPUT->show_message('errorsaving''error'nullfalse);
    
rcmail_overwrite_action('add');
  }
}

?>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

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

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

--[ c99shell v.2.1 [PHP 7 Update] [1.12.2019] maintained by KaizenLouie and updated by cermmik | C99Shell Github (MySQL update) | Generation time: 0.0047 ]--