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

Software: Apache. PHP/5.6.40-67+ubuntu20.04.1+deb.sury.org+1 

uname -a: Linux hosting1.erectacloud.it 5.4.0-182-generic #202-Ubuntu SMP Fri Apr 26 12:29:36 UTC
2024 x86_64
 

uid=5229(web473) gid=5117(client172) groups=5117(client172),5002(sshusers) 

Safe-mode: OFF (not secure)

/var/www/clients/client172/web473/web/OLD_WP/wp-content/plugins/wordpress-seo/vendor/yoast/api-libs/google/io/   drwxr-xr-x
Free 181.97 GB of 490.84 GB (37.07%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     Google_REST.php (4.46 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/*
 * Copyright 2010 Google Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/**
 * This class implements the RESTful transport of apiServiceRequest()'s
 *
 * @author Chris Chabot <chabotc@google.com>
 * @author Chirag Shah <chirags@google.com>
 */
class Yoast_Google_REST {
  
/**
   * Executes a apiServiceRequest using a RESTful call by transforming it into
   * an apiHttpRequest, and executed via apiIO::authenticatedRequest().
   *
   * @param Yoast_Google_HttpRequest $req
   * @return array decoded result
   * @throws Yoast_Google_ServiceException on server side error (ie: not authenticated,
   *  invalid or malformed post body, invalid url)
   */
  
static public function execute(Yoast_Google_HttpRequest $req) {
    
$httpRequest Yoast_Google_Client::$io->makeRequest($req);
    
$decodedResponse self::decodeHttpResponse($httpRequest);
    
$ret = isset($decodedResponse['data'])
        ? 
$decodedResponse['data'] : $decodedResponse;
    return 
$ret;
  }

  
  
/**
   * Decode an HTTP Response.
   * @static
   * @throws Yoast_Google_ServiceException
   * @param Yoast_Google_HttpRequest $response The http response to be decoded.
   * @return mixed|null
   */
  
public static function decodeHttpResponse($response) {
    
$code $response->getResponseHttpCode();
    
$body $response->getResponseBody();
    
$decoded null;
    
    if ((
intVal($code)) >= 300) {
      
$decoded json_decode($bodytrue);
      
$err 'Error calling ' $response->getRequestMethod() . ' ' $response->getUrl();
      if (
$decoded != null && isset($decoded['error']['message'])  && isset($decoded['error']['code'])) {
        
// if we're getting a json encoded error definition, use that instead of the raw response
        // body for improved readability
        
$err .= ": ({$decoded['error']['code']}{$decoded['error']['message']}";
      } else {
        
$err .= ": ($code$body";
      }

      throw new 
Yoast_Google_ServiceException($err$codenull$decoded['error']['errors']);
    }
    
    
// Only attempt to decode the response, if the response code wasn't (204) 'no content'
    
if ($code != '204') {
      
$decoded json_decode($bodytrue);
      if (
$decoded === null || $decoded === "") {
        throw new 
Yoast_Google_ServiceException("Invalid json in service response: $body");
      }
    }
    return 
$decoded;
  }

  
/**
   * Parse/expand request parameters and create a fully qualified
   * request uri.
   * @static
   * @param string $servicePath
   * @param string $restPath
   * @param array $params
   * @return string $requestUrl
   */
  
static function createRequestUri($servicePath$restPath$params) {
    
$requestUrl $servicePath $restPath;
    
$uriTemplateVars = array();
    
$queryVars = array();
    foreach (
$params as $paramName => $paramSpec) {
      
// Discovery v1.0 puts the canonical location under the 'location' field.
      
if (! isset($paramSpec['location'])) {
        
$paramSpec['location'] = $paramSpec['restParameterType'];
      }

      if (
$paramSpec['type'] == 'boolean') {
        
$paramSpec['value'] = ($paramSpec['value']) ? 'true' 'false';
      }
      if (
$paramSpec['location'] == 'path') {
        
$uriTemplateVars[$paramName] = $paramSpec['value'];
      } else {
        if (isset(
$paramSpec['repeated']) && is_array($paramSpec['value'])) {
          foreach (
$paramSpec['value'] as $value) {
            
$queryVars[] = $paramName '=' rawurlencode($value);
          }
        } else {
          
$queryVars[] = $paramName '=' rawurlencode($paramSpec['value']);
        }
      }
    }

    if (
count($uriTemplateVars)) {
      
$uriTemplateParser = new URI_Template_Parser($requestUrl);
      
$requestUrl $uriTemplateParser->expand($uriTemplateVars);
    }
    
//FIXME work around for the the uri template lib which url encodes
    // the @'s & confuses our servers.
    
$requestUrl str_replace('%40''@'$requestUrl);

    if (
count($queryVars)) {
      
$requestUrl .= '?' implode($queryVars'&');
    }

    return 
$requestUrl;
  }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: 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.0099 ]--