diff --git a/README.md b/README.md index 64f0ddf1..5ac24f48 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ **Requires at least:** 4.9 **Tested up to:** 5.3 **Requires PHP:** 5.5 -**Stable tag:** 2.3.1 +**Stable tag:** 2.3.2 **License:** GPLv3 Copies files to Amazon S3, DigitalOcean Spaces or Google Cloud Storage as they are uploaded to the Media Library. Optionally configure Amazon CloudFront or another CDN for faster delivery. @@ -89,6 +89,12 @@ This version requires PHP 5.3.3+ and the Amazon Web Services plugin ## Changelog ## +### WP Offload Media Lite 2.3.2 - 2019-12-09 ### +* Improvement: Reduced database queries when external object cache available +* Bug fix: Uncaught Error: Call to undefined function DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\choose_handler() +* Bug fix: SVG files not automatically offloaded +* Tested: PHP 7.4 + ### WP Offload Media Lite 2.3.1 - 2019-11-19 ### * Bug fix: Uncaught Error: Cannot use object of type Media_Library_Item as array in wp-includes/media.php:217 * Bug fix: Image not automatically offloaded if subsizes not expected diff --git a/classes/amazon-s3-and-cloudfront.php b/classes/amazon-s3-and-cloudfront.php index 7bda2f00..c426ec2d 100644 --- a/classes/amazon-s3-and-cloudfront.php +++ b/classes/amazon-s3-and-cloudfront.php @@ -1064,7 +1064,7 @@ function wp_update_attachment_metadata( $data, $post_id ) { // Protect against updates of partially formed metadata since WordPress 5.3. // Checks whether new upload currently has no subsizes recorded but is expected to have subsizes during upload, // and if so, are any of its currently missing sizes part of the set. - if ( function_exists( 'wp_get_registered_image_subsizes' ) && function_exists( 'wp_get_missing_image_subsizes' ) ) { + if ( ! empty( $data ) && function_exists( 'wp_get_registered_image_subsizes' ) && function_exists( 'wp_get_missing_image_subsizes' ) ) { if ( empty( $data['sizes'] ) && wp_attachment_is_image( $post_id ) ) { // There is no unified way of checking whether subsizes are expected, so we have to duplicate WordPress code here. diff --git a/classes/items/item.php b/classes/items/item.php index e6c672eb..e0b54fce 100644 --- a/classes/items/item.php +++ b/classes/items/item.php @@ -20,6 +20,16 @@ abstract class Item { protected static $items_cache_by_path = array(); protected static $items_cache_by_source_path = array(); + /** + * @var array Keys with array of fields that can be used for cache lookups. + */ + protected static $cache_keys = array( + 'id' => array( 'id' ), + 'source_id' => array( 'source_id' ), + 'path' => array( 'path', 'original_path' ), + 'source_path' => array( 'source_path', 'original_source_path' ), + ); + private $id; private $provider; private $region; @@ -71,6 +81,136 @@ public function __construct( $provider, $region, $bucket, $path, $is_private, $s static::add_to_items_cache( $this ); } + /** + * Returns the string used to group all keys in the object cache by. + * + * @return string + */ + protected static function get_object_cache_group() { + static $group; + + if ( empty( $group ) ) { + /** @var Amazon_S3_And_CloudFront $as3cf */ + global $as3cf; + $group = trim( '' . apply_filters( 'as3cf_object_cache_group', $as3cf->get_plugin_prefix() ) ); + } + + return $group; + } + + /** + * Get base string for all of current blog's object cache keys. + * + * @return string + */ + protected static function get_object_cache_base_key() { + $blog_id = get_current_blog_id(); + + return static::items_table() . '-' . $blog_id . '-' . static::$source_type; + } + + /** + * Get full object cache key. + * + * @param string $base_key + * @param string $key + * @param string $field + * + * @return string + */ + protected static function get_object_cache_full_key( $base_key, $key, $field ) { + return sanitize_text_field( $base_key . '-' . $key . '-' . $field ); + } + + /** + * Add the given item to the object cache. + * + * @param Item $item + */ + protected static function add_to_object_cache( $item ) { + if ( empty( $item ) || empty( static::$cache_keys ) ) { + return; + } + + $base_key = static::get_object_cache_base_key(); + $group = static::get_object_cache_group(); + + $keys = array(); + + foreach ( static::$cache_keys as $key => $fields ) { + foreach ( $fields as $field ) { + $full_key = static::get_object_cache_full_key( $base_key, $key, $item->{$field}() ); + + if ( in_array( $full_key, $keys ) ) { + continue; + } + + wp_cache_set( $full_key, $item, $group ); + + $keys[] = $full_key; + } + } + } + + /** + * Delete the given item from the object cache. + * + * @param Item $item + */ + protected static function remove_from_object_cache( $item ) { + if ( empty( $item ) || empty( static::$cache_keys ) ) { + return; + } + + $base_key = static::get_object_cache_base_key(); + $group = static::get_object_cache_group(); + + $keys = array(); + + foreach ( static::$cache_keys as $key => $fields ) { + foreach ( $fields as $field ) { + $full_key = static::get_object_cache_full_key( $base_key, $key, $item->{$field}() ); + + if ( in_array( $full_key, $keys ) ) { + continue; + } + + wp_cache_delete( $full_key, $group ); + + $keys[] = $full_key; + } + } + } + + /** + * Try and get Item from object cache by known key and value. + * + * Note: Actual lookup is scoped by blog and item's source_type, so example key may be 'source_id'. + * + * @param string $key The base of the key that makes up the lookup, e.g. field for given value. + * @param mixed $value Will be coerced to string for lookup. + * + * @return bool|Item + */ + protected static function get_from_object_cache( $key, $value ) { + if ( ! array_key_exists( $key, static::$cache_keys ) ) { + return false; + } + + $base_key = static::get_object_cache_base_key(); + $full_key = static::get_object_cache_full_key( $base_key, $key, $value ); + $group = static::get_object_cache_group(); + $force = false; + $found = false; + $result = wp_cache_get( $full_key, $group, $force, $found ); + + if ( $found ) { + return $result; + } + + return false; + } + /** * (Re)initialize the static cache used for speeding up queries. */ @@ -111,7 +251,7 @@ protected static function add_to_items_cache( $item ) { } /** - * Add an item to the static cache to allow fast retrieval via get_from_items_cache_by_* functions. + * Remove an item from the static cache that allows fast retrieval via get_from_items_cache_by_* functions. * * @param Item $item */ @@ -151,6 +291,14 @@ private static function get_from_items_cache_by_id( $id ) { return static::$items_cache_by_id[ $blog_id ][ $id ]; } + $item = static::get_from_object_cache( 'id', $id ); + + if ( $item ) { + static::add_to_items_cache( $item ); + + return $item; + } + return false; } @@ -168,6 +316,14 @@ private static function get_from_items_cache_by_source_id( $source_id ) { return static::$items_cache_by_source_id[ $blog_id ][ static::$source_type ][ $source_id ]; } + $item = static::get_from_object_cache( 'source_id', $source_id ); + + if ( $item ) { + static::add_to_items_cache( $item ); + + return $item; + } + return false; } @@ -372,14 +528,22 @@ public function save() { $this->id = $wpdb->insert_id; // Now that the item has an ID it should be (re)cached. - self::add_to_items_cache( $this ); + static::add_to_items_cache( $this ); } } else { + // Make sure object cache does not have stale items. + $old_item = static::get_from_object_cache( 'id', $this->id() ); + static::remove_from_object_cache( $old_item ); + unset( $old_item ); + $result = $wpdb->update( static::items_table(), $this->key_values(), array( 'id' => $this->id ), $this->formats(), array( '%d' ) ); } - if ( false === $result ) { - self::remove_from_items_cache( $this ); + if ( $result ) { + // Now that the item has an ID it should be (re)cached. + static::add_to_object_cache( $this ); + } else { + static::remove_from_items_cache( $this ); return new WP_Error( 'item_save', 'Error saving item:- ' . $wpdb->last_error ); } @@ -396,6 +560,7 @@ public function delete() { global $wpdb; static::remove_from_items_cache( $this ); + static::remove_from_object_cache( $this ); if ( empty( $this->id ) ) { return new WP_Error( 'item_delete', 'Error trying to delete item with no id.' ); @@ -414,17 +579,18 @@ public function delete() { * Creates an item based on object from database. * * @param object $object + * @param bool $add_to_object_cache Should this object be added to the object cache too? * * @return Item */ - protected static function create( $object ) { + protected static function create( $object, $add_to_object_cache = false ) { $extra_info = array(); if ( ! empty( $object->extra_info ) ) { $extra_info = unserialize( $object->extra_info ); } - return new static( + $item = new static( $object->provider, $object->region, $object->bucket, @@ -436,6 +602,12 @@ protected static function create( $object ) { $extra_info, $object->id ); + + if ( $add_to_object_cache ) { + static::add_to_object_cache( $item ); + } + + return $item; } /** @@ -466,7 +638,7 @@ public static function get_by_id( $id ) { return false; } - return static::create( $object ); + return static::create( $object, true ); } /** @@ -505,7 +677,7 @@ public static function get_by_source_id( $source_id ) { return false; } - return static::create( $object ); + return static::create( $object, true ); } /** diff --git a/languages/amazon-s3-and-cloudfront-en.pot b/languages/amazon-s3-and-cloudfront-en.pot index 30af312e..a6e55a43 100644 --- a/languages/amazon-s3-and-cloudfront-en.pot +++ b/languages/amazon-s3-and-cloudfront-en.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: amazon-s3-and-cloudfront\n" "Report-Msgid-Bugs-To: nom@deliciousbrains.com\n" -"POT-Creation-Date: 2019-11-19 10:16+0000\n" +"POT-Creation-Date: 2019-12-09 11:47+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/readme.txt b/readme.txt index 9a8520c9..0b816931 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Tags: uploads, amazon, s3, amazon s3, digitalocean, digitalocean spaces, google Requires at least: 4.9 Tested up to: 5.3 Requires PHP: 5.5 -Stable tag: 2.3.1 +Stable tag: 2.3.2 License: GPLv3 Copies files to Amazon S3, DigitalOcean Spaces or Google Cloud Storage as they are uploaded to the Media Library. Optionally configure Amazon CloudFront or another CDN for faster delivery. @@ -81,6 +81,12 @@ This version requires PHP 5.3.3+ and the Amazon Web Services plugin == Changelog == += WP Offload Media Lite 2.3.2 - 2019-12-09 = +* Improvement: Reduced database queries when external object cache available +* Bug fix: Uncaught Error: Call to undefined function DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\choose_handler() +* Bug fix: SVG files not automatically offloaded +* Tested: PHP 7.4 + = WP Offload Media Lite 2.3.1 - 2019-11-19 = * Bug fix: Uncaught Error: Cannot use object of type Media_Library_Item as array in wp-includes/media.php:217 * Bug fix: Image not automatically offloaded if subsizes not expected diff --git a/vendor/Gcp/autoload.php b/vendor/Gcp/autoload.php index 287b09b4..1bcb6c08 100644 --- a/vendor/Gcp/autoload.php +++ b/vendor/Gcp/autoload.php @@ -2,4 +2,4 @@ // autoload.php @generated by Composer require_once __DIR__ . '/composer/autoload_real.php'; -return \ComposerAutoloaderInit9fd2c411275a48d2ebf11f5a1bd6ca20::getLoader(); +return \ComposerAutoloaderInitad2bbf672104326f33ebff61e2e8e9b8::getLoader(); diff --git a/vendor/Gcp/composer/autoload_classmap.php b/vendor/Gcp/composer/autoload_classmap.php index 83b18ff8..bac8a14b 100644 --- a/vendor/Gcp/composer/autoload_classmap.php +++ b/vendor/Gcp/composer/autoload_classmap.php @@ -3,4 +3,4 @@ // autoload_classmap.php @generated by Composer $vendorDir = \dirname(\dirname(__FILE__)); $baseDir = \dirname($vendorDir); -return array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\BeforeValidException' => $vendorDir . '/firebase/php-jwt/src/BeforeValidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\ExpiredException' => $vendorDir . '/firebase/php-jwt/src/ExpiredException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT' => $vendorDir . '/firebase/php-jwt/src/JWT.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\SignatureInvalidException' => $vendorDir . '/firebase/php-jwt/src/SignatureInvalidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\ApplicationDefaultCredentials' => $vendorDir . '/google/auth/src/ApplicationDefaultCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CacheTrait' => $vendorDir . '/google/auth/src/CacheTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\InvalidArgumentException' => $vendorDir . '/google/auth/src/Cache/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\Item' => $vendorDir . '/google/auth/src/Cache/Item.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\MemoryCacheItemPool' => $vendorDir . '/google/auth/src/Cache/MemoryCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\SysVCacheItemPool' => $vendorDir . '/google/auth/src/Cache/SysVCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CredentialsLoader' => $vendorDir . '/google/auth/src/CredentialsLoader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\AppIdentityCredentials' => $vendorDir . '/google/auth/src/Credentials/AppIdentityCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\GCECredentials' => $vendorDir . '/google/auth/src/Credentials/GCECredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\IAMCredentials' => $vendorDir . '/google/auth/src/Credentials/IAMCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\InsecureCredentials' => $vendorDir . '/google/auth/src/Credentials/InsecureCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountCredentials' => $vendorDir . '/google/auth/src/Credentials/ServiceAccountCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountJwtAccessCredentials' => $vendorDir . '/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\UserRefreshCredentials' => $vendorDir . '/google/auth/src/Credentials/UserRefreshCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenCache' => $vendorDir . '/google/auth/src/FetchAuthTokenCache.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenInterface' => $vendorDir . '/google/auth/src/FetchAuthTokenInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle5HttpHandler' => $vendorDir . '/google/auth/src/HttpHandler/Guzzle5HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle6HttpHandler' => $vendorDir . '/google/auth/src/HttpHandler/Guzzle6HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\HttpHandlerFactory' => $vendorDir . '/google/auth/src/HttpHandler/HttpHandlerFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\AuthTokenMiddleware' => $vendorDir . '/google/auth/src/Middleware/AuthTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\ScopedAccessTokenMiddleware' => $vendorDir . '/google/auth/src/Middleware/ScopedAccessTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\SimpleMiddleware' => $vendorDir . '/google/auth/src/Middleware/SimpleMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\OAuth2' => $vendorDir . '/google/auth/src/OAuth2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\AuthTokenSubscriber' => $vendorDir . '/google/auth/src/Subscriber/AuthTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\ScopedAccessTokenSubscriber' => $vendorDir . '/google/auth/src/Subscriber/ScopedAccessTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\SimpleSubscriber' => $vendorDir . '/google/auth/src/Subscriber/SimpleSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\AnonymousCredentials' => $vendorDir . '/google/cloud-core/src/AnonymousCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ArrayTrait' => $vendorDir . '/google/cloud-core/src/ArrayTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemon' => $vendorDir . '/google/cloud-core/src/Batch/BatchDaemon.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemonTrait' => $vendorDir . '/google/cloud-core/src/Batch/BatchDaemonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchJob' => $vendorDir . '/google/cloud-core/src/Batch/BatchJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchRunner' => $vendorDir . '/google/cloud-core/src/Batch/BatchRunner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchTrait' => $vendorDir . '/google/cloud-core/src/Batch/BatchTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ClosureSerializerInterface' => $vendorDir . '/google/cloud-core/src/Batch/ClosureSerializerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ConfigStorageInterface' => $vendorDir . '/google/cloud-core/src/Batch/ConfigStorageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\HandleFailureTrait' => $vendorDir . '/google/cloud-core/src/Batch/HandleFailureTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InMemoryConfigStorage' => $vendorDir . '/google/cloud-core/src/Batch/InMemoryConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InterruptTrait' => $vendorDir . '/google/cloud-core/src/Batch/InterruptTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobConfig' => $vendorDir . '/google/cloud-core/src/Batch/JobConfig.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobInterface' => $vendorDir . '/google/cloud-core/src/Batch/JobInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobTrait' => $vendorDir . '/google/cloud-core/src/Batch/JobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\OpisClosureSerializer' => $vendorDir . '/google/cloud-core/src/Batch/OpisClosureSerializer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ProcessItemInterface' => $vendorDir . '/google/cloud-core/src/Batch/ProcessItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\Retry' => $vendorDir . '/google/cloud-core/src/Batch/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SerializableClientTrait' => $vendorDir . '/google/cloud-core/src/Batch/SerializableClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJob' => $vendorDir . '/google/cloud-core/src/Batch/SimpleJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJobTrait' => $vendorDir . '/google/cloud-core/src/Batch/SimpleJobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvConfigStorage' => $vendorDir . '/google/cloud-core/src/Batch/SysvConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvProcessor' => $vendorDir . '/google/cloud-core/src/Batch/SysvProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Blob' => $vendorDir . '/google/cloud-core/src/Blob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\CallTrait' => $vendorDir . '/google/cloud-core/src/CallTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ClientTrait' => $vendorDir . '/google/cloud-core/src/ClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata' => $vendorDir . '/google/cloud-core/src/Compute/Metadata.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\ReaderInterface' => $vendorDir . '/google/cloud-core/src/Compute/Metadata/Readers/ReaderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\StreamReader' => $vendorDir . '/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ConcurrencyControlTrait' => $vendorDir . '/google/cloud-core/src/ConcurrencyControlTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\DebugInfoTrait' => $vendorDir . '/google/cloud-core/src/DebugInfoTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Duration' => $vendorDir . '/google/cloud-core/src/Duration.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\EmulatorTrait' => $vendorDir . '/google/cloud-core/src/EmulatorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\AbortedException' => $vendorDir . '/google/cloud-core/src/Exception/AbortedException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\BadRequestException' => $vendorDir . '/google/cloud-core/src/Exception/BadRequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ConflictException' => $vendorDir . '/google/cloud-core/src/Exception/ConflictException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\DeadlineExceededException' => $vendorDir . '/google/cloud-core/src/Exception/DeadlineExceededException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\FailedPreconditionException' => $vendorDir . '/google/cloud-core/src/Exception/FailedPreconditionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\GoogleException' => $vendorDir . '/google/cloud-core/src/Exception/GoogleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\NotFoundException' => $vendorDir . '/google/cloud-core/src/Exception/NotFoundException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServerException' => $vendorDir . '/google/cloud-core/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServiceException' => $vendorDir . '/google/cloud-core/src/Exception/ServiceException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ExponentialBackoff' => $vendorDir . '/google/cloud-core/src/ExponentialBackoff.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GeoPoint' => $vendorDir . '/google/cloud-core/src/GeoPoint.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcRequestWrapper' => $vendorDir . '/google/cloud-core/src/GrpcRequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcTrait' => $vendorDir . '/google/cloud-core/src/GrpcTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\Iam' => $vendorDir . '/google/cloud-core/src/Iam/Iam.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\IamConnectionInterface' => $vendorDir . '/google/cloud-core/src/Iam/IamConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\PolicyBuilder' => $vendorDir . '/google/cloud-core/src/Iam/PolicyBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Int64' => $vendorDir . '/google/cloud-core/src/Int64.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIterator' => $vendorDir . '/google/cloud-core/src/Iterator/ItemIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIteratorTrait' => $vendorDir . '/google/cloud-core/src/Iterator/ItemIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIterator' => $vendorDir . '/google/cloud-core/src/Iterator/PageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIteratorTrait' => $vendorDir . '/google/cloud-core/src/Iterator/PageIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\JsonTrait' => $vendorDir . '/google/cloud-core/src/JsonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\FlockLock' => $vendorDir . '/google/cloud-core/src/Lock/FlockLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockInterface' => $vendorDir . '/google/cloud-core/src/Lock/LockInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockTrait' => $vendorDir . '/google/cloud-core/src/Lock/LockTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SemaphoreLock' => $vendorDir . '/google/cloud-core/src/Lock/SemaphoreLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SymfonyLockAdapter' => $vendorDir . '/google/cloud-core/src/Lock/SymfonyLockAdapter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexFormatter' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandler' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LROTrait' => $vendorDir . '/google/cloud-core/src/LongRunning/LROTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningConnectionInterface' => $vendorDir . '/google/cloud-core/src/LongRunning/LongRunningConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningOperation' => $vendorDir . '/google/cloud-core/src/LongRunning/LongRunningOperation.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\OperationResponseTrait' => $vendorDir . '/google/cloud-core/src/LongRunning/OperationResponseTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\PhpArray' => $vendorDir . '/google/cloud-core/src/PhpArray.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\EmptyMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/EmptyMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEFlexMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/GAEFlexMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/GAEMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEStandardMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/GAEStandardMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderInterface' => $vendorDir . '/google/cloud-core/src/Report/MetadataProviderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderUtils' => $vendorDir . '/google/cloud-core/src/Report/MetadataProviderUtils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\SimpleMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/SimpleMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestBuilder' => $vendorDir . '/google/cloud-core/src/RequestBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapper' => $vendorDir . '/google/cloud-core/src/RequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapperTrait' => $vendorDir . '/google/cloud-core/src/RequestWrapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RestTrait' => $vendorDir . '/google/cloud-core/src/RestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Retry' => $vendorDir . '/google/cloud-core/src/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RetryDeciderTrait' => $vendorDir . '/google/cloud-core/src/RetryDeciderTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ServiceBuilder' => $vendorDir . '/google/cloud-core/src/ServiceBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\SysvTrait' => $vendorDir . '/google/cloud-core/src/SysvTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\ArrayHasSameValuesToken' => $vendorDir . '/google/cloud-core/src/Testing/ArrayHasSameValuesToken.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\CheckForClassTrait' => $vendorDir . '/google/cloud-core/src/Testing/CheckForClassTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DatastoreOperationRefreshTrait' => $vendorDir . '/google/cloud-core/src/Testing/DatastoreOperationRefreshTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DocBlockStripSpaces' => $vendorDir . '/google/cloud-core/src/Testing/DocBlockStripSpaces.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\FileListFilterIterator' => $vendorDir . '/google/cloud-core/src/Testing/FileListFilterIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\GrpcTestTrait' => $vendorDir . '/google/cloud-core/src/Testing/GrpcTestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\KeyPairGenerateTrait' => $vendorDir . '/google/cloud-core/src/Testing/KeyPairGenerateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Lock\\MockValues' => $vendorDir . '/google/cloud-core/src/Testing/Lock/MockValues.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\RegexFileFilter' => $vendorDir . '/google/cloud-core/src/Testing/RegexFileFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Container' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Container.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Coverage' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/Coverage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ExcludeFilter' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/ExcludeFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ResultPrinter' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/ResultPrinter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Scanner' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/Scanner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ScannerInterface' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/ScannerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Fixtures' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Fixtures.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\InvokeResult' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Parser/InvokeResult.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Parser' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Parser/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Snippet' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Parser/Snippet.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\SnippetTestCase' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/SnippetTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\StubTrait' => $vendorDir . '/google/cloud-core/src/Testing/StubTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\DeletionQueue' => $vendorDir . '/google/cloud-core/src/Testing/System/DeletionQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\SystemTestCase' => $vendorDir . '/google/cloud-core/src/Testing/System/SystemTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\TestHelpers' => $vendorDir . '/google/cloud-core/src/Testing/TestHelpers.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\TimeTrait' => $vendorDir . '/google/cloud-core/src/TimeTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Timestamp' => $vendorDir . '/google/cloud-core/src/Timestamp.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\AbstractUploader' => $vendorDir . '/google/cloud-core/src/Upload/AbstractUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\MultipartUploader' => $vendorDir . '/google/cloud-core/src/Upload/MultipartUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\ResumableUploader' => $vendorDir . '/google/cloud-core/src/Upload/ResumableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\SignedUrlUploader' => $vendorDir . '/google/cloud-core/src/Upload/SignedUrlUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\StreamableUploader' => $vendorDir . '/google/cloud-core/src/Upload/StreamableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\UriTrait' => $vendorDir . '/google/cloud-core/src/UriTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValidateTrait' => $vendorDir . '/google/cloud-core/src/ValidateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValueMapperTrait' => $vendorDir . '/google/cloud-core/src/ValueMapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\WhitelistTrait' => $vendorDir . '/google/cloud-core/src/WhitelistTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Acl' => $vendorDir . '/google/cloud-storage/src/Acl.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Bucket' => $vendorDir . '/google/cloud-storage/src/Bucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\ConnectionInterface' => $vendorDir . '/google/cloud-storage/src/Connection/ConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\IamBucket' => $vendorDir . '/google/cloud-storage/src/Connection/IamBucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\Rest' => $vendorDir . '/google/cloud-storage/src/Connection/Rest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\EncryptionTrait' => $vendorDir . '/google/cloud-storage/src/EncryptionTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Lifecycle' => $vendorDir . '/google/cloud-storage/src/Lifecycle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Notification' => $vendorDir . '/google/cloud-storage/src/Notification.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectIterator' => $vendorDir . '/google/cloud-storage/src/ObjectIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectPageIterator' => $vendorDir . '/google/cloud-storage/src/ObjectPageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ReadStream' => $vendorDir . '/google/cloud-storage/src/ReadStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageClient' => $vendorDir . '/google/cloud-storage/src/StorageClient.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageObject' => $vendorDir . '/google/cloud-storage/src/StorageObject.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StreamWrapper' => $vendorDir . '/google/cloud-storage/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\WriteStream' => $vendorDir . '/google/cloud-storage/src/WriteStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Client' => $vendorDir . '/guzzlehttp/guzzle/src/Client.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\ClientInterface' => $vendorDir . '/guzzlehttp/guzzle/src/ClientInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJarInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\FileCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SessionCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SetCookie' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\BadResponseException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ClientException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ClientException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ConnectException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\GuzzleException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\RequestException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/RequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\SeekException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/SeekException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ServerException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TooManyRedirectsException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TransferException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TransferException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\HandlerStack' => $vendorDir . '/guzzlehttp/guzzle/src/HandlerStack.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactory' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactoryInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlMultiHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\EasyHandle' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\MockHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\Proxy' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/Proxy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\StreamHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\MessageFormatter' => $vendorDir . '/guzzlehttp/guzzle/src/MessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Middleware' => $vendorDir . '/guzzlehttp/guzzle/src/Middleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Pool' => $vendorDir . '/guzzlehttp/guzzle/src/Pool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\PrepareBodyMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\AggregateException' => $vendorDir . '/guzzlehttp/promises/src/AggregateException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\CancellationException' => $vendorDir . '/guzzlehttp/promises/src/CancellationException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Coroutine' => $vendorDir . '/guzzlehttp/promises/src/Coroutine.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\EachPromise' => $vendorDir . '/guzzlehttp/promises/src/EachPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\FulfilledPromise' => $vendorDir . '/guzzlehttp/promises/src/FulfilledPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Promise' => $vendorDir . '/guzzlehttp/promises/src/Promise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromiseInterface' => $vendorDir . '/guzzlehttp/promises/src/PromiseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromisorInterface' => $vendorDir . '/guzzlehttp/promises/src/PromisorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectedPromise' => $vendorDir . '/guzzlehttp/promises/src/RejectedPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectionException' => $vendorDir . '/guzzlehttp/promises/src/RejectionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueue' => $vendorDir . '/guzzlehttp/promises/src/TaskQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueueInterface' => $vendorDir . '/guzzlehttp/promises/src/TaskQueueInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\AppendStream' => $vendorDir . '/guzzlehttp/psr7/src/AppendStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\BufferStream' => $vendorDir . '/guzzlehttp/psr7/src/BufferStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\CachingStream' => $vendorDir . '/guzzlehttp/psr7/src/CachingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\DroppingStream' => $vendorDir . '/guzzlehttp/psr7/src/DroppingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\FnStream' => $vendorDir . '/guzzlehttp/psr7/src/FnStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\InflateStream' => $vendorDir . '/guzzlehttp/psr7/src/InflateStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LazyOpenStream' => $vendorDir . '/guzzlehttp/psr7/src/LazyOpenStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LimitStream' => $vendorDir . '/guzzlehttp/psr7/src/LimitStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MessageTrait' => $vendorDir . '/guzzlehttp/psr7/src/MessageTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MultipartStream' => $vendorDir . '/guzzlehttp/psr7/src/MultipartStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\NoSeekStream' => $vendorDir . '/guzzlehttp/psr7/src/NoSeekStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\PumpStream' => $vendorDir . '/guzzlehttp/psr7/src/PumpStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Request' => $vendorDir . '/guzzlehttp/psr7/src/Request.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Response' => $vendorDir . '/guzzlehttp/psr7/src/Response.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Rfc7230' => $vendorDir . '/guzzlehttp/psr7/src/Rfc7230.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\ServerRequest' => $vendorDir . '/guzzlehttp/psr7/src/ServerRequest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Stream' => $vendorDir . '/guzzlehttp/psr7/src/Stream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => $vendorDir . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamWrapper' => $vendorDir . '/guzzlehttp/psr7/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UploadedFile' => $vendorDir . '/guzzlehttp/psr7/src/UploadedFile.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Uri' => $vendorDir . '/guzzlehttp/psr7/src/Uri.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriNormalizer' => $vendorDir . '/guzzlehttp/psr7/src/UriNormalizer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriResolver' => $vendorDir . '/guzzlehttp/psr7/src/UriResolver.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RedirectMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RequestOptions' => $vendorDir . '/guzzlehttp/guzzle/src/RequestOptions.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RetryMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RetryMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\TransferStats' => $vendorDir . '/guzzlehttp/guzzle/src/TransferStats.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\UriTemplate' => $vendorDir . '/guzzlehttp/guzzle/src/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ErrorHandler' => $vendorDir . '/monolog/monolog/src/Monolog/ErrorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ChromePHPFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/ChromePHPFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ElasticaFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/ElasticaFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FlowdockFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/FlowdockFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FluentdFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FormatterInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/FormatterInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\GelfMessageFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/GelfMessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\HtmlFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\JsonFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LineFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/LineFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogglyFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/LogglyFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogstashFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/LogstashFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\MongoDBFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\NormalizerFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ScalarFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/ScalarFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\WildfireFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/WildfireFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AbstractHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractProcessingHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractSyslogHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AbstractSyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AmqpHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AmqpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BrowserConsoleHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BufferHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/BufferHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ChromePHPHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CouchDBHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/CouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CubeHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/CubeHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Curl\\Util' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/Curl/Util.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DeduplicationHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/DeduplicationHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DoctrineCouchDBHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/DoctrineCouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DynamoDbHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/DynamoDbHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ElasticSearchHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ElasticSearchHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ErrorLogHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ErrorLogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FilterHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FilterHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossedHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ActivationStrategyInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ActivationStrategyInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ChannelLevelActivationStrategy' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ChannelLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ErrorLevelActivationStrategy' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ErrorLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FirePHPHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FirePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FleepHookHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FleepHookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FlowdockHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GelfHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/GelfHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GroupHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/GroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/HandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerWrapper' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/HandlerWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HipChatHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/HipChatHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\IFTTTHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\InsightOpsHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogEntriesHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/LogEntriesHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogglyHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/LogglyHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MailHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MailHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MandrillHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MandrillHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MissingExtensionException' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MissingExtensionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MongoDBHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MongoDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NativeMailerHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/NativeMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NewRelicHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NullHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/NullHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PHPConsoleHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PsrHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/PsrHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PushoverHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/PushoverHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RavenHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RavenHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RedisHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RedisHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RollbarHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RollbarHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RotatingFileHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SamplingHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SamplingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SlackHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackWebhookHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Slack\\SlackRecord' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackbotHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SocketHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SocketHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\StreamHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SwiftMailerHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SwiftMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdpHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdp\\UdpSocket' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SyslogUdp/UdpSocket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\TestHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/TestHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\WhatFailureGroupHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ZendMonitorHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Logger' => $vendorDir . '/monolog/monolog/src/Monolog/Logger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\GitProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/GitProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\IntrospectionProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/IntrospectionProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryPeakUsageProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MemoryPeakUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MemoryProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryUsageProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MemoryUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MercurialProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MercurialProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessIdProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/ProcessIdProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessorInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/ProcessorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\PsrLogMessageProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/PsrLogMessageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\TagProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/TagProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\UidProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/UidProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\WebProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/WebProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Registry' => $vendorDir . '/monolog/monolog/src/Monolog/Registry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ResettableInterface' => $vendorDir . '/monolog/monolog/src/Monolog/ResettableInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\SignalHandler' => $vendorDir . '/monolog/monolog/src/Monolog/SignalHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Utils' => $vendorDir . '/monolog/monolog/src/Monolog/Utils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheException' => $vendorDir . '/psr/cache/src/CacheException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemInterface' => $vendorDir . '/psr/cache/src/CacheItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemPoolInterface' => $vendorDir . '/psr/cache/src/CacheItemPoolInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\InvalidArgumentException' => $vendorDir . '/psr/cache/src/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\MessageInterface' => $vendorDir . '/psr/http-message/src/MessageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\RequestInterface' => $vendorDir . '/psr/http-message/src/RequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ResponseInterface' => $vendorDir . '/psr/http-message/src/ResponseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ServerRequestInterface' => $vendorDir . '/psr/http-message/src/ServerRequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\StreamInterface' => $vendorDir . '/psr/http-message/src/StreamInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UploadedFileInterface' => $vendorDir . '/psr/http-message/src/UploadedFileInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UriInterface' => $vendorDir . '/psr/http-message/src/UriInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\AbstractLogger' => $vendorDir . '/psr/log/Psr/Log/AbstractLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\InvalidArgumentException' => $vendorDir . '/psr/log/Psr/Log/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LogLevel' => $vendorDir . '/psr/log/Psr/Log/LogLevel.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\NullLogger' => $vendorDir . '/psr/log/Psr/Log/NullLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\DummyTest' => $vendorDir . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\LoggerInterfaceTest' => $vendorDir . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\TestLogger' => $vendorDir . '/psr/log/Psr/Log/Test/TestLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Abstraction' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Expression' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Expression.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Literal' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Literal.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Variable' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Variable.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Abstraction' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Operator/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Named' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Operator/Named.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\UnNamed' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Operator/UnNamed.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Parser' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\UriTemplate' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/UriTemplate.php'); +return array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\BeforeValidException' => $vendorDir . '/firebase/php-jwt/src/BeforeValidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\ExpiredException' => $vendorDir . '/firebase/php-jwt/src/ExpiredException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT' => $vendorDir . '/firebase/php-jwt/src/JWT.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\SignatureInvalidException' => $vendorDir . '/firebase/php-jwt/src/SignatureInvalidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\AccessToken' => $vendorDir . '/google/auth/src/AccessToken.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\ApplicationDefaultCredentials' => $vendorDir . '/google/auth/src/ApplicationDefaultCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CacheTrait' => $vendorDir . '/google/auth/src/CacheTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\InvalidArgumentException' => $vendorDir . '/google/auth/src/Cache/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\Item' => $vendorDir . '/google/auth/src/Cache/Item.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\MemoryCacheItemPool' => $vendorDir . '/google/auth/src/Cache/MemoryCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\SysVCacheItemPool' => $vendorDir . '/google/auth/src/Cache/SysVCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CredentialsLoader' => $vendorDir . '/google/auth/src/CredentialsLoader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\AppIdentityCredentials' => $vendorDir . '/google/auth/src/Credentials/AppIdentityCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\GCECredentials' => $vendorDir . '/google/auth/src/Credentials/GCECredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\IAMCredentials' => $vendorDir . '/google/auth/src/Credentials/IAMCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\InsecureCredentials' => $vendorDir . '/google/auth/src/Credentials/InsecureCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountCredentials' => $vendorDir . '/google/auth/src/Credentials/ServiceAccountCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountJwtAccessCredentials' => $vendorDir . '/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\UserRefreshCredentials' => $vendorDir . '/google/auth/src/Credentials/UserRefreshCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenCache' => $vendorDir . '/google/auth/src/FetchAuthTokenCache.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenInterface' => $vendorDir . '/google/auth/src/FetchAuthTokenInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle5HttpHandler' => $vendorDir . '/google/auth/src/HttpHandler/Guzzle5HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle6HttpHandler' => $vendorDir . '/google/auth/src/HttpHandler/Guzzle6HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\HttpClientCache' => $vendorDir . '/google/auth/src/HttpHandler/HttpClientCache.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\HttpHandlerFactory' => $vendorDir . '/google/auth/src/HttpHandler/HttpHandlerFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Iam' => $vendorDir . '/google/auth/src/Iam.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\AuthTokenMiddleware' => $vendorDir . '/google/auth/src/Middleware/AuthTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\ScopedAccessTokenMiddleware' => $vendorDir . '/google/auth/src/Middleware/ScopedAccessTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\SimpleMiddleware' => $vendorDir . '/google/auth/src/Middleware/SimpleMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\OAuth2' => $vendorDir . '/google/auth/src/OAuth2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\ServiceAccountSignerTrait' => $vendorDir . '/google/auth/src/ServiceAccountSignerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\SignBlobInterface' => $vendorDir . '/google/auth/src/SignBlobInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\AuthTokenSubscriber' => $vendorDir . '/google/auth/src/Subscriber/AuthTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\ScopedAccessTokenSubscriber' => $vendorDir . '/google/auth/src/Subscriber/ScopedAccessTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\SimpleSubscriber' => $vendorDir . '/google/auth/src/Subscriber/SimpleSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\Builtin' => $vendorDir . '/google/crc32/src/Builtin.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\CRC32' => $vendorDir . '/google/crc32/src/CRC32.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\CRCInterface' => $vendorDir . '/google/crc32/src/CRCInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\CRCTrait' => $vendorDir . '/google/crc32/src/CRCTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\Google' => $vendorDir . '/google/crc32/src/Google.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\PHP' => $vendorDir . '/google/crc32/src/PHP.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\PHPSlicedBy4' => $vendorDir . '/google/crc32/src/PHPSlicedBy4.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\Table' => $vendorDir . '/google/crc32/src/Table.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\AnonymousCredentials' => $vendorDir . '/google/cloud-core/src/AnonymousCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ArrayTrait' => $vendorDir . '/google/cloud-core/src/ArrayTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemon' => $vendorDir . '/google/cloud-core/src/Batch/BatchDaemon.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemonTrait' => $vendorDir . '/google/cloud-core/src/Batch/BatchDaemonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchJob' => $vendorDir . '/google/cloud-core/src/Batch/BatchJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchRunner' => $vendorDir . '/google/cloud-core/src/Batch/BatchRunner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchTrait' => $vendorDir . '/google/cloud-core/src/Batch/BatchTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ClosureSerializerInterface' => $vendorDir . '/google/cloud-core/src/Batch/ClosureSerializerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ConfigStorageInterface' => $vendorDir . '/google/cloud-core/src/Batch/ConfigStorageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\HandleFailureTrait' => $vendorDir . '/google/cloud-core/src/Batch/HandleFailureTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InMemoryConfigStorage' => $vendorDir . '/google/cloud-core/src/Batch/InMemoryConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InterruptTrait' => $vendorDir . '/google/cloud-core/src/Batch/InterruptTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobConfig' => $vendorDir . '/google/cloud-core/src/Batch/JobConfig.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobInterface' => $vendorDir . '/google/cloud-core/src/Batch/JobInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobTrait' => $vendorDir . '/google/cloud-core/src/Batch/JobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\OpisClosureSerializer' => $vendorDir . '/google/cloud-core/src/Batch/OpisClosureSerializer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ProcessItemInterface' => $vendorDir . '/google/cloud-core/src/Batch/ProcessItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\Retry' => $vendorDir . '/google/cloud-core/src/Batch/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SerializableClientTrait' => $vendorDir . '/google/cloud-core/src/Batch/SerializableClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJob' => $vendorDir . '/google/cloud-core/src/Batch/SimpleJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJobTrait' => $vendorDir . '/google/cloud-core/src/Batch/SimpleJobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvConfigStorage' => $vendorDir . '/google/cloud-core/src/Batch/SysvConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvProcessor' => $vendorDir . '/google/cloud-core/src/Batch/SysvProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Blob' => $vendorDir . '/google/cloud-core/src/Blob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\CallTrait' => $vendorDir . '/google/cloud-core/src/CallTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ClientTrait' => $vendorDir . '/google/cloud-core/src/ClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata' => $vendorDir . '/google/cloud-core/src/Compute/Metadata.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\HttpHandlerReader' => $vendorDir . '/google/cloud-core/src/Compute/Metadata/Readers/HttpHandlerReader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\ReaderInterface' => $vendorDir . '/google/cloud-core/src/Compute/Metadata/Readers/ReaderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\StreamReader' => $vendorDir . '/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ConcurrencyControlTrait' => $vendorDir . '/google/cloud-core/src/ConcurrencyControlTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\DebugInfoTrait' => $vendorDir . '/google/cloud-core/src/DebugInfoTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Duration' => $vendorDir . '/google/cloud-core/src/Duration.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\EmulatorTrait' => $vendorDir . '/google/cloud-core/src/EmulatorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\AbortedException' => $vendorDir . '/google/cloud-core/src/Exception/AbortedException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\BadRequestException' => $vendorDir . '/google/cloud-core/src/Exception/BadRequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ConflictException' => $vendorDir . '/google/cloud-core/src/Exception/ConflictException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\DeadlineExceededException' => $vendorDir . '/google/cloud-core/src/Exception/DeadlineExceededException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\FailedPreconditionException' => $vendorDir . '/google/cloud-core/src/Exception/FailedPreconditionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\GoogleException' => $vendorDir . '/google/cloud-core/src/Exception/GoogleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\NotFoundException' => $vendorDir . '/google/cloud-core/src/Exception/NotFoundException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServerException' => $vendorDir . '/google/cloud-core/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServiceException' => $vendorDir . '/google/cloud-core/src/Exception/ServiceException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ExponentialBackoff' => $vendorDir . '/google/cloud-core/src/ExponentialBackoff.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GeoPoint' => $vendorDir . '/google/cloud-core/src/GeoPoint.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcRequestWrapper' => $vendorDir . '/google/cloud-core/src/GrpcRequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcTrait' => $vendorDir . '/google/cloud-core/src/GrpcTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\Iam' => $vendorDir . '/google/cloud-core/src/Iam/Iam.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\IamConnectionInterface' => $vendorDir . '/google/cloud-core/src/Iam/IamConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\PolicyBuilder' => $vendorDir . '/google/cloud-core/src/Iam/PolicyBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Int64' => $vendorDir . '/google/cloud-core/src/Int64.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIterator' => $vendorDir . '/google/cloud-core/src/Iterator/ItemIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIteratorTrait' => $vendorDir . '/google/cloud-core/src/Iterator/ItemIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIterator' => $vendorDir . '/google/cloud-core/src/Iterator/PageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIteratorTrait' => $vendorDir . '/google/cloud-core/src/Iterator/PageIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\JsonTrait' => $vendorDir . '/google/cloud-core/src/JsonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\FlockLock' => $vendorDir . '/google/cloud-core/src/Lock/FlockLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockInterface' => $vendorDir . '/google/cloud-core/src/Lock/LockInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockTrait' => $vendorDir . '/google/cloud-core/src/Lock/LockTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SemaphoreLock' => $vendorDir . '/google/cloud-core/src/Lock/SemaphoreLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SymfonyLockAdapter' => $vendorDir . '/google/cloud-core/src/Lock/SymfonyLockAdapter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexFormatter' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexFormatterV2' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexFormatterV2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandler' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandlerFactory' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexHandlerFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandlerV2' => $vendorDir . '/google/cloud-core/src/Logger/AppEngineFlexHandlerV2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\FormatterTrait' => $vendorDir . '/google/cloud-core/src/Logger/FormatterTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LROTrait' => $vendorDir . '/google/cloud-core/src/LongRunning/LROTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningConnectionInterface' => $vendorDir . '/google/cloud-core/src/LongRunning/LongRunningConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningOperation' => $vendorDir . '/google/cloud-core/src/LongRunning/LongRunningOperation.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\OperationResponseTrait' => $vendorDir . '/google/cloud-core/src/LongRunning/OperationResponseTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\PhpArray' => $vendorDir . '/google/cloud-core/src/PhpArray.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\EmptyMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/EmptyMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEFlexMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/GAEFlexMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/GAEMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEStandardMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/GAEStandardMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderInterface' => $vendorDir . '/google/cloud-core/src/Report/MetadataProviderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderUtils' => $vendorDir . '/google/cloud-core/src/Report/MetadataProviderUtils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\SimpleMetadataProvider' => $vendorDir . '/google/cloud-core/src/Report/SimpleMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestBuilder' => $vendorDir . '/google/cloud-core/src/RequestBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapper' => $vendorDir . '/google/cloud-core/src/RequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapperTrait' => $vendorDir . '/google/cloud-core/src/RequestWrapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RestTrait' => $vendorDir . '/google/cloud-core/src/RestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Retry' => $vendorDir . '/google/cloud-core/src/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RetryDeciderTrait' => $vendorDir . '/google/cloud-core/src/RetryDeciderTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ServiceBuilder' => $vendorDir . '/google/cloud-core/src/ServiceBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\SysvTrait' => $vendorDir . '/google/cloud-core/src/SysvTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\ArrayHasSameValuesToken' => $vendorDir . '/google/cloud-core/src/Testing/ArrayHasSameValuesToken.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\CheckForClassTrait' => $vendorDir . '/google/cloud-core/src/Testing/CheckForClassTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DatastoreOperationRefreshTrait' => $vendorDir . '/google/cloud-core/src/Testing/DatastoreOperationRefreshTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DocBlockStripSpaces' => $vendorDir . '/google/cloud-core/src/Testing/DocBlockStripSpaces.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\FileListFilterIterator' => $vendorDir . '/google/cloud-core/src/Testing/FileListFilterIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\GrpcTestTrait' => $vendorDir . '/google/cloud-core/src/Testing/GrpcTestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\KeyPairGenerateTrait' => $vendorDir . '/google/cloud-core/src/Testing/KeyPairGenerateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Lock\\MockValues' => $vendorDir . '/google/cloud-core/src/Testing/Lock/MockValues.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\RegexFileFilter' => $vendorDir . '/google/cloud-core/src/Testing/RegexFileFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Container' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Container.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Coverage' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/Coverage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ExcludeFilter' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/ExcludeFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ResultPrinter' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/ResultPrinter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Scanner' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/Scanner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ScannerInterface' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Coverage/ScannerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Fixtures' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Fixtures.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\InvokeResult' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Parser/InvokeResult.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Parser' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Parser/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Snippet' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/Parser/Snippet.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\SnippetTestCase' => $vendorDir . '/google/cloud-core/src/Testing/Snippet/SnippetTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\StubTrait' => $vendorDir . '/google/cloud-core/src/Testing/StubTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\DeletionQueue' => $vendorDir . '/google/cloud-core/src/Testing/System/DeletionQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\KeyManager' => $vendorDir . '/google/cloud-core/src/Testing/System/KeyManager.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\SystemTestCase' => $vendorDir . '/google/cloud-core/src/Testing/System/SystemTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\TestHelpers' => $vendorDir . '/google/cloud-core/src/Testing/TestHelpers.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\TimeTrait' => $vendorDir . '/google/cloud-core/src/TimeTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Timestamp' => $vendorDir . '/google/cloud-core/src/Timestamp.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\AbstractUploader' => $vendorDir . '/google/cloud-core/src/Upload/AbstractUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\MultipartUploader' => $vendorDir . '/google/cloud-core/src/Upload/MultipartUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\ResumableUploader' => $vendorDir . '/google/cloud-core/src/Upload/ResumableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\SignedUrlUploader' => $vendorDir . '/google/cloud-core/src/Upload/SignedUrlUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\StreamableUploader' => $vendorDir . '/google/cloud-core/src/Upload/StreamableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\UriTrait' => $vendorDir . '/google/cloud-core/src/UriTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValidateTrait' => $vendorDir . '/google/cloud-core/src/ValidateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValueMapperTrait' => $vendorDir . '/google/cloud-core/src/ValueMapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\WhitelistTrait' => $vendorDir . '/google/cloud-core/src/WhitelistTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Acl' => $vendorDir . '/google/cloud-storage/src/Acl.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Bucket' => $vendorDir . '/google/cloud-storage/src/Bucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\ConnectionInterface' => $vendorDir . '/google/cloud-storage/src/Connection/ConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\IamBucket' => $vendorDir . '/google/cloud-storage/src/Connection/IamBucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\Rest' => $vendorDir . '/google/cloud-storage/src/Connection/Rest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\CreatedHmacKey' => $vendorDir . '/google/cloud-storage/src/CreatedHmacKey.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\EncryptionTrait' => $vendorDir . '/google/cloud-storage/src/EncryptionTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\HmacKey' => $vendorDir . '/google/cloud-storage/src/HmacKey.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Lifecycle' => $vendorDir . '/google/cloud-storage/src/Lifecycle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Notification' => $vendorDir . '/google/cloud-storage/src/Notification.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectIterator' => $vendorDir . '/google/cloud-storage/src/ObjectIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectPageIterator' => $vendorDir . '/google/cloud-storage/src/ObjectPageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ReadStream' => $vendorDir . '/google/cloud-storage/src/ReadStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\SigningHelper' => $vendorDir . '/google/cloud-storage/src/SigningHelper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageClient' => $vendorDir . '/google/cloud-storage/src/StorageClient.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageObject' => $vendorDir . '/google/cloud-storage/src/StorageObject.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StreamWrapper' => $vendorDir . '/google/cloud-storage/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\WriteStream' => $vendorDir . '/google/cloud-storage/src/WriteStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Client' => $vendorDir . '/guzzlehttp/guzzle/src/Client.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\ClientInterface' => $vendorDir . '/guzzlehttp/guzzle/src/ClientInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJarInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\FileCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SessionCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SetCookie' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\BadResponseException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ClientException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ClientException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ConnectException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\GuzzleException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\InvalidArgumentException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\RequestException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/RequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\SeekException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/SeekException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ServerException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TooManyRedirectsException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TransferException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TransferException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\HandlerStack' => $vendorDir . '/guzzlehttp/guzzle/src/HandlerStack.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactory' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactoryInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlMultiHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\EasyHandle' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\MockHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\Proxy' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/Proxy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\StreamHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\MessageFormatter' => $vendorDir . '/guzzlehttp/guzzle/src/MessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Middleware' => $vendorDir . '/guzzlehttp/guzzle/src/Middleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Pool' => $vendorDir . '/guzzlehttp/guzzle/src/Pool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\PrepareBodyMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\AggregateException' => $vendorDir . '/guzzlehttp/promises/src/AggregateException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\CancellationException' => $vendorDir . '/guzzlehttp/promises/src/CancellationException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Coroutine' => $vendorDir . '/guzzlehttp/promises/src/Coroutine.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\EachPromise' => $vendorDir . '/guzzlehttp/promises/src/EachPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\FulfilledPromise' => $vendorDir . '/guzzlehttp/promises/src/FulfilledPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Promise' => $vendorDir . '/guzzlehttp/promises/src/Promise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromiseInterface' => $vendorDir . '/guzzlehttp/promises/src/PromiseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromisorInterface' => $vendorDir . '/guzzlehttp/promises/src/PromisorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectedPromise' => $vendorDir . '/guzzlehttp/promises/src/RejectedPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectionException' => $vendorDir . '/guzzlehttp/promises/src/RejectionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueue' => $vendorDir . '/guzzlehttp/promises/src/TaskQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueueInterface' => $vendorDir . '/guzzlehttp/promises/src/TaskQueueInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\AppendStream' => $vendorDir . '/guzzlehttp/psr7/src/AppendStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\BufferStream' => $vendorDir . '/guzzlehttp/psr7/src/BufferStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\CachingStream' => $vendorDir . '/guzzlehttp/psr7/src/CachingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\DroppingStream' => $vendorDir . '/guzzlehttp/psr7/src/DroppingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\FnStream' => $vendorDir . '/guzzlehttp/psr7/src/FnStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\InflateStream' => $vendorDir . '/guzzlehttp/psr7/src/InflateStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LazyOpenStream' => $vendorDir . '/guzzlehttp/psr7/src/LazyOpenStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LimitStream' => $vendorDir . '/guzzlehttp/psr7/src/LimitStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MessageTrait' => $vendorDir . '/guzzlehttp/psr7/src/MessageTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MultipartStream' => $vendorDir . '/guzzlehttp/psr7/src/MultipartStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\NoSeekStream' => $vendorDir . '/guzzlehttp/psr7/src/NoSeekStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\PumpStream' => $vendorDir . '/guzzlehttp/psr7/src/PumpStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Request' => $vendorDir . '/guzzlehttp/psr7/src/Request.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Response' => $vendorDir . '/guzzlehttp/psr7/src/Response.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Rfc7230' => $vendorDir . '/guzzlehttp/psr7/src/Rfc7230.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\ServerRequest' => $vendorDir . '/guzzlehttp/psr7/src/ServerRequest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Stream' => $vendorDir . '/guzzlehttp/psr7/src/Stream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => $vendorDir . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamWrapper' => $vendorDir . '/guzzlehttp/psr7/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UploadedFile' => $vendorDir . '/guzzlehttp/psr7/src/UploadedFile.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Uri' => $vendorDir . '/guzzlehttp/psr7/src/Uri.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriNormalizer' => $vendorDir . '/guzzlehttp/psr7/src/UriNormalizer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriResolver' => $vendorDir . '/guzzlehttp/psr7/src/UriResolver.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RedirectMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RequestOptions' => $vendorDir . '/guzzlehttp/guzzle/src/RequestOptions.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RetryMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RetryMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\TransferStats' => $vendorDir . '/guzzlehttp/guzzle/src/TransferStats.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\UriTemplate' => $vendorDir . '/guzzlehttp/guzzle/src/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ErrorHandler' => $vendorDir . '/monolog/monolog/src/Monolog/ErrorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ChromePHPFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/ChromePHPFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ElasticaFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/ElasticaFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FlowdockFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/FlowdockFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FluentdFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FormatterInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/FormatterInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\GelfMessageFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/GelfMessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\HtmlFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\JsonFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LineFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/LineFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogglyFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/LogglyFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogstashFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/LogstashFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\MongoDBFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\NormalizerFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ScalarFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/ScalarFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\WildfireFormatter' => $vendorDir . '/monolog/monolog/src/Monolog/Formatter/WildfireFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AbstractHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractProcessingHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractSyslogHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AbstractSyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AmqpHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/AmqpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BrowserConsoleHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BufferHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/BufferHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ChromePHPHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CouchDBHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/CouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CubeHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/CubeHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Curl\\Util' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/Curl/Util.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DeduplicationHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/DeduplicationHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DoctrineCouchDBHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/DoctrineCouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DynamoDbHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/DynamoDbHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ElasticSearchHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ElasticSearchHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ErrorLogHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ErrorLogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FilterHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FilterHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossedHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ActivationStrategyInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ActivationStrategyInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ChannelLevelActivationStrategy' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ChannelLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ErrorLevelActivationStrategy' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ErrorLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FirePHPHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FirePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FleepHookHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FleepHookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FlowdockHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FormattableHandlerInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FormattableHandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FormattableHandlerTrait' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/FormattableHandlerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GelfHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/GelfHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GroupHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/GroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/HandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerWrapper' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/HandlerWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HipChatHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/HipChatHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\IFTTTHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\InsightOpsHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogEntriesHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/LogEntriesHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogglyHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/LogglyHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MailHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MailHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MandrillHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MandrillHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MissingExtensionException' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MissingExtensionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MongoDBHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/MongoDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NativeMailerHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/NativeMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NewRelicHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NullHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/NullHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PHPConsoleHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ProcessableHandlerInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ProcessableHandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ProcessableHandlerTrait' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ProcessableHandlerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PsrHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/PsrHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PushoverHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/PushoverHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RavenHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RavenHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RedisHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RedisHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RollbarHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RollbarHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RotatingFileHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SamplingHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SamplingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SlackHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackWebhookHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Slack\\SlackRecord' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackbotHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SocketHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SocketHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\StreamHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SwiftMailerHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SwiftMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdpHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdp\\UdpSocket' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/SyslogUdp/UdpSocket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\TestHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/TestHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\WhatFailureGroupHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ZendMonitorHandler' => $vendorDir . '/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Logger' => $vendorDir . '/monolog/monolog/src/Monolog/Logger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\GitProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/GitProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\IntrospectionProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/IntrospectionProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryPeakUsageProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MemoryPeakUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MemoryProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryUsageProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MemoryUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MercurialProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/MercurialProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessIdProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/ProcessIdProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessorInterface' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/ProcessorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\PsrLogMessageProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/PsrLogMessageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\TagProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/TagProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\UidProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/UidProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\WebProcessor' => $vendorDir . '/monolog/monolog/src/Monolog/Processor/WebProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Registry' => $vendorDir . '/monolog/monolog/src/Monolog/Registry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ResettableInterface' => $vendorDir . '/monolog/monolog/src/Monolog/ResettableInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\SignalHandler' => $vendorDir . '/monolog/monolog/src/Monolog/SignalHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Utils' => $vendorDir . '/monolog/monolog/src/Monolog/Utils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheException' => $vendorDir . '/psr/cache/src/CacheException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemInterface' => $vendorDir . '/psr/cache/src/CacheItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemPoolInterface' => $vendorDir . '/psr/cache/src/CacheItemPoolInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\InvalidArgumentException' => $vendorDir . '/psr/cache/src/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\MessageInterface' => $vendorDir . '/psr/http-message/src/MessageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\RequestInterface' => $vendorDir . '/psr/http-message/src/RequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ResponseInterface' => $vendorDir . '/psr/http-message/src/ResponseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ServerRequestInterface' => $vendorDir . '/psr/http-message/src/ServerRequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\StreamInterface' => $vendorDir . '/psr/http-message/src/StreamInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UploadedFileInterface' => $vendorDir . '/psr/http-message/src/UploadedFileInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UriInterface' => $vendorDir . '/psr/http-message/src/UriInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\AbstractLogger' => $vendorDir . '/psr/log/Psr/Log/AbstractLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\InvalidArgumentException' => $vendorDir . '/psr/log/Psr/Log/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LogLevel' => $vendorDir . '/psr/log/Psr/Log/LogLevel.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\NullLogger' => $vendorDir . '/psr/log/Psr/Log/NullLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\DummyTest' => $vendorDir . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\LoggerInterfaceTest' => $vendorDir . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\TestLogger' => $vendorDir . '/psr/log/Psr/Log/Test/TestLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Abstraction' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Expression' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Expression.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Literal' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Literal.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Variable' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Node/Variable.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Abstraction' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Operator/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Named' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Operator/Named.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\UnNamed' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Operator/UnNamed.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Parser' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\UriTemplate' => $vendorDir . '/rize/uri-template/src/Rize/UriTemplate/UriTemplate.php'); diff --git a/vendor/Gcp/composer/autoload_files.php b/vendor/Gcp/composer/autoload_files.php index 1fb7b98c..1d5a24c5 100644 --- a/vendor/Gcp/composer/autoload_files.php +++ b/vendor/Gcp/composer/autoload_files.php @@ -3,4 +3,4 @@ // autoload_files.php @generated by Composer $vendorDir = \dirname(\dirname(__FILE__)); $baseDir = \dirname($vendorDir); -return array('7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php', 'c964ee0ededf28c96ebd9db5099ef910' => $vendorDir . '/guzzlehttp/promises/src/functions_include.php', 'a0edc8309cc5e1d60e3047b5df6b7052' => $vendorDir . '/guzzlehttp/psr7/src/functions_include.php', '37a3dc5111fe8f707ab4c132ef1dbc62' => $vendorDir . '/guzzlehttp/guzzle/src/functions_include.php'); +return array('dbi_as3cf_gcp_7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php', 'dbi_as3cf_gcp_c964ee0ededf28c96ebd9db5099ef910' => $vendorDir . '/guzzlehttp/promises/src/functions_include.php', 'dbi_as3cf_gcp_a0edc8309cc5e1d60e3047b5df6b7052' => $vendorDir . '/guzzlehttp/psr7/src/functions_include.php', 'dbi_as3cf_gcp_37a3dc5111fe8f707ab4c132ef1dbc62' => $vendorDir . '/guzzlehttp/guzzle/src/functions_include.php'); diff --git a/vendor/Gcp/composer/autoload_psr4.php b/vendor/Gcp/composer/autoload_psr4.php index c50c0b51..c8a14bab 100644 --- a/vendor/Gcp/composer/autoload_psr4.php +++ b/vendor/Gcp/composer/autoload_psr4.php @@ -3,4 +3,4 @@ // autoload_psr4.php @generated by Composer $vendorDir = \dirname(\dirname(__FILE__)); $baseDir = \dirname($vendorDir); -return array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-message/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\' => array($vendorDir . '/psr/cache/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\' => array($vendorDir . '/monolog/monolog/src/Monolog'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\' => array($vendorDir . '/google/cloud-storage/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\' => array($vendorDir . '/google/cloud-core/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\' => array($vendorDir . '/google/auth/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\' => array($vendorDir . '/firebase/php-jwt/src')); +return array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-message/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\' => array($vendorDir . '/psr/cache/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\' => array($vendorDir . '/monolog/monolog/src/Monolog'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\' => array($vendorDir . '/google/cloud-storage/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\' => array($vendorDir . '/google/cloud-core/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\' => array($vendorDir . '/google/crc32/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\' => array($vendorDir . '/google/auth/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\' => array($vendorDir . '/firebase/php-jwt/src')); diff --git a/vendor/Gcp/composer/autoload_real.php b/vendor/Gcp/composer/autoload_real.php index 9f9ee483..128f312f 100644 --- a/vendor/Gcp/composer/autoload_real.php +++ b/vendor/Gcp/composer/autoload_real.php @@ -1,7 +1,7 @@ = 50600 && !\defined('HHVM_VERSION') && (!\function_exists('zend_loader_file_encoded') || !\zend_loader_file_encoded()); if ($useStaticLoader) { require_once __DIR__ . '/autoload_static.php'; - \call_user_func(\DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload\ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20::getInitializer($loader)); + \call_user_func(\DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload\ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8::getInitializer($loader)); } else { $classMap = (require __DIR__ . '/autoload_classmap.php'); if ($classMap) { @@ -31,17 +31,17 @@ public static function getLoader() $loader->setClassMapAuthoritative(\true); $loader->register(\true); if ($useStaticLoader) { - $includeFiles =DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload\ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20::$files; + $includeFiles =DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload\ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8::$files; } else { $includeFiles = (require __DIR__ . '/autoload_files.php'); } foreach ($includeFiles as $fileIdentifier => $file) { - \composerRequire9fd2c411275a48d2ebf11f5a1bd6ca20($fileIdentifier, $file); + \composerRequiread2bbf672104326f33ebff61e2e8e9b8($fileIdentifier, $file); } return $loader; } } -function composerRequire9fd2c411275a48d2ebf11f5a1bd6ca20($fileIdentifier, $file) +function composerRequiread2bbf672104326f33ebff61e2e8e9b8($fileIdentifier, $file) { if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { require $file; diff --git a/vendor/Gcp/composer/autoload_static.php b/vendor/Gcp/composer/autoload_static.php index 6bd52e6b..6bc86265 100644 --- a/vendor/Gcp/composer/autoload_static.php +++ b/vendor/Gcp/composer/autoload_static.php @@ -3,20 +3,20 @@ // autoload_static.php @generated by Composer namespace DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload; -class ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20 +class ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8 { - public static $files = array('7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php', 'c964ee0ededf28c96ebd9db5099ef910' => __DIR__ . '/..' . '/guzzlehttp/promises/src/functions_include.php', 'a0edc8309cc5e1d60e3047b5df6b7052' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/functions_include.php', '37a3dc5111fe8f707ab4c132ef1dbc62' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/functions_include.php'); - public static $prefixLengthsPsr4 = array('P' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\' => 8, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\' => 17, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\' => 10), 'M' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\' => 8), 'G' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\' => 16, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\' => 19, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\' => 11, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\' => 21, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\' => 18, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\' => 12), 'F' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\' => 13)); - public static $prefixDirsPsr4 = array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\' => array(0 => __DIR__ . '/..' . '/psr/log/Psr/Log'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\' => array(0 => __DIR__ . '/..' . '/psr/http-message/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\' => array(0 => __DIR__ . '/..' . '/psr/cache/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\' => array(0 => __DIR__ . '/..' . '/monolog/monolog/src/Monolog'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\' => array(0 => __DIR__ . '/..' . '/guzzlehttp/psr7/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\' => array(0 => __DIR__ . '/..' . '/guzzlehttp/promises/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\' => array(0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\' => array(0 => __DIR__ . '/..' . '/google/cloud-storage/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\' => array(0 => __DIR__ . '/..' . '/google/cloud-core/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\' => array(0 => __DIR__ . '/..' . '/google/auth/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\' => array(0 => __DIR__ . '/..' . '/firebase/php-jwt/src')); + public static $files = array('dbi_as3cf_gcp_7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php', 'dbi_as3cf_gcp_c964ee0ededf28c96ebd9db5099ef910' => __DIR__ . '/..' . '/guzzlehttp/promises/src/functions_include.php', 'dbi_as3cf_gcp_a0edc8309cc5e1d60e3047b5df6b7052' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/functions_include.php', 'dbi_as3cf_gcp_37a3dc5111fe8f707ab4c132ef1dbc62' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/functions_include.php'); + public static $prefixLengthsPsr4 = array('P' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\' => 8, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\' => 17, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\' => 10), 'M' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\' => 8), 'G' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\' => 16, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\' => 19, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\' => 11, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\' => 21, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\' => 18, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\' => 13, 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\' => 12), 'F' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\' => 13)); + public static $prefixDirsPsr4 = array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\' => array(0 => __DIR__ . '/..' . '/psr/log/Psr/Log'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\' => array(0 => __DIR__ . '/..' . '/psr/http-message/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\' => array(0 => __DIR__ . '/..' . '/psr/cache/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\' => array(0 => __DIR__ . '/..' . '/monolog/monolog/src/Monolog'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\' => array(0 => __DIR__ . '/..' . '/guzzlehttp/psr7/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\' => array(0 => __DIR__ . '/..' . '/guzzlehttp/promises/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\' => array(0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\' => array(0 => __DIR__ . '/..' . '/google/cloud-storage/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\' => array(0 => __DIR__ . '/..' . '/google/cloud-core/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\' => array(0 => __DIR__ . '/..' . '/google/crc32/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\' => array(0 => __DIR__ . '/..' . '/google/auth/src'), 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\' => array(0 => __DIR__ . '/..' . '/firebase/php-jwt/src')); public static $prefixesPsr0 = array('R' => array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate' => array(0 => __DIR__ . '/..' . '/rize/uri-template/src'))); - public static $classMap = array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\BeforeValidException' => __DIR__ . '/..' . '/firebase/php-jwt/src/BeforeValidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\ExpiredException' => __DIR__ . '/..' . '/firebase/php-jwt/src/ExpiredException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT' => __DIR__ . '/..' . '/firebase/php-jwt/src/JWT.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\SignatureInvalidException' => __DIR__ . '/..' . '/firebase/php-jwt/src/SignatureInvalidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\ApplicationDefaultCredentials' => __DIR__ . '/..' . '/google/auth/src/ApplicationDefaultCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CacheTrait' => __DIR__ . '/..' . '/google/auth/src/CacheTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\InvalidArgumentException' => __DIR__ . '/..' . '/google/auth/src/Cache/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\Item' => __DIR__ . '/..' . '/google/auth/src/Cache/Item.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\MemoryCacheItemPool' => __DIR__ . '/..' . '/google/auth/src/Cache/MemoryCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\SysVCacheItemPool' => __DIR__ . '/..' . '/google/auth/src/Cache/SysVCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CredentialsLoader' => __DIR__ . '/..' . '/google/auth/src/CredentialsLoader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\AppIdentityCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/AppIdentityCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\GCECredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/GCECredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\IAMCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/IAMCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\InsecureCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/InsecureCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/ServiceAccountCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountJwtAccessCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\UserRefreshCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/UserRefreshCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenCache' => __DIR__ . '/..' . '/google/auth/src/FetchAuthTokenCache.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenInterface' => __DIR__ . '/..' . '/google/auth/src/FetchAuthTokenInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle5HttpHandler' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/Guzzle5HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle6HttpHandler' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/Guzzle6HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\HttpHandlerFactory' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/HttpHandlerFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\AuthTokenMiddleware' => __DIR__ . '/..' . '/google/auth/src/Middleware/AuthTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\ScopedAccessTokenMiddleware' => __DIR__ . '/..' . '/google/auth/src/Middleware/ScopedAccessTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\SimpleMiddleware' => __DIR__ . '/..' . '/google/auth/src/Middleware/SimpleMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\OAuth2' => __DIR__ . '/..' . '/google/auth/src/OAuth2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\AuthTokenSubscriber' => __DIR__ . '/..' . '/google/auth/src/Subscriber/AuthTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\ScopedAccessTokenSubscriber' => __DIR__ . '/..' . '/google/auth/src/Subscriber/ScopedAccessTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\SimpleSubscriber' => __DIR__ . '/..' . '/google/auth/src/Subscriber/SimpleSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\AnonymousCredentials' => __DIR__ . '/..' . '/google/cloud-core/src/AnonymousCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ArrayTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ArrayTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemon' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchDaemon.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemonTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchDaemonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchJob' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchRunner' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchRunner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ClosureSerializerInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/ClosureSerializerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ConfigStorageInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/ConfigStorageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\HandleFailureTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/HandleFailureTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InMemoryConfigStorage' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/InMemoryConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InterruptTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/InterruptTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobConfig' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/JobConfig.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/JobInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/JobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\OpisClosureSerializer' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/OpisClosureSerializer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ProcessItemInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/ProcessItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\Retry' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SerializableClientTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SerializableClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJob' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SimpleJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJobTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SimpleJobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvConfigStorage' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SysvConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvProcessor' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SysvProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Blob' => __DIR__ . '/..' . '/google/cloud-core/src/Blob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\CallTrait' => __DIR__ . '/..' . '/google/cloud-core/src/CallTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ClientTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\ReaderInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata/Readers/ReaderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\StreamReader' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ConcurrencyControlTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ConcurrencyControlTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\DebugInfoTrait' => __DIR__ . '/..' . '/google/cloud-core/src/DebugInfoTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Duration' => __DIR__ . '/..' . '/google/cloud-core/src/Duration.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\EmulatorTrait' => __DIR__ . '/..' . '/google/cloud-core/src/EmulatorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\AbortedException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/AbortedException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\BadRequestException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/BadRequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ConflictException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/ConflictException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\DeadlineExceededException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/DeadlineExceededException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\FailedPreconditionException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/FailedPreconditionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\GoogleException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/GoogleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\NotFoundException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/NotFoundException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServerException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServiceException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/ServiceException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ExponentialBackoff' => __DIR__ . '/..' . '/google/cloud-core/src/ExponentialBackoff.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GeoPoint' => __DIR__ . '/..' . '/google/cloud-core/src/GeoPoint.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcRequestWrapper' => __DIR__ . '/..' . '/google/cloud-core/src/GrpcRequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcTrait' => __DIR__ . '/..' . '/google/cloud-core/src/GrpcTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\Iam' => __DIR__ . '/..' . '/google/cloud-core/src/Iam/Iam.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\IamConnectionInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Iam/IamConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\PolicyBuilder' => __DIR__ . '/..' . '/google/cloud-core/src/Iam/PolicyBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Int64' => __DIR__ . '/..' . '/google/cloud-core/src/Int64.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIterator' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/ItemIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIteratorTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/ItemIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIterator' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/PageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIteratorTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/PageIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\JsonTrait' => __DIR__ . '/..' . '/google/cloud-core/src/JsonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\FlockLock' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/FlockLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/LockInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/LockTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SemaphoreLock' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/SemaphoreLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SymfonyLockAdapter' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/SymfonyLockAdapter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexFormatter' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandler' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LROTrait' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/LROTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningConnectionInterface' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/LongRunningConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningOperation' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/LongRunningOperation.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\OperationResponseTrait' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/OperationResponseTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\PhpArray' => __DIR__ . '/..' . '/google/cloud-core/src/PhpArray.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\EmptyMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/EmptyMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEFlexMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/GAEFlexMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/GAEMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEStandardMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/GAEStandardMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Report/MetadataProviderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderUtils' => __DIR__ . '/..' . '/google/cloud-core/src/Report/MetadataProviderUtils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\SimpleMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/SimpleMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestBuilder' => __DIR__ . '/..' . '/google/cloud-core/src/RequestBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapper' => __DIR__ . '/..' . '/google/cloud-core/src/RequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapperTrait' => __DIR__ . '/..' . '/google/cloud-core/src/RequestWrapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RestTrait' => __DIR__ . '/..' . '/google/cloud-core/src/RestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Retry' => __DIR__ . '/..' . '/google/cloud-core/src/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RetryDeciderTrait' => __DIR__ . '/..' . '/google/cloud-core/src/RetryDeciderTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ServiceBuilder' => __DIR__ . '/..' . '/google/cloud-core/src/ServiceBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\SysvTrait' => __DIR__ . '/..' . '/google/cloud-core/src/SysvTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\ArrayHasSameValuesToken' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/ArrayHasSameValuesToken.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\CheckForClassTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/CheckForClassTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DatastoreOperationRefreshTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/DatastoreOperationRefreshTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DocBlockStripSpaces' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/DocBlockStripSpaces.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\FileListFilterIterator' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/FileListFilterIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\GrpcTestTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/GrpcTestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\KeyPairGenerateTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/KeyPairGenerateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Lock\\MockValues' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Lock/MockValues.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\RegexFileFilter' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/RegexFileFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Container' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Container.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Coverage' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/Coverage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ExcludeFilter' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/ExcludeFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ResultPrinter' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/ResultPrinter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Scanner' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/Scanner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ScannerInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/ScannerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Fixtures' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Fixtures.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\InvokeResult' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Parser/InvokeResult.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Parser' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Parser/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Snippet' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Parser/Snippet.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\SnippetTestCase' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/SnippetTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\StubTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/StubTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\DeletionQueue' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/System/DeletionQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\SystemTestCase' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/System/SystemTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\TestHelpers' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/TestHelpers.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\TimeTrait' => __DIR__ . '/..' . '/google/cloud-core/src/TimeTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Timestamp' => __DIR__ . '/..' . '/google/cloud-core/src/Timestamp.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\AbstractUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/AbstractUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\MultipartUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/MultipartUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\ResumableUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/ResumableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\SignedUrlUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/SignedUrlUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\StreamableUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/StreamableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\UriTrait' => __DIR__ . '/..' . '/google/cloud-core/src/UriTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValidateTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ValidateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValueMapperTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ValueMapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\WhitelistTrait' => __DIR__ . '/..' . '/google/cloud-core/src/WhitelistTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Acl' => __DIR__ . '/..' . '/google/cloud-storage/src/Acl.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Bucket' => __DIR__ . '/..' . '/google/cloud-storage/src/Bucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\ConnectionInterface' => __DIR__ . '/..' . '/google/cloud-storage/src/Connection/ConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\IamBucket' => __DIR__ . '/..' . '/google/cloud-storage/src/Connection/IamBucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\Rest' => __DIR__ . '/..' . '/google/cloud-storage/src/Connection/Rest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\EncryptionTrait' => __DIR__ . '/..' . '/google/cloud-storage/src/EncryptionTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Lifecycle' => __DIR__ . '/..' . '/google/cloud-storage/src/Lifecycle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Notification' => __DIR__ . '/..' . '/google/cloud-storage/src/Notification.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectIterator' => __DIR__ . '/..' . '/google/cloud-storage/src/ObjectIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectPageIterator' => __DIR__ . '/..' . '/google/cloud-storage/src/ObjectPageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ReadStream' => __DIR__ . '/..' . '/google/cloud-storage/src/ReadStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageClient' => __DIR__ . '/..' . '/google/cloud-storage/src/StorageClient.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageObject' => __DIR__ . '/..' . '/google/cloud-storage/src/StorageObject.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StreamWrapper' => __DIR__ . '/..' . '/google/cloud-storage/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\WriteStream' => __DIR__ . '/..' . '/google/cloud-storage/src/WriteStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Client' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Client.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\ClientInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/ClientInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJarInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\FileCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SessionCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SetCookie' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\BadResponseException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ClientException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ClientException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ConnectException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\GuzzleException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\RequestException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/RequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\SeekException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/SeekException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ServerException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TooManyRedirectsException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TransferException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TransferException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\HandlerStack' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/HandlerStack.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactory' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactoryInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlMultiHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\EasyHandle' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\MockHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\Proxy' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/Proxy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\StreamHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\MessageFormatter' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/MessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Middleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Middleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Pool' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Pool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\PrepareBodyMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\AggregateException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/AggregateException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\CancellationException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/CancellationException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Coroutine' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Coroutine.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\EachPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/EachPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\FulfilledPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/FulfilledPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Promise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Promise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromiseInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromiseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromisorInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromisorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectedPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectedPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectionException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueue' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueueInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueueInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\AppendStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/AppendStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\BufferStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/BufferStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\CachingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/CachingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\DroppingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/DroppingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\FnStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/FnStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\InflateStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/InflateStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LazyOpenStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LazyOpenStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LimitStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LimitStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MessageTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MessageTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MultipartStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MultipartStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\NoSeekStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/NoSeekStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\PumpStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/PumpStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Request' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Request.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Response' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Response.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Rfc7230' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Rfc7230.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\ServerRequest' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/ServerRequest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Stream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Stream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamWrapper' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UploadedFile' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UploadedFile.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Uri' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Uri.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriNormalizer' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriNormalizer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriResolver' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriResolver.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RedirectMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RequestOptions' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RequestOptions.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RetryMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RetryMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\TransferStats' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/TransferStats.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\UriTemplate' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ErrorHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/ErrorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ChromePHPFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/ChromePHPFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ElasticaFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/ElasticaFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FlowdockFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/FlowdockFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FluentdFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FormatterInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/FormatterInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\GelfMessageFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/GelfMessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\HtmlFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\JsonFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LineFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/LineFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogglyFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/LogglyFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogstashFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/LogstashFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\MongoDBFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\NormalizerFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ScalarFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/ScalarFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\WildfireFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/WildfireFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AbstractHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractProcessingHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractSyslogHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AbstractSyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AmqpHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AmqpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BrowserConsoleHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BufferHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/BufferHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ChromePHPHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CouchDBHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/CouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CubeHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/CubeHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Curl\\Util' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/Curl/Util.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DeduplicationHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/DeduplicationHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DoctrineCouchDBHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/DoctrineCouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DynamoDbHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/DynamoDbHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ElasticSearchHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ElasticSearchHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ErrorLogHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ErrorLogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FilterHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FilterHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossedHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ActivationStrategyInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ActivationStrategyInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ChannelLevelActivationStrategy' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ChannelLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ErrorLevelActivationStrategy' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ErrorLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FirePHPHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FirePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FleepHookHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FleepHookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FlowdockHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GelfHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/GelfHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GroupHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/GroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/HandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerWrapper' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/HandlerWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HipChatHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/HipChatHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\IFTTTHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\InsightOpsHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogEntriesHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/LogEntriesHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogglyHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/LogglyHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MailHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MailHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MandrillHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MandrillHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MissingExtensionException' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MissingExtensionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MongoDBHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MongoDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NativeMailerHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/NativeMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NewRelicHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NullHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/NullHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PHPConsoleHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PsrHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/PsrHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PushoverHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/PushoverHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RavenHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RavenHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RedisHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RedisHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RollbarHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RollbarHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RotatingFileHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SamplingHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SamplingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SlackHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackWebhookHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Slack\\SlackRecord' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackbotHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SocketHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SocketHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\StreamHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SwiftMailerHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SwiftMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdpHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdp\\UdpSocket' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SyslogUdp/UdpSocket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\TestHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/TestHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\WhatFailureGroupHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ZendMonitorHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Logger' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Logger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\GitProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/GitProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\IntrospectionProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/IntrospectionProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryPeakUsageProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MemoryPeakUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MemoryProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryUsageProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MemoryUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MercurialProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MercurialProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessIdProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/ProcessIdProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessorInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/ProcessorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\PsrLogMessageProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/PsrLogMessageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\TagProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/TagProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\UidProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/UidProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\WebProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/WebProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Registry' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Registry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ResettableInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/ResettableInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\SignalHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/SignalHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Utils' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Utils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheException' => __DIR__ . '/..' . '/psr/cache/src/CacheException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemPoolInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemPoolInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/cache/src/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\MessageInterface' => __DIR__ . '/..' . '/psr/http-message/src/MessageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\RequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/RequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ResponseInterface' => __DIR__ . '/..' . '/psr/http-message/src/ResponseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ServerRequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/ServerRequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\StreamInterface' => __DIR__ . '/..' . '/psr/http-message/src/StreamInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UploadedFileInterface' => __DIR__ . '/..' . '/psr/http-message/src/UploadedFileInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UriInterface' => __DIR__ . '/..' . '/psr/http-message/src/UriInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\AbstractLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/AbstractLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/log/Psr/Log/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LogLevel' => __DIR__ . '/..' . '/psr/log/Psr/Log/LogLevel.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\NullLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/NullLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\DummyTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\LoggerInterfaceTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\TestLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/TestLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Abstraction' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Expression' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Expression.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Literal' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Literal.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Variable' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Variable.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Abstraction' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Operator/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Named' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Operator/Named.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\UnNamed' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Operator/UnNamed.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Parser' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\UriTemplate' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/UriTemplate.php'); + public static $classMap = array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\BeforeValidException' => __DIR__ . '/..' . '/firebase/php-jwt/src/BeforeValidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\ExpiredException' => __DIR__ . '/..' . '/firebase/php-jwt/src/ExpiredException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT' => __DIR__ . '/..' . '/firebase/php-jwt/src/JWT.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\SignatureInvalidException' => __DIR__ . '/..' . '/firebase/php-jwt/src/SignatureInvalidException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\AccessToken' => __DIR__ . '/..' . '/google/auth/src/AccessToken.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\ApplicationDefaultCredentials' => __DIR__ . '/..' . '/google/auth/src/ApplicationDefaultCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CacheTrait' => __DIR__ . '/..' . '/google/auth/src/CacheTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\InvalidArgumentException' => __DIR__ . '/..' . '/google/auth/src/Cache/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\Item' => __DIR__ . '/..' . '/google/auth/src/Cache/Item.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\MemoryCacheItemPool' => __DIR__ . '/..' . '/google/auth/src/Cache/MemoryCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Cache\\SysVCacheItemPool' => __DIR__ . '/..' . '/google/auth/src/Cache/SysVCacheItemPool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\CredentialsLoader' => __DIR__ . '/..' . '/google/auth/src/CredentialsLoader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\AppIdentityCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/AppIdentityCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\GCECredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/GCECredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\IAMCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/IAMCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\InsecureCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/InsecureCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/ServiceAccountCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\ServiceAccountJwtAccessCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Credentials\\UserRefreshCredentials' => __DIR__ . '/..' . '/google/auth/src/Credentials/UserRefreshCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenCache' => __DIR__ . '/..' . '/google/auth/src/FetchAuthTokenCache.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\FetchAuthTokenInterface' => __DIR__ . '/..' . '/google/auth/src/FetchAuthTokenInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle5HttpHandler' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/Guzzle5HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\Guzzle6HttpHandler' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/Guzzle6HttpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\HttpClientCache' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/HttpClientCache.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\HttpHandler\\HttpHandlerFactory' => __DIR__ . '/..' . '/google/auth/src/HttpHandler/HttpHandlerFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Iam' => __DIR__ . '/..' . '/google/auth/src/Iam.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\AuthTokenMiddleware' => __DIR__ . '/..' . '/google/auth/src/Middleware/AuthTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\ScopedAccessTokenMiddleware' => __DIR__ . '/..' . '/google/auth/src/Middleware/ScopedAccessTokenMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Middleware\\SimpleMiddleware' => __DIR__ . '/..' . '/google/auth/src/Middleware/SimpleMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\OAuth2' => __DIR__ . '/..' . '/google/auth/src/OAuth2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\ServiceAccountSignerTrait' => __DIR__ . '/..' . '/google/auth/src/ServiceAccountSignerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\SignBlobInterface' => __DIR__ . '/..' . '/google/auth/src/SignBlobInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\AuthTokenSubscriber' => __DIR__ . '/..' . '/google/auth/src/Subscriber/AuthTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\ScopedAccessTokenSubscriber' => __DIR__ . '/..' . '/google/auth/src/Subscriber/ScopedAccessTokenSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\Subscriber\\SimpleSubscriber' => __DIR__ . '/..' . '/google/auth/src/Subscriber/SimpleSubscriber.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\Builtin' => __DIR__ . '/..' . '/google/crc32/src/Builtin.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\CRC32' => __DIR__ . '/..' . '/google/crc32/src/CRC32.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\CRCInterface' => __DIR__ . '/..' . '/google/crc32/src/CRCInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\CRCTrait' => __DIR__ . '/..' . '/google/crc32/src/CRCTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\Google' => __DIR__ . '/..' . '/google/crc32/src/Google.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\PHP' => __DIR__ . '/..' . '/google/crc32/src/PHP.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\PHPSlicedBy4' => __DIR__ . '/..' . '/google/crc32/src/PHPSlicedBy4.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\Table' => __DIR__ . '/..' . '/google/crc32/src/Table.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\AnonymousCredentials' => __DIR__ . '/..' . '/google/cloud-core/src/AnonymousCredentials.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ArrayTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ArrayTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemon' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchDaemon.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchDaemonTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchDaemonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchJob' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchRunner' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchRunner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\BatchTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/BatchTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ClosureSerializerInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/ClosureSerializerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ConfigStorageInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/ConfigStorageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\HandleFailureTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/HandleFailureTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InMemoryConfigStorage' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/InMemoryConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\InterruptTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/InterruptTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobConfig' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/JobConfig.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/JobInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\JobTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/JobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\OpisClosureSerializer' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/OpisClosureSerializer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\ProcessItemInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/ProcessItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\Retry' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SerializableClientTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SerializableClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJob' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SimpleJob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SimpleJobTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SimpleJobTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvConfigStorage' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SysvConfigStorage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Batch\\SysvProcessor' => __DIR__ . '/..' . '/google/cloud-core/src/Batch/SysvProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Blob' => __DIR__ . '/..' . '/google/cloud-core/src/Blob.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\CallTrait' => __DIR__ . '/..' . '/google/cloud-core/src/CallTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ClientTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ClientTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\HttpHandlerReader' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata/Readers/HttpHandlerReader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\ReaderInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata/Readers/ReaderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Compute\\Metadata\\Readers\\StreamReader' => __DIR__ . '/..' . '/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ConcurrencyControlTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ConcurrencyControlTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\DebugInfoTrait' => __DIR__ . '/..' . '/google/cloud-core/src/DebugInfoTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Duration' => __DIR__ . '/..' . '/google/cloud-core/src/Duration.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\EmulatorTrait' => __DIR__ . '/..' . '/google/cloud-core/src/EmulatorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\AbortedException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/AbortedException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\BadRequestException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/BadRequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ConflictException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/ConflictException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\DeadlineExceededException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/DeadlineExceededException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\FailedPreconditionException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/FailedPreconditionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\GoogleException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/GoogleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\NotFoundException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/NotFoundException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServerException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Exception\\ServiceException' => __DIR__ . '/..' . '/google/cloud-core/src/Exception/ServiceException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ExponentialBackoff' => __DIR__ . '/..' . '/google/cloud-core/src/ExponentialBackoff.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GeoPoint' => __DIR__ . '/..' . '/google/cloud-core/src/GeoPoint.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcRequestWrapper' => __DIR__ . '/..' . '/google/cloud-core/src/GrpcRequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\GrpcTrait' => __DIR__ . '/..' . '/google/cloud-core/src/GrpcTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\Iam' => __DIR__ . '/..' . '/google/cloud-core/src/Iam/Iam.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\IamConnectionInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Iam/IamConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iam\\PolicyBuilder' => __DIR__ . '/..' . '/google/cloud-core/src/Iam/PolicyBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Int64' => __DIR__ . '/..' . '/google/cloud-core/src/Int64.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIterator' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/ItemIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\ItemIteratorTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/ItemIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIterator' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/PageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Iterator\\PageIteratorTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Iterator/PageIteratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\JsonTrait' => __DIR__ . '/..' . '/google/cloud-core/src/JsonTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\FlockLock' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/FlockLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/LockInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\LockTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/LockTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SemaphoreLock' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/SemaphoreLock.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Lock\\SymfonyLockAdapter' => __DIR__ . '/..' . '/google/cloud-core/src/Lock/SymfonyLockAdapter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexFormatter' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexFormatterV2' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexFormatterV2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandler' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandlerFactory' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexHandlerFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\AppEngineFlexHandlerV2' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/AppEngineFlexHandlerV2.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Logger\\FormatterTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Logger/FormatterTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LROTrait' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/LROTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningConnectionInterface' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/LongRunningConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\LongRunningOperation' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/LongRunningOperation.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\LongRunning\\OperationResponseTrait' => __DIR__ . '/..' . '/google/cloud-core/src/LongRunning/OperationResponseTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\PhpArray' => __DIR__ . '/..' . '/google/cloud-core/src/PhpArray.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\EmptyMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/EmptyMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEFlexMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/GAEFlexMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/GAEMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\GAEStandardMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/GAEStandardMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Report/MetadataProviderInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\MetadataProviderUtils' => __DIR__ . '/..' . '/google/cloud-core/src/Report/MetadataProviderUtils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Report\\SimpleMetadataProvider' => __DIR__ . '/..' . '/google/cloud-core/src/Report/SimpleMetadataProvider.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestBuilder' => __DIR__ . '/..' . '/google/cloud-core/src/RequestBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapper' => __DIR__ . '/..' . '/google/cloud-core/src/RequestWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RequestWrapperTrait' => __DIR__ . '/..' . '/google/cloud-core/src/RequestWrapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RestTrait' => __DIR__ . '/..' . '/google/cloud-core/src/RestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Retry' => __DIR__ . '/..' . '/google/cloud-core/src/Retry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\RetryDeciderTrait' => __DIR__ . '/..' . '/google/cloud-core/src/RetryDeciderTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ServiceBuilder' => __DIR__ . '/..' . '/google/cloud-core/src/ServiceBuilder.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\SysvTrait' => __DIR__ . '/..' . '/google/cloud-core/src/SysvTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\ArrayHasSameValuesToken' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/ArrayHasSameValuesToken.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\CheckForClassTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/CheckForClassTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DatastoreOperationRefreshTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/DatastoreOperationRefreshTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\DocBlockStripSpaces' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/DocBlockStripSpaces.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\FileListFilterIterator' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/FileListFilterIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\GrpcTestTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/GrpcTestTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\KeyPairGenerateTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/KeyPairGenerateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Lock\\MockValues' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Lock/MockValues.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\RegexFileFilter' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/RegexFileFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Container' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Container.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Coverage' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/Coverage.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ExcludeFilter' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/ExcludeFilter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ResultPrinter' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/ResultPrinter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\Scanner' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/Scanner.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Coverage\\ScannerInterface' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Coverage/ScannerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Fixtures' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Fixtures.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\InvokeResult' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Parser/InvokeResult.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Parser' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Parser/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\Parser\\Snippet' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/Parser/Snippet.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\Snippet\\SnippetTestCase' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/Snippet/SnippetTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\StubTrait' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/StubTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\DeletionQueue' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/System/DeletionQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\KeyManager' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/System/KeyManager.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\System\\SystemTestCase' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/System/SystemTestCase.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Testing\\TestHelpers' => __DIR__ . '/..' . '/google/cloud-core/src/Testing/TestHelpers.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\TimeTrait' => __DIR__ . '/..' . '/google/cloud-core/src/TimeTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Timestamp' => __DIR__ . '/..' . '/google/cloud-core/src/Timestamp.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\AbstractUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/AbstractUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\MultipartUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/MultipartUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\ResumableUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/ResumableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\SignedUrlUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/SignedUrlUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\Upload\\StreamableUploader' => __DIR__ . '/..' . '/google/cloud-core/src/Upload/StreamableUploader.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\UriTrait' => __DIR__ . '/..' . '/google/cloud-core/src/UriTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValidateTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ValidateTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\ValueMapperTrait' => __DIR__ . '/..' . '/google/cloud-core/src/ValueMapperTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Core\\WhitelistTrait' => __DIR__ . '/..' . '/google/cloud-core/src/WhitelistTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Acl' => __DIR__ . '/..' . '/google/cloud-storage/src/Acl.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Bucket' => __DIR__ . '/..' . '/google/cloud-storage/src/Bucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\ConnectionInterface' => __DIR__ . '/..' . '/google/cloud-storage/src/Connection/ConnectionInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\IamBucket' => __DIR__ . '/..' . '/google/cloud-storage/src/Connection/IamBucket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Connection\\Rest' => __DIR__ . '/..' . '/google/cloud-storage/src/Connection/Rest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\CreatedHmacKey' => __DIR__ . '/..' . '/google/cloud-storage/src/CreatedHmacKey.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\EncryptionTrait' => __DIR__ . '/..' . '/google/cloud-storage/src/EncryptionTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\HmacKey' => __DIR__ . '/..' . '/google/cloud-storage/src/HmacKey.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Lifecycle' => __DIR__ . '/..' . '/google/cloud-storage/src/Lifecycle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\Notification' => __DIR__ . '/..' . '/google/cloud-storage/src/Notification.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectIterator' => __DIR__ . '/..' . '/google/cloud-storage/src/ObjectIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ObjectPageIterator' => __DIR__ . '/..' . '/google/cloud-storage/src/ObjectPageIterator.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\ReadStream' => __DIR__ . '/..' . '/google/cloud-storage/src/ReadStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\SigningHelper' => __DIR__ . '/..' . '/google/cloud-storage/src/SigningHelper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageClient' => __DIR__ . '/..' . '/google/cloud-storage/src/StorageClient.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StorageObject' => __DIR__ . '/..' . '/google/cloud-storage/src/StorageObject.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\StreamWrapper' => __DIR__ . '/..' . '/google/cloud-storage/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Cloud\\Storage\\WriteStream' => __DIR__ . '/..' . '/google/cloud-storage/src/WriteStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Client' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Client.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\ClientInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/ClientInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\CookieJarInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\FileCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SessionCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Cookie\\SetCookie' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\BadResponseException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ClientException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ClientException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ConnectException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\GuzzleException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\RequestException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/RequestException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\SeekException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/SeekException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\ServerException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ServerException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TooManyRedirectsException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Exception\\TransferException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TransferException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\HandlerStack' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/HandlerStack.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactory' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlFactoryInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\CurlMultiHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\EasyHandle' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\MockHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\Proxy' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/Proxy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Handler\\StreamHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\MessageFormatter' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/MessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Middleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Middleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Pool' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Pool.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\PrepareBodyMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\AggregateException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/AggregateException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\CancellationException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/CancellationException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Coroutine' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Coroutine.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\EachPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/EachPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\FulfilledPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/FulfilledPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\Promise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Promise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromiseInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromiseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\PromisorInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromisorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectedPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectedPromise.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\RejectionException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueue' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueue.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Promise\\TaskQueueInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueueInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\AppendStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/AppendStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\BufferStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/BufferStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\CachingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/CachingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\DroppingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/DroppingStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\FnStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/FnStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\InflateStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/InflateStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LazyOpenStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LazyOpenStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\LimitStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LimitStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MessageTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MessageTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\MultipartStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MultipartStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\NoSeekStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/NoSeekStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\PumpStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/PumpStream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Request' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Request.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Response' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Response.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Rfc7230' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Rfc7230.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\ServerRequest' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/ServerRequest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Stream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Stream.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\StreamWrapper' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UploadedFile' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UploadedFile.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\Uri' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Uri.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriNormalizer' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriNormalizer.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\UriResolver' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriResolver.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RedirectMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RequestOptions' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RequestOptions.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\RetryMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RetryMiddleware.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\TransferStats' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/TransferStats.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\UriTemplate' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ErrorHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/ErrorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ChromePHPFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/ChromePHPFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ElasticaFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/ElasticaFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FlowdockFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/FlowdockFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FluentdFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\FormatterInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/FormatterInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\GelfMessageFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/GelfMessageFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\HtmlFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\JsonFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LineFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/LineFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogglyFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/LogglyFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\LogstashFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/LogstashFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\MongoDBFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\NormalizerFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\ScalarFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/ScalarFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Formatter\\WildfireFormatter' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Formatter/WildfireFormatter.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AbstractHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractProcessingHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AbstractSyslogHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AbstractSyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\AmqpHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/AmqpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BrowserConsoleHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\BufferHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/BufferHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ChromePHPHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CouchDBHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/CouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\CubeHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/CubeHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Curl\\Util' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/Curl/Util.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DeduplicationHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/DeduplicationHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DoctrineCouchDBHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/DoctrineCouchDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\DynamoDbHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/DynamoDbHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ElasticSearchHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ElasticSearchHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ErrorLogHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ErrorLogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FilterHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FilterHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossedHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ActivationStrategyInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ActivationStrategyInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ChannelLevelActivationStrategy' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ChannelLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FingersCrossed\\ErrorLevelActivationStrategy' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FingersCrossed/ErrorLevelActivationStrategy.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FirePHPHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FirePHPHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FleepHookHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FleepHookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FlowdockHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FormattableHandlerInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FormattableHandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\FormattableHandlerTrait' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/FormattableHandlerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GelfHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/GelfHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\GroupHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/GroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/HandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HandlerWrapper' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/HandlerWrapper.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\HipChatHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/HipChatHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\IFTTTHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\InsightOpsHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogEntriesHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/LogEntriesHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\LogglyHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/LogglyHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MailHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MailHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MandrillHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MandrillHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MissingExtensionException' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MissingExtensionException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\MongoDBHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/MongoDBHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NativeMailerHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/NativeMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NewRelicHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\NullHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/NullHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PHPConsoleHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ProcessableHandlerInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ProcessableHandlerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ProcessableHandlerTrait' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ProcessableHandlerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PsrHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/PsrHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\PushoverHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/PushoverHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RavenHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RavenHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RedisHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RedisHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RollbarHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RollbarHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\RotatingFileHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SamplingHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SamplingHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SlackHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackWebhookHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\Slack\\SlackRecord' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SlackbotHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SocketHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SocketHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\StreamHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/StreamHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SwiftMailerHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SwiftMailerHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SyslogHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdpHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\SyslogUdp\\UdpSocket' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/SyslogUdp/UdpSocket.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\TestHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/TestHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\WhatFailureGroupHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Handler\\ZendMonitorHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Logger' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Logger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\GitProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/GitProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\IntrospectionProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/IntrospectionProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryPeakUsageProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MemoryPeakUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MemoryProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MemoryUsageProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MemoryUsageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\MercurialProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/MercurialProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessIdProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/ProcessIdProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\ProcessorInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/ProcessorInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\PsrLogMessageProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/PsrLogMessageProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\TagProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/TagProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\UidProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/UidProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Processor\\WebProcessor' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Processor/WebProcessor.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Registry' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Registry.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\ResettableInterface' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/ResettableInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\SignalHandler' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/SignalHandler.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Utils' => __DIR__ . '/..' . '/monolog/monolog/src/Monolog/Utils.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheException' => __DIR__ . '/..' . '/psr/cache/src/CacheException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\CacheItemPoolInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemPoolInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Cache\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/cache/src/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\MessageInterface' => __DIR__ . '/..' . '/psr/http-message/src/MessageInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\RequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/RequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ResponseInterface' => __DIR__ . '/..' . '/psr/http-message/src/ResponseInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\ServerRequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/ServerRequestInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\StreamInterface' => __DIR__ . '/..' . '/psr/http-message/src/StreamInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UploadedFileInterface' => __DIR__ . '/..' . '/psr/http-message/src/UploadedFileInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Http\\Message\\UriInterface' => __DIR__ . '/..' . '/psr/http-message/src/UriInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\AbstractLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/AbstractLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/log/Psr/Log/InvalidArgumentException.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LogLevel' => __DIR__ . '/..' . '/psr/log/Psr/Log/LogLevel.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerAwareTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerInterface.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\LoggerTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerTrait.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\NullLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/NullLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\DummyTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\LoggerInterfaceTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Psr\\Log\\Test\\TestLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/TestLogger.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Abstraction' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Expression' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Expression.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Literal' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Literal.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Node\\Variable' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Node/Variable.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Abstraction' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Operator/Abstraction.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\Named' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Operator/Named.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Operator\\UnNamed' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Operator/UnNamed.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\Parser' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/Parser.php', 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Rize\\UriTemplate\\UriTemplate' => __DIR__ . '/..' . '/rize/uri-template/src/Rize/UriTemplate/UriTemplate.php'); public static function getInitializer(\DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload\ClassLoader $loader) { return \Closure::bind(function () use($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20::$prefixDirsPsr4; - $loader->prefixesPsr0 = ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20::$prefixesPsr0; - $loader->classMap = ComposerStaticInit9fd2c411275a48d2ebf11f5a1bd6ca20::$classMap; + $loader->prefixLengthsPsr4 = ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8::$prefixLengthsPsr4; + $loader->prefixDirsPsr4 = ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8::$prefixDirsPsr4; + $loader->prefixesPsr0 = ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8::$prefixesPsr0; + $loader->classMap = ComposerStaticInitad2bbf672104326f33ebff61e2e8e9b8::$classMap; }, null, \DeliciousBrains\WP_Offload_Media\Gcp\Composer\Autoload\ClassLoader::class); } } diff --git a/vendor/Gcp/composer/installed.json b/vendor/Gcp/composer/installed.json index adf0825c..47d48bb0 100644 --- a/vendor/Gcp/composer/installed.json +++ b/vendor/Gcp/composer/installed.json @@ -49,17 +49,17 @@ }, { "name": "google\/auth", - "version": "v1.4.0", - "version_normalized": "1.4.0.0", + "version": "v1.6.1", + "version_normalized": "1.6.1.0", "source": { "type": "git", "url": "https:\/\/github.com\/googleapis\/google-auth-library-php.git", - "reference": "196237248e636a3554a7d9e4dfddeb97f450ab5c" + "reference": "45635ac69d0b95f38885531d4ebcdfcb2ebb6f36" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/googleapis\/google-auth-library-php\/zipball\/196237248e636a3554a7d9e4dfddeb97f450ab5c", - "reference": "196237248e636a3554a7d9e4dfddeb97f450ab5c", + "url": "https:\/\/api.github.com\/repos\/googleapis\/google-auth-library-php\/zipball\/45635ac69d0b95f38885531d4ebcdfcb2ebb6f36", + "reference": "45635ac69d0b95f38885531d4ebcdfcb2ebb6f36", "shasum": "" }, "require": { @@ -73,10 +73,14 @@ "require-dev": { "friendsofphp\/php-cs-fixer": "^1.11", "guzzlehttp\/promises": "0.1.1|^1.3", + "phpseclib\/phpseclib": "^2", "phpunit\/phpunit": "^4.8.36|^5.7", "sebastian\/comparator": ">=1.2.3" }, - "time": "2018-09-17T20:29:21+00:00", + "suggest": { + "phpseclib\/phpseclib": "May be used in place of OpenSSL for signing strings or for token management. Please require version ^2." + }, + "time": "2019-10-29T20:13:04+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -98,32 +102,33 @@ }, { "name": "google\/cloud-core", - "version": "v1.25.1", - "version_normalized": "1.25.1.0", + "version": "v1.34.0", + "version_normalized": "1.34.0.0", "source": { "type": "git", "url": "https:\/\/github.com\/googleapis\/google-cloud-php-core.git", - "reference": "106c78d25b14f55167338d71737507be2bf8400c" + "reference": "52db21acb2da25d2d79e493842de58da7836c97f" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/googleapis\/google-cloud-php-core\/zipball\/106c78d25b14f55167338d71737507be2bf8400c", - "reference": "106c78d25b14f55167338d71737507be2bf8400c", + "url": "https:\/\/api.github.com\/repos\/googleapis\/google-cloud-php-core\/zipball\/52db21acb2da25d2d79e493842de58da7836c97f", + "reference": "52db21acb2da25d2d79e493842de58da7836c97f", "shasum": "" }, "require": { - "google\/auth": "^1.2", + "google\/auth": "^1.6", "guzzlehttp\/guzzle": "^5.3|^6.0", "guzzlehttp\/promises": "^1.3", "guzzlehttp\/psr7": "^1.2", - "monolog\/monolog": "~1", + "monolog\/monolog": "^1.1|^2.0", "php": ">=5.5", "psr\/http-message": "1.0.*", "rize\/uri-template": "~0.3" }, "require-dev": { "erusev\/parsedown": "^1.6", - "google\/gax": "^0.38.0", + "google\/common-protos": "^1.0", + "google\/gax": "^1.1", "opis\/closure": "^3", "phpdocumentor\/reflection": "^3.0", "phpunit\/phpunit": "^4.8|^5.0", @@ -133,7 +138,7 @@ "opis\/closure": "May be used to serialize closures to process jobs in the batch daemon. Please require version ^3.", "symfony\/lock": "Required for the Spanner cached based session pool. Please require the following commit: 3.3.x-dev#1ba6ac9" }, - "time": "2018-12-18T18:55:23+00:00", + "time": "2019-10-28T19:05:44+00:00", "bin": [ "bin\/google-cloud-batch" ], @@ -160,21 +165,22 @@ }, { "name": "google\/cloud-storage", - "version": "v1.10.0", - "version_normalized": "1.10.0.0", + "version": "v1.16.0", + "version_normalized": "1.16.0.0", "source": { "type": "git", "url": "https:\/\/github.com\/googleapis\/google-cloud-php-storage.git", - "reference": "6e2ea113a802f95f3779931e5446c42afbd75cb8" + "reference": "308ad790b257286e02777e3bf1a2c0473a4651a7" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/googleapis\/google-cloud-php-storage\/zipball\/6e2ea113a802f95f3779931e5446c42afbd75cb8", - "reference": "6e2ea113a802f95f3779931e5446c42afbd75cb8", + "url": "https:\/\/api.github.com\/repos\/googleapis\/google-cloud-php-storage\/zipball\/308ad790b257286e02777e3bf1a2c0473a4651a7", + "reference": "308ad790b257286e02777e3bf1a2c0473a4651a7", "shasum": "" }, "require": { - "google\/cloud-core": "^1.25" + "google\/cloud-core": "^1.31", + "google\/crc32": "^0.1.0" }, "require-dev": { "erusev\/parsedown": "^1.6", @@ -188,7 +194,7 @@ "google\/cloud-pubsub": "May be used to register a topic to receive bucket notifications.", "phpseclib\/phpseclib": "May be used in place of OpenSSL for creating signed Cloud Storage URLs. Please require version ^2." }, - "time": "2018-12-10T22:57:51+00:00", + "time": "2019-11-12T23:35:42+00:00", "type": "library", "extra": { "component": { @@ -210,35 +216,80 @@ ], "description": "Cloud Storage Client for PHP" }, + { + "name": "google\/crc32", + "version": "v0.1.0", + "version_normalized": "0.1.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/google\/php-crc32.git", + "reference": "a8525f0dea6fca1893e1bae2f6e804c5f7d007fb" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/google\/php-crc32\/zipball\/a8525f0dea6fca1893e1bae2f6e804c5f7d007fb", + "reference": "a8525f0dea6fca1893e1bae2f6e804c5f7d007fb", + "shasum": "" + }, + "require": { + "php": ">=5.4" + }, + "require-dev": { + "friendsofphp\/php-cs-fixer": "^1.13 || v2.14.2", + "paragonie\/random_compat": ">=2", + "phpunit\/phpunit": "^4" + }, + "time": "2019-05-09T06:24:58+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\": "src" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "Andrew Brampton", + "email": "bramp@google.com" + } + ], + "description": "Various CRC32 implementations", + "homepage": "https:\/\/github.com\/google\/php-crc32" + }, { "name": "guzzlehttp\/guzzle", - "version": "6.3.3", - "version_normalized": "6.3.3.0", + "version": "6.4.1", + "version_normalized": "6.4.1.0", "source": { "type": "git", "url": "https:\/\/github.com\/guzzle\/guzzle.git", - "reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba" + "reference": "0895c932405407fd3a7368b6910c09a24d26db11" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/guzzle\/guzzle\/zipball\/407b0cb880ace85c9b63c5f9551db498cb2d50ba", - "reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba", + "url": "https:\/\/api.github.com\/repos\/guzzle\/guzzle\/zipball\/0895c932405407fd3a7368b6910c09a24d26db11", + "reference": "0895c932405407fd3a7368b6910c09a24d26db11", "shasum": "" }, "require": { + "ext-json": "*", "guzzlehttp\/promises": "^1.0", - "guzzlehttp\/psr7": "^1.4", + "guzzlehttp\/psr7": "^1.6.1", "php": ">=5.5" }, "require-dev": { "ext-curl": "*", "phpunit\/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr\/log": "^1.0" + "psr\/log": "^1.1" }, "suggest": { "psr\/log": "Required for using the Log middleware" }, - "time": "2018-04-22T15:46:56+00:00", + "time": "2019-10-23T15:58:00+00:00", "type": "library", "extra": { "branch-alias": { @@ -247,12 +298,12 @@ }, "installation-source": "dist", "autoload": { - "files": [ - "src\/functions_include.php" - ], "psr-4": { "DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\": "src\/" - } + }, + "files": [ + "src\/functions_include.php" + ] }, "notification-url": "https:\/\/packagist.org\/downloads\/", "license": [ @@ -332,35 +383,39 @@ }, { "name": "guzzlehttp\/psr7", - "version": "1.5.2", - "version_normalized": "1.5.2.0", + "version": "1.6.1", + "version_normalized": "1.6.1.0", "source": { "type": "git", "url": "https:\/\/github.com\/guzzle\/psr7.git", - "reference": "9f83dded91781a01c63574e387eaa769be769115" + "reference": "239400de7a173fe9901b9ac7c06497751f00727a" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/guzzle\/psr7\/zipball\/9f83dded91781a01c63574e387eaa769be769115", - "reference": "9f83dded91781a01c63574e387eaa769be769115", + "url": "https:\/\/api.github.com\/repos\/guzzle\/psr7\/zipball\/239400de7a173fe9901b9ac7c06497751f00727a", + "reference": "239400de7a173fe9901b9ac7c06497751f00727a", "shasum": "" }, "require": { "php": ">=5.4.0", "psr\/http-message": "~1.0", - "ralouphie\/getallheaders": "^2.0.5" + "ralouphie\/getallheaders": "^2.0.5 || ^3.0.0" }, "provide": { "psr\/http-message-implementation": "1.0" }, "require-dev": { + "ext-zlib": "*", "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" }, - "time": "2018-12-04T20:46:45+00:00", + "suggest": { + "zendframework\/zend-httphandlerrunner": "Emit PSR-7 responses" + }, + "time": "2019-07-01T23:21:34+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.5-dev" + "dev-master": "1.6-dev" } }, "installation-source": "dist", @@ -401,17 +456,17 @@ }, { "name": "monolog\/monolog", - "version": "1.24.0", - "version_normalized": "1.24.0.0", + "version": "1.25.2", + "version_normalized": "1.25.2.0", "source": { "type": "git", "url": "https:\/\/github.com\/Seldaek\/monolog.git", - "reference": "bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266" + "reference": "d5e2fb341cb44f7e2ab639d12a1e5901091ec287" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/Seldaek\/monolog\/zipball\/bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266", - "reference": "bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266", + "url": "https:\/\/api.github.com\/repos\/Seldaek\/monolog\/zipball\/d5e2fb341cb44f7e2ab639d12a1e5901091ec287", + "reference": "d5e2fb341cb44f7e2ab639d12a1e5901091ec287", "shasum": "" }, "require": { @@ -447,7 +502,7 @@ "ruflin\/elastica": "Allow sending log messages to an Elastic Search server", "sentry\/sentry": "Allow sending log messages to a Sentry server" }, - "time": "2018-11-05T09:00:11+00:00", + "time": "2019-11-13T10:00:05+00:00", "type": "library", "extra": { "branch-alias": { @@ -581,27 +636,27 @@ }, { "name": "psr\/log", - "version": "1.1.0", - "version_normalized": "1.1.0.0", + "version": "1.1.2", + "version_normalized": "1.1.2.0", "source": { "type": "git", "url": "https:\/\/github.com\/php-fig\/log.git", - "reference": "6c001f1daafa3a3ac1d8ff69ee4db8e799a654dd" + "reference": "446d54b4cb6bf489fc9d75f55843658e6f25d801" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/php-fig\/log\/zipball\/6c001f1daafa3a3ac1d8ff69ee4db8e799a654dd", - "reference": "6c001f1daafa3a3ac1d8ff69ee4db8e799a654dd", + "url": "https:\/\/api.github.com\/repos\/php-fig\/log\/zipball\/446d54b4cb6bf489fc9d75f55843658e6f25d801", + "reference": "446d54b4cb6bf489fc9d75f55843658e6f25d801", "shasum": "" }, "require": { "php": ">=5.3.0" }, - "time": "2018-11-20T15:27:04+00:00", + "time": "2019-11-01T11:05:21+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.1.x-dev" } }, "installation-source": "dist", @@ -630,27 +685,27 @@ }, { "name": "ralouphie\/getallheaders", - "version": "2.0.5", - "version_normalized": "2.0.5.0", + "version": "3.0.3", + "version_normalized": "3.0.3.0", "source": { "type": "git", "url": "https:\/\/github.com\/ralouphie\/getallheaders.git", - "reference": "5601c8a83fbba7ef674a7369456d12f1e0d0eafa" + "reference": "120b605dfeb996808c31b6477290a714d356e822" }, "dist": { "type": "zip", - "url": "https:\/\/api.github.com\/repos\/ralouphie\/getallheaders\/zipball\/5601c8a83fbba7ef674a7369456d12f1e0d0eafa", - "reference": "5601c8a83fbba7ef674a7369456d12f1e0d0eafa", + "url": "https:\/\/api.github.com\/repos\/ralouphie\/getallheaders\/zipball\/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", "shasum": "" }, "require": { - "php": ">=5.3" + "php": ">=5.6" }, "require-dev": { - "phpunit\/phpunit": "~3.7.0", - "satooshi\/php-coveralls": ">=1.0" + "php-coveralls\/php-coveralls": "^2.1", + "phpunit\/phpunit": "^5 || ^6.5" }, - "time": "2016-02-11T07:05:27+00:00", + "time": "2019-03-08T08:55:37+00:00", "type": "library", "installation-source": "dist", "autoload": { diff --git a/vendor/Gcp/google/auth/CHANGELOG.md b/vendor/Gcp/google/auth/CHANGELOG.md index 0bfb1a8f..58d37431 100644 --- a/vendor/Gcp/google/auth/CHANGELOG.md +++ b/vendor/Gcp/google/auth/CHANGELOG.md @@ -1,3 +1,34 @@ +## 1.6.1 (10/29/2019) + +* [fix] Handle DST correctly for cache item expirations. (#246) + +## 1.6.0 (10/01/2019) + +* [feat] Add utility for verifying and revoking access tokens. (#243) +* [docs] Fix README console terminology. (#242) +* [feat] Support custom scopes with GCECredentials. (#239) +* [fix] Fix phpseclib existence check. (#237) + +## 1.5.2 (07/22/2019) + +* [fix] Move loadItems call out of `SysVCacheItemPool` constructor. (#229) +* [fix] Add `Metadata-Flavor` header to initial GCE metadata call. (#232) + +## 1.5.1 (04/16/2019) + +* [fix] Moved `getClientName()` from `Google\Auth\FetchAuthTokenInterface` + to `Google\Auth\SignBlobInterface`, and removed `getClientName()` from + `InsecureCredentials` and `UserRefreshCredentials`. (#223) + +## 1.5.0 (04/15/2019) + +### Changes + + * Add support for signing strings with a Credentials instance. (#221) + * [Docs] Describe the arrays returned by fetchAuthToken. (#216) + * [Testing] Fix failing tests (#217) + * Update GitHub issue templates (#214, #213) + ## 1.4.0 (09/17/2018) ### Changes diff --git a/vendor/Gcp/google/auth/CONTRIBUTING.md b/vendor/Gcp/google/auth/CONTRIBUTING.md deleted file mode 100644 index 0cfb74b6..00000000 --- a/vendor/Gcp/google/auth/CONTRIBUTING.md +++ /dev/null @@ -1,73 +0,0 @@ -# How to become a contributor and submit your own code - -## Contributor License Agreements - -We'd love to accept your sample apps and patches! Before we can take them, we -have to jump a couple of legal hurdles. - -Please fill out either the individual or corporate Contributor License Agreement -(CLA). - - * If you are an individual writing original source code and you're sure you - own the intellectual property, then you'll need to sign an [individual CLA] - (http://code.google.com/legal/individual-cla-v1.0.html). - * If you work for a company that wants to allow you to contribute your work, - then you'll need to sign a [corporate CLA] - (http://code.google.com/legal/corporate-cla-v1.0.html). - -Follow either of the two links above to access the appropriate CLA and -instructions for how to sign and return it. Once we receive it, we'll be able to -accept your pull requests. - -## Issue reporting - -* Check that the issue has not already been reported. -* Check that the issue has not already been fixed in the latest code - (a.k.a. `master`). -* Be clear, concise and precise in your description of the problem. -* Open an issue with a descriptive title and a summary in grammatically correct, - complete sentences. -* Include any relevant code to the issue summary. - -## Pull requests - -* Read [how to properly contribute to open source projects on Github][2]. -* Fork the project. -* Use a topic/feature branch to easily amend a pull request later, if necessary. -* Write [good commit messages][3]. -* Use the same coding conventions as the rest of the project. -* Commit and push until you are happy with your contribution. -* Make sure to add tests for it. This is important so I don't break it - in a future version unintentionally. -* Add an entry to the [Changelog](CHANGELOG.md) accordingly. See [changelog entry format](#changelog-entry-format). -* Please try not to mess with the Rakefile, version, or history. If you want to - have your own version, or is otherwise necessary, that is fine, but please - isolate to its own commit so I can cherry-pick around it. -* Make sure the test suite is passing and the code you wrote doesn't produce - phpunit or phplint offenses. -* [Squash related commits together][5]. -* Open a [pull request][4] that relates to *only* one subject with a clear title - and description in grammatically correct, complete sentences. - -### Changelog entry format - -Here are a few examples: - -``` -* ADC Support for User Refresh Tokens (@tbetbetbe[]) -* [#16](https://github.com/google/google-auth-library-php/issues/16): ADC Support for User Refresh Tokens ([@tbetbetbe][]) -``` - -* Mark it up in [Markdown syntax][6]. -* The entry line should start with `* ` (an asterisk and a space). -* If the change has a related GitHub issue (e.g. a bug fix for a reported issue), put a link to the issue as `[#16](https://github.com/google/google-auth-library-php/issues/16): `. -* Describe the brief of the change. The sentence should end with a punctuation. -* At the end of the entry, add an implicit link to your GitHub user page as `([@username][])`. -* If this is your first contribution to google-auth-library-php project, add a link definition for the implicit link to the bottom of the changelog as `[@username]: https://github.com/username`. - -[1]: https://github.com/google/google-auth-php-library/issues -[2]: http://gun.io/blog/how-to-github-fork-branch-and-pull-request -[3]: http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html -[4]: https://help.github.com/articles/using-pull-requests -[5]: http://gitready.com/advanced/2009/02/10/squashing-commits-with-rebase.html -[6]: http://daringfireball.net/projects/markdown/syntax diff --git a/vendor/Gcp/google/auth/README.md b/vendor/Gcp/google/auth/README.md index d102382a..eea62eef 100644 --- a/vendor/Gcp/google/auth/README.md +++ b/vendor/Gcp/google/auth/README.md @@ -47,7 +47,7 @@ you're building an application that uses Google Compute Engine. #### Download your Service Account Credentials JSON file To use `Application Default Credentials`, You first need to download a set of -JSON credentials for your project. Go to **APIs & Auth** > **Credentials** in +JSON credentials for your project. Go to **APIs & Services** > **Credentials** in the [Google Developers Console][developer console] and select **Service account** from the **Add credentials** dropdown. @@ -143,7 +143,7 @@ about the client or APIs on [StackOverflow](http://stackoverflow.com). [google-apis-php-client]: https://github.com/google/google-api-php-client [application default credentials]: https://developers.google.com/accounts/docs/application-default-credentials -[contributing]: https://github.com/google/google-auth-library-php/tree/master/CONTRIBUTING.md +[contributing]: https://github.com/google/google-auth-library-php/tree/master/.github/CONTRIBUTING.md [copying]: https://github.com/google/google-auth-library-php/tree/master/COPYING [Guzzle]: https://github.com/guzzle/guzzle [Guzzle 5]: http://docs.guzzlephp.org/en/5.3 diff --git a/vendor/Gcp/google/auth/composer.json b/vendor/Gcp/google/auth/composer.json index cc474526..47c8cb51 100644 --- a/vendor/Gcp/google/auth/composer.json +++ b/vendor/Gcp/google/auth/composer.json @@ -21,7 +21,11 @@ "guzzlehttp\/promises": "0.1.1|^1.3", "friendsofphp\/php-cs-fixer": "^1.11", "phpunit\/phpunit": "^4.8.36|^5.7", - "sebastian\/comparator": ">=1.2.3" + "sebastian\/comparator": ">=1.2.3", + "phpseclib\/phpseclib": "^2" + }, + "suggest": { + "phpseclib\/phpseclib": "May be used in place of OpenSSL for signing strings or for token management. Please require version ^2." }, "autoload": { "psr-4": { diff --git a/vendor/Gcp/google/auth/phpunit.xml.dist b/vendor/Gcp/google/auth/phpunit.xml.dist deleted file mode 100644 index 31a80334..00000000 --- a/vendor/Gcp/google/auth/phpunit.xml.dist +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - tests - - - - - src - - src/ - - - - diff --git a/vendor/Gcp/google/auth/src/AccessToken.php b/vendor/Gcp/google/auth/src/AccessToken.php new file mode 100644 index 00000000..87ce70d9 --- /dev/null +++ b/vendor/Gcp/google/auth/src/AccessToken.php @@ -0,0 +1,253 @@ +httpHandler = $httpHandler ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); + $this->cache = $cache ?: new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Cache\MemoryCacheItemPool(); + $this->configureJwtService(); + // set phpseclib constants if applicable + $this->setPhpsecConstants(); + } + /** + * Verifies an id token and returns the authenticated apiLoginTicket. + * Throws an exception if the id token is not valid. + * The audience parameter can be used to control which id tokens are + * accepted. By default, the id token must have been issued to this OAuth2 client. + * + * @param string $token The JSON Web Token to be verified. + * @param array $options [optional] { + * Configuration options. + * + * @type string $audience The indended recipient of the token. + * @type string $certsLocation The location (remote or local) from which + * to retrieve certificates, if not cached. This value should only be + * provided in limited circumstances in which you are sure of the + * behavior. + * } + * @return array|bool the token payload, if successful, or false if not. + * @throws \InvalidArgumentException If certs could not be retrieved from a local file. + * @throws \InvalidArgumentException If received certs are in an invalid format. + * @throws \RuntimeException If certs could not be retrieved from a remote location. + */ + public function verify($token, array $options = []) + { + $audience = isset($options['audience']) ? $options['audience'] : null; + $certsLocation = isset($options['certsLocation']) ? $options['certsLocation'] : self::FEDERATED_SIGNON_CERT_URL; + unset($options['audience'], $options['certsLocation']); + // Check signature against each available cert. + // allow the loop to complete unless a known bad result is encountered. + $certs = $this->getFederatedSignOnCerts($certsLocation, $options); + foreach ($certs as $cert) { + $rsa = new \DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Crypt\RSA(); + $rsa->loadKey(['n' => new \DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Math\BigInteger($this->callJwtStatic('urlsafeB64Decode', [$cert['n']]), 256), 'e' => new \DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Math\BigInteger($this->callJwtStatic('urlsafeB64Decode', [$cert['e']]), 256)]); + try { + $pubkey = $rsa->getPublicKey(); + $payload = $this->callJwtStatic('decode', [$token, $pubkey, ['RS256']]); + if (property_exists($payload, 'aud')) { + if ($audience && $payload->aud != $audience) { + return false; + } + } + // support HTTP and HTTPS issuers + // @see https://developers.google.com/identity/sign-in/web/backend-auth + $issuers = [self::OAUTH2_ISSUER, self::OAUTH2_ISSUER_HTTPS]; + if (!isset($payload->iss) || !in_array($payload->iss, $issuers)) { + return false; + } + return (array) $payload; + } catch (ExpiredException $e) { + return false; + } catch (\ExpiredException $e) { + // (firebase/php-jwt 2) + return false; + } catch (SignatureInvalidException $e) { + // continue + } catch (\SignatureInvalidException $e) { + // continue (firebase/php-jwt 2) + } catch (\DomainException $e) { + // continue + } + } + return false; + } + /** + * Revoke an OAuth2 access token or refresh token. This method will revoke the current access + * token, if a token isn't provided. + * + * @param string|array $token The token (access token or a refresh token) that should be revoked. + * @param array $options [optional] Configuration options. + * @return boolean Returns True if the revocation was successful, otherwise False. + */ + public function revoke($token, array $options = []) + { + if (is_array($token)) { + if (isset($token['refresh_token'])) { + $token = $token['refresh_token']; + } else { + $token = $token['access_token']; + } + } + $body = \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\stream_for(http_build_query(['token' => $token])); + $request = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('POST', self::OAUTH2_REVOKE_URI, ['Cache-Control' => 'no-store', 'Content-Type' => 'application/x-www-form-urlencoded'], $body); + $httpHandler = $this->httpHandler; + $response = $httpHandler($request, $options); + return $response->getStatusCode() == 200; + } + /** + * Gets federated sign-on certificates to use for verifying identity tokens. + * Returns certs as array structure, where keys are key ids, and values + * are PEM encoded certificates. + * + * @param string $location The location from which to retrieve certs. + * @param array $options [optional] Configuration options. + * @return array + * @throws \InvalidArgumentException If received certs are in an invalid format. + */ + private function getFederatedSignOnCerts($location, array $options = []) + { + $cacheItem = $this->cache->getItem('federated_signon_certs_v3'); + $certs = $cacheItem ? $cacheItem->get() : null; + $gotNewCerts = false; + if (!$certs) { + $certs = $this->retrieveCertsFromLocation($location, $options); + $gotNewCerts = true; + } + if (!isset($certs['keys'])) { + throw new \InvalidArgumentException('federated sign-on certs expects "keys" to be set'); + } + // Push caching off until after verifying certs are in a valid format. + // Don't want to cache bad data. + if ($gotNewCerts) { + $cacheItem->expiresAt(new \DateTime('+1 hour')); + $cacheItem->set($certs); + $this->cache->save($cacheItem); + } + return $certs['keys']; + } + /** + * Retrieve and cache a certificates file. + * + * @param $url string location + * @param array $options [optional] Configuration options. + * @throws \RuntimeException + * @return array certificates + * @throws \InvalidArgumentException If certs could not be retrieved from a local file. + * @throws \RuntimeException If certs could not be retrieved from a remote location. + */ + private function retrieveCertsFromLocation($url, array $options = []) + { + // If we're retrieving a local file, just grab it. + if (strpos($url, 'http') !== 0) { + if (!file_exists($url)) { + throw new \InvalidArgumentException(sprintf('Failed to retrieve verification certificates from path: %s.', $url)); + } + return json_decode(file_get_contents($url), true); + } + $httpHandler = $this->httpHandler; + $response = $httpHandler(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', $url), $options); + if ($response->getStatusCode() == 200) { + return json_decode((string) $response->getBody(), true); + } + throw new \RuntimeException(sprintf('Failed to retrieve verification certificates: "%s".', $response->getBody()->getContents()), $response->getStatusCode()); + } + /** + * Set required defaults for JWT. + */ + private function configureJwtService() + { + $class = class_exists('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT') ? 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT' : '\\JWT'; + if (property_exists($class, 'leeway') && $class::$leeway < 1) { + // Ensures JWT leeway is at least 1 + // @see https://github.com/google/google-api-php-client/issues/827 + $class::$leeway = 1; + } + } + /** + * phpseclib calls "phpinfo" by default, which requires special + * whitelisting in the AppEngine VM environment. This function + * sets constants to bypass the need for phpseclib to check phpinfo + * + * @see phpseclib/Math/BigInteger + * @see https://github.com/GoogleCloudPlatform/getting-started-php/issues/85 + * @codeCoverageIgnore + */ + private function setPhpsecConstants() + { + if (filter_var(getenv('GAE_VM'), FILTER_VALIDATE_BOOLEAN)) { + if (!defined('MATH_BIGINTEGER_OPENSSL_ENABLED')) { + define('MATH_BIGINTEGER_OPENSSL_ENABLED', true); + } + if (!defined('CRYPT_RSA_MODE')) { + define('CRYPT_RSA_MODE', \DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Crypt\RSA::MODE_OPENSSL); + } + } + } + /** + * Provide a hook to mock calls to the JWT static methods. + * + * @param string $method + * @param array $args + * @return mixed + */ + protected function callJwtStatic($method, array $args = []) + { + $class = class_exists('DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT') ? 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Firebase\\JWT\\JWT' : 'JWT'; + return call_user_func_array([$class, $method], $args); + } +} diff --git a/vendor/Gcp/google/auth/src/ApplicationDefaultCredentials.php b/vendor/Gcp/google/auth/src/ApplicationDefaultCredentials.php index 1d754bb4..532abb20 100644 --- a/vendor/Gcp/google/auth/src/ApplicationDefaultCredentials.php +++ b/vendor/Gcp/google/auth/src/ApplicationDefaultCredentials.php @@ -20,8 +20,11 @@ use DomainException; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\AppIdentityCredentials; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Middleware\AuthTokenMiddleware; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Subscriber\AuthTokenSubscriber; +use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Client; use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Cache\CacheItemPoolInterface; /** * ApplicationDefaultCredentials obtains the default credentials for @@ -125,12 +128,19 @@ public static function getCredentials($scope = null, callable $httpHandler = nul { $creds = null; $jsonKey = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader::fromEnv() ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader::fromWellKnownFile(); + if (!$httpHandler) { + if (!($client = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient())) { + $client = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Client(); + \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::setHttpClient($client); + } + $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build($client); + } if (!is_null($jsonKey)) { $creds = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader::makeCredentials($scope, $jsonKey); } elseif (\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\AppIdentityCredentials::onAppEngine() && !\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials::onAppEngineFlexible()) { $creds = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\AppIdentityCredentials($scope); } elseif (\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials::onGce($httpHandler)) { - $creds = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials(); + $creds = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials(null, $scope); } if (is_null($creds)) { throw new \DomainException(self::notFound()); diff --git a/vendor/Gcp/google/auth/src/Cache/Item.php b/vendor/Gcp/google/auth/src/Cache/Item.php index da5ab316..7ba43070 100644 --- a/vendor/Gcp/google/auth/src/Cache/Item.php +++ b/vendor/Gcp/google/auth/src/Cache/Item.php @@ -32,7 +32,7 @@ final class Item implements \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Cache\Cach */ private $value; /** - * @var \DateTime + * @var \DateTime|null */ private $expiration; /** @@ -71,7 +71,7 @@ public function isHit() if ($this->expiration === null) { return true; } - return new \DateTime() < $this->expiration; + return $this->currentTime()->getTimestamp() < $this->expiration->getTimestamp(); } /** * {@inheritdoc} @@ -101,9 +101,9 @@ public function expiresAt($expiration) public function expiresAfter($time) { if (is_int($time)) { - $this->expiration = new \DateTime("now + {$time} seconds"); + $this->expiration = $this->currentTime()->add(new \DateInterval("PT{$time}S")); } elseif ($time instanceof \DateInterval) { - $this->expiration = (new \DateTime())->add($time); + $this->expiration = $this->currentTime()->add($time); } elseif ($time === null) { $this->expiration = $time; } else { @@ -148,4 +148,8 @@ private function isValidExpiration($expiration) } return false; } + protected function currentTime() + { + return new \DateTime('now', new \DateTimeZone('UTC')); + } } diff --git a/vendor/Gcp/google/auth/src/Cache/SysVCacheItemPool.php b/vendor/Gcp/google/auth/src/Cache/SysVCacheItemPool.php index 5f943f6f..ed33e77c 100644 --- a/vendor/Gcp/google/auth/src/Cache/SysVCacheItemPool.php +++ b/vendor/Gcp/google/auth/src/Cache/SysVCacheItemPool.php @@ -46,41 +46,10 @@ class SysVCacheItemPool implements \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Cac * @var array */ private $options; - /** - * Save the current items. - * - * @return bool true when success, false upon failure - */ - private function saveCurrentItems() - { - $shmid = shm_attach($this->sysvKey, $this->options['memsize'], $this->options['perm']); - if ($shmid !== false) { - $ret = shm_put_var($shmid, $this->options['variableKey'], $this->items); - shm_detach($shmid); - return $ret; - } - return false; - } - /** - * Load the items from the shared memory. - * - * @return bool true when success, false upon failure + /* + * @var bool */ - private function loadItems() - { - $shmid = shm_attach($this->sysvKey, $this->options['memsize'], $this->options['perm']); - if ($shmid !== false) { - $data = @shm_get_var($shmid, $this->options['variableKey']); - if (!empty($data)) { - $this->items = $data; - } else { - $this->items = []; - } - shm_detach($shmid); - return true; - } - return false; - } + private $hasLoadedItems = false; /** * Create a SystemV shared memory based CacheItemPool. * @@ -104,7 +73,6 @@ public function __construct($options = []) $this->items = []; $this->deferredItems = []; $this->sysvKey = ftok(__FILE__, $this->options['proj']); - $this->loadItems(); } /** * {@inheritdoc} @@ -155,6 +123,9 @@ public function deleteItem($key) */ public function deleteItems(array $keys) { + if (!$this->hasLoadedItems) { + $this->loadItems(); + } foreach ($keys as $key) { unset($this->items[$key]); } @@ -165,6 +136,9 @@ public function deleteItems(array $keys) */ public function save(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Cache\CacheItemInterface $item) { + if (!$this->hasLoadedItems) { + $this->loadItems(); + } $this->items[$item->getKey()] = $item; return $this->saveCurrentItems(); } @@ -189,4 +163,40 @@ public function commit() $this->deferredItems = []; return true; } + /** + * Save the current items. + * + * @return bool true when success, false upon failure + */ + private function saveCurrentItems() + { + $shmid = shm_attach($this->sysvKey, $this->options['memsize'], $this->options['perm']); + if ($shmid !== false) { + $ret = shm_put_var($shmid, $this->options['variableKey'], $this->items); + shm_detach($shmid); + return $ret; + } + return false; + } + /** + * Load the items from the shared memory. + * + * @return bool true when success, false upon failure + */ + private function loadItems() + { + $shmid = shm_attach($this->sysvKey, $this->options['memsize'], $this->options['perm']); + if ($shmid !== false) { + $data = @shm_get_var($shmid, $this->options['variableKey']); + if (!empty($data)) { + $this->items = $data; + } else { + $this->items = []; + } + shm_detach($shmid); + $this->hasLoadedItems = true; + return true; + } + return false; + } } diff --git a/vendor/Gcp/google/auth/src/Credentials/AppIdentityCredentials.php b/vendor/Gcp/google/auth/src/Credentials/AppIdentityCredentials.php index 160032ac..8c47b80b 100644 --- a/vendor/Gcp/google/auth/src/Credentials/AppIdentityCredentials.php +++ b/vendor/Gcp/google/auth/src/Credentials/AppIdentityCredentials.php @@ -24,6 +24,7 @@ */ use DeliciousBrains\WP_Offload_Media\Gcp\google\appengine\api\app_identity\AppIdentityService; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface; /** * AppIdentityCredentials supports authorization on Google App Engine. * @@ -48,7 +49,7 @@ * * $res = $client->get('volumes?q=Henry+David+Thoreau&country=US'); */ -class AppIdentityCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader +class AppIdentityCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface { /** * Result of fetchAuthToken. @@ -60,6 +61,10 @@ class AppIdentityCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Googl * Array of OAuth2 scopes to be requested. */ private $scope; + /** + * @var string + */ + private $clientName; public function __construct($scope = array()) { $this->scope = $scope; @@ -92,23 +97,17 @@ public static function onAppEngine() * * @param callable $httpHandler callback which delivers psr7 request * - * @return array the auth metadata: - * array(2) { - * ["access_token"]=> - * string(3) "xyz" - * ["expiration_time"]=> - * string(10) "1444339905" - * } - * - * @throws \Exception + * @return array A set of auth related metadata, containing the following + * keys: + * - access_token (string) + * - expiration_time (string) */ public function fetchAuthToken(callable $httpHandler = null) { - if (!self::onAppEngine()) { - return array(); - } - if (!class_exists('DeliciousBrains\\WP_Offload_Media\\Gcp\\google\\appengine\\api\\app_identity\\AppIdentityService')) { - throw new \Exception('This class must be run in App Engine, or you must include the AppIdentityService ' . 'mock class defined in tests/mocks/AppIdentityService.php'); + try { + $this->checkAppEngineContext(); + } catch (\Exception $e) { + return []; } // AppIdentityService expects an array when multiple scopes are supplied $scope = is_array($this->scope) ? $this->scope : explode(' ', $this->scope); @@ -116,6 +115,37 @@ public function fetchAuthToken(callable $httpHandler = null) $this->lastReceivedToken = $token; return $token; } + /** + * Sign a string using AppIdentityService. + * + * @param string $stringToSign The string to sign. + * @param bool $forceOpenSsl [optional] Does not apply to this credentials + * type. + * @return string The signature, base64-encoded. + * @throws \Exception If AppEngine SDK or mock is not available. + */ + public function signBlob($stringToSign, $forceOpenSsl = false) + { + $this->checkAppEngineContext(); + return base64_encode(\DeliciousBrains\WP_Offload_Media\Gcp\google\appengine\api\app_identity\AppIdentityService::signForApp($stringToSign)['signature']); + } + /** + * Get the client name from AppIdentityService. + * + * Subsequent calls to this method will return a cached value. + * + * @param callable $httpHandler Not used in this implementation. + * @return string + * @throws \Exception If AppEngine SDK or mock is not available. + */ + public function getClientName(callable $httpHandler = null) + { + $this->checkAppEngineContext(); + if (!$this->clientName) { + $this->clientName = \DeliciousBrains\WP_Offload_Media\Gcp\google\appengine\api\app_identity\AppIdentityService::getServiceAccountName(); + } + return $this->clientName; + } /** * @return array|null */ @@ -136,4 +166,10 @@ public function getCacheKey() { return ''; } + private function checkAppEngineContext() + { + if (!self::onAppEngine() || !class_exists('DeliciousBrains\\WP_Offload_Media\\Gcp\\google\\appengine\\api\\app_identity\\AppIdentityService')) { + throw new \Exception('This class must be run in App Engine, or you must include the AppIdentityService ' . 'mock class defined in tests/mocks/AppIdentityService.php'); + } + } } diff --git a/vendor/Gcp/google/auth/src/Credentials/GCECredentials.php b/vendor/Gcp/google/auth/src/Credentials/GCECredentials.php index 77ad476b..df014899 100644 --- a/vendor/Gcp/google/auth/src/Credentials/GCECredentials.php +++ b/vendor/Gcp/google/auth/src/Credentials/GCECredentials.php @@ -18,7 +18,10 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Iam; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\ClientException; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\RequestException; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\ServerException; @@ -47,7 +50,7 @@ * * $res = $client->get('myproject/taskqueues/myqueue'); */ -class GCECredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader +class GCECredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface { const cacheKey = 'GOOGLE_AUTH_PHP_GCE'; /** @@ -61,6 +64,10 @@ class GCECredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\C * The metadata path of the default token. */ const TOKEN_URI_PATH = 'v1/instance/service-accounts/default/token'; + /** + * The metadata path of the client ID. + */ + const CLIENT_ID_URI_PATH = 'v1/instance/service-accounts/default/email'; /** * The header whose presence indicates GCE presence. */ @@ -93,6 +100,36 @@ class GCECredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\C * Result of fetchAuthToken. */ protected $lastReceivedToken; + /** + * @var string + */ + private $clientName; + /** + * @var Iam|null + */ + private $iam; + /** + * @var string + */ + private $tokenUri; + /** + * @param Iam $iam [optional] An IAM instance. + * @param string|array $scope [optional] the scope of the access request, + * expressed either as an array or as a space-delimited string. + */ + public function __construct(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Iam $iam = null, $scope = null) + { + $this->iam = $iam; + $tokenUri = self::getTokenUri(); + if ($scope) { + if (is_string($scope)) { + $scope = explode(' ', $scope); + } + $scope = implode(',', $scope); + $tokenUri = $tokenUri . '?scopes=' . $scope; + } + $this->tokenUri = $tokenUri; + } /** * The full uri for accessing the default token. * @@ -103,6 +140,16 @@ public static function getTokenUri() $base = 'http://' . self::METADATA_IP . '/computeMetadata/'; return $base . self::TOKEN_URI_PATH; } + /** + * The full uri for accessing the default service account. + * + * @return string + */ + public static function getClientNameUri() + { + $base = 'http://' . self::METADATA_IP . '/computeMetadata/'; + return $base . self::CLIENT_ID_URI_PATH; + } /** * Determines if this an App Engine Flexible instance, by accessing the * GAE_INSTANCE environment variable. @@ -124,9 +171,7 @@ public static function onAppEngineFlexible() */ public static function onGce(callable $httpHandler = null) { - if (is_null($httpHandler)) { - $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(); - } + $httpHandler = $httpHandler ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); $checkUri = 'http://' . self::METADATA_IP; for ($i = 1; $i <= self::MAX_COMPUTE_PING_TRIES; $i++) { try { @@ -138,13 +183,12 @@ public static function onGce(callable $httpHandler = null) // could lead to false negatives in the event that we are on GCE, but // the metadata resolution was particularly slow. The latter case is // "unlikely". - $resp = $httpHandler(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', $checkUri), ['timeout' => self::COMPUTE_PING_CONNECTION_TIMEOUT_S]); + $resp = $httpHandler(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', $checkUri, [self::FLAVOR_HEADER => 'Google']), ['timeout' => self::COMPUTE_PING_CONNECTION_TIMEOUT_S]); return $resp->getHeaderLine(self::FLAVOR_HEADER) == 'Google'; } catch (ClientException $e) { } catch (ServerException $e) { } catch (RequestException $e) { } - $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(); } return false; } @@ -156,26 +200,27 @@ public static function onGce(callable $httpHandler = null) * * @param callable $httpHandler callback which delivers psr7 request * - * @return array the response + * @return array A set of auth related metadata, containing the following + * keys: + * - access_token (string) + * - expires_in (int) + * - token_type (string) * * @throws \Exception */ public function fetchAuthToken(callable $httpHandler = null) { - if (is_null($httpHandler)) { - $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(); - } + $httpHandler = $httpHandler ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); if (!$this->hasCheckedOnGce) { $this->isOnGce = self::onGce($httpHandler); + $this->hasCheckedOnGce = true; } if (!$this->isOnGce) { return array(); // return an empty array with no access token } - $resp = $httpHandler(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', self::getTokenUri(), [self::FLAVOR_HEADER => 'Google'])); - $body = (string) $resp->getBody(); - // Assume it's JSON; if it's not throw an exception - if (null === ($json = json_decode($body, true))) { + $json = $this->getFromMetadata($httpHandler, $this->tokenUri); + if (null === ($json = json_decode($json, true))) { throw new \Exception('Invalid JSON response'); } // store this so we can retrieve it later @@ -200,4 +245,63 @@ public function getLastReceivedToken() } return null; } + /** + * Get the client name from GCE metadata. + * + * Subsequent calls will return a cached value. + * + * @param callable $httpHandler callback which delivers psr7 request + * @return string + */ + public function getClientName(callable $httpHandler = null) + { + if ($this->clientName) { + return $this->clientName; + } + $httpHandler = $httpHandler ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); + if (!$this->hasCheckedOnGce) { + $this->isOnGce = self::onGce($httpHandler); + $this->hasCheckedOnGce = true; + } + if (!$this->isOnGce) { + return ''; + } + $this->clientName = $this->getFromMetadata($httpHandler, self::getClientNameUri()); + return $this->clientName; + } + /** + * Sign a string using the default service account private key. + * + * This implementation uses IAM's signBlob API. + * + * @see https://cloud.google.com/iam/credentials/reference/rest/v1/projects.serviceAccounts/signBlob SignBlob + * + * @param string $stringToSign The string to sign. + * @param bool $forceOpenSsl [optional] Does not apply to this credentials + * type. + * @return string + */ + public function signBlob($stringToSign, $forceOpenSsl = false) + { + $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); + // Providing a signer is useful for testing, but it's undocumented + // because it's not something a user would generally need to do. + $signer = $this->iam ?: new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Iam($httpHandler); + $email = $this->getClientName($httpHandler); + $previousToken = $this->getLastReceivedToken(); + $accessToken = $previousToken ? $previousToken['access_token'] : $this->fetchAuthToken($httpHandler)['access_token']; + return $signer->signBlob($email, $accessToken, $stringToSign); + } + /** + * Fetch the value of a GCE metadata server URI. + * + * @param callable $httpHandler An HTTP Handler to deliver PSR7 requests. + * @param string $uri The metadata URI. + * @return string + */ + private function getFromMetadata(callable $httpHandler, $uri) + { + $resp = $httpHandler(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', $uri, [self::FLAVOR_HEADER => 'Google'])); + return (string) $resp->getBody(); + } } diff --git a/vendor/Gcp/google/auth/src/Credentials/InsecureCredentials.php b/vendor/Gcp/google/auth/src/Credentials/InsecureCredentials.php index 0b2730b7..6c078a57 100644 --- a/vendor/Gcp/google/auth/src/Credentials/InsecureCredentials.php +++ b/vendor/Gcp/google/auth/src/Credentials/InsecureCredentials.php @@ -33,7 +33,9 @@ class InsecureCredentials implements \DeliciousBrains\WP_Offload_Media\Gcp\Googl * Fetches the auth token. In this case it returns an empty string. * * @param callable $httpHandler - * @return array + * @return array A set of auth related metadata, containing the following + * keys: + * - access_token (string) */ public function fetchAuthToken(callable $httpHandler = null) { diff --git a/vendor/Gcp/google/auth/src/Credentials/ServiceAccountCredentials.php b/vendor/Gcp/google/auth/src/Credentials/ServiceAccountCredentials.php index 54f43596..9c64867f 100644 --- a/vendor/Gcp/google/auth/src/Credentials/ServiceAccountCredentials.php +++ b/vendor/Gcp/google/auth/src/Credentials/ServiceAccountCredentials.php @@ -19,6 +19,8 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\OAuth2; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\ServiceAccountSignerTrait; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface; /** * ServiceAccountCredentials supports authorization using a Google service * account. @@ -52,8 +54,9 @@ * * $res = $client->get('myproject/taskqueues/myqueue'); */ -class ServiceAccountCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader +class ServiceAccountCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface { + use ServiceAccountSignerTrait; /** * The OAuth2 instance used to conduct authorization. * @@ -92,7 +95,11 @@ public function __construct($scope, $jsonKey, $sub = null) /** * @param callable $httpHandler * - * @return array + * @return array A set of auth related metadata, containing the following + * keys: + * - access_token (string) + * - expires_in (int) + * - token_type (string) */ public function fetchAuthToken(callable $httpHandler = null) { @@ -145,4 +152,16 @@ public function setSub($sub) { $this->auth->setSub($sub); } + /** + * Get the client name from the keyfile. + * + * In this case, it returns the keyfile's client_email key. + * + * @param callable $httpHandler Not used by this credentials type. + * @return string + */ + public function getClientName(callable $httpHandler = null) + { + return $this->auth->getIssuer(); + } } diff --git a/vendor/Gcp/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php b/vendor/Gcp/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php index d8f1d628..7db82fef 100644 --- a/vendor/Gcp/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php +++ b/vendor/Gcp/google/auth/src/Credentials/ServiceAccountJwtAccessCredentials.php @@ -19,6 +19,8 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\OAuth2; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\ServiceAccountSignerTrait; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface; /** * Authenticates requests using Google's Service Account credentials via * JWT Access. @@ -28,8 +30,9 @@ * console (via 'Generate new Json Key'). It is not part of any OAuth2 * flow, rather it creates a JWT and sends that as a credential. */ -class ServiceAccountJwtAccessCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader +class ServiceAccountJwtAccessCredentials extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface { + use ServiceAccountSignerTrait; /** * The OAuth2 instance used to conduct authorization. * @@ -83,7 +86,9 @@ public function updateMetadata($metadata, $authUri = null, callable $httpHandler * * @param callable $httpHandler * - * @return array|void + * @return array|void A set of auth related metadata, containing the + * following keys: + * - access_token (string) */ public function fetchAuthToken(callable $httpHandler = null) { @@ -108,4 +113,16 @@ public function getLastReceivedToken() { return $this->auth->getLastReceivedToken(); } + /** + * Get the client name from the keyfile. + * + * In this case, it returns the keyfile's client_email key. + * + * @param callable $httpHandler Not used by this credentials type. + * @return string + */ + public function getClientName(callable $httpHandler = null) + { + return $this->auth->getIssuer(); + } } diff --git a/vendor/Gcp/google/auth/src/Credentials/UserRefreshCredentials.php b/vendor/Gcp/google/auth/src/Credentials/UserRefreshCredentials.php index f02867a6..ab2e0d2f 100644 --- a/vendor/Gcp/google/auth/src/Credentials/UserRefreshCredentials.php +++ b/vendor/Gcp/google/auth/src/Credentials/UserRefreshCredentials.php @@ -76,7 +76,13 @@ public function __construct($scope, $jsonKey) /** * @param callable $httpHandler * - * @return array + * @return array A set of auth related metadata, containing the following + * keys: + * - access_token (string) + * - expires_in (int) + * - scope (string) + * - token_type (string) + * - id_token (string) */ public function fetchAuthToken(callable $httpHandler = null) { diff --git a/vendor/Gcp/google/auth/src/FetchAuthTokenCache.php b/vendor/Gcp/google/auth/src/FetchAuthTokenCache.php index 7d2a08f7..6eaf2cab 100644 --- a/vendor/Gcp/google/auth/src/FetchAuthTokenCache.php +++ b/vendor/Gcp/google/auth/src/FetchAuthTokenCache.php @@ -22,7 +22,7 @@ * A class to implement caching for any object implementing * FetchAuthTokenInterface */ -class FetchAuthTokenCache implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\FetchAuthTokenInterface +class FetchAuthTokenCache implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\FetchAuthTokenInterface, \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\SignBlobInterface { use CacheTrait; /** @@ -88,4 +88,32 @@ public function getLastReceivedToken() { return $this->fetcher->getLastReceivedToken(); } + /** + * Get the client name from the fetcher. + * + * @param callable $httpHandler An HTTP handler to deliver PSR7 requests. + * @return string + */ + public function getClientName(callable $httpHandler = null) + { + return $this->fetcher->getClientName($httpHandler); + } + /** + * Sign a blob using the fetcher. + * + * @param string $stringToSign The string to sign. + * @param bool $forceOpenssl Require use of OpenSSL for local signing. Does + * not apply to signing done using external services. **Defaults to** + * `false`. + * @return string The resulting signature. + * @throws \RuntimeException If the fetcher does not implement + * `Google\Auth\SignBlobInterface`. + */ + public function signBlob($stringToSign, $forceOpenSsl = false) + { + if (!$this->fetcher instanceof SignBlobInterface) { + throw new \RuntimeException('Credentials fetcher does not implement ' . 'DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\Auth\\SignBlobInterface'); + } + return $this->fetcher->signBlob($stringToSign, $forceOpenSsl); + } } diff --git a/vendor/Gcp/google/auth/src/HttpHandler/HttpClientCache.php b/vendor/Gcp/google/auth/src/HttpHandler/HttpClientCache.php new file mode 100644 index 00000000..a5bd545e --- /dev/null +++ b/vendor/Gcp/google/auth/src/HttpHandler/HttpClientCache.php @@ -0,0 +1,51 @@ +httpHandler = $httpHandler ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); + } + /** + * Sign a string using the IAM signBlob API. + * + * Note that signing using IAM requires your service account to have the + * `iam.serviceAccounts.signBlob` permission, part of the "Service Account + * Token Creator" IAM role. + * + * @param string $email The service account email. + * @param string $accessToken An access token from the service account. + * @param string $stringToSign The string to be signed. + * @param array $delegates [optional] A list of service account emails to + * add to the delegate chain. If omitted, the value of `$email` will + * be used. + * @return string The signed string, base64-encoded. + */ + public function signBlob($email, $accessToken, $stringToSign, array $delegates = []) + { + $httpHandler = $this->httpHandler; + $name = sprintf(self::SERVICE_ACCOUNT_NAME, $email); + $uri = self::IAM_API_ROOT . '/' . sprintf(self::SIGN_BLOB_PATH, $name); + if ($delegates) { + foreach ($delegates as &$delegate) { + $delegate = sprintf(self::SERVICE_ACCOUNT_NAME, $delegate); + } + } else { + $delegates = [$name]; + } + $body = ['delegates' => $delegates, 'payload' => base64_encode($stringToSign)]; + $headers = ['Authorization' => 'Bearer ' . $accessToken]; + $request = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('POST', $uri, $headers, \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\stream_for(json_encode($body))); + $res = $httpHandler($request); + $body = json_decode((string) $res->getBody(), true); + return $body['signedBlob']; + } +} diff --git a/vendor/Gcp/google/auth/src/OAuth2.php b/vendor/Gcp/google/auth/src/OAuth2.php index 46244826..55bbdee0 100644 --- a/vendor/Gcp/google/auth/src/OAuth2.php +++ b/vendor/Gcp/google/auth/src/OAuth2.php @@ -17,6 +17,7 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request; @@ -411,7 +412,7 @@ public function generateCredentialsRequest() public function fetchAuthToken(callable $httpHandler = null) { if (is_null($httpHandler)) { - $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(); + $httpHandler = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); } $response = $httpHandler($this->generateCredentialsRequest()); $credentials = $this->parseTokenResponse($response); @@ -1072,6 +1073,19 @@ public function getLastReceivedToken() } return null; } + /** + * Get the client ID. + * + * Alias of {@see Google\Auth\OAuth2::getClientId()}. + * + * @param callable $httpHandler + * @return string + * @access private + */ + public function getClientName(callable $httpHandler = null) + { + return $this->getClientId(); + } /** * @todo handle uri as array * diff --git a/vendor/Gcp/google/auth/src/ServiceAccountSignerTrait.php b/vendor/Gcp/google/auth/src/ServiceAccountSignerTrait.php new file mode 100644 index 00000000..e6bc85f2 --- /dev/null +++ b/vendor/Gcp/google/auth/src/ServiceAccountSignerTrait.php @@ -0,0 +1,53 @@ +auth->getSigningKey(); + $signedString = ''; + if (class_exists('DeliciousBrains\\WP_Offload_Media\\Gcp\\phpseclib\\Crypt\\RSA') && !$forceOpenssl) { + $rsa = new \DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Crypt\RSA(); + $rsa->loadKey($privateKey); + $rsa->setSignatureMode(\DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Crypt\RSA::SIGNATURE_PKCS1); + $rsa->setHash('sha256'); + $signedString = $rsa->sign($stringToSign); + } elseif (extension_loaded('openssl')) { + openssl_sign($stringToSign, $signedString, $privateKey, 'sha256WithRSAEncryption'); + } else { + // @codeCoverageIgnoreStart + throw new \RuntimeException('OpenSSL is not installed.'); + } + // @codeCoverageIgnoreEnd + return base64_encode($signedString); + } +} diff --git a/vendor/Gcp/google/auth/src/SignBlobInterface.php b/vendor/Gcp/google/auth/src/SignBlobInterface.php new file mode 100644 index 00000000..a2f5685b --- /dev/null +++ b/vendor/Gcp/google/auth/src/SignBlobInterface.php @@ -0,0 +1,43 @@ +=5.5", "rize\/uri-template": "~0.3", - "google\/auth": "^1.2", + "google\/auth": "^1.6", "guzzlehttp\/guzzle": "^5.3|^6.0", "guzzlehttp\/promises": "^1.3", "guzzlehttp\/psr7": "^1.2", - "monolog\/monolog": "~1", + "monolog\/monolog": "^1.1|^2.0", "psr\/http-message": "1.0.*" }, "require-dev": { @@ -18,8 +18,9 @@ "squizlabs\/php_codesniffer": "2.*", "phpdocumentor\/reflection": "^3.0", "erusev\/parsedown": "^1.6", - "google\/gax": "^0.38.0", - "opis\/closure": "^3" + "google\/gax": "^1.1", + "opis\/closure": "^3", + "google\/common-protos": "^1.0" }, "suggest": { "opis\/closure": "May be used to serialize closures to process jobs in the batch daemon. Please require version ^3.", diff --git a/vendor/Gcp/google/cloud-core/src/ArrayTrait.php b/vendor/Gcp/google/cloud-core/src/ArrayTrait.php index 7b169831..c5a483a6 100644 --- a/vendor/Gcp/google/cloud-core/src/ArrayTrait.php +++ b/vendor/Gcp/google/cloud-core/src/ArrayTrait.php @@ -28,7 +28,7 @@ trait ArrayTrait * @param string $key * @param array $arr * @param bool $isRequired - * @return string|null + * @return mixed * @throws \InvalidArgumentException */ private function pluck($key, array &$arr, $isRequired = true) @@ -46,7 +46,7 @@ private function pluck($key, array &$arr, $isRequired = true) /** * Pluck a subset of an array. * - * @param string $keys + * @param string[] $keys * @param array $arr * @return array */ diff --git a/vendor/Gcp/google/cloud-core/src/Batch/BatchRunner.php b/vendor/Gcp/google/cloud-core/src/Batch/BatchRunner.php index 7d7b7f49..182020e9 100644 --- a/vendor/Gcp/google/cloud-core/src/Batch/BatchRunner.php +++ b/vendor/Gcp/google/cloud-core/src/Batch/BatchRunner.php @@ -113,7 +113,7 @@ public function registerJob($identifier, $func, array $options = []) * @param string $identifier Unique identifier of the job. * @param mixed $item It needs to be serializable. * - * @return bool true on success, false on failure + * @return void * @throws \RuntimeException */ public function submitItem($identifier, $item) @@ -123,7 +123,7 @@ public function submitItem($identifier, $item) throw new \RuntimeException("The identifier does not exist: {$identifier}"); } $idNum = $job->id(); - return $this->processor->submit($item, $idNum); + $this->processor->submit($item, $idNum); } /** * Get the job with the given identifier. diff --git a/vendor/Gcp/google/cloud-core/src/Batch/BatchTrait.php b/vendor/Gcp/google/cloud-core/src/Batch/BatchTrait.php index 2447b9fc..101507b0 100644 --- a/vendor/Gcp/google/cloud-core/src/Batch/BatchTrait.php +++ b/vendor/Gcp/google/cloud-core/src/Batch/BatchTrait.php @@ -78,14 +78,14 @@ public function send(array $items) call_user_func_array($this->getCallback(), [$items]); } catch (\Exception $e) { if ($this->debugOutput) { - fwrite($this->debugOutputResource ?: STDERR, $e->getMessage() . PHP_EOL . PHP_EOL . $e->getTraceAsString() . PHP_EOL); + fwrite($this->debugOutputResource, $e->getMessage() . PHP_EOL . PHP_EOL . $e->getTraceAsString() . PHP_EOL); } return false; } $end = microtime(true); if ($this->debugOutput) { - fwrite($this->debugOutputResource ?: STDERR, sprintf('%f seconds for %s: %d items' . PHP_EOL, $end - $start, $this->batchMethod, count($items))); - fwrite($this->debugOutputResource ?: STDERR, sprintf('memory used: %d' . PHP_EOL, memory_get_usage())); + fwrite($this->debugOutputResource, sprintf('%f seconds for %s: %d items' . PHP_EOL, $end - $start, $this->batchMethod, count($items))); + fwrite($this->debugOutputResource, sprintf('memory used: %d' . PHP_EOL, memory_get_usage())); } return true; } @@ -101,10 +101,11 @@ protected abstract function getCallback(); * Configuration options. * * @type resource $debugOutputResource A resource to output debug output - * to. + * to. **Defaults to** `php://stderr`. * @type bool $debugOutput Whether or not to output debug information. - * Please note debug output currently only applies in CLI based - * applications. **Defaults to** `false`. + * Please note that unless a debug output resource is configured + * this setting will only apply to CLI based applications. + * **Defaults to** `false`. * @type array $batchOptions A set of options for a BatchJob. * {@see \Google\Cloud\Core\Batch\BatchJob::__construct()} for * more details. @@ -140,7 +141,7 @@ private function setCommonBatchProperties(array $options = []) $this->setSerializableClientOptions($options); $this->batchMethod = $options['batchMethod']; $this->identifier = $options['identifier']; - $this->debugOutputResource = isset($options['debugOutputResource']) ? $options['debugOutputResource'] : null; + $this->debugOutputResource = isset($options['debugOutputResource']) ? $options['debugOutputResource'] : fopen('php://stderr', 'w'); $this->debugOutput = isset($options['debugOutput']) ? $options['debugOutput'] : false; $batchOptions = isset($options['batchOptions']) ? $options['batchOptions'] : []; $this->batchOptions = $batchOptions + ['batchSize' => 1000, 'callPeriod' => 2.0, 'numWorkers' => 2]; diff --git a/vendor/Gcp/google/cloud-core/src/Batch/HandleFailureTrait.php b/vendor/Gcp/google/cloud-core/src/Batch/HandleFailureTrait.php index 821658af..c69a01f4 100644 --- a/vendor/Gcp/google/cloud-core/src/Batch/HandleFailureTrait.php +++ b/vendor/Gcp/google/cloud-core/src/Batch/HandleFailureTrait.php @@ -44,10 +44,8 @@ private function initFailureFile() if ($this->baseDir === false) { $this->baseDir = sprintf('%s/batch-daemon-failure', sys_get_temp_dir()); } - if (!is_dir($this->baseDir)) { - if (@mkdir($this->baseDir, 0700, true) === false) { - throw new \RuntimeException(sprintf('Couuld not create a directory: %s', $this->baseDir)); - } + if (!is_dir($this->baseDir) && !@mkdir($this->baseDir, 0700, true) && !is_dir($this->baseDir)) { + throw new \RuntimeException(sprintf('Could not create a directory: %s', $this->baseDir)); } // Use getmypid for simplicity. $this->failureFile = sprintf('%s/failed-items-%d', $this->baseDir, getmypid()); diff --git a/vendor/Gcp/google/cloud-core/src/Batch/InterruptTrait.php b/vendor/Gcp/google/cloud-core/src/Batch/InterruptTrait.php index 44f8858b..83f80061 100644 --- a/vendor/Gcp/google/cloud-core/src/Batch/InterruptTrait.php +++ b/vendor/Gcp/google/cloud-core/src/Batch/InterruptTrait.php @@ -46,7 +46,7 @@ private function setupSignalHandlers() * * @return void */ - public function sigHandler($signo, $signinfo = null) + public function sigHandler($signo, $siginfo = null) { switch ($signo) { case SIGINT: diff --git a/vendor/Gcp/google/cloud-core/src/Batch/JobTrait.php b/vendor/Gcp/google/cloud-core/src/Batch/JobTrait.php index 30f7c15b..d1527a50 100644 --- a/vendor/Gcp/google/cloud-core/src/Batch/JobTrait.php +++ b/vendor/Gcp/google/cloud-core/src/Batch/JobTrait.php @@ -40,7 +40,7 @@ trait JobTrait */ private $numWorkers; /** - * @var string An optional file that is required to run this job. + * @var string|null An optional file that is required to run this job. */ private $bootstrapFile; /** diff --git a/vendor/Gcp/google/cloud-core/src/Batch/SimpleJob.php b/vendor/Gcp/google/cloud-core/src/Batch/SimpleJob.php index 27576c14..43e3e0fa 100644 --- a/vendor/Gcp/google/cloud-core/src/Batch/SimpleJob.php +++ b/vendor/Gcp/google/cloud-core/src/Batch/SimpleJob.php @@ -17,7 +17,6 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Batch; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\SysvTrait; /** * Represents a simple job that runs a single method that loops forever. * diff --git a/vendor/Gcp/google/cloud-core/src/ClientTrait.php b/vendor/Gcp/google/cloud-core/src/ClientTrait.php index e7ffb5e8..8378fec4 100644 --- a/vendor/Gcp/google/cloud-core/src/ClientTrait.php +++ b/vendor/Gcp/google/cloud-core/src/ClientTrait.php @@ -122,14 +122,14 @@ private function getKeyFile(array $config = []) * * Process: * 1. If $config['projectId'] is set, use that. - * 2. If $config['keyFile'] is set, attempt to retrieve a project ID from + * 2. If an emulator is enabled, return a dummy value. + * 3. If $config['keyFile'] is set, attempt to retrieve a project ID from * that. - * 3. Check `GOOGLE_CLOUD_PROJECT` environment variable. - * 4. Check `GCLOUD_PROJECT` environment variable. - * 5. If code is running on compute engine, try to get the project ID from + * 4. Check `GOOGLE_CLOUD_PROJECT` environment variable. + * 5. Check `GCLOUD_PROJECT` environment variable. + * 6. If code is running on compute engine, try to get the project ID from * the metadata store. - * 6. If an emulator is enabled, return a dummy value. - * 4. Throw exception. + * 7. Throw exception. * * @param array $config * @return string @@ -141,6 +141,9 @@ private function detectProjectId(array $config) if ($config['projectId']) { return $config['projectId']; } + if ($config['hasEmulator']) { + return 'emulator-project'; + } if (isset($config['keyFile'])) { if (isset($config['keyFile']['project_id'])) { return $config['keyFile']['project_id']; @@ -163,9 +166,6 @@ private function detectProjectId(array $config) return $projectId; } } - if ($config['hasEmulator']) { - return 'emulator-project'; - } if ($config['projectIdRequired']) { throw new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\GoogleException('No project ID was provided, ' . 'and we were unable to detect a default project ID.'); } diff --git a/vendor/Gcp/google/cloud-core/src/Compute/Metadata.php b/vendor/Gcp/google/cloud-core/src/Compute/Metadata.php index c937fb49..bdd8e69c 100644 --- a/vendor/Gcp/google/cloud-core/src/Compute/Metadata.php +++ b/vendor/Gcp/google/cloud-core/src/Compute/Metadata.php @@ -17,7 +17,7 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\StreamReader; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\HttpHandlerReader; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\ReaderInterface; /** * A library for accessing the Google Compute Engine (GCE) metadata. @@ -25,9 +25,6 @@ * The metadata is available from Google Compute Engine instances and * App Engine Managed VMs instances. * - * You can get the GCE metadata values very easily like: - * - * * Example: * ``` * use Google\Cloud\Core\Compute\Metadata; @@ -44,7 +41,7 @@ class Metadata { /** - * @var StreamReader The metadata reader. + * @var ReaderInterface The metadata reader. */ private $reader; /** @@ -56,15 +53,17 @@ class Metadata */ private $numericProjectId; /** - * We use StreamReader for the default implementation for fetching the URL. + * @param ReaderInterface $reader [optional] A metadata reader implementation. */ - public function __construct() + public function __construct(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\ReaderInterface $reader = null) { - $this->reader = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\StreamReader(); + $this->reader = $reader ?: new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\HttpHandlerReader(); } /** * Replace the default reader implementation * + * @deprecated If a custom reader implementation is desired, provide it at + * construction. * @param ReaderInterface $reader The reader implementation */ public function setReader(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers\ReaderInterface $reader) diff --git a/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/HttpHandlerReader.php b/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/HttpHandlerReader.php new file mode 100644 index 00000000..83bba927 --- /dev/null +++ b/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/HttpHandlerReader.php @@ -0,0 +1,55 @@ +httpHandler = $httpHandler ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpClientCache::getHttpClient()); + } + /** + * Read the metadata for a given path. + * + * @param string $path The metadata path, relative to `/computeMetadata/v1/`. + * @return string + */ + public function read($path) + { + $url = sprintf('http://%s/computeMetadata/v1/%s', \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials::METADATA_IP, $path); + $request = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', $url, [\DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials::FLAVOR_HEADER => 'Google']); + $handler = $this->httpHandler; + $res = $handler($request); + return (string) $res->getBody(); + } +} diff --git a/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php b/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php index 10f6aaed..e28e0099 100644 --- a/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php +++ b/vendor/Gcp/google/cloud-core/src/Compute/Metadata/Readers/StreamReader.php @@ -17,6 +17,7 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Compute\Metadata\Readers; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials; /** * A class only reading the metadata URL with an appropriate header. * @@ -26,10 +27,14 @@ class StreamReader implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud { /** * The base PATH for the metadata. + * + * @deprecated */ const BASE_URL = 'http://169.254.169.254/computeMetadata/v1/'; /** * The header whose presence indicates GCE presence. + * + * @deprecated */ const FLAVOR_HEADER = 'Metadata-Flavor: Google'; /** @@ -41,15 +46,40 @@ class StreamReader implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud */ public function __construct() { - $options = array('http' => array('method' => 'GET', 'header' => self::FLAVOR_HEADER)); - $this->context = stream_context_create($options); + $options = ['http' => ['method' => 'GET', 'header' => \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials::FLAVOR_HEADER . ': Google']]; + $this->context = $this->createStreamContext($options); } /** - * A method to read the metadata value for a given path. + * Read the metadata for a given path. + * + * @param string $path The metadata path, relative to `/computeMetadata/v1/`. + * @return string */ public function read($path) { - $url = self::BASE_URL . $path; + $url = sprintf('http://%s/computeMetadata/v1/%s', \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Credentials\GCECredentials::METADATA_IP, $path); + return $this->getMetadata($url); + } + /** + * Abstracted for testing. + * + * @param array $options + * @return resource + * @codeCoverageIgnore + */ + protected function createStreamContext(array $options) + { + return stream_context_create($options); + } + /** + * Abstracted for testing. + * + * @param string $url + * @return string + * @codeCoverageIgnore + */ + protected function getMetadata($url) + { return file_get_contents($url, false, $this->context); } } diff --git a/vendor/Gcp/google/cloud-core/src/DebugInfoTrait.php b/vendor/Gcp/google/cloud-core/src/DebugInfoTrait.php index 71ee7884..8775cf76 100644 --- a/vendor/Gcp/google/cloud-core/src/DebugInfoTrait.php +++ b/vendor/Gcp/google/cloud-core/src/DebugInfoTrait.php @@ -19,6 +19,8 @@ /** * Provides easier to read debug information when dumping a class to stdout. + * + * @codeCoverageIgnore */ trait DebugInfoTrait { diff --git a/vendor/Gcp/google/cloud-core/src/EmulatorTrait.php b/vendor/Gcp/google/cloud-core/src/EmulatorTrait.php index faa0d3a3..6c8ebc14 100644 --- a/vendor/Gcp/google/cloud-core/src/EmulatorTrait.php +++ b/vendor/Gcp/google/cloud-core/src/EmulatorTrait.php @@ -17,13 +17,26 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\RequestBuilder; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\RequestWrapper; /** - * Provides common logic for configuring the usage of an emualtor. + * Provides common logic for configuring the usage of an emulator. */ trait EmulatorTrait { + /** + * Configure the gapic configuration to use a service emulator. + * + * @param string $emulatorHost + * @return array + */ + private function emulatorGapicConfig($emulatorHost) + { + // Strip the URL scheme from the input, if it was provided. + if ($scheme = parse_url($emulatorHost, PHP_URL_SCHEME)) { + $search = $scheme . '://'; + $emulatorHost = str_replace($search, '', $emulatorHost); + } + return ['apiEndpoint' => $emulatorHost, 'transportConfig' => ['grpc' => ['stubOpts' => ['credentials' => \DeliciousBrains\WP_Offload_Media\Gcp\Grpc\ChannelCredentials::createInsecure()]]]]; + } /** * Retrieve a valid base uri for a service emulator. * diff --git a/vendor/Gcp/google/cloud-core/src/ExponentialBackoff.php b/vendor/Gcp/google/cloud-core/src/ExponentialBackoff.php index fa5e6713..d98bf106 100644 --- a/vendor/Gcp/google/cloud-core/src/ExponentialBackoff.php +++ b/vendor/Gcp/google/cloud-core/src/ExponentialBackoff.php @@ -28,13 +28,17 @@ class ExponentialBackoff */ private $retries; /** - * @var callable + * @var callable|null */ private $retryFunction; /** * @var callable */ private $delayFunction; + /** + * @var callable|null + */ + private $calcDelayFunction; /** * @param int $retries [optional] Number of retries for a failed request. * @param callable $retryFunction [optional] returns bool for whether or not to retry @@ -45,7 +49,7 @@ public function __construct($retries = null, callable $retryFunction = null) $this->retryFunction = $retryFunction; // @todo revisit this approach // @codeCoverageIgnoreStart - $this->delayFunction = function ($delay) { + $this->delayFunction = static function ($delay) { usleep($delay); }; // @codeCoverageIgnoreEnd @@ -61,6 +65,7 @@ public function __construct($retries = null, callable $retryFunction = null) public function execute(callable $function, array $arguments = []) { $delayFunction = $this->delayFunction; + $calcDelayFunction = $this->calcDelayFunction ?: [$this, 'calculateDelay']; $retryAttempt = 0; $exception = null; while (true) { @@ -75,13 +80,15 @@ public function execute(callable $function, array $arguments = []) if ($retryAttempt >= $this->retries) { break; } - $delayFunction($this->calculateDelay($retryAttempt)); + $delayFunction($calcDelayFunction($retryAttempt)); $retryAttempt++; } } throw $exception; } /** + * If not set, defaults to using `usleep`. + * * @param callable $delayFunction * @return void */ @@ -89,6 +96,17 @@ public function setDelayFunction(callable $delayFunction) { $this->delayFunction = $delayFunction; } + /** + * If not set, defaults to using + * {@see Google\Cloud\Core\ExponentialBackoff::calculateDelay()}. + * + * @param callable $calcDelayFunction + * @return void + */ + public function setCalcDelayFunction(callable $calcDelayFunction) + { + $this->calcDelayFunction = $calcDelayFunction; + } /** * Calculates exponential delay. * diff --git a/vendor/Gcp/google/cloud-core/src/GrpcRequestWrapper.php b/vendor/Gcp/google/cloud-core/src/GrpcRequestWrapper.php index ba200f00..3797f827 100644 --- a/vendor/Gcp/google/cloud-core/src/GrpcRequestWrapper.php +++ b/vendor/Gcp/google/cloud-core/src/GrpcRequestWrapper.php @@ -24,16 +24,10 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\PagedListResponse; use DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\Serializer; use DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\ServerStream; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\GAX\ApiException as GaxApiException; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\GAX\OperationResponse as GaxOperationResponse; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\GAX\PagedListResponse as GaxPagedListResponse; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\GAX\Serializer as GaxSerializer; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\GAX\ServerStream as GaxServerStream; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Protobuf\Internal\Message; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Rpc\BadRequest; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Rpc\Code; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Rpc\RetryInfo; -use Grpc; /** * The GrpcRequestWrapper is responsible for delivering gRPC requests. */ @@ -78,7 +72,7 @@ class GrpcRequestWrapper public function __construct(array $config = []) { $this->setCommonDefaults($config); - $config += ['authHttpHandler' => null, 'serializer' => $this->buildSerializer(), 'grpcOptions' => []]; + $config += ['authHttpHandler' => null, 'serializer' => new \DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\Serializer(), 'grpcOptions' => []]; $this->authHttpHandler = $config['authHttpHandler'] ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(); $this->serializer = $config['serializer']; $this->grpcOptions = $config['grpcOptions']; @@ -120,7 +114,7 @@ public function send(callable $request, array $args, array $options = []) try { return $this->handleResponse($backoff->execute($request, $args)); } catch (\Exception $ex) { - if ($ex instanceof ApiException || $ex instanceof GaxApiException) { + if ($ex instanceof ApiException) { throw $this->convertToGoogleException($ex); } throw $ex; @@ -130,20 +124,20 @@ public function send(callable $request, array $args, array $options = []) * Serializes a gRPC response. * * @param mixed $response - * @return \Generator|array|null + * @return \Generator|OperationResponse|array|null */ private function handleResponse($response) { - if ($response instanceof PagedListResponse || $response instanceof GaxPagedListResponse) { + if ($response instanceof PagedListResponse) { $response = $response->getPage()->getResponseObject(); } if ($response instanceof Message) { return $this->serializer->encodeMessage($response); } - if ($response instanceof OperationResponse || $response instanceof GaxOperationResponse) { + if ($response instanceof OperationResponse) { return $response; } - if ($response instanceof ServerStream || $response instanceof GaxServerStream) { + if ($response instanceof ServerStream) { return $this->handleStream($response); } return null; @@ -151,7 +145,7 @@ private function handleResponse($response) /** * Handles a streaming response. * - * @param ServerStream|GaxServerStream $response + * @param ServerStream $response * @return \Generator|array|null */ private function handleStream($response) @@ -168,7 +162,7 @@ private function handleStream($response) /** * Convert a ApiCore exception to a Google Exception. * - * @param ApiException|GaxApiException $ex + * @param \Exception $ex * @return Exception\ServiceException */ private function convertToGoogleException($ex) @@ -216,11 +210,4 @@ private function convertToGoogleException($ex) } return new $exception($ex->getMessage(), $ex->getCode(), $ex, $metadata); } - /** - * @return Serializer|GaxSerializer - */ - private function buildSerializer() - { - return class_exists(\DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\Serializer::class) ? new \DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\Serializer() : new \DeliciousBrains\WP_Offload_Media\Gcp\Google\GAX\Serializer(); - } } diff --git a/vendor/Gcp/google/cloud-core/src/GrpcTrait.php b/vendor/Gcp/google/cloud-core/src/GrpcTrait.php index fc27856e..b0eab080 100644 --- a/vendor/Gcp/google/cloud-core/src/GrpcTrait.php +++ b/vendor/Gcp/google/cloud-core/src/GrpcTrait.php @@ -17,11 +17,7 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core; -use DateTime; -use DateTimeZone; use DeliciousBrains\WP_Offload_Media\Gcp\Google\ApiCore\CredentialsWrapper; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\Cache\MemoryCacheItemPool; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\FetchAuthTokenCache; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\ArrayTrait; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\NotFoundException; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\GrpcRequestWrapper; @@ -220,4 +216,15 @@ private function formatTimestampForApi($value) list($dt, $nanos) = $this->parseTimeString($value); return ['seconds' => (int) $dt->format('U'), 'nanos' => (int) $nanos]; } + /** + * Construct a gapic client. Allows for tests to intercept. + * + * @param string $gapicName + * @param array $config + * @return mixed + */ + protected function constructGapic($gapicName, array $config) + { + return new $gapicName($config); + } } diff --git a/vendor/Gcp/google/cloud-core/src/Iterator/ItemIteratorTrait.php b/vendor/Gcp/google/cloud-core/src/Iterator/ItemIteratorTrait.php index 7b422fd7..63a252c3 100644 --- a/vendor/Gcp/google/cloud-core/src/Iterator/ItemIteratorTrait.php +++ b/vendor/Gcp/google/cloud-core/src/Iterator/ItemIteratorTrait.php @@ -50,7 +50,7 @@ public function __construct(\Iterator $pageIterator) */ public function nextResultToken() { - return $this->pageIterator->nextResultToken(); + return method_exists($this->pageIterator, 'nextResultToken') ? $this->pageIterator->nextResultToken() : null; } /** * Iterate over the results on a per page basis. diff --git a/vendor/Gcp/google/cloud-core/src/JsonTrait.php b/vendor/Gcp/google/cloud-core/src/JsonTrait.php index e3c9f9fa..83e39cf9 100644 --- a/vendor/Gcp/google/cloud-core/src/JsonTrait.php +++ b/vendor/Gcp/google/cloud-core/src/JsonTrait.php @@ -32,7 +32,7 @@ trait JsonTrait * @return mixed * @throws \InvalidArgumentException */ - private function jsonDecode($json, $assoc = false, $depth = 512, $options = 0) + private static function jsonDecode($json, $assoc = false, $depth = 512, $options = 0) { $data = json_decode($json, $assoc, $depth, $options); if (JSON_ERROR_NONE !== json_last_error()) { @@ -48,7 +48,7 @@ private function jsonDecode($json, $assoc = false, $depth = 512, $options = 0) * @return string * @throws \InvalidArgumentException */ - private function jsonEncode($value, $options = 0, $depth = 512) + private static function jsonEncode($value, $options = 0, $depth = 512) { $json = json_encode($value, $options, $depth); if (JSON_ERROR_NONE !== json_last_error()) { diff --git a/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatter.php b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatter.php index fa295feb..fe18cb22 100644 --- a/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatter.php +++ b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatter.php @@ -17,14 +17,15 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Logger; -use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\JsonTrait; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\LineFormatter; /** - * Class for formatting logs on App Engine flexible environment. + * Monolog 1.x formatter for formatting logs on App Engine flexible environment. + * + * If you are using Monolog 2.x, use {@see \Google\Cloud\Core\Logger\AppEngineFlexFormatterV2} instead. */ class AppEngineFlexFormatter extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\LineFormatter { - use JsonTrait; + use FormatterTrait; /** * @param string $format [optional] The format of the message * @param string $dateFormat [optional] The format of the timestamp @@ -39,18 +40,10 @@ public function __construct($format = null, $dateFormat = null, $ignoreEmptyCont * metadata including the trace id then return the json string. * * @param array $record A record to format - * @return mixed The formatted record + * @return string The formatted record */ public function format(array $record) { - $message = parent::format($record); - list($usec, $sec) = explode(" ", microtime()); - $usec = (int) ((double) $usec * 1000000000); - $sec = (int) $sec; - $payload = ['message' => $message, 'timestamp' => ['seconds' => $sec, 'nanos' => $usec], 'thread' => '', 'severity' => $record['level_name']]; - if (isset($_SERVER['HTTP_X_CLOUD_TRACE_CONTEXT'])) { - $payload['traceId'] = explode("/", $_SERVER['HTTP_X_CLOUD_TRACE_CONTEXT'])[0]; - } - return "\n" . $this->jsonEncode($payload); + return $this->formatPayload($record, parent::format($record)); } } diff --git a/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatterV2.php b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatterV2.php new file mode 100644 index 00000000..1e917897 --- /dev/null +++ b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexFormatterV2.php @@ -0,0 +1,49 @@ +formatPayload($record, parent::format($record)); + } +} diff --git a/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandler.php b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandler.php index c4d431a6..e0fdb060 100644 --- a/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandler.php +++ b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandler.php @@ -21,7 +21,9 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\StreamHandler; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; /** - * Class for logging on App Engine flexible environment. + * Monolog 1.x handler for logging on App Engine flexible environment. + * + * If you are using Monolog 2.x, use {@see \Google\Cloud\Core\Logger\AppEngineFlexHandlerV2} instead. */ class AppEngineFlexHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\StreamHandler { @@ -39,7 +41,7 @@ class AppEngineFlexHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog public function __construct($level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::INFO, $bubble = true, $filePermission = 0640, $useLocking = false, $stream = null) { if ($stream === null) { - $pid = posix_getpid(); + $pid = getmypid(); $stream = "file:///var/log/app_engine/app.{$pid}.json"; } parent::__construct($stream, $level, $bubble, $filePermission, $useLocking); diff --git a/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandlerFactory.php b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandlerFactory.php new file mode 100644 index 00000000..b0321095 --- /dev/null +++ b/vendor/Gcp/google/cloud-core/src/Logger/AppEngineFlexHandlerFactory.php @@ -0,0 +1,56 @@ + $message, 'timestamp' => ['seconds' => $sec, 'nanos' => $usec], 'thread' => '', 'severity' => $record['level_name']]; + if (isset($_SERVER['HTTP_X_CLOUD_TRACE_CONTEXT'])) { + $payload['traceId'] = explode('/', $_SERVER['HTTP_X_CLOUD_TRACE_CONTEXT'])[0]; + } + return "\n" . json_encode($payload); + } +} diff --git a/vendor/Gcp/google/cloud-core/src/PhpArray.php b/vendor/Gcp/google/cloud-core/src/PhpArray.php index 51de0752..281888cd 100644 --- a/vendor/Gcp/google/cloud-core/src/PhpArray.php +++ b/vendor/Gcp/google/cloud-core/src/PhpArray.php @@ -26,6 +26,7 @@ * Extend the Protobuf-PHP array codec to allow messages to match the format * used for REST. * @deprecated + * @codeCoverageIgnore */ class PhpArray extends \DeliciousBrains\WP_Offload_Media\Gcp\DrSlump\Protobuf\Codec\PhpArray { diff --git a/vendor/Gcp/google/cloud-core/src/RequestBuilder.php b/vendor/Gcp/google/cloud-core/src/RequestBuilder.php index e3a4ba16..a6166725 100644 --- a/vendor/Gcp/google/cloud-core/src/RequestBuilder.php +++ b/vendor/Gcp/google/cloud-core/src/RequestBuilder.php @@ -19,6 +19,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request; +use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Uri; use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\RequestInterface; /** * Builds a PSR7 request from a service definition. @@ -51,8 +52,18 @@ class RequestBuilder public function __construct($servicePath, $baseUri, array $resourceRoot = []) { $this->service = $this->loadServiceDefinition($servicePath); - $this->baseUri = $baseUri; $this->resourceRoot = $resourceRoot; + // Append service definition base path if bare apiEndpoint domain is given. + if (isset($this->service['basePath'])) { + $uriParts = parse_url($baseUri) + ['path' => null]; + if (!$uriParts['path'] || $uriParts['path'] === '/') { + $uriParts['path'] = $this->service['basePath']; + // Recreate the URI from its modified parts and ensure it ends in a single slash. + $this->baseUri = rtrim((string) \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Uri::fromParts($uriParts), '/') . '/'; + return; + } + } + $this->baseUri = rtrim($baseUri, '/') . '/'; } /** * Build the request. diff --git a/vendor/Gcp/google/cloud-core/src/RequestWrapper.php b/vendor/Gcp/google/cloud-core/src/RequestWrapper.php index 32892ded..f8ceabc4 100644 --- a/vendor/Gcp/google/cloud-core/src/RequestWrapper.php +++ b/vendor/Gcp/google/cloud-core/src/RequestWrapper.php @@ -33,7 +33,6 @@ */ class RequestWrapper { - use JsonTrait; use RequestWrapperTrait; use RetryDeciderTrait; /** @@ -72,15 +71,14 @@ class RequestWrapper */ private $retryFunction; /** - * @var callable|null Sets the conditions for determining how long to wait - * between attempts to retry. + * @var callable Executes a delay. */ - private $restDelayFunction; + private $delayFunction; /** - * @var callable Sets the conditions for determining how long to wait + * @var callable|null Sets the conditions for determining how long to wait * between attempts to retry. */ - private $delayFunction; + private $calcDelayFunction; /** * @param array $config [optional] { * Configuration options. Please see @@ -103,15 +101,20 @@ class RequestWrapper * @type array $restOptions HTTP client specific configuration options. * @type bool $shouldSignRequest Whether to enable request signing. * @type callable $restRetryFunction Sets the conditions for whether or - * not a request should attempt to retry. - * @type callable $restDelayFunction Sets the conditions for determining - * how long to wait between attempts to retry. + * not a request should attempt to retry. Function signature should + * match: `function (\Exception $ex) : bool`. + * @type callable $restDelayFunction Executes a delay, defaults to + * utilizing `usleep`. Function signature should match: + * `function (int $delay) : void`. + * @type callable $restCalcDelayFunction Sets the conditions for + * determining how long to wait between attempts to retry. Function + * signature should match: `function (int $attempt) : int`. * } */ public function __construct(array $config = []) { $this->setCommonDefaults($config); - $config += ['accessToken' => null, 'asyncHttpHandler' => null, 'authHttpHandler' => null, 'httpHandler' => null, 'restOptions' => [], 'shouldSignRequest' => true, 'componentVersion' => null, 'restRetryFunction' => null, 'restDelayFunction' => null]; + $config += ['accessToken' => null, 'asyncHttpHandler' => null, 'authHttpHandler' => null, 'httpHandler' => null, 'restOptions' => [], 'shouldSignRequest' => true, 'componentVersion' => null, 'restRetryFunction' => null, 'restDelayFunction' => null, 'restCalcDelayFunction' => null]; $this->componentVersion = $config['componentVersion']; $this->accessToken = $config['accessToken']; $this->restOptions = $config['restOptions']; @@ -120,6 +123,7 @@ public function __construct(array $config = []) $this->delayFunction = $config['restDelayFunction'] ?: function ($delay) { usleep($delay); }; + $this->calcDelayFunction = $config['restCalcDelayFunction']; $this->httpHandler = $config['httpHandler'] ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory::build(); $this->authHttpHandler = $config['authHttpHandler'] ?: $this->httpHandler; $this->asyncHttpHandler = $config['asyncHttpHandler'] ?: $this->buildDefaultAsyncHandler(); @@ -139,9 +143,14 @@ public function __construct(array $config = []) * @type int $retries Number of retries for a failed request. * **Defaults to** `3`. * @type callable $restRetryFunction Sets the conditions for whether or - * not a request should attempt to retry. - * @type callable $restDelayFunction Sets the conditions for determining - * how long to wait between attempts to retry. + * not a request should attempt to retry. Function signature should + * match: `function (\Exception $ex) : bool`. + * @type callable $restDelayFunction Executes a delay, defaults to + * utilizing `usleep`. Function signature should match: + * `function (int $delay) : void`. + * @type callable $restCalcDelayFunction Sets the conditions for + * determining how long to wait between attempts to retry. Function + * signature should match: `function (int $attempt) : int`. * @type array $restOptions HTTP client specific configuration options. * } * @return ResponseInterface @@ -149,7 +158,13 @@ public function __construct(array $config = []) public function send(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\RequestInterface $request, array $options = []) { $retryOptions = $this->getRetryOptions($options); - $backoff = $this->configureBackoff($retryOptions['retries'], $retryOptions['retryFunction'], $retryOptions['delayFunction']); + $backoff = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\ExponentialBackoff($retryOptions['retries'], $retryOptions['retryFunction']); + if ($retryOptions['delayFunction']) { + $backoff->setDelayFunction($retryOptions['delayFunction']); + } + if ($retryOptions['calcDelayFunction']) { + $backoff->setCalcDelayFunction($retryOptions['calcDelayFunction']); + } try { return $backoff->execute($this->httpHandler, [$this->applyHeaders($request), $this->getRequestOptions($options)]); } catch (\Exception $ex) { @@ -168,9 +183,14 @@ public function send(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\Requ * @type int $retries Number of retries for a failed request. * **Defaults to** `3`. * @type callable $restRetryFunction Sets the conditions for whether or - * not a request should attempt to retry. - * @type callable $restDelayFunction Sets the conditions for determining - * how long to wait between attempts to retry. + * not a request should attempt to retry. Function signature should + * match: `function (\Exception $ex) : bool`. + * @type callable $restDelayFunction Executes a delay, defaults to + * utilizing `usleep`. Function signature should match: + * `function (int $delay) : void`. + * @type callable $restCalcDelayFunction Sets the conditions for + * determining how long to wait between attempts to retry. Function + * signature should match: `function (int $attempt) : int`. * @type array $restOptions HTTP client specific configuration options. * } * @return PromiseInterface @@ -187,12 +207,16 @@ public function sendAsync(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message $fn = function ($retryAttempt) use(&$fn, $request, $options) { $asyncHttpHandler = $this->asyncHttpHandler; $retryOptions = $this->getRetryOptions($options); + if (!$retryOptions['calcDelayFunction']) { + $retryOptions['calcDelayFunction'] = [\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\ExponentialBackoff::class, 'calculateDelay']; + } return $asyncHttpHandler($this->applyHeaders($request), $this->getRequestOptions($options))->then(null, function (\Exception $ex) use($fn, $retryAttempt, $retryOptions) { $shouldRetry = $retryOptions['retryFunction']($ex); if ($shouldRetry === false || $retryAttempt >= $retryOptions['retries']) { throw $this->convertToGoogleException($ex); } - $retryOptions['delayFunction'](\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\ExponentialBackoff::calculateDelay($retryAttempt)); + $delay = $retryOptions['calcDelayFunction']($retryAttempt); + $retryOptions['delayFunction']($delay); $retryAttempt++; return $fn($retryAttempt); }); @@ -275,38 +299,17 @@ private function convertToGoogleException(\Exception $ex) /** * Gets the exception message. * + * @access private * @param \Exception $ex * @return string */ private function getExceptionMessage(\Exception $ex) { if ($ex instanceof RequestException && $ex->hasResponse()) { - $res = (string) $ex->getResponse()->getBody(); - try { - $this->jsonDecode($res); - return $res; - } catch (\InvalidArgumentException $e) { - // no-op - } + return (string) $ex->getResponse()->getBody(); } return $ex->getMessage(); } - /** - * Configures an exponential backoff implementation. - * - * @param int $retries - * @param callable $retryFunction - * @param callable $delayFunction - * @return ExponentialBackoff - */ - private function configureBackoff($retries, callable $retryFunction, callable $delayFunction) - { - $backoff = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\ExponentialBackoff($retries, $retryFunction); - if ($delayFunction) { - $backoff->setDelayFunction($delayFunction); - } - return $backoff; - } /** * Gets a set of request options. * @@ -330,7 +333,7 @@ private function getRequestOptions(array $options) */ private function getRetryOptions(array $options) { - return ['retries' => isset($options['retries']) ? $options['retries'] : $this->retries, 'retryFunction' => isset($options['restRetryFunction']) ? $options['restRetryFunction'] : $this->retryFunction, 'delayFunction' => isset($options['restDelayFunction']) ? $options['restDelayFunction'] : $this->delayFunction]; + return ['retries' => isset($options['retries']) ? $options['retries'] : $this->retries, 'retryFunction' => isset($options['restRetryFunction']) ? $options['restRetryFunction'] : $this->retryFunction, 'delayFunction' => isset($options['restDelayFunction']) ? $options['restDelayFunction'] : $this->delayFunction, 'calcDelayFunction' => isset($options['restCalcDelayFunction']) ? $options['restCalcDelayFunction'] : $this->calcDelayFunction]; } /** * Builds the default async HTTP handler. diff --git a/vendor/Gcp/google/cloud-core/src/RequestWrapperTrait.php b/vendor/Gcp/google/cloud-core/src/RequestWrapperTrait.php index 28f1c264..bca465bb 100644 --- a/vendor/Gcp/google/cloud-core/src/RequestWrapperTrait.php +++ b/vendor/Gcp/google/cloud-core/src/RequestWrapperTrait.php @@ -37,7 +37,7 @@ trait RequestWrapperTrait */ private $authCacheOptions; /** - * @var FetchAuthTokenInterface Fetches credentials. + * @var FetchAuthTokenInterface|null Fetches credentials. */ private $credentialsFetcher; /** @@ -106,6 +106,15 @@ public function keyFile() { return $this->keyFile; } + /** + * Get the scopes + * + * @return array + */ + public function scopes() + { + return $this->scopes; + } /** * Gets the credentials fetcher and sets up caching. Precedence is as * follows: diff --git a/vendor/Gcp/google/cloud-core/src/RestTrait.php b/vendor/Gcp/google/cloud-core/src/RestTrait.php index 36bd7f9c..2b871662 100644 --- a/vendor/Gcp/google/cloud-core/src/RestTrait.php +++ b/vendor/Gcp/google/cloud-core/src/RestTrait.php @@ -85,4 +85,22 @@ public function send($resource, $method, array $options = [], $whitelisted = fal throw $e; } } + /** + * Return a custom API endpoint in the proper format, or default if none provided. + * + * @param string $default + * @param array $config + * @return string + */ + private function getApiEndpoint($default, array $config) + { + $res = isset($config['apiEndpoint']) ? $config['apiEndpoint'] : $default; + if (substr($res, -1) !== '/') { + $res = $res . '/'; + } + if (strpos($res, '//') === false) { + $res = 'https://' . $res; + } + return $res; + } } diff --git a/vendor/Gcp/google/cloud-core/src/Retry.php b/vendor/Gcp/google/cloud-core/src/Retry.php index add25add..76172f0d 100644 --- a/vendor/Gcp/google/cloud-core/src/Retry.php +++ b/vendor/Gcp/google/cloud-core/src/Retry.php @@ -32,13 +32,13 @@ class Retry /** * @var callable */ - private $retryFunction; + private $delayFunction; /** - * @var callable + * @var callable|null */ - private $delayFunction; + private $retryFunction; /** - * @param int $retries Maximum number of retries for a failed request. + * @param int|null $retries Maximum number of retries for a failed request. * @param callable $delayFunction A function returning an array of format * `['seconds' => (int >= 0), 'nanos' => (int >= 0)] specifying how * long an operation should pause before retrying. Should accept a diff --git a/vendor/Gcp/google/cloud-core/src/RetryDeciderTrait.php b/vendor/Gcp/google/cloud-core/src/RetryDeciderTrait.php index 30f3998a..93b6d588 100644 --- a/vendor/Gcp/google/cloud-core/src/RetryDeciderTrait.php +++ b/vendor/Gcp/google/cloud-core/src/RetryDeciderTrait.php @@ -17,11 +17,13 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core; +use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\RequestException; /** * Provides methods for deciding if a request should be retried. */ trait RetryDeciderTrait { + use JsonTrait; /** * @var array */ @@ -49,7 +51,12 @@ private function getRetryFunction($shouldRetryMessages = true) if (!$shouldRetryMessages) { return false; } - $message = json_decode($ex->getMessage(), true); + $message = $ex instanceof RequestException && $ex->hasResponse() ? (string) $ex->getResponse()->getBody() : $ex->getMessage(); + try { + $message = $this->jsonDecode($message, true); + } catch (\InvalidArgumentException $ex) { + return false; + } if (!isset($message['error']['errors'])) { return false; } diff --git a/vendor/Gcp/google/cloud-core/src/ServiceBuilder.php b/vendor/Gcp/google/cloud-core/src/ServiceBuilder.php index 40f93e8a..29747f0c 100644 --- a/vendor/Gcp/google/cloud-core/src/ServiceBuilder.php +++ b/vendor/Gcp/google/cloud-core/src/ServiceBuilder.php @@ -17,6 +17,8 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\Guzzle5HttpHandler; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\Guzzle6HttpHandler; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\HttpHandler\HttpHandlerFactory; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\BigQuery\BigQueryClient; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Datastore\DatastoreClient; diff --git a/vendor/Gcp/google/cloud-core/src/TimeTrait.php b/vendor/Gcp/google/cloud-core/src/TimeTrait.php index 49dbd999..ed33fb8d 100644 --- a/vendor/Gcp/google/cloud-core/src/TimeTrait.php +++ b/vendor/Gcp/google/cloud-core/src/TimeTrait.php @@ -28,7 +28,7 @@ trait TimeTrait * @param string $timestamp A string representation of a timestamp, encoded * in RFC 3339 format (YYYY-MM-DDTHH:MM:SS.000000[000]TZ). * @return array [\DateTimeImmutable, int] - * @throws \InvalidArgumentException If the timestamp string is in an unrecognized format. + * @throws \Exception If the timestamp string is in an unrecognized format. */ private function parseTimeString($timestamp) { @@ -39,10 +39,7 @@ private function parseTimeString($timestamp) $timestamp = str_replace('.' . $subSeconds, '.' . substr($subSeconds, 0, 6), $timestamp); } $dt = new \DateTimeImmutable($timestamp); - if (!$dt) { - throw new \InvalidArgumentException(sprintf('Could not create a DateTime instance from given timestamp %s.', $timestamp)); - } - $nanos = (int) str_pad($subSeconds, 9, '0', STR_PAD_RIGHT); + $nanos = $this->convertFractionToNanoSeconds($subSeconds); return [$dt, $nanos]; } /** @@ -69,12 +66,7 @@ private function formatTimeAsString(\DateTimeInterface $dateTime, $ns) if ($ns === null) { return $dateTime->format(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Timestamp::FORMAT); } else { - $ns = (string) $ns; - $ns = str_pad($ns, 9, '0', STR_PAD_LEFT); - if (substr($ns, 6, 3) === '000') { - $ns = substr($ns, 0, 6); - } - return sprintf($dateTime->format(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Timestamp::FORMAT_INTERPOLATE), $ns); + return sprintf($dateTime->format(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Timestamp::FORMAT_INTERPOLATE), $this->convertNanoSecondsToFraction($ns)); } } /** @@ -92,4 +84,38 @@ private function formatTimeAsArray(\DateTimeInterface $dateTime, $ns) } return ['seconds' => (int) $dateTime->format('U'), 'nanos' => (int) $ns]; } + /** + * Convert subseconds, expressed as a decimal to nanoseconds. + * + * @param int|string $subseconds Provide value as a whole number (i.e. + * provide 0.1 as 1). + * @return int + */ + private function convertFractionToNanoSeconds($subseconds) + { + return (int) str_pad($subseconds, 9, '0', STR_PAD_RIGHT); + } + /** + * Convert nanoseconds to subseconds. + * + * Note that result should be used as a fraction of one second, but is + * given as an integer. + * + * @param int|string $nanos + * @param bool $rpad Whether to right-pad to 6 or 9 digits. **Defaults to** + * `true`. + * @return string + */ + private function convertNanoSecondsToFraction($nanos, $rpad = true) + { + $nanos = (string) $nanos; + $res = str_pad($nanos, 9, '0', STR_PAD_LEFT); + if (substr($res, 6, 3) === '000') { + $res = substr($res, 0, 6); + } + if (!$rpad) { + $res = rtrim($res, '0'); + } + return $res; + } } diff --git a/vendor/Gcp/google/cloud-core/src/Upload/MultipartUploader.php b/vendor/Gcp/google/cloud-core/src/Upload/MultipartUploader.php index bd8fa120..baef2c8a 100644 --- a/vendor/Gcp/google/cloud-core/src/Upload/MultipartUploader.php +++ b/vendor/Gcp/google/cloud-core/src/Upload/MultipartUploader.php @@ -34,7 +34,11 @@ class MultipartUploader extends \DeliciousBrains\WP_Offload_Media\Gcp\Google\Clo public function upload() { $multipartStream = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\MultipartStream([['name' => 'metadata', 'headers' => ['Content-Type' => 'application/json; charset=UTF-8'], 'contents' => $this->jsonEncode($this->metadata)], ['name' => 'data', 'headers' => ['Content-Type' => $this->contentType], 'contents' => $this->data]], 'boundary'); - $headers = ['Content-Type' => 'multipart/related; boundary=boundary', 'Content-Length' => $multipartStream->getSize()]; + $headers = ['Content-Type' => 'multipart/related; boundary=boundary']; + $size = $multipartStream->getSize(); + if ($size !== null) { + $headers['Content-Length'] = $size; + } return $this->jsonDecode($this->requestWrapper->send(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('POST', $this->uri, $headers, $multipartStream), $this->requestOptions)->getBody(), true); } } diff --git a/vendor/Gcp/google/cloud-core/src/Upload/ResumableUploader.php b/vendor/Gcp/google/cloud-core/src/Upload/ResumableUploader.php index ccaae92a..ac87cf86 100644 --- a/vendor/Gcp/google/cloud-core/src/Upload/ResumableUploader.php +++ b/vendor/Gcp/google/cloud-core/src/Upload/ResumableUploader.php @@ -18,6 +18,8 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Upload; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\GoogleException; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\ServiceException; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\UploadException; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\JsonTrait; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\RequestWrapper; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7; @@ -120,8 +122,11 @@ public function resume($resumeUri) /** * Triggers the upload process. * + * Errors are of form [`google.rpc.Status`](https://cloud.google.com/apis/design/errors#error_model), + * and may be obtained via {@see Google\Cloud\Core\Exception\ServiceException::getMetadata()}. + * * @return array - * @throws GoogleException + * @throws ServiceException */ public function upload() { @@ -138,7 +143,7 @@ public function upload() try { $response = $this->requestWrapper->send($request, $this->requestOptions); } catch (GoogleException $ex) { - throw new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\GoogleException("Upload failed. Please use this URI to resume your upload: {$this->resumeUri}", $ex->getCode()); + throw new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\ServiceException("Upload failed. Please use this URI to resume your upload: {$this->resumeUri}", $ex->getCode(), null, json_decode($ex->getMessage(), true) ?: []); } if (is_callable($this->uploadProgressCallback)) { call_user_func($this->uploadProgressCallback, $currStreamLimitSize); @@ -184,7 +189,7 @@ protected function getStatusResponse() * Gets the starting range for the upload. * * @param string $rangeHeader - * @return int + * @return int|null */ protected function getRangeStart($rangeHeader) { diff --git a/vendor/Gcp/google/cloud-core/src/Upload/SignedUrlUploader.php b/vendor/Gcp/google/cloud-core/src/Upload/SignedUrlUploader.php index c39ebe14..65065060 100644 --- a/vendor/Gcp/google/cloud-core/src/Upload/SignedUrlUploader.php +++ b/vendor/Gcp/google/cloud-core/src/Upload/SignedUrlUploader.php @@ -70,7 +70,7 @@ protected function createResumeUri() /** * Decode the response body * - * @param ReponseInterface $response + * @param ResponseInterface $response * @return string */ protected function decodeResponse(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface $response) diff --git a/vendor/Gcp/google/cloud-storage/VERSION b/vendor/Gcp/google/cloud-storage/VERSION index ed21137e..71bd5d9e 100644 --- a/vendor/Gcp/google/cloud-storage/VERSION +++ b/vendor/Gcp/google/cloud-storage/VERSION @@ -1 +1 @@ -1.10.0 \ No newline at end of file +1.16.0 \ No newline at end of file diff --git a/vendor/Gcp/google/cloud-storage/composer.json b/vendor/Gcp/google/cloud-storage/composer.json index ef4c74bf..f1d42ea3 100644 --- a/vendor/Gcp/google/cloud-storage/composer.json +++ b/vendor/Gcp/google/cloud-storage/composer.json @@ -4,7 +4,8 @@ "license": "Apache-2.0", "minimum-stability": "stable", "require": { - "google\/cloud-core": "^1.25" + "google\/cloud-core": "^1.31", + "google\/crc32": "^0.1.0" }, "require-dev": { "phpunit\/phpunit": "^4.8|^5.0", diff --git a/vendor/Gcp/google/cloud-storage/src/Bucket.php b/vendor/Gcp/google/cloud-storage/src/Bucket.php index 6bf90e07..24da792e 100644 --- a/vendor/Gcp/google/cloud-storage/src/Bucket.php +++ b/vendor/Gcp/google/cloud-storage/src/Bucket.php @@ -24,11 +24,13 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Iam\Iam; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Iterator\ItemIterator; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Iterator\PageIterator; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Timestamp; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Upload\ResumableUploader; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Upload\StreamableUploader; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\PubSub\Topic; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\Connection\ConnectionInterface; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\Connection\IamBucket; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\SigningHelper; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7; use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\StreamInterface; /** @@ -76,7 +78,7 @@ class Bucket */ private $info; /** - * @var Iam + * @var Iam|null */ private $iam; /** @@ -202,6 +204,7 @@ public function exists() * uploads. * @see https://cloud.google.com/storage/docs/json_api/v1/objects/insert Objects insert API documentation. * @see https://cloud.google.com/storage/docs/encryption#customer-supplied Customer-supplied encryption keys. + * @see https://github.com/google/php-crc32 crc32c PHP extension for hardware-accelerated validation hashes. * * @param string|resource|StreamInterface|null $data The data to be uploaded. * @param array $options [optional] { @@ -211,10 +214,17 @@ public function exists() * of type string or null. * @type bool $resumable Indicates whether or not the upload will be * performed in a resumable fashion. - * @type bool $validate Indicates whether or not validation will be - * applied using md5 hashing functionality. If true and the - * calculated hash does not match that of the upstream server the - * upload will be rejected. + * @type bool|string $validate Indicates whether or not validation will + * be applied using md5 or crc32c hashing functionality. If + * enabled, and the calculated hash does not match that of the + * upstream server, the upload will be rejected. Available options + * are `true`, `false`, `md5` and `crc32`. If true, either md5 or + * crc32c will be chosen based on your platform. If false, no + * validation hash will be sent. Choose either `md5` or `crc32` to + * force a hash method regardless of performance implications. In + * PHP versions earlier than 7.4, performance will be very + * adversely impacted by using crc32c unless you install the + * `crc32c` PHP extension. **Defaults to** `true`. * @type int $chunkSize If provided the upload will be done in chunks. * The size must be in multiples of 262144 bytes. With chunking * you have increased reliability at the risk of higher overhead. @@ -234,11 +244,11 @@ public function exists() * `"projectPrivate"`, and `"publicRead"`. * @type array $metadata The full list of available options are outlined * at the [JSON API docs](https://cloud.google.com/storage/docs/json_api/v1/objects/insert#request-body). - * @type array $metadata['metadata'] User-provided metadata, in key/value pairs. + * @type array $metadata.metadata User-provided metadata, in key/value pairs. * @type string $encryptionKey A base64 encoded AES-256 customer-supplied * encryption key. If you would prefer to manage encryption * utilizing the Cloud Key Management Service (KMS) please use the - * $metadata['kmsKeyName'] setting. Please note if using KMS the + * `$metadata.kmsKeyName` setting. Please note if using KMS the * key ring must use the same location as the bucket. * @type string $encryptionKeySHA256 Base64 encoded SHA256 hash of the * customer-supplied encryption key. This value will be calculated @@ -664,6 +674,7 @@ public function delete(array $options = []) * @see https://cloud.google.com/storage/docs/json_api/v1/buckets/patch Buckets patch API documentation. * @see https://cloud.google.com/storage/docs/key-terms#bucket-labels Bucket Labels * + * @codingStandardsIgnoreStart * @param array $options [optional] { * Configuration options. * @@ -726,7 +737,19 @@ public function delete(array $options = []) * @type int $retentionPolicy.retentionPeriod Specifies the duration * that objects need to be retained, in seconds. Retention * duration must be greater than zero and less than 100 years. + * @type array $iamConfiguration The bucket's IAM configuration. + * @type bool $iamConfiguration.bucketPolicyOnly.enabled this is an alias + * for $iamConfiguration.uniformBucketLevelAccess. + * @type bool $iamConfiguration.uniformBucketLevelAccess.enabled If set and + * true, access checks only use bucket-level IAM policies or + * above. When enabled, requests attempting to view or manipulate + * ACLs will fail with error code 400. **NOTE**: Before using + * Uniform bucket-level access, please review the + * [feature documentation](https://cloud.google.com/storage/docs/uniform-bucket-level-access), + * as well as + * [Should You Use uniform bucket-level access](https://cloud.google.com/storage/docs/uniform-bucket-level-access#should-you-use) * } + * @codingStandardsIgnoreEnd * @return array */ public function update(array $options = []) @@ -1061,6 +1084,80 @@ public function lockRetentionPolicy(array $options = []) } return $this->info = $this->connection->lockRetentionPolicy($options + $this->identity); } + /** + * Create a Signed URL listing objects in this bucket. + * + * Example: + * ``` + * $url = $bucket->signedUrl(time() + 3600); + * ``` + * + * ``` + * // Use V4 Signing + * $url = $bucket->signedUrl(time() + 3600, [ + * 'version' => 'v4' + * ]); + * ``` + * + * @see https://cloud.google.com/storage/docs/access-control/signed-urls Signed URLs + * + * @param Timestamp|\DateTimeInterface|int $expires Specifies when the URL + * will expire. May provide an instance of {@see Google\Cloud\Core\Timestamp}, + * [http://php.net/datetimeimmutable](`\DateTimeImmutable`), or a + * UNIX timestamp as an integer. + * @param array $options { + * Configuration Options. + * + * @type string $cname The CNAME for the bucket, for instance + * `https://cdn.example.com`. **Defaults to** + * `https://storage.googleapis.com`. + * @type string $contentMd5 The MD5 digest value in base64. If you + * provide this, the client must provide this HTTP header with + * this same value in its request. If provided, take care to + * always provide this value as a base64 encoded string. + * @type string $contentType If you provide this value, the client must + * provide this HTTP header set to the same value. + * @type bool $forceOpenssl If true, OpenSSL will be used regardless of + * whether phpseclib is available. **Defaults to** `false`. + * @type array $headers If additional headers are provided, the server + * will check to make sure that the client provides matching + * values. Provide headers as a key/value array, where the key is + * the header name, and the value is an array of header values. + * Headers with multiple values may provide values as a simple + * array, or a comma-separated string. For a reference of allowed + * headers, see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers). + * Header values will be trimmed of leading and trailing spaces, + * multiple spaces within values will be collapsed to a single + * space, and line breaks will be replaced by an empty string. + * V2 Signed URLs may not provide `x-goog-encryption-key` or + * `x-goog-encryption-key-sha256` headers. + * @type array $keyFile Keyfile data to use in place of the keyfile with + * which the client was constructed. If `$options.keyFilePath` is + * set, this option is ignored. + * @type string $keyFilePath A path to a valid keyfile to use in place + * of the keyfile with which the client was constructed. + * @type string|array $scopes One or more authentication scopes to be + * used with a key file. This option is ignored unless + * `$options.keyFile` or `$options.keyFilePath` is set. + * @type array $queryParams Additional query parameters to be included + * as part of the signed URL query string. For allowed values, + * see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers#query). + * @type string $version One of "v2" or "v4". *Defaults to** `"v2"`. + * } + * @return string + * @throws \InvalidArgumentException If the given expiration is invalid or in the past. + * @throws \InvalidArgumentException If the given `$options.method` is not valid. + * @throws \InvalidArgumentException If the given `$options.keyFilePath` is not valid. + * @throws \InvalidArgumentException If the given custom headers are invalid. + * @throws \RuntimeException If the keyfile does not contain the required information. + */ + public function signedUrl($expires, array $options = []) + { + // May be overridden for testing. + $signingHelper = $this->pluck('helper', $options, false) ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\SigningHelper::getHelper(); + $resource = sprintf('/%s', $this->identity['bucket']); + return $signingHelper->sign($this->connection, $expires, $resource, null, $options); + } /** * Determines if an object name is required. * diff --git a/vendor/Gcp/google/cloud-storage/src/Connection/ConnectionInterface.php b/vendor/Gcp/google/cloud-storage/src/Connection/ConnectionInterface.php index 716a7a8d..f441e3d4 100644 --- a/vendor/Gcp/google/cloud-storage/src/Connection/ConnectionInterface.php +++ b/vendor/Gcp/google/cloud-storage/src/Connection/ConnectionInterface.php @@ -135,4 +135,24 @@ public function getServiceAccount(array $args = []); * @param array $args */ public function lockRetentionPolicy(array $args = []); + /** + * @param array $args + */ + public function createHmacKey(array $args = []); + /** + * @param array $args + */ + public function deleteHmacKey(array $args = []); + /** + * @param array $args + */ + public function getHmacKey(array $args = []); + /** + * @param array $args + */ + public function updateHmacKey(array $args = []); + /** + * @param array $args + */ + public function listHmacKeys(array $args = []); } diff --git a/vendor/Gcp/google/cloud-storage/src/Connection/Rest.php b/vendor/Gcp/google/cloud-storage/src/Connection/Rest.php index b1a08e08..f66ffa66 100644 --- a/vendor/Gcp/google/cloud-storage/src/Connection/Rest.php +++ b/vendor/Gcp/google/cloud-storage/src/Connection/Rest.php @@ -27,10 +27,12 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\UriTrait; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\Connection\ConnectionInterface; use DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\StorageClient; -use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Promise\PromiseInterface; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Builtin; +use DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request; use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface; +use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\StreamInterface; /** * Implementation of the * [Google Cloud Storage JSON API](https://cloud.google.com/storage/docs/json_api/). @@ -39,9 +41,9 @@ class Rest implements \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage { use RestTrait; use UriTrait; - const BASE_URI = 'https://www.googleapis.com/storage/v1/'; - const UPLOAD_URI = 'https://www.googleapis.com/upload/storage/v1/b/{bucket}/o{?query*}'; - const DOWNLOAD_URI = 'https://www.googleapis.com/storage/v1/b/{bucket}/o/{object}{?query*}'; + const BASE_URI = 'https://storage.googleapis.com/storage/v1/'; + const UPLOAD_URI = 'https://storage.googleapis.com/upload/storage/v1/b/{bucket}/o{?query*}'; + const DOWNLOAD_URI = 'https://storage.googleapis.com/storage/v1/b/{bucket}/o/{object}{?query*}'; /** * @var string */ @@ -235,9 +237,11 @@ private function resolveUploadOptions(array $args) if (!$args['name']) { $args['name'] = basename($args['data']->getMetadata('uri')); } - // @todo add support for rolling hash - if ($args['validate'] && !isset($args['metadata']['md5Hash'])) { + $validate = $this->chooseValidationMethod($args); + if ($validate === 'md5') { $args['metadata']['md5Hash'] = base64_encode(\DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\hash($args['data'], 'md5', true)); + } elseif ($validate === 'crc32') { + $args['metadata']['crc32c'] = $this->crcFromStream($args['data']); } $args['metadata']['name'] = $args['name']; unset($args['name']); @@ -310,6 +314,41 @@ public function lockRetentionPolicy(array $args = []) { return $this->send('buckets', 'lockRetentionPolicy', $args); } + /** + * @param array $args + */ + public function createHmacKey(array $args = []) + { + return $this->send('projects.resources.hmacKeys', 'create', $args); + } + /** + * @param array $args + */ + public function deleteHmacKey(array $args = []) + { + return $this->send('projects.resources.hmacKeys', 'delete', $args); + } + /** + * @param array $args + */ + public function getHmacKey(array $args = []) + { + return $this->send('projects.resources.hmacKeys', 'get', $args); + } + /** + * @param array $args + */ + public function updateHmacKey(array $args = []) + { + return $this->send('projects.resources.hmacKeys', 'update', $args); + } + /** + * @param array $args + */ + public function listHmacKeys(array $args = []) + { + return $this->send('projects.resources.hmacKeys', 'list', $args); + } /** * @param array $args * @return array @@ -317,8 +356,81 @@ public function lockRetentionPolicy(array $args = []) private function buildDownloadObjectParams(array $args) { $args += ['bucket' => null, 'object' => null, 'generation' => null, 'userProject' => null]; - $requestOptions = array_intersect_key($args, ['restOptions' => null, 'retries' => null, 'restRetryFunction' => null, 'restDelayFunction' => null]); + $requestOptions = array_intersect_key($args, ['restOptions' => null, 'retries' => null, 'restRetryFunction' => null, 'restCalcDelayFunction' => null, 'restDelayFunction' => null]); $uri = $this->expandUri(self::DOWNLOAD_URI, ['bucket' => $args['bucket'], 'object' => $args['object'], 'query' => ['generation' => $args['generation'], 'alt' => 'media', 'userProject' => $args['userProject']]]); return [new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Request('GET', \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\uri_for($uri)), $requestOptions]; } + /** + * Choose a upload validation method based on user input and platform + * requirements. + * + * @param array $args + * @return bool|string + */ + private function chooseValidationMethod(array $args) + { + // If the user provided a hash, skip hashing. + if (isset($args['metadata']['md5']) || isset($args['metadata']['crc32c'])) { + return false; + } + $validate = $args['validate']; + if (in_array($validate, [false, 'crc32', 'md5'], true)) { + return $validate; + } + // not documented, but the feature is called crc32c, so let's accept that as input anyways. + if ($validate === 'crc32c') { + return 'crc32'; + } + // is the extension loaded? + if ($this->crc32cExtensionLoaded()) { + return 'crc32'; + } + // is crc32c available in `hash()`? + if ($this->supportsBuiltinCrc32c()) { + return 'crc32'; + } + return 'md5'; + } + /** + * Generate a CRC32c checksum from a stream. + * + * @param StreamInterface $data + * @return string + */ + private function crcFromStream(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\StreamInterface $data) + { + $pos = $data->tell(); + if ($pos > 0) { + $data->rewind(); + } + $crc32c = \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::create(\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::CASTAGNOLI); + $data->rewind(); + while (!$data->eof()) { + $crc32c->update($data->read(1048576)); + } + $data->seek($pos); + return base64_encode($crc32c->hash(true)); + } + /** + * Check if the crc32c extension is available. + * + * Protected access for unit testing. + * + * @return bool + */ + protected function crc32cExtensionLoaded() + { + return extension_loaded('crc32c'); + } + /** + * Check if hash() supports crc32c. + * + * Protected access for unit testing. + * + * @return bool + */ + protected function supportsBuiltinCrc32c() + { + return \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Builtin::supports(\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::CASTAGNOLI); + } } diff --git a/vendor/Gcp/google/cloud-storage/src/Connection/ServiceDefinition/storage-v1.json b/vendor/Gcp/google/cloud-storage/src/Connection/ServiceDefinition/storage-v1.json index b2065ddd..526f6360 100644 --- a/vendor/Gcp/google/cloud-storage/src/Connection/ServiceDefinition/storage-v1.json +++ b/vendor/Gcp/google/cloud-storage/src/Connection/ServiceDefinition/storage-v1.json @@ -1,22 +1,22 @@ { "kind": "discovery#restDescription", - "etag": "\"-iA1DTNe4s-I6JZXPt1t1Ypy8IU/jLupXEh5MvYeA2ibX_aBxLuxU28\"", + "etag": "\"F5McR9eEaw0XRpaO3M9gbIugkbs/bQWWH-5yykbmINHZHPMOypW2I3M\"", "discoveryVersion": "v1", "id": "storage:v1", "name": "storage", "version": "v1", - "revision": "20180118", + "revision": "20191011", "title": "Cloud Storage JSON API", "description": "Stores and retrieves potentially large, immutable data objects.", "ownerDomain": "google.com", "ownerName": "Google", "icons": { - "x16": "https://www.google.com/images/icons/product/cloud_storage-16.png", - "x32": "https://www.google.com/images/icons/product/cloud_storage-32.png" + "x16": "https://www.google.com/images/icons/product/cloud_storage-16.png", + "x32": "https://www.google.com/images/icons/product/cloud_storage-32.png" }, "documentationLink": "https://developers.google.com/storage/docs/json_api/", "labels": [ - "labs" + "labs" ], "protocol": "rest", "baseUrl": "https://www.googleapis.com/storage/v1/", @@ -25,3760 +25,4374 @@ "servicePath": "storage/v1/", "batchPath": "batch/storage/v1", "parameters": { - "alt": { - "type": "string", - "description": "Data format for the response.", - "default": "json", - "enum": [ - "json" - ], - "enumDescriptions": [ - "Responses with Content-Type of application/json" - ], - "location": "query" - }, - "fields": { - "type": "string", - "description": "Selector specifying which fields to include in a partial response.", - "location": "query" - }, - "key": { - "type": "string", - "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.", - "location": "query" - }, - "oauth_token": { - "type": "string", - "description": "OAuth 2.0 token for the current user.", - "location": "query" - }, - "prettyPrint": { - "type": "boolean", - "description": "Returns response with indentations and line breaks.", - "default": "true", - "location": "query" - }, - "quotaUser": { - "type": "string", - "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.", - "location": "query" - }, - "userIp": { - "type": "string", - "description": "IP address of the site where the request originates. Use this if you want to enforce per-user limits.", - "location": "query" - } + "alt": { + "type": "string", + "description": "Data format for the response.", + "default": "json", + "enum": [ + "json" + ], + "enumDescriptions": [ + "Responses with Content-Type of application/json" + ], + "location": "query" + }, + "fields": { + "type": "string", + "description": "Selector specifying which fields to include in a partial response.", + "location": "query" + }, + "key": { + "type": "string", + "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.", + "location": "query" + }, + "oauth_token": { + "type": "string", + "description": "OAuth 2.0 token for the current user.", + "location": "query" + }, + "prettyPrint": { + "type": "boolean", + "description": "Returns response with indentations and line breaks.", + "default": "true", + "location": "query" + }, + "quotaUser": { + "type": "string", + "description": "An opaque string that represents a user for quota purposes. Must not exceed 40 characters.", + "location": "query" + }, + "userIp": { + "type": "string", + "description": "Deprecated. Please use quotaUser instead.", + "location": "query" + } }, "auth": { - "oauth2": { - "scopes": { - "https://www.googleapis.com/auth/cloud-platform": { - "description": "View and manage your data across Google Cloud Platform services" - }, - "https://www.googleapis.com/auth/cloud-platform.read-only": { - "description": "View your data across Google Cloud Platform services" - }, - "https://www.googleapis.com/auth/devstorage.full_control": { - "description": "Manage your data and permissions in Google Cloud Storage" - }, - "https://www.googleapis.com/auth/devstorage.read_only": { - "description": "View your data in Google Cloud Storage" - }, - "https://www.googleapis.com/auth/devstorage.read_write": { - "description": "Manage your data in Google Cloud Storage" - } - } + "oauth2": { + "scopes": { + "https://www.googleapis.com/auth/cloud-platform": { + "description": "View and manage your data across Google Cloud Platform services" + }, + "https://www.googleapis.com/auth/cloud-platform.read-only": { + "description": "View your data across Google Cloud Platform services" + }, + "https://www.googleapis.com/auth/devstorage.full_control": { + "description": "Manage your data and permissions in Google Cloud Storage" + }, + "https://www.googleapis.com/auth/devstorage.read_only": { + "description": "View your data in Google Cloud Storage" + }, + "https://www.googleapis.com/auth/devstorage.read_write": { + "description": "Manage your data in Google Cloud Storage" + } } + } }, "schemas": { - "Bucket": { - "id": "Bucket", + "Bucket": { + "id": "Bucket", + "type": "object", + "description": "A bucket.", + "properties": { + "acl": { + "type": "array", + "description": "Access controls on the bucket.", + "items": { + "$ref": "BucketAccessControl" + }, + "annotations": { + "required": [ + "storage.buckets.update" + ] + } + }, + "billing": { "type": "object", - "description": "A bucket.", + "description": "The bucket's billing configuration.", "properties": { - "acl": { - "type": "array", - "description": "Access controls on the bucket.", - "items": { - "$ref": "BucketAccessControl" - }, - "annotations": { - "required": [ - "storage.buckets.update" - ] - } - }, - "billing": { - "type": "object", - "description": "The bucket's billing configuration.", - "properties": { - "requesterPays": { - "type": "boolean", - "description": "When set to true, Requester Pays is enabled for this bucket." - } - } - }, - "cors": { - "type": "array", - "description": "The bucket's Cross-Origin Resource Sharing (CORS) configuration.", - "items": { - "type": "object", - "properties": { - "maxAgeSeconds": { - "type": "integer", - "description": "The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses.", - "format": "int32" - }, - "method": { - "type": "array", - "description": "The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: \"*\" is permitted in the list of methods, and means \"any method\".", - "items": { - "type": "string" - } - }, - "origin": { - "type": "array", - "description": "The list of Origins eligible to receive CORS response headers. Note: \"*\" is permitted in the list of origins, and means \"any Origin\".", - "items": { - "type": "string" - } - }, - "responseHeader": { - "type": "array", - "description": "The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains.", - "items": { - "type": "string" - } - } - } - } - }, - "defaultEventBasedHold": { + "requesterPays": { + "type": "boolean", + "description": "When set to true, Requester Pays is enabled for this bucket." + } + } + }, + "cors": { + "type": "array", + "description": "The bucket's Cross-Origin Resource Sharing (CORS) configuration.", + "items": { + "type": "object", + "properties": { + "maxAgeSeconds": { + "type": "integer", + "description": "The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses.", + "format": "int32" + }, + "method": { + "type": "array", + "description": "The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: \"*\" is permitted in the list of methods, and means \"any method\".", + "items": { + "type": "string" + } + }, + "origin": { + "type": "array", + "description": "The list of Origins eligible to receive CORS response headers. Note: \"*\" is permitted in the list of origins, and means \"any Origin\".", + "items": { + "type": "string" + } + }, + "responseHeader": { + "type": "array", + "description": "The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains.", + "items": { + "type": "string" + } + } + } + } + }, + "defaultEventBasedHold": { + "type": "boolean", + "description": "The default value for event-based hold on newly created objects in this bucket. Event-based hold is a way to retain objects indefinitely until an event occurs, signified by the hold's release. After being released, such objects will be subject to bucket-level retention (if any). One sample use case of this flag is for banks to hold loan documents for at least 3 years after loan is paid in full. Here, bucket-level retention is 3 years and the event is loan being paid in full. In this example, these objects will be held intact for any number of years until the event has occurred (event-based hold on the object is released) and then 3 more years after that. That means retention duration of the objects begins from the moment event-based hold transitioned from true to false. Objects under event-based hold cannot be deleted, overwritten or archived until the hold is removed." + }, + "defaultObjectAcl": { + "type": "array", + "description": "Default access controls to apply to new objects when no ACL is provided.", + "items": { + "$ref": "ObjectAccessControl" + } + }, + "encryption": { + "type": "object", + "description": "Encryption configuration for a bucket.", + "properties": { + "defaultKmsKeyName": { + "type": "string", + "description": "A Cloud KMS key that will be used to encrypt objects inserted into this bucket, if no encryption method is specified." + } + } + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for the bucket." + }, + "iamConfiguration": { + "type": "object", + "description": "The bucket's IAM configuration.", + "properties": { + "bucketPolicyOnly": { + "type": "object", + "description": "The bucket's Bucket Policy Only configuration.", + "properties": { + "enabled": { "type": "boolean", - "description": "Defines the default value for Event-Based hold on newly created objects in this bucket. Event-Based hold is a way to retain objects indefinitely until an event occurs, signified by the hold's release. After being released, such objects will be subject to bucket-level retention (if any). One sample use case of this flag is for banks to hold loan documents for at least 3 years after loan is paid in full. Here bucket-level retention is 3 years and the event is loan being paid in full. In this example these objects will be held intact for any number of years until the event has occurred (hold is released) and then 3 more years after that. Objects under Event-Based hold cannot be deleted, overwritten or archived until the hold is removed." - }, - "defaultObjectAcl": { - "type": "array", - "description": "Default access controls to apply to new objects when no ACL is provided.", - "items": { - "$ref": "ObjectAccessControl" - } - }, - "encryption": { - "type": "object", - "description": "Encryption configuration used by default for newly inserted objects, when no encryption config is specified.", - "properties": { - "defaultKmsKeyName": { - "type": "string", - "description": "A Cloud KMS key that will be used to encrypt objects inserted into this bucket, if no encryption method is specified. Limited availability; usable only by enabled projects." - } - } - }, - "etag": { - "type": "string", - "description": "HTTP 1.1 Entity tag for the bucket." - }, - "id": { - "type": "string", - "description": "The ID of the bucket. For buckets, the id and name properties are the same." - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For buckets, this is always storage#bucket.", - "default": "storage#bucket" - }, - "labels": { - "type": "object", - "description": "User-provided labels, in key/value pairs.", - "additionalProperties": { - "type": "string", - "description": "An individual label entry." - } - }, - "lifecycle": { - "type": "object", - "description": "The bucket's lifecycle configuration. See lifecycle management for more information.", - "properties": { - "rule": { - "type": "array", - "description": "A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken.", - "items": { - "type": "object", - "properties": { - "action": { - "type": "object", - "description": "The action to take.", - "properties": { - "storageClass": { - "type": "string", - "description": "Target storage class. Required iff the type of the action is SetStorageClass." - }, - "type": { - "type": "string", - "description": "Type of the action. Currently, only Delete and SetStorageClass are supported." - } - } - }, - "condition": { - "type": "object", - "description": "The condition(s) under which the action will be taken.", - "properties": { - "age": { - "type": "integer", - "description": "Age of an object (in days). This condition is satisfied when an object reaches the specified age.", - "format": "int32" - }, - "createdBefore": { - "type": "string", - "description": "A date in RFC 3339 format with only the date part (for instance, \"2013-01-15\"). This condition is satisfied when an object is created before midnight of the specified date in UTC.", - "format": "date" - }, - "isLive": { - "type": "boolean", - "description": "Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects." - }, - "matchesStorageClass": { - "type": "array", - "description": "Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY.", - "items": { - "type": "string" - } - }, - "numNewerVersions": { - "type": "integer", - "description": "Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object.", - "format": "int32" - } - } - } - } - } - } - } - }, - "location": { - "type": "string", - "description": "The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list." - }, - "logging": { - "type": "object", - "description": "The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs.", - "properties": { - "logBucket": { - "type": "string", - "description": "The destination bucket where the current bucket's logs should be placed." - }, - "logObjectPrefix": { - "type": "string", - "description": "A prefix for log object names." - } - } - }, - "metageneration": { - "type": "string", - "description": "The metadata generation of this bucket.", - "format": "int64" - }, - "name": { - "type": "string", - "description": "The name of the bucket.", - "annotations": { - "required": [ - "storage.buckets.insert" - ] - } - }, - "owner": { - "type": "object", - "description": "The owner of the bucket. This is always the project team's owner group.", - "properties": { - "entity": { - "type": "string", - "description": "The entity, in the form project-owner-projectId." - }, - "entityId": { - "type": "string", - "description": "The ID for the entity." - } - } - }, - "projectNumber": { - "type": "string", - "description": "The project number of the project the bucket belongs to.", - "format": "uint64" - }, - "retentionPolicy": { - "type": "object", - "description": "Defines the retention policy for a bucket. The Retention policy enforces a minimum retention time for all objects contained in the bucket, based on their creation time. Any attempt to overwrite or delete objects younger than the retention period will result in a PERMISSION_DENIED error. An unlocked retention policy can be modified or removed from the bucket via the UpdateBucketMetadata RPC. A locked retention policy cannot be removed or shortened in duration for the lifetime of the bucket. Attempting to remove or decrease period of a locked retention policy will result in a PERMISSION_DENIED error.", - "properties": { - "effectiveTime": { - "type": "string", - "description": "The time from which policy was enforced and effective. RFC 3339 format.", - "format": "date-time" - }, - "isLocked": { - "type": "boolean", - "description": "Once locked, an object retention policy cannot be modified." - }, - "retentionPeriod": { - "type": "string", - "description": "Specifies the duration that objects need to be retained. Retention duration must be greater than zero and less than 100 years. Note that enforcement of retention periods less than a day is not guaranteed. Such periods should only be used for testing purposes.", - "format": "int64" - } - } - }, - "selfLink": { + "description": "If set, access is controlled only by bucket-level or above IAM policies." + }, + "lockedTime": { "type": "string", - "description": "The URI of this bucket." - }, - "storageClass": { - "type": "string", - "description": "The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes." - }, - "timeCreated": { - "type": "string", - "description": "The creation time of the bucket in RFC 3339 format.", + "description": "The deadline for changing iamConfiguration.bucketPolicyOnly.enabled from true to false in RFC 3339 format. iamConfiguration.bucketPolicyOnly.enabled may be changed from true to false until the locked time, after which the field is immutable.", "format": "date-time" - }, - "updated": { + } + } + }, + "uniformBucketLevelAccess": { + "type": "object", + "description": "The bucket's uniform bucket-level access configuration.", + "properties": { + "enabled": { + "type": "boolean", + "description": "If set, access is controlled only by bucket-level or above IAM policies." + }, + "lockedTime": { "type": "string", - "description": "The modification time of the bucket in RFC 3339 format.", + "description": "The deadline for changing iamConfiguration.uniformBucketLevelAccess.enabled from true to false in RFC 3339 format. iamConfiguration.uniformBucketLevelAccess.enabled may be changed from true to false until the locked time, after which the field is immutable.", "format": "date-time" - }, - "versioning": { - "type": "object", - "description": "The bucket's versioning configuration.", - "properties": { - "enabled": { - "type": "boolean", - "description": "While set to true, versioning is fully enabled for this bucket." - } - } - }, - "website": { - "type": "object", - "description": "The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information.", - "properties": { - "mainPageSuffix": { - "type": "string", - "description": "If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages." - }, - "notFoundPage": { - "type": "string", - "description": "If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result." - } - } + } } + } } - }, - "BucketAccessControl": { - "id": "BucketAccessControl", + }, + "id": { + "type": "string", + "description": "The ID of the bucket. For buckets, the id and name properties are the same." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For buckets, this is always storage#bucket.", + "default": "storage#bucket" + }, + "labels": { "type": "object", - "description": "An access-control entry.", - "properties": { - "bucket": { - "type": "string", - "description": "The name of the bucket." - }, - "domain": { - "type": "string", - "description": "The domain associated with the entity, if any." - }, - "email": { - "type": "string", - "description": "The email address associated with the entity, if any." - }, - "entity": { - "type": "string", - "description": "The entity holding the permission, in one of the following forms: \n- user-userId \n- user-email \n- group-groupId \n- group-email \n- domain-domain \n- project-team-projectId \n- allUsers \n- allAuthenticatedUsers Examples: \n- The user liz@example.com would be user-liz@example.com. \n- The group example@googlegroups.com would be group-example@googlegroups.com. \n- To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com.", - "annotations": { - "required": [ - "storage.bucketAccessControls.insert" - ] - } - }, - "entityId": { - "type": "string", - "description": "The ID for the entity, if any." - }, - "etag": { - "type": "string", - "description": "HTTP 1.1 Entity tag for the access-control entry." - }, - "id": { - "type": "string", - "description": "The ID of the access-control entry." - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl.", - "default": "storage#bucketAccessControl" - }, - "projectTeam": { - "type": "object", - "description": "The project team associated with the entity, if any.", - "properties": { - "projectNumber": { - "type": "string", - "description": "The project number." - }, - "team": { - "type": "string", - "description": "The team." - } - } - }, - "role": { - "type": "string", - "description": "The access permission for the entity.", - "annotations": { - "required": [ - "storage.bucketAccessControls.insert" - ] - } - }, - "selfLink": { - "type": "string", - "description": "The link to this access-control entry." - } + "description": "User-provided labels, in key/value pairs.", + "additionalProperties": { + "type": "string", + "description": "An individual label entry." } - }, - "BucketAccessControls": { - "id": "BucketAccessControls", + }, + "lifecycle": { "type": "object", - "description": "An access-control list.", + "description": "The bucket's lifecycle configuration. See lifecycle management for more information.", "properties": { + "rule": { + "type": "array", + "description": "A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken.", "items": { - "type": "array", - "description": "The list of items.", - "items": { - "$ref": "BucketAccessControl" + "type": "object", + "properties": { + "action": { + "type": "object", + "description": "The action to take.", + "properties": { + "storageClass": { + "type": "string", + "description": "Target storage class. Required iff the type of the action is SetStorageClass." + }, + "type": { + "type": "string", + "description": "Type of the action. Currently, only Delete and SetStorageClass are supported." + } + } + }, + "condition": { + "type": "object", + "description": "The condition(s) under which the action will be taken.", + "properties": { + "age": { + "type": "integer", + "description": "Age of an object (in days). This condition is satisfied when an object reaches the specified age.", + "format": "int32" + }, + "createdBefore": { + "type": "string", + "description": "A date in RFC 3339 format with only the date part (for instance, \"2013-01-15\"). This condition is satisfied when an object is created before midnight of the specified date in UTC.", + "format": "date" + }, + "isLive": { + "type": "boolean", + "description": "Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects." + }, + "matchesPattern": { + "type": "string", + "description": "A regular expression that satisfies the RE2 syntax. This condition is satisfied when the name of the object matches the RE2 pattern. Note: This feature is currently in the \"Early Access\" launch stage and is only available to a whitelisted set of users; that means that this feature may be changed in backward-incompatible ways and that it is not guaranteed to be released." + }, + "matchesStorageClass": { + "type": "array", + "description": "Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY.", + "items": { + "type": "string" + } + }, + "numNewerVersions": { + "type": "integer", + "description": "Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object.", + "format": "int32" + } + } } - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For lists of bucket access control entries, this is always storage#bucketAccessControls.", - "default": "storage#bucketAccessControls" + } } + } } - }, - "Buckets": { - "id": "Buckets", + }, + "location": { + "type": "string", + "description": "The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list." + }, + "locationType": { + "type": "string", + "description": "The type of the bucket location." + }, + "logging": { "type": "object", - "description": "A list of buckets.", + "description": "The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs.", "properties": { - "items": { - "type": "array", - "description": "The list of items.", - "items": { - "$ref": "Bucket" - } - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For lists of buckets, this is always storage#buckets.", - "default": "storage#buckets" - }, - "nextPageToken": { - "type": "string", - "description": "The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results." - } + "logBucket": { + "type": "string", + "description": "The destination bucket where the current bucket's logs should be placed." + }, + "logObjectPrefix": { + "type": "string", + "description": "A prefix for log object names." + } + } + }, + "metageneration": { + "type": "string", + "description": "The metadata generation of this bucket.", + "format": "int64" + }, + "name": { + "type": "string", + "description": "The name of the bucket.", + "annotations": { + "required": [ + "storage.buckets.insert" + ] } - }, - "Channel": { - "id": "Channel", + }, + "owner": { "type": "object", - "description": "An notification channel used to watch for resource changes.", + "description": "The owner of the bucket. This is always the project team's owner group.", "properties": { - "address": { - "type": "string", - "description": "The address where notifications are delivered for this channel." - }, - "expiration": { - "type": "string", - "description": "Date and time of notification channel expiration, expressed as a Unix timestamp, in milliseconds. Optional.", - "format": "int64" - }, - "id": { - "type": "string", - "description": "A UUID or similar unique string that identifies this channel." - }, - "kind": { - "type": "string", - "description": "Identifies this as a notification channel used to watch for changes to a resource. Value: the fixed string \"api#channel\".", - "default": "api#channel" - }, - "params": { - "type": "object", - "description": "Additional parameters controlling delivery channel behavior. Optional.", - "additionalProperties": { - "type": "string", - "description": "Declares a new parameter by name." - } - }, - "payload": { - "type": "boolean", - "description": "A Boolean value to indicate whether payload is wanted. Optional." - }, - "resourceId": { - "type": "string", - "description": "An opaque ID that identifies the resource being watched on this channel. Stable across different API versions." - }, - "resourceUri": { - "type": "string", - "description": "A version-specific identifier for the watched resource." - }, - "token": { - "type": "string", - "description": "An arbitrary string delivered to the target address with each notification delivered over this channel. Optional." - }, - "type": { - "type": "string", - "description": "The type of delivery mechanism used for this channel." - } + "entity": { + "type": "string", + "description": "The entity, in the form project-owner-projectId." + }, + "entityId": { + "type": "string", + "description": "The ID for the entity." + } } - }, - "ComposeRequest": { - "id": "ComposeRequest", + }, + "projectNumber": { + "type": "string", + "description": "The project number of the project the bucket belongs to.", + "format": "uint64" + }, + "retentionPolicy": { "type": "object", - "description": "A Compose request.", + "description": "The bucket's retention policy. The retention policy enforces a minimum retention time for all objects contained in the bucket, based on their creation time. Any attempt to overwrite or delete objects younger than the retention period will result in a PERMISSION_DENIED error. An unlocked retention policy can be modified or removed from the bucket via a storage.buckets.update operation. A locked retention policy cannot be removed or shortened in duration for the lifetime of the bucket. Attempting to remove or decrease period of a locked retention policy will result in a PERMISSION_DENIED error.", "properties": { - "destination": { - "$ref": "Object", - "description": "Properties of the resulting object." - }, - "kind": { - "type": "string", - "description": "The kind of item this is.", - "default": "storage#composeRequest" - }, - "sourceObjects": { - "type": "array", - "description": "The list of source objects that will be concatenated into a single object.", - "items": { - "type": "object", - "properties": { - "generation": { - "type": "string", - "description": "The generation of this object to use as the source.", - "format": "int64" - }, - "name": { - "type": "string", - "description": "The source object's name. The source object's bucket is implicitly the destination bucket.", - "annotations": { - "required": [ - "storage.objects.compose" - ] - } - }, - "objectPreconditions": { - "type": "object", - "description": "Conditions that must be met for this operation to execute.", - "properties": { - "ifGenerationMatch": { - "type": "string", - "description": "Only perform the composition if the generation of the source object that would be used matches this value. If this value and a generation are both specified, they must be the same value or the call will fail.", - "format": "int64" - } - } - } - } - }, - "annotations": { - "required": [ - "storage.objects.compose" - ] - } - } + "effectiveTime": { + "type": "string", + "description": "Server-determined value that indicates the time from which policy was enforced and effective. This value is in RFC 3339 format.", + "format": "date-time" + }, + "isLocked": { + "type": "boolean", + "description": "Once locked, an object retention policy cannot be modified." + }, + "retentionPeriod": { + "type": "string", + "description": "The duration in seconds that objects need to be retained. Retention duration must be greater than zero and less than 100 years. Note that enforcement of retention periods less than a day is not guaranteed. Such periods should only be used for testing purposes.", + "format": "int64" + } } - }, - "Notification": { - "id": "Notification", + }, + "selfLink": { + "type": "string", + "description": "The URI of this bucket." + }, + "storageClass": { + "type": "string", + "description": "The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes." + }, + "timeCreated": { + "type": "string", + "description": "The creation time of the bucket in RFC 3339 format.", + "format": "date-time" + }, + "updated": { + "type": "string", + "description": "The modification time of the bucket in RFC 3339 format.", + "format": "date-time" + }, + "versioning": { "type": "object", - "description": "A subscription to receive Google PubSub notifications.", + "description": "The bucket's versioning configuration.", "properties": { - "custom_attributes": { - "type": "object", - "description": "An optional list of additional attributes to attach to each Cloud PubSub message published for this notification subscription.", - "additionalProperties": { - "type": "string" - } - }, - "etag": { - "type": "string", - "description": "HTTP 1.1 Entity tag for this subscription notification." - }, - "event_types": { - "type": "array", - "description": "If present, only send notifications about listed event types. If empty, sent notifications for all event types.", - "items": { - "type": "string" - } - }, - "id": { - "type": "string", - "description": "The ID of the notification." - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For notifications, this is always storage#notification.", - "default": "storage#notification" - }, - "object_name_prefix": { - "type": "string", - "description": "If present, only apply this notification configuration to object names that begin with this prefix." - }, - "payload_format": { - "type": "string", - "description": "The desired content of the Payload.", - "default": "JSON_API_V1", - "annotations": { - "required": [ - "storage.notifications.insert" - ] - } - }, - "selfLink": { - "type": "string", - "description": "The canonical URL of this notification." - }, - "topic": { - "type": "string", - "description": "The Cloud PubSub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'", - "annotations": { - "required": [ - "storage.notifications.insert" - ] - } - } + "enabled": { + "type": "boolean", + "description": "While set to true, versioning is fully enabled for this bucket." + } } - }, - "Notifications": { - "id": "Notifications", + }, + "website": { "type": "object", - "description": "A list of notification subscriptions.", + "description": "The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information.", "properties": { - "items": { - "type": "array", - "description": "The list of items.", - "items": { - "$ref": "Notification" - } - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For lists of notifications, this is always storage#notifications.", - "default": "storage#notifications" - } + "mainPageSuffix": { + "type": "string", + "description": "If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages." + }, + "notFoundPage": { + "type": "string", + "description": "If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result." + } + } + } + } + }, + "BucketAccessControl": { + "id": "BucketAccessControl", + "type": "object", + "description": "An access-control entry.", + "properties": { + "bucket": { + "type": "string", + "description": "The name of the bucket." + }, + "domain": { + "type": "string", + "description": "The domain associated with the entity, if any." + }, + "email": { + "type": "string", + "description": "The email address associated with the entity, if any." + }, + "entity": { + "type": "string", + "description": "The entity holding the permission, in one of the following forms: \n- user-userId \n- user-email \n- group-groupId \n- group-email \n- domain-domain \n- project-team-projectId \n- allUsers \n- allAuthenticatedUsers Examples: \n- The user liz@example.com would be user-liz@example.com. \n- The group example@googlegroups.com would be group-example@googlegroups.com. \n- To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com.", + "annotations": { + "required": [ + "storage.bucketAccessControls.insert" + ] } - }, - "Object": { - "id": "Object", + }, + "entityId": { + "type": "string", + "description": "The ID for the entity, if any." + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for the access-control entry." + }, + "id": { + "type": "string", + "description": "The ID of the access-control entry." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl.", + "default": "storage#bucketAccessControl" + }, + "projectTeam": { "type": "object", - "description": "An object.", + "description": "The project team associated with the entity, if any.", "properties": { - "acl": { - "type": "array", - "description": "Access controls on the object.", - "items": { - "$ref": "ObjectAccessControl" - }, - "annotations": { - "required": [ - "storage.objects.update" - ] - } - }, - "bucket": { - "type": "string", - "description": "The name of the bucket containing this object." - }, - "cacheControl": { - "type": "string", - "description": "Cache-Control directive for the object data. If omitted, and the object is accessible to all anonymous users, the default will be public, max-age=3600." - }, - "componentCount": { - "type": "integer", - "description": "Number of underlying components that make up this object. Components are accumulated by compose operations.", - "format": "int32" - }, - "contentDisposition": { - "type": "string", - "description": "Content-Disposition of the object data." - }, - "contentEncoding": { - "type": "string", - "description": "Content-Encoding of the object data." - }, - "contentLanguage": { - "type": "string", - "description": "Content-Language of the object data." - }, - "contentType": { - "type": "string", - "description": "Content-Type of the object data. If an object is stored without a Content-Type, it is served as application/octet-stream." - }, - "crc32c": { - "type": "string", - "description": "CRC32c checksum, as described in RFC 4960, Appendix B; encoded using base64 in big-endian byte order. For more information about using the CRC32c checksum, see Hashes and ETags: Best Practices." - }, - "customerEncryption": { - "type": "object", - "description": "Metadata of customer-supplied encryption key, if the object is encrypted by such a key.", - "properties": { - "encryptionAlgorithm": { - "type": "string", - "description": "The encryption algorithm." - }, - "keySha256": { - "type": "string", - "description": "SHA256 hash value of the encryption key." - } - } - }, - "etag": { - "type": "string", - "description": "HTTP 1.1 Entity tag for the object." - }, - "eventBasedHold": { - "type": "boolean", - "description": "Defines the Event-Based hold for an object. Event-Based hold is a way to retain objects indefinitely until an event occurs, signified by the hold's release. After being released, such objects will be subject to bucket-level retention (if any). One sample use case of this flag is for banks to hold loan documents for at least 3 years after loan is paid in full. Here bucket-level retention is 3 years and the event is loan being paid in full. In this example these objects will be held intact for any number of years until the event has occurred (hold is released) and then 3 more years after that." - }, + "projectNumber": { + "type": "string", + "description": "The project number." + }, + "team": { + "type": "string", + "description": "The team." + } + } + }, + "role": { + "type": "string", + "description": "The access permission for the entity.", + "annotations": { + "required": [ + "storage.bucketAccessControls.insert" + ] + } + }, + "selfLink": { + "type": "string", + "description": "The link to this access-control entry." + } + } + }, + "BucketAccessControls": { + "id": "BucketAccessControls", + "type": "object", + "description": "An access-control list.", + "properties": { + "items": { + "type": "array", + "description": "The list of items.", + "items": { + "$ref": "BucketAccessControl" + } + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For lists of bucket access control entries, this is always storage#bucketAccessControls.", + "default": "storage#bucketAccessControls" + } + } + }, + "Buckets": { + "id": "Buckets", + "type": "object", + "description": "A list of buckets.", + "properties": { + "items": { + "type": "array", + "description": "The list of items.", + "items": { + "$ref": "Bucket" + } + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For lists of buckets, this is always storage#buckets.", + "default": "storage#buckets" + }, + "nextPageToken": { + "type": "string", + "description": "The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results." + } + } + }, + "Channel": { + "id": "Channel", + "type": "object", + "description": "An notification channel used to watch for resource changes.", + "properties": { + "address": { + "type": "string", + "description": "The address where notifications are delivered for this channel." + }, + "expiration": { + "type": "string", + "description": "Date and time of notification channel expiration, expressed as a Unix timestamp, in milliseconds. Optional.", + "format": "int64" + }, + "id": { + "type": "string", + "description": "A UUID or similar unique string that identifies this channel." + }, + "kind": { + "type": "string", + "description": "Identifies this as a notification channel used to watch for changes to a resource, which is \"api#channel\".", + "default": "api#channel" + }, + "params": { + "type": "object", + "description": "Additional parameters controlling delivery channel behavior. Optional.", + "additionalProperties": { + "type": "string", + "description": "Declares a new parameter by name." + } + }, + "payload": { + "type": "boolean", + "description": "A Boolean value to indicate whether payload is wanted. Optional." + }, + "resourceId": { + "type": "string", + "description": "An opaque ID that identifies the resource being watched on this channel. Stable across different API versions." + }, + "resourceUri": { + "type": "string", + "description": "A version-specific identifier for the watched resource." + }, + "token": { + "type": "string", + "description": "An arbitrary string delivered to the target address with each notification delivered over this channel. Optional." + }, + "type": { + "type": "string", + "description": "The type of delivery mechanism used for this channel." + } + } + }, + "ComposeRequest": { + "id": "ComposeRequest", + "type": "object", + "description": "A Compose request.", + "properties": { + "destination": { + "$ref": "Object", + "description": "Properties of the resulting object." + }, + "kind": { + "type": "string", + "description": "The kind of item this is.", + "default": "storage#composeRequest" + }, + "sourceObjects": { + "type": "array", + "description": "The list of source objects that will be concatenated into a single object.", + "items": { + "type": "object", + "properties": { "generation": { - "type": "string", - "description": "The content generation of this object. Used for object versioning.", - "format": "int64" - }, - "id": { - "type": "string", - "description": "The ID of the object, including the bucket name, object name, and generation number." - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For objects, this is always storage#object.", - "default": "storage#object" - }, - "kmsKeyName": { - "type": "string", - "description": "Cloud KMS Key used to encrypt this object, if the object is encrypted by such a key. Limited availability; usable only by enabled projects." - }, - "md5Hash": { - "type": "string", - "description": "MD5 hash of the data; encoded using base64. For more information about using the MD5 hash, see Hashes and ETags: Best Practices." - }, - "mediaLink": { - "type": "string", - "description": "Media download link." - }, - "metadata": { - "type": "object", - "description": "User-provided metadata, in key/value pairs.", - "additionalProperties": { - "type": "string", - "description": "An individual metadata entry." - } - }, - "metageneration": { - "type": "string", - "description": "The version of the metadata for this object at this generation. Used for preconditions and for detecting changes in metadata. A metageneration number is only meaningful in the context of a particular generation of a particular object.", - "format": "int64" + "type": "string", + "description": "The generation of this object to use as the source.", + "format": "int64" }, "name": { - "type": "string", - "description": "The name of the object. Required if not specified by URL parameter." - }, - "owner": { - "type": "object", - "description": "The owner of the object. This will always be the uploader of the object.", - "properties": { - "entity": { - "type": "string", - "description": "The entity, in the form user-userId." - }, - "entityId": { - "type": "string", - "description": "The ID for the entity." - } + "type": "string", + "description": "The source object's name. All source objects must reside in the same bucket.", + "annotations": { + "required": [ + "storage.objects.compose" + ] + } + }, + "objectPreconditions": { + "type": "object", + "description": "Conditions that must be met for this operation to execute.", + "properties": { + "ifGenerationMatch": { + "type": "string", + "description": "Only perform the composition if the generation of the source object that would be used matches this value. If this value and a generation are both specified, they must be the same value or the call will fail.", + "format": "int64" } - }, - "retentionExpirationTime": { - "type": "string", - "description": "Specifies the earliest time that the object's retention period expires. This value is server-determined and is in RFC 3339 format. Note 1: This field is not provided for objects with an active Event-Based hold, since retention expiration is unknown until the hold is removed. Note 2: This value can be provided even when TemporaryHold is set (so that the user can reason about policy without having to first unset the TemporaryHold).", - "format": "date-time" - }, - "selfLink": { - "type": "string", - "description": "The link to this object." - }, - "size": { - "type": "string", - "description": "Content-Length of the data in bytes.", - "format": "uint64" - }, - "storageClass": { - "type": "string", - "description": "Storage class of the object." - }, - "temporaryHold": { - "type": "boolean", - "description": "Defines the temporary hold for an object. This flag is used to enforce a temporary hold on an object. While it is set to true, the object is protected against deletion and overwrites. A common use case of this flag is regulatory investigations where objects need to be retained while the investigation is ongoing." - }, - "timeCreated": { - "type": "string", - "description": "The creation time of the object in RFC 3339 format.", - "format": "date-time" - }, - "timeDeleted": { - "type": "string", - "description": "The deletion time of the object in RFC 3339 format. Will be returned if and only if this version of the object has been deleted.", - "format": "date-time" - }, - "timeStorageClassUpdated": { - "type": "string", - "description": "The time at which the object's storage class was last changed. When the object is initially created, it will be set to timeCreated.", - "format": "date-time" - }, - "updated": { - "type": "string", - "description": "The modification time of the object metadata in RFC 3339 format.", - "format": "date-time" + } } + } + }, + "annotations": { + "required": [ + "storage.objects.compose" + ] } - }, - "ObjectAccessControl": { - "id": "ObjectAccessControl", - "type": "object", - "description": "An access-control entry.", - "properties": { - "bucket": { - "type": "string", - "description": "The name of the bucket." - }, - "domain": { - "type": "string", - "description": "The domain associated with the entity, if any." - }, - "email": { - "type": "string", - "description": "The email address associated with the entity, if any." - }, - "entity": { - "type": "string", - "description": "The entity holding the permission, in one of the following forms: \n- user-userId \n- user-email \n- group-groupId \n- group-email \n- domain-domain \n- project-team-projectId \n- allUsers \n- allAuthenticatedUsers Examples: \n- The user liz@example.com would be user-liz@example.com. \n- The group example@googlegroups.com would be group-example@googlegroups.com. \n- To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com.", - "annotations": { - "required": [ - "storage.defaultObjectAccessControls.insert", - "storage.objectAccessControls.insert" - ] - } - }, - "entityId": { - "type": "string", - "description": "The ID for the entity, if any." - }, - "etag": { - "type": "string", - "description": "HTTP 1.1 Entity tag for the access-control entry." - }, - "generation": { - "type": "string", - "description": "The content generation of the object, if applied to an object.", - "format": "int64" - }, - "id": { - "type": "string", - "description": "The ID of the access-control entry." - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For object access control entries, this is always storage#objectAccessControl.", - "default": "storage#objectAccessControl" - }, - "object": { - "type": "string", - "description": "The name of the object, if applied to an object." - }, - "projectTeam": { - "type": "object", - "description": "The project team associated with the entity, if any.", - "properties": { - "projectNumber": { - "type": "string", - "description": "The project number." - }, - "team": { - "type": "string", - "description": "The team." - } - } - }, - "role": { - "type": "string", - "description": "The access permission for the entity.", - "annotations": { - "required": [ - "storage.defaultObjectAccessControls.insert", - "storage.objectAccessControls.insert" - ] - } - }, - "selfLink": { - "type": "string", - "description": "The link to this access-control entry." - } + } + } + }, + "Expr": { + "id": "Expr", + "type": "object", + "description": "Represents an expression text. Example: title: \"User account presence\" description: \"Determines whether the request has a user account\" expression: \"size(request.user) \u003e 0\"", + "properties": { + "description": { + "type": "string", + "description": "An optional description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI." + }, + "expression": { + "type": "string", + "description": "Textual representation of an expression in Common Expression Language syntax. The application context of the containing message determines which well-known feature set of CEL is supported." + }, + "location": { + "type": "string", + "description": "An optional string indicating the location of the expression for error reporting, e.g. a file name and a position in the file." + }, + "title": { + "type": "string", + "description": "An optional title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression." + } + } + }, + "HmacKey": { + "id": "HmacKey", + "type": "object", + "description": "JSON template to produce a JSON-style HMAC Key resource for Create responses.", + "properties": { + "kind": { + "type": "string", + "description": "The kind of item this is. For HMAC keys, this is always storage#hmacKey.", + "default": "storage#hmacKey" + }, + "metadata": { + "$ref": "HmacKeyMetadata", + "description": "Key metadata." + }, + "secret": { + "type": "string", + "description": "HMAC secret key material." + } + } + }, + "HmacKeyMetadata": { + "id": "HmacKeyMetadata", + "type": "object", + "description": "JSON template to produce a JSON-style HMAC Key metadata resource.", + "properties": { + "accessId": { + "type": "string", + "description": "The ID of the HMAC Key." + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for the HMAC key." + }, + "id": { + "type": "string", + "description": "The ID of the HMAC key, including the Project ID and the Access ID." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For HMAC Key metadata, this is always storage#hmacKeyMetadata.", + "default": "storage#hmacKeyMetadata" + }, + "projectId": { + "type": "string", + "description": "Project ID owning the service account to which the key authenticates." + }, + "selfLink": { + "type": "string", + "description": "The link to this resource." + }, + "serviceAccountEmail": { + "type": "string", + "description": "The email address of the key's associated service account." + }, + "state": { + "type": "string", + "description": "The state of the key. Can be one of ACTIVE, INACTIVE, or DELETED." + }, + "timeCreated": { + "type": "string", + "description": "The creation time of the HMAC key in RFC 3339 format.", + "format": "date-time" + }, + "updated": { + "type": "string", + "description": "The last modification time of the HMAC key metadata in RFC 3339 format.", + "format": "date-time" + } + } + }, + "HmacKeysMetadata": { + "id": "HmacKeysMetadata", + "type": "object", + "description": "A list of hmacKeys.", + "properties": { + "items": { + "type": "array", + "description": "The list of items.", + "items": { + "$ref": "HmacKeyMetadata" } - }, - "ObjectAccessControls": { - "id": "ObjectAccessControls", + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For lists of hmacKeys, this is always storage#hmacKeysMetadata.", + "default": "storage#hmacKeysMetadata" + }, + "nextPageToken": { + "type": "string", + "description": "The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results." + } + } + }, + "Notification": { + "id": "Notification", + "type": "object", + "description": "A subscription to receive Google PubSub notifications.", + "properties": { + "custom_attributes": { "type": "object", - "description": "An access-control list.", - "properties": { - "items": { - "type": "array", - "description": "The list of items.", - "items": { - "$ref": "ObjectAccessControl" - } - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For lists of object access control entries, this is always storage#objectAccessControls.", - "default": "storage#objectAccessControls" - } + "description": "An optional list of additional attributes to attach to each Cloud PubSub message published for this notification subscription.", + "additionalProperties": { + "type": "string" } - }, - "Objects": { - "id": "Objects", - "type": "object", - "description": "A list of objects.", - "properties": { - "items": { - "type": "array", - "description": "The list of items.", - "items": { - "$ref": "Object" - } - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For lists of objects, this is always storage#objects.", - "default": "storage#objects" - }, - "nextPageToken": { - "type": "string", - "description": "The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results." - }, - "prefixes": { - "type": "array", - "description": "The list of prefixes of objects matching-but-not-listed up to and including the requested delimiter.", - "items": { - "type": "string" - } - } + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for this subscription notification." + }, + "event_types": { + "type": "array", + "description": "If present, only send notifications about listed event types. If empty, sent notifications for all event types.", + "items": { + "type": "string" + } + }, + "id": { + "type": "string", + "description": "The ID of the notification." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For notifications, this is always storage#notification.", + "default": "storage#notification" + }, + "object_name_prefix": { + "type": "string", + "description": "If present, only apply this notification configuration to object names that begin with this prefix." + }, + "payload_format": { + "type": "string", + "description": "The desired content of the Payload.", + "default": "JSON_API_V1", + "annotations": { + "required": [ + "storage.notifications.insert" + ] + } + }, + "selfLink": { + "type": "string", + "description": "The canonical URL of this notification." + }, + "topic": { + "type": "string", + "description": "The Cloud PubSub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'", + "annotations": { + "required": [ + "storage.notifications.insert" + ] + } + } + } + }, + "Notifications": { + "id": "Notifications", + "type": "object", + "description": "A list of notification subscriptions.", + "properties": { + "items": { + "type": "array", + "description": "The list of items.", + "items": { + "$ref": "Notification" } - }, - "Policy": { - "id": "Policy", + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For lists of notifications, this is always storage#notifications.", + "default": "storage#notifications" + } + } + }, + "Object": { + "id": "Object", + "type": "object", + "description": "An object.", + "properties": { + "acl": { + "type": "array", + "description": "Access controls on the object.", + "items": { + "$ref": "ObjectAccessControl" + }, + "annotations": { + "required": [ + "storage.objects.update" + ] + } + }, + "bucket": { + "type": "string", + "description": "The name of the bucket containing this object." + }, + "cacheControl": { + "type": "string", + "description": "Cache-Control directive for the object data. If omitted, and the object is accessible to all anonymous users, the default will be public, max-age=3600." + }, + "componentCount": { + "type": "integer", + "description": "Number of underlying components that make up this object. Components are accumulated by compose operations.", + "format": "int32" + }, + "contentDisposition": { + "type": "string", + "description": "Content-Disposition of the object data." + }, + "contentEncoding": { + "type": "string", + "description": "Content-Encoding of the object data." + }, + "contentLanguage": { + "type": "string", + "description": "Content-Language of the object data." + }, + "contentType": { + "type": "string", + "description": "Content-Type of the object data. If an object is stored without a Content-Type, it is served as application/octet-stream." + }, + "crc32c": { + "type": "string", + "description": "CRC32c checksum, as described in RFC 4960, Appendix B; encoded using base64 in big-endian byte order. For more information about using the CRC32c checksum, see Hashes and ETags: Best Practices." + }, + "customerEncryption": { "type": "object", - "description": "A bucket/object IAM policy.", + "description": "Metadata of customer-supplied encryption key, if the object is encrypted by such a key.", "properties": { - "bindings": { - "type": "array", - "description": "An association between a role, which comes with a set of permissions, and members who may assume that role.", - "items": { - "type": "object", - "properties": { - "condition": { - "type": "any" - }, - "members": { - "type": "array", - "description": "A collection of identifiers for members who may assume the provided role. Recognized identifiers are as follows: \n- allUsers — A special identifier that represents anyone on the internet; with or without a Google account. \n- allAuthenticatedUsers — A special identifier that represents anyone who is authenticated with a Google account or a service account. \n- user:emailid — An email address that represents a specific account. For example, user:alice@gmail.com or user:joe@example.com. \n- serviceAccount:emailid — An email address that represents a service account. For example, serviceAccount:my-other-app@appspot.gserviceaccount.com . \n- group:emailid — An email address that represents a Google group. For example, group:admins@example.com. \n- domain:domain — A Google Apps domain name that represents all the users of that domain. For example, domain:google.com or domain:example.com. \n- projectOwner:projectid — Owners of the given project. For example, projectOwner:my-example-project \n- projectEditor:projectid — Editors of the given project. For example, projectEditor:my-example-project \n- projectViewer:projectid — Viewers of the given project. For example, projectViewer:my-example-project", - "items": { - "type": "string" - }, - "annotations": { - "required": [ - "storage.buckets.setIamPolicy", - "storage.objects.setIamPolicy" - ] - } - }, - "role": { - "type": "string", - "description": "The role to which members belong. Two types of roles are supported: new IAM roles, which grant permissions that do not map directly to those provided by ACLs, and legacy IAM roles, which do map directly to ACL permissions. All roles are of the format roles/storage.specificRole.\nThe new IAM roles are: \n- roles/storage.admin — Full control of Google Cloud Storage resources. \n- roles/storage.objectViewer — Read-Only access to Google Cloud Storage objects. \n- roles/storage.objectCreator — Access to create objects in Google Cloud Storage. \n- roles/storage.objectAdmin — Full control of Google Cloud Storage objects. The legacy IAM roles are: \n- roles/storage.legacyObjectReader — Read-only access to objects without listing. Equivalent to an ACL entry on an object with the READER role. \n- roles/storage.legacyObjectOwner — Read/write access to existing objects without listing. Equivalent to an ACL entry on an object with the OWNER role. \n- roles/storage.legacyBucketReader — Read access to buckets with object listing. Equivalent to an ACL entry on a bucket with the READER role. \n- roles/storage.legacyBucketWriter — Read access to buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the WRITER role. \n- roles/storage.legacyBucketOwner — Read and write access to existing buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the OWNER role.", - "annotations": { - "required": [ - "storage.buckets.setIamPolicy", - "storage.objects.setIamPolicy" - ] - } - } - } - }, - "annotations": { - "required": [ - "storage.buckets.setIamPolicy", - "storage.objects.setIamPolicy" - ] - } - }, - "etag": { - "type": "string", - "description": "HTTP 1.1 Entity tag for the policy.", - "format": "byte" - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For policies, this is always storage#policy. This field is ignored on input.", - "default": "storage#policy" - }, - "resourceId": { - "type": "string", - "description": "The ID of the resource to which this policy belongs. Will be of the form projects/_/buckets/bucket for buckets, and projects/_/buckets/bucket/objects/object for objects. A specific generation may be specified by appending #generationNumber to the end of the object name, e.g. projects/_/buckets/my-bucket/objects/data.txt#17. The current generation can be denoted with #0. This field is ignored on input." - } + "encryptionAlgorithm": { + "type": "string", + "description": "The encryption algorithm." + }, + "keySha256": { + "type": "string", + "description": "SHA256 hash value of the encryption key." + } } - }, - "RewriteResponse": { - "id": "RewriteResponse", + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for the object." + }, + "eventBasedHold": { + "type": "boolean", + "description": "Whether an object is under event-based hold. Event-based hold is a way to retain objects until an event occurs, which is signified by the hold's release (i.e. this value is set to false). After being released (set to false), such objects will be subject to bucket-level retention (if any). One sample use case of this flag is for banks to hold loan documents for at least 3 years after loan is paid in full. Here, bucket-level retention is 3 years and the event is the loan being paid in full. In this example, these objects will be held intact for any number of years until the event has occurred (event-based hold on the object is released) and then 3 more years after that. That means retention duration of the objects begins from the moment event-based hold transitioned from true to false." + }, + "generation": { + "type": "string", + "description": "The content generation of this object. Used for object versioning.", + "format": "int64" + }, + "id": { + "type": "string", + "description": "The ID of the object, including the bucket name, object name, and generation number." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For objects, this is always storage#object.", + "default": "storage#object" + }, + "kmsKeyName": { + "type": "string", + "description": "Cloud KMS Key used to encrypt this object, if the object is encrypted by such a key." + }, + "md5Hash": { + "type": "string", + "description": "MD5 hash of the data; encoded using base64. For more information about using the MD5 hash, see Hashes and ETags: Best Practices." + }, + "mediaLink": { + "type": "string", + "description": "Media download link." + }, + "metadata": { "type": "object", - "description": "A rewrite response.", - "properties": { - "done": { - "type": "boolean", - "description": "true if the copy is finished; otherwise, false if the copy is in progress. This property is always present in the response." - }, - "kind": { - "type": "string", - "description": "The kind of item this is.", - "default": "storage#rewriteResponse" - }, - "objectSize": { - "type": "string", - "description": "The total size of the object being copied in bytes. This property is always present in the response.", - "format": "int64" - }, - "resource": { - "$ref": "Object", - "description": "A resource containing the metadata for the copied-to object. This property is present in the response only when copying completes." - }, - "rewriteToken": { - "type": "string", - "description": "A token to use in subsequent requests to continue copying data. This token is present in the response only when there is more data to copy." - }, - "totalBytesRewritten": { - "type": "string", - "description": "The total bytes written so far, which can be used to provide a waiting user with a progress indicator. This property is always present in the response.", - "format": "int64" - } + "description": "User-provided metadata, in key/value pairs.", + "additionalProperties": { + "type": "string", + "description": "An individual metadata entry." } - }, - "ServiceAccount": { - "id": "ServiceAccount", + }, + "metageneration": { + "type": "string", + "description": "The version of the metadata for this object at this generation. Used for preconditions and for detecting changes in metadata. A metageneration number is only meaningful in the context of a particular generation of a particular object.", + "format": "int64" + }, + "name": { + "type": "string", + "description": "The name of the object. Required if not specified by URL parameter." + }, + "owner": { "type": "object", - "description": "A subscription to receive Google PubSub notifications.", + "description": "The owner of the object. This will always be the uploader of the object.", "properties": { - "email_address": { - "type": "string", - "description": "The ID of the notification." - }, - "kind": { - "type": "string", - "description": "The kind of item this is. For notifications, this is always storage#notification.", - "default": "storage#serviceAccount" - } + "entity": { + "type": "string", + "description": "The entity, in the form user-userId." + }, + "entityId": { + "type": "string", + "description": "The ID for the entity." + } + } + }, + "retentionExpirationTime": { + "type": "string", + "description": "A server-determined value that specifies the earliest time that the object's retention period expires. This value is in RFC 3339 format. Note 1: This field is not provided for objects with an active event-based hold, since retention expiration is unknown until the hold is removed. Note 2: This value can be provided even when temporary hold is set (so that the user can reason about policy without having to first unset the temporary hold).", + "format": "date-time" + }, + "selfLink": { + "type": "string", + "description": "The link to this object." + }, + "size": { + "type": "string", + "description": "Content-Length of the data in bytes.", + "format": "uint64" + }, + "storageClass": { + "type": "string", + "description": "Storage class of the object." + }, + "temporaryHold": { + "type": "boolean", + "description": "Whether an object is under temporary hold. While this flag is set to true, the object is protected against deletion and overwrites. A common use case of this flag is regulatory investigations where objects need to be retained while the investigation is ongoing. Note that unlike event-based hold, temporary hold does not impact retention expiration time of an object." + }, + "timeCreated": { + "type": "string", + "description": "The creation time of the object in RFC 3339 format.", + "format": "date-time" + }, + "timeDeleted": { + "type": "string", + "description": "The deletion time of the object in RFC 3339 format. Will be returned if and only if this version of the object has been deleted.", + "format": "date-time" + }, + "timeStorageClassUpdated": { + "type": "string", + "description": "The time at which the object's storage class was last changed. When the object is initially created, it will be set to timeCreated.", + "format": "date-time" + }, + "updated": { + "type": "string", + "description": "The modification time of the object metadata in RFC 3339 format.", + "format": "date-time" + } + } + }, + "ObjectAccessControl": { + "id": "ObjectAccessControl", + "type": "object", + "description": "An access-control entry.", + "properties": { + "bucket": { + "type": "string", + "description": "The name of the bucket." + }, + "domain": { + "type": "string", + "description": "The domain associated with the entity, if any." + }, + "email": { + "type": "string", + "description": "The email address associated with the entity, if any." + }, + "entity": { + "type": "string", + "description": "The entity holding the permission, in one of the following forms: \n- user-userId \n- user-email \n- group-groupId \n- group-email \n- domain-domain \n- project-team-projectId \n- allUsers \n- allAuthenticatedUsers Examples: \n- The user liz@example.com would be user-liz@example.com. \n- The group example@googlegroups.com would be group-example@googlegroups.com. \n- To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com.", + "annotations": { + "required": [ + "storage.defaultObjectAccessControls.insert", + "storage.objectAccessControls.insert" + ] } - }, - "TestIamPermissionsResponse": { - "id": "TestIamPermissionsResponse", + }, + "entityId": { + "type": "string", + "description": "The ID for the entity, if any." + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for the access-control entry." + }, + "generation": { + "type": "string", + "description": "The content generation of the object, if applied to an object.", + "format": "int64" + }, + "id": { + "type": "string", + "description": "The ID of the access-control entry." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For object access control entries, this is always storage#objectAccessControl.", + "default": "storage#objectAccessControl" + }, + "object": { + "type": "string", + "description": "The name of the object, if applied to an object." + }, + "projectTeam": { "type": "object", - "description": "A storage.(buckets|objects).testIamPermissions response.", + "description": "The project team associated with the entity, if any.", "properties": { - "kind": { - "type": "string", - "description": "The kind of item this is.", - "default": "storage#testIamPermissionsResponse" - }, - "permissions": { - "type": "array", - "description": "The permissions held by the caller. Permissions are always of the format storage.resource.capability, where resource is one of buckets or objects. The supported permissions are as follows: \n- storage.buckets.delete — Delete bucket. \n- storage.buckets.get — Read bucket metadata. \n- storage.buckets.getIamPolicy — Read bucket IAM policy. \n- storage.buckets.create — Create bucket. \n- storage.buckets.list — List buckets. \n- storage.buckets.setIamPolicy — Update bucket IAM policy. \n- storage.buckets.update — Update bucket metadata. \n- storage.objects.delete — Delete object. \n- storage.objects.get — Read object data and metadata. \n- storage.objects.getIamPolicy — Read object IAM policy. \n- storage.objects.create — Create object. \n- storage.objects.list — List objects. \n- storage.objects.setIamPolicy — Update object IAM policy. \n- storage.objects.update — Update object metadata.", - "items": { - "type": "string" - } - } + "projectNumber": { + "type": "string", + "description": "The project number." + }, + "team": { + "type": "string", + "description": "The team." + } + } + }, + "role": { + "type": "string", + "description": "The access permission for the entity.", + "annotations": { + "required": [ + "storage.defaultObjectAccessControls.insert", + "storage.objectAccessControls.insert" + ] } + }, + "selfLink": { + "type": "string", + "description": "The link to this access-control entry." + } } - }, - "resources": { - "bucketAccessControls": { - "methods": { - "delete": { - "id": "storage.bucketAccessControls.delete", - "path": "b/{bucket}/acl/{entity}", - "httpMethod": "DELETE", - "description": "Permanently deletes the ACL entry for the specified entity on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "get": { - "id": "storage.bucketAccessControls.get", - "path": "b/{bucket}/acl/{entity}", - "httpMethod": "GET", - "description": "Returns the ACL entry for the specified entity on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "response": { - "$ref": "BucketAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "insert": { - "id": "storage.bucketAccessControls.insert", - "path": "b/{bucket}/acl", - "httpMethod": "POST", - "description": "Creates a new ACL entry on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "BucketAccessControl" - }, - "response": { - "$ref": "BucketAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "list": { - "id": "storage.bucketAccessControls.list", - "path": "b/{bucket}/acl", - "httpMethod": "GET", - "description": "Retrieves ACL entries on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "response": { - "$ref": "BucketAccessControls" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "patch": { - "id": "storage.bucketAccessControls.patch", - "path": "b/{bucket}/acl/{entity}", - "httpMethod": "PATCH", - "description": "Updates an ACL entry on the specified bucket. This method supports patch semantics.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "request": { - "$ref": "BucketAccessControl" - }, - "response": { - "$ref": "BucketAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" + }, + "ObjectAccessControls": { + "id": "ObjectAccessControls", + "type": "object", + "description": "An access-control list.", + "properties": { + "items": { + "type": "array", + "description": "The list of items.", + "items": { + "$ref": "ObjectAccessControl" + } + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For lists of object access control entries, this is always storage#objectAccessControls.", + "default": "storage#objectAccessControls" + } + } + }, + "Objects": { + "id": "Objects", + "type": "object", + "description": "A list of objects.", + "properties": { + "items": { + "type": "array", + "description": "The list of items.", + "items": { + "$ref": "Object" + } + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For lists of objects, this is always storage#objects.", + "default": "storage#objects" + }, + "nextPageToken": { + "type": "string", + "description": "The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results." + }, + "prefixes": { + "type": "array", + "description": "The list of prefixes of objects matching-but-not-listed up to and including the requested delimiter.", + "items": { + "type": "string" + } + } + } + }, + "Policy": { + "id": "Policy", + "type": "object", + "description": "A bucket/object IAM policy.", + "properties": { + "bindings": { + "type": "array", + "description": "An association between a role, which comes with a set of permissions, and members who may assume that role.", + "items": { + "type": "object", + "properties": { + "condition": { + "$ref": "Expr", + "description": "The condition that is associated with this binding. NOTE: an unsatisfied condition will not allow user access via current binding. Different bindings, including their conditions, are examined independently." + }, + "members": { + "type": "array", + "description": "A collection of identifiers for members who may assume the provided role. Recognized identifiers are as follows: \n- allUsers — A special identifier that represents anyone on the internet; with or without a Google account. \n- allAuthenticatedUsers — A special identifier that represents anyone who is authenticated with a Google account or a service account. \n- user:emailid — An email address that represents a specific account. For example, user:alice@gmail.com or user:joe@example.com. \n- serviceAccount:emailid — An email address that represents a service account. For example, serviceAccount:my-other-app@appspot.gserviceaccount.com . \n- group:emailid — An email address that represents a Google group. For example, group:admins@example.com. \n- domain:domain — A Google Apps domain name that represents all the users of that domain. For example, domain:google.com or domain:example.com. \n- projectOwner:projectid — Owners of the given project. For example, projectOwner:my-example-project \n- projectEditor:projectid — Editors of the given project. For example, projectEditor:my-example-project \n- projectViewer:projectid — Viewers of the given project. For example, projectViewer:my-example-project", + "items": { + "type": "string" + }, + "annotations": { + "required": [ + "storage.buckets.setIamPolicy", + "storage.objects.setIamPolicy" ] + } }, - "update": { - "id": "storage.bucketAccessControls.update", - "path": "b/{bucket}/acl/{entity}", - "httpMethod": "PUT", - "description": "Updates an ACL entry on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "request": { - "$ref": "BucketAccessControl" - }, - "response": { - "$ref": "BucketAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" + "role": { + "type": "string", + "description": "The role to which members belong. Two types of roles are supported: new IAM roles, which grant permissions that do not map directly to those provided by ACLs, and legacy IAM roles, which do map directly to ACL permissions. All roles are of the format roles/storage.specificRole.\nThe new IAM roles are: \n- roles/storage.admin — Full control of Google Cloud Storage resources. \n- roles/storage.objectViewer — Read-Only access to Google Cloud Storage objects. \n- roles/storage.objectCreator — Access to create objects in Google Cloud Storage. \n- roles/storage.objectAdmin — Full control of Google Cloud Storage objects. The legacy IAM roles are: \n- roles/storage.legacyObjectReader — Read-only access to objects without listing. Equivalent to an ACL entry on an object with the READER role. \n- roles/storage.legacyObjectOwner — Read/write access to existing objects without listing. Equivalent to an ACL entry on an object with the OWNER role. \n- roles/storage.legacyBucketReader — Read access to buckets with object listing. Equivalent to an ACL entry on a bucket with the READER role. \n- roles/storage.legacyBucketWriter — Read access to buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the WRITER role. \n- roles/storage.legacyBucketOwner — Read and write access to existing buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the OWNER role.", + "annotations": { + "required": [ + "storage.buckets.setIamPolicy", + "storage.objects.setIamPolicy" ] + } } + } + }, + "annotations": { + "required": [ + "storage.buckets.setIamPolicy", + "storage.objects.setIamPolicy" + ] } - }, - "buckets": { - "methods": { - "delete": { - "id": "storage.buckets.delete", - "path": "b/{bucket}", - "httpMethod": "DELETE", - "description": "Permanently deletes an empty bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "If set, only deletes the bucket if its metageneration matches this value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "If set, only deletes the bucket if its metageneration does not match this value.", - "format": "int64", - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "get": { - "id": "storage.buckets.get", - "path": "b/{bucket}", - "httpMethod": "GET", - "description": "Returns metadata for the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit owner, acl and defaultObjectAcl properties." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "response": { - "$ref": "Bucket" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "getIamPolicy": { - "id": "storage.buckets.getIamPolicy", - "path": "b/{bucket}/iam", - "httpMethod": "GET", - "description": "Returns an IAM policy for the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "response": { - "$ref": "Policy" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "insert": { - "id": "storage.buckets.insert", - "path": "b", - "httpMethod": "POST", - "description": "Creates a new bucket.", - "parameters": { - "predefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to this bucket.", - "enum": [ - "authenticatedRead", - "private", - "projectPrivate", - "publicRead", - "publicReadWrite" - ], - "enumDescriptions": [ - "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", - "Project team owners get OWNER access.", - "Project team members get access according to their roles.", - "Project team owners get OWNER access, and allUsers get READER access.", - "Project team owners get OWNER access, and allUsers get WRITER access." - ], - "location": "query" - }, - "predefinedDefaultObjectAcl": { - "type": "string", - "description": "Apply a predefined set of default object access controls to this bucket.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "project": { - "type": "string", - "description": "A valid API project identifier.", - "required": true, - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl, unless the bucket resource specifies acl or defaultObjectAcl properties, when it defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit owner, acl and defaultObjectAcl properties." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request.", - "location": "query" - } - }, - "parameterOrder": [ - "project" - ], - "request": { - "$ref": "Bucket" - }, - "response": { - "$ref": "Bucket" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "list": { - "id": "storage.buckets.list", - "path": "b", - "httpMethod": "GET", - "description": "Retrieves a list of buckets for a given project.", - "parameters": { - "maxResults": { - "type": "integer", - "description": "Maximum number of buckets to return in a single response. The service will use this parameter or 1,000 items, whichever is smaller.", - "default": "1000", - "format": "uint32", - "minimum": "0", - "location": "query" - }, - "pageToken": { - "type": "string", - "description": "A previously-returned page token representing part of the larger set of results to view.", - "location": "query" - }, - "prefix": { - "type": "string", - "description": "Filter results to buckets whose names begin with this prefix.", - "location": "query" - }, - "project": { - "type": "string", - "description": "A valid API project identifier.", - "required": true, - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit owner, acl and defaultObjectAcl properties." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request.", - "location": "query" - } - }, - "parameterOrder": [ - "project" - ], - "response": { - "$ref": "Buckets" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "lockRetentionPolicy": { - "id": "storage.buckets.lockRetentionPolicy", - "path": "b/{bucket}/lockRetentionPolicy", - "httpMethod": "POST", - "description": "Locks retention policy on a bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether bucket's current metageneration matches the given value.", - "required": true, - "format": "int64", - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "ifMetagenerationMatch" - ], - "response": { - "$ref": "Bucket" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "patch": { - "id": "storage.buckets.patch", - "path": "b/{bucket}", - "httpMethod": "PATCH", - "description": "Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate. This method supports patch semantics.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "predefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to this bucket.", - "enum": [ - "authenticatedRead", - "private", - "projectPrivate", - "publicRead", - "publicReadWrite" - ], - "enumDescriptions": [ - "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", - "Project team owners get OWNER access.", - "Project team members get access according to their roles.", - "Project team owners get OWNER access, and allUsers get READER access.", - "Project team owners get OWNER access, and allUsers get WRITER access." - ], - "location": "query" - }, - "predefinedDefaultObjectAcl": { - "type": "string", - "description": "Apply a predefined set of default object access controls to this bucket.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit owner, acl and defaultObjectAcl properties." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "Bucket" - }, - "response": { - "$ref": "Bucket" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "setIamPolicy": { - "id": "storage.buckets.setIamPolicy", - "path": "b/{bucket}/iam", - "httpMethod": "PUT", - "description": "Updates an IAM policy for the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "Policy" - }, - "response": { - "$ref": "Policy" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "testIamPermissions": { - "id": "storage.buckets.testIamPermissions", - "path": "b/{bucket}/iam/testPermissions", - "httpMethod": "GET", - "description": "Tests a set of permissions on the given bucket to see which, if any, are held by the caller.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "permissions": { - "type": "string", - "description": "Permissions to test.", - "required": true, - "repeated": true, - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "permissions" - ], - "response": { - "$ref": "TestIamPermissionsResponse" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "update": { - "id": "storage.buckets.update", - "path": "b/{bucket}", - "httpMethod": "PUT", - "description": "Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "predefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to this bucket.", - "enum": [ - "authenticatedRead", - "private", - "projectPrivate", - "publicRead", - "publicReadWrite" - ], - "enumDescriptions": [ - "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", - "Project team owners get OWNER access.", - "Project team members get access according to their roles.", - "Project team owners get OWNER access, and allUsers get READER access.", - "Project team owners get OWNER access, and allUsers get WRITER access." - ], - "location": "query" - }, - "predefinedDefaultObjectAcl": { - "type": "string", - "description": "Apply a predefined set of default object access controls to this bucket.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit owner, acl and defaultObjectAcl properties." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "Bucket" - }, - "response": { - "$ref": "Bucket" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - } - } - }, - "channels": { - "methods": { - "stop": { - "id": "storage.channels.stop", - "path": "channels/stop", - "httpMethod": "POST", - "description": "Stop watching resources through this channel", - "request": { - "$ref": "Channel", - "parameterName": "resource" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - } - } - }, - "defaultObjectAccessControls": { - "methods": { - "delete": { - "id": "storage.defaultObjectAccessControls.delete", - "path": "b/{bucket}/defaultObjectAcl/{entity}", - "httpMethod": "DELETE", - "description": "Permanently deletes the default object ACL entry for the specified entity on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "get": { - "id": "storage.defaultObjectAccessControls.get", - "path": "b/{bucket}/defaultObjectAcl/{entity}", - "httpMethod": "GET", - "description": "Returns the default object ACL entry for the specified entity on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "insert": { - "id": "storage.defaultObjectAccessControls.insert", - "path": "b/{bucket}/defaultObjectAcl", - "httpMethod": "POST", - "description": "Creates a new default object ACL entry on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "ObjectAccessControl" - }, - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "list": { - "id": "storage.defaultObjectAccessControls.list", - "path": "b/{bucket}/defaultObjectAcl", - "httpMethod": "GET", - "description": "Retrieves default object ACL entries on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "If present, only return default ACL listing if the bucket's current metageneration matches this value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "If present, only return default ACL listing if the bucket's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "response": { - "$ref": "ObjectAccessControls" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "patch": { - "id": "storage.defaultObjectAccessControls.patch", - "path": "b/{bucket}/defaultObjectAcl/{entity}", - "httpMethod": "PATCH", - "description": "Updates a default object ACL entry on the specified bucket. This method supports patch semantics.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "request": { - "$ref": "ObjectAccessControl" - }, - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "update": { - "id": "storage.defaultObjectAccessControls.update", - "path": "b/{bucket}/defaultObjectAcl/{entity}", - "httpMethod": "PUT", - "description": "Updates a default object ACL entry on the specified bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "entity" - ], - "request": { - "$ref": "ObjectAccessControl" - }, - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - } + }, + "etag": { + "type": "string", + "description": "HTTP 1.1 Entity tag for the policy.", + "format": "byte" + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For policies, this is always storage#policy. This field is ignored on input.", + "default": "storage#policy" + }, + "resourceId": { + "type": "string", + "description": "The ID of the resource to which this policy belongs. Will be of the form projects/_/buckets/bucket for buckets, and projects/_/buckets/bucket/objects/object for objects. A specific generation may be specified by appending #generationNumber to the end of the object name, e.g. projects/_/buckets/my-bucket/objects/data.txt#17. The current generation can be denoted with #0. This field is ignored on input." + }, + "version": { + "type": "integer", + "description": "The IAM policy format version.", + "format": "int32" + } + } + }, + "RewriteResponse": { + "id": "RewriteResponse", + "type": "object", + "description": "A rewrite response.", + "properties": { + "done": { + "type": "boolean", + "description": "true if the copy is finished; otherwise, false if the copy is in progress. This property is always present in the response." + }, + "kind": { + "type": "string", + "description": "The kind of item this is.", + "default": "storage#rewriteResponse" + }, + "objectSize": { + "type": "string", + "description": "The total size of the object being copied in bytes. This property is always present in the response.", + "format": "int64" + }, + "resource": { + "$ref": "Object", + "description": "A resource containing the metadata for the copied-to object. This property is present in the response only when copying completes." + }, + "rewriteToken": { + "type": "string", + "description": "A token to use in subsequent requests to continue copying data. This token is present in the response only when there is more data to copy." + }, + "totalBytesRewritten": { + "type": "string", + "description": "The total bytes written so far, which can be used to provide a waiting user with a progress indicator. This property is always present in the response.", + "format": "int64" + } + } + }, + "ServiceAccount": { + "id": "ServiceAccount", + "type": "object", + "description": "A subscription to receive Google PubSub notifications.", + "properties": { + "email_address": { + "type": "string", + "description": "The ID of the notification." + }, + "kind": { + "type": "string", + "description": "The kind of item this is. For notifications, this is always storage#notification.", + "default": "storage#serviceAccount" + } + } + }, + "TestIamPermissionsResponse": { + "id": "TestIamPermissionsResponse", + "type": "object", + "description": "A storage.(buckets|objects).testIamPermissions response.", + "properties": { + "kind": { + "type": "string", + "description": "The kind of item this is.", + "default": "storage#testIamPermissionsResponse" + }, + "permissions": { + "type": "array", + "description": "The permissions held by the caller. Permissions are always of the format storage.resource.capability, where resource is one of buckets or objects. The supported permissions are as follows: \n- storage.buckets.delete — Delete bucket. \n- storage.buckets.get — Read bucket metadata. \n- storage.buckets.getIamPolicy — Read bucket IAM policy. \n- storage.buckets.create — Create bucket. \n- storage.buckets.list — List buckets. \n- storage.buckets.setIamPolicy — Update bucket IAM policy. \n- storage.buckets.update — Update bucket metadata. \n- storage.objects.delete — Delete object. \n- storage.objects.get — Read object data and metadata. \n- storage.objects.getIamPolicy — Read object IAM policy. \n- storage.objects.create — Create object. \n- storage.objects.list — List objects. \n- storage.objects.setIamPolicy — Update object IAM policy. \n- storage.objects.update — Update object metadata.", + "items": { + "type": "string" } - }, - "notifications": { - "methods": { - "delete": { - "id": "storage.notifications.delete", - "path": "b/{bucket}/notificationConfigs/{notification}", - "httpMethod": "DELETE", - "description": "Permanently deletes a notification subscription.", - "parameters": { - "bucket": { - "type": "string", - "description": "The parent bucket of the notification.", - "required": true, - "location": "path" - }, - "notification": { - "type": "string", - "description": "ID of the notification to delete.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "notification" - ], - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "get": { - "id": "storage.notifications.get", - "path": "b/{bucket}/notificationConfigs/{notification}", - "httpMethod": "GET", - "description": "View a notification configuration.", - "parameters": { - "bucket": { - "type": "string", - "description": "The parent bucket of the notification.", - "required": true, - "location": "path" - }, - "notification": { - "type": "string", - "description": "Notification ID", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "notification" - ], - "response": { - "$ref": "Notification" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "insert": { - "id": "storage.notifications.insert", - "path": "b/{bucket}/notificationConfigs", - "httpMethod": "POST", - "description": "Creates a notification subscription for a given bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "The parent bucket of the notification.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "Notification" - }, - "response": { - "$ref": "Notification" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "list": { - "id": "storage.notifications.list", - "path": "b/{bucket}/notificationConfigs", - "httpMethod": "GET", - "description": "Retrieves a list of notification subscriptions for a given bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a Google Cloud Storage bucket.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "response": { - "$ref": "Notifications" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] + } + } + } + }, + "resources": { + "bucketAccessControls": { + "methods": { + "delete": { + "id": "storage.bucketAccessControls.delete", + "path": "b/{bucket}/acl/{entity}", + "httpMethod": "DELETE", + "description": "Permanently deletes the ACL entry for the specified entity on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "get": { + "id": "storage.bucketAccessControls.get", + "path": "b/{bucket}/acl/{entity}", + "httpMethod": "GET", + "description": "Returns the ACL entry for the specified entity on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "response": { + "$ref": "BucketAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "insert": { + "id": "storage.bucketAccessControls.insert", + "path": "b/{bucket}/acl", + "httpMethod": "POST", + "description": "Creates a new ACL entry on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "BucketAccessControl" + }, + "response": { + "$ref": "BucketAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "list": { + "id": "storage.bucketAccessControls.list", + "path": "b/{bucket}/acl", + "httpMethod": "GET", + "description": "Retrieves ACL entries on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "response": { + "$ref": "BucketAccessControls" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "patch": { + "id": "storage.bucketAccessControls.patch", + "path": "b/{bucket}/acl/{entity}", + "httpMethod": "PATCH", + "description": "Patches an ACL entry on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "request": { + "$ref": "BucketAccessControl" + }, + "response": { + "$ref": "BucketAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "update": { + "id": "storage.bucketAccessControls.update", + "path": "b/{bucket}/acl/{entity}", + "httpMethod": "PUT", + "description": "Updates an ACL entry on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "request": { + "$ref": "BucketAccessControl" + }, + "response": { + "$ref": "BucketAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + } + } + }, + "buckets": { + "methods": { + "delete": { + "id": "storage.buckets.delete", + "path": "b/{bucket}", + "httpMethod": "DELETE", + "description": "Permanently deletes an empty bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "If set, only deletes the bucket if its metageneration matches this value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "If set, only deletes the bucket if its metageneration does not match this value.", + "format": "int64", + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "get": { + "id": "storage.buckets.get", + "path": "b/{bucket}", + "httpMethod": "GET", + "description": "Returns metadata for the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit owner, acl and defaultObjectAcl properties." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "response": { + "$ref": "Bucket" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "getIamPolicy": { + "id": "storage.buckets.getIamPolicy", + "path": "b/{bucket}/iam", + "httpMethod": "GET", + "description": "Returns an IAM policy for the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "optionsRequestedPolicyVersion": { + "type": "integer", + "description": "The IAM policy format version to be returned. If the optionsRequestedPolicyVersion is for an older version that doesn't support part of the requested IAM policy, the request fails.", + "format": "int32", + "minimum": "1", + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "insert": { + "id": "storage.buckets.insert", + "path": "b", + "httpMethod": "POST", + "description": "Creates a new bucket.", + "parameters": { + "predefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to this bucket.", + "enum": [ + "authenticatedRead", + "private", + "projectPrivate", + "publicRead", + "publicReadWrite" + ], + "enumDescriptions": [ + "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", + "Project team owners get OWNER access.", + "Project team members get access according to their roles.", + "Project team owners get OWNER access, and allUsers get READER access.", + "Project team owners get OWNER access, and allUsers get WRITER access." + ], + "location": "query" + }, + "predefinedDefaultObjectAcl": { + "type": "string", + "description": "Apply a predefined set of default object access controls to this bucket.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "project": { + "type": "string", + "description": "A valid API project identifier.", + "required": true, + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl, unless the bucket resource specifies acl or defaultObjectAcl properties, when it defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit owner, acl and defaultObjectAcl properties." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "project" + ], + "request": { + "$ref": "Bucket" + }, + "response": { + "$ref": "Bucket" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "list": { + "id": "storage.buckets.list", + "path": "b", + "httpMethod": "GET", + "description": "Retrieves a list of buckets for a given project.", + "parameters": { + "maxResults": { + "type": "integer", + "description": "Maximum number of buckets to return in a single response. The service will use this parameter or 1,000 items, whichever is smaller.", + "default": "1000", + "format": "uint32", + "minimum": "0", + "location": "query" + }, + "pageToken": { + "type": "string", + "description": "A previously-returned page token representing part of the larger set of results to view.", + "location": "query" + }, + "prefix": { + "type": "string", + "description": "Filter results to buckets whose names begin with this prefix.", + "location": "query" + }, + "project": { + "type": "string", + "description": "A valid API project identifier.", + "required": true, + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit owner, acl and defaultObjectAcl properties." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "project" + ], + "response": { + "$ref": "Buckets" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "lockRetentionPolicy": { + "id": "storage.buckets.lockRetentionPolicy", + "path": "b/{bucket}/lockRetentionPolicy", + "httpMethod": "POST", + "description": "Locks retention policy on a bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether bucket's current metageneration matches the given value.", + "required": true, + "format": "int64", + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "ifMetagenerationMatch" + ], + "response": { + "$ref": "Bucket" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "patch": { + "id": "storage.buckets.patch", + "path": "b/{bucket}", + "httpMethod": "PATCH", + "description": "Patches a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "predefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to this bucket.", + "enum": [ + "authenticatedRead", + "private", + "projectPrivate", + "publicRead", + "publicReadWrite" + ], + "enumDescriptions": [ + "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", + "Project team owners get OWNER access.", + "Project team members get access according to their roles.", + "Project team owners get OWNER access, and allUsers get READER access.", + "Project team owners get OWNER access, and allUsers get WRITER access." + ], + "location": "query" + }, + "predefinedDefaultObjectAcl": { + "type": "string", + "description": "Apply a predefined set of default object access controls to this bucket.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit owner, acl and defaultObjectAcl properties." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "Bucket" + }, + "response": { + "$ref": "Bucket" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "setIamPolicy": { + "id": "storage.buckets.setIamPolicy", + "path": "b/{bucket}/iam", + "httpMethod": "PUT", + "description": "Updates an IAM policy for the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "Policy" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "testIamPermissions": { + "id": "storage.buckets.testIamPermissions", + "path": "b/{bucket}/iam/testPermissions", + "httpMethod": "GET", + "description": "Tests a set of permissions on the given bucket to see which, if any, are held by the caller.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "permissions": { + "type": "string", + "description": "Permissions to test.", + "required": true, + "repeated": true, + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "permissions" + ], + "response": { + "$ref": "TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "update": { + "id": "storage.buckets.update", + "path": "b/{bucket}", + "httpMethod": "PUT", + "description": "Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "predefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to this bucket.", + "enum": [ + "authenticatedRead", + "private", + "projectPrivate", + "publicRead", + "publicReadWrite" + ], + "enumDescriptions": [ + "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", + "Project team owners get OWNER access.", + "Project team members get access according to their roles.", + "Project team owners get OWNER access, and allUsers get READER access.", + "Project team owners get OWNER access, and allUsers get WRITER access." + ], + "location": "query" + }, + "predefinedDefaultObjectAcl": { + "type": "string", + "description": "Apply a predefined set of default object access controls to this bucket.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit owner, acl and defaultObjectAcl properties." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "Bucket" + }, + "response": { + "$ref": "Bucket" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + } + } + }, + "channels": { + "methods": { + "stop": { + "id": "storage.channels.stop", + "path": "channels/stop", + "httpMethod": "POST", + "description": "Stop watching resources through this channel", + "request": { + "$ref": "Channel", + "parameterName": "resource" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + } + } + }, + "defaultObjectAccessControls": { + "methods": { + "delete": { + "id": "storage.defaultObjectAccessControls.delete", + "path": "b/{bucket}/defaultObjectAcl/{entity}", + "httpMethod": "DELETE", + "description": "Permanently deletes the default object ACL entry for the specified entity on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "get": { + "id": "storage.defaultObjectAccessControls.get", + "path": "b/{bucket}/defaultObjectAcl/{entity}", + "httpMethod": "GET", + "description": "Returns the default object ACL entry for the specified entity on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "insert": { + "id": "storage.defaultObjectAccessControls.insert", + "path": "b/{bucket}/defaultObjectAcl", + "httpMethod": "POST", + "description": "Creates a new default object ACL entry on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "ObjectAccessControl" + }, + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "list": { + "id": "storage.defaultObjectAccessControls.list", + "path": "b/{bucket}/defaultObjectAcl", + "httpMethod": "GET", + "description": "Retrieves default object ACL entries on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "If present, only return default ACL listing if the bucket's current metageneration matches this value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "If present, only return default ACL listing if the bucket's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "response": { + "$ref": "ObjectAccessControls" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "patch": { + "id": "storage.defaultObjectAccessControls.patch", + "path": "b/{bucket}/defaultObjectAcl/{entity}", + "httpMethod": "PATCH", + "description": "Patches a default object ACL entry on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "request": { + "$ref": "ObjectAccessControl" + }, + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "update": { + "id": "storage.defaultObjectAccessControls.update", + "path": "b/{bucket}/defaultObjectAcl/{entity}", + "httpMethod": "PUT", + "description": "Updates a default object ACL entry on the specified bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "entity" + ], + "request": { + "$ref": "ObjectAccessControl" + }, + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + } + } + }, + "notifications": { + "methods": { + "delete": { + "id": "storage.notifications.delete", + "path": "b/{bucket}/notificationConfigs/{notification}", + "httpMethod": "DELETE", + "description": "Permanently deletes a notification subscription.", + "parameters": { + "bucket": { + "type": "string", + "description": "The parent bucket of the notification.", + "required": true, + "location": "path" + }, + "notification": { + "type": "string", + "description": "ID of the notification to delete.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "notification" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "get": { + "id": "storage.notifications.get", + "path": "b/{bucket}/notificationConfigs/{notification}", + "httpMethod": "GET", + "description": "View a notification configuration.", + "parameters": { + "bucket": { + "type": "string", + "description": "The parent bucket of the notification.", + "required": true, + "location": "path" + }, + "notification": { + "type": "string", + "description": "Notification ID", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "notification" + ], + "response": { + "$ref": "Notification" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "insert": { + "id": "storage.notifications.insert", + "path": "b/{bucket}/notificationConfigs", + "httpMethod": "POST", + "description": "Creates a notification subscription for a given bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "The parent bucket of the notification.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "Notification" + }, + "response": { + "$ref": "Notification" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "list": { + "id": "storage.notifications.list", + "path": "b/{bucket}/notificationConfigs", + "httpMethod": "GET", + "description": "Retrieves a list of notification subscriptions for a given bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a Google Cloud Storage bucket.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "response": { + "$ref": "Notifications" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + } + } + }, + "objectAccessControls": { + "methods": { + "delete": { + "id": "storage.objectAccessControls.delete", + "path": "b/{bucket}/o/{object}/acl/{entity}", + "httpMethod": "DELETE", + "description": "Permanently deletes the ACL entry for the specified entity on the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object", + "entity" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "get": { + "id": "storage.objectAccessControls.get", + "path": "b/{bucket}/o/{object}/acl/{entity}", + "httpMethod": "GET", + "description": "Returns the ACL entry for the specified entity on the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object", + "entity" + ], + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "insert": { + "id": "storage.objectAccessControls.insert", + "path": "b/{bucket}/o/{object}/acl", + "httpMethod": "POST", + "description": "Creates a new ACL entry on the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "request": { + "$ref": "ObjectAccessControl" + }, + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "list": { + "id": "storage.objectAccessControls.list", + "path": "b/{bucket}/o/{object}/acl", + "httpMethod": "GET", + "description": "Retrieves ACL entries on the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "response": { + "$ref": "ObjectAccessControls" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "patch": { + "id": "storage.objectAccessControls.patch", + "path": "b/{bucket}/o/{object}/acl/{entity}", + "httpMethod": "PATCH", + "description": "Patches an ACL entry on the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object", + "entity" + ], + "request": { + "$ref": "ObjectAccessControl" + }, + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "update": { + "id": "storage.objectAccessControls.update", + "path": "b/{bucket}/o/{object}/acl/{entity}", + "httpMethod": "PUT", + "description": "Updates an ACL entry on the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of a bucket.", + "required": true, + "location": "path" + }, + "entity": { + "type": "string", + "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object", + "entity" + ], + "request": { + "$ref": "ObjectAccessControl" + }, + "response": { + "$ref": "ObjectAccessControl" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + } + } + }, + "objects": { + "methods": { + "compose": { + "id": "storage.objects.compose", + "path": "b/{destinationBucket}/o/{destinationObject}/compose", + "httpMethod": "POST", + "description": "Concatenates a list of existing objects into a new object in the same bucket.", + "parameters": { + "destinationBucket": { + "type": "string", + "description": "Name of the bucket containing the source objects. The destination object is stored in this bucket.", + "required": true, + "location": "path" + }, + "destinationObject": { + "type": "string", + "description": "Name of the new object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "destinationPredefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to the destination object.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "kmsKeyName": { + "type": "string", + "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "destinationBucket", + "destinationObject" + ], + "request": { + "$ref": "ComposeRequest" + }, + "response": { + "$ref": "Object" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "copy": { + "id": "storage.objects.copy", + "path": "b/{sourceBucket}/o/{sourceObject}/copyTo/b/{destinationBucket}/o/{destinationObject}", + "httpMethod": "POST", + "description": "Copies a source object to a destination object. Optionally overrides metadata.", + "parameters": { + "destinationBucket": { + "type": "string", + "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "destinationObject": { + "type": "string", + "description": "Name of the new object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any.", + "required": true, + "location": "path" + }, + "destinationPredefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to the destination object.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the destination object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the destination object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the destination object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the destination object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current generation matches the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current generation does not match the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "sourceBucket": { + "type": "string", + "description": "Name of the bucket in which to find the source object.", + "required": true, + "location": "path" + }, + "sourceGeneration": { + "type": "string", + "description": "If present, selects a specific revision of the source object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "sourceObject": { + "type": "string", + "description": "Name of the source object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "sourceBucket", + "sourceObject", + "destinationBucket", + "destinationObject" + ], + "request": { + "$ref": "Object" + }, + "response": { + "$ref": "Object" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "delete": { + "id": "storage.objects.delete", + "path": "b/{bucket}/o/{object}", + "httpMethod": "DELETE", + "description": "Deletes an object and its metadata. Deletions are permanent if versioning is not enabled for the bucket, or if the generation parameter is used.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, permanently deletes a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "get": { + "id": "storage.objects.get", + "path": "b/{bucket}/o/{object}", + "httpMethod": "GET", + "description": "Retrieves an object or its metadata.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "response": { + "$ref": "Object" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ], + "supportsMediaDownload": true, + "useMediaDownloadService": true + }, + "getIamPolicy": { + "id": "storage.objects.getIamPolicy", + "path": "b/{bucket}/o/{object}/iam", + "httpMethod": "GET", + "description": "Returns an IAM policy for the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "insert": { + "id": "storage.objects.insert", + "path": "b/{bucket}/o", + "httpMethod": "POST", + "description": "Stores a new object and metadata.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.", + "required": true, + "location": "path" + }, + "contentEncoding": { + "type": "string", + "description": "If set, sets the contentEncoding property of the final object to this value. Setting this parameter is equivalent to setting the contentEncoding metadata property. This can be useful when uploading an object with uploadType=media to indicate the encoding of the content being uploaded.", + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "kmsKeyName": { + "type": "string", + "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", + "location": "query" + }, + "name": { + "type": "string", + "description": "Name of the object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "location": "query" + }, + "predefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to this object.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "Object" + }, + "response": { + "$ref": "Object" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ], + "supportsMediaUpload": true, + "mediaUpload": { + "accept": [ + "*/*" + ], + "protocols": { + "simple": { + "multipart": true, + "path": "/upload/storage/v1/b/{bucket}/o" + }, + "resumable": { + "multipart": true, + "path": "/resumable/upload/storage/v1/b/{bucket}/o" } + } } - }, - "objectAccessControls": { + }, + "list": { + "id": "storage.objects.list", + "path": "b/{bucket}/o", + "httpMethod": "GET", + "description": "Retrieves a list of objects matching the criteria.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which to look for objects.", + "required": true, + "location": "path" + }, + "delimiter": { + "type": "string", + "description": "Returns results in a directory-like mode. items will contain only objects whose names, aside from the prefix, do not contain delimiter. Objects whose names, aside from the prefix, contain delimiter will have their name, truncated after the delimiter, returned in prefixes. Duplicate prefixes are omitted.", + "location": "query" + }, + "includeTrailingDelimiter": { + "type": "boolean", + "description": "If true, objects that end in exactly one instance of delimiter will have their metadata included in items in addition to prefixes.", + "location": "query" + }, + "maxResults": { + "type": "integer", + "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", + "default": "1000", + "format": "uint32", + "minimum": "0", + "location": "query" + }, + "pageToken": { + "type": "string", + "description": "A previously-returned page token representing part of the larger set of results to view.", + "location": "query" + }, + "prefix": { + "type": "string", + "description": "Filter results to objects whose names begin with this prefix.", + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + }, + "versions": { + "type": "boolean", + "description": "If true, lists all versions of an object as distinct results. The default is false. For more information, see Object Versioning.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "response": { + "$ref": "Objects" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ], + "supportsSubscription": true + }, + "patch": { + "id": "storage.objects.patch", + "path": "b/{bucket}/o/{object}", + "httpMethod": "PATCH", + "description": "Patches an object's metadata.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "predefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to this object.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request, for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "request": { + "$ref": "Object" + }, + "response": { + "$ref": "Object" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "rewrite": { + "id": "storage.objects.rewrite", + "path": "b/{sourceBucket}/o/{sourceObject}/rewriteTo/b/{destinationBucket}/o/{destinationObject}", + "httpMethod": "POST", + "description": "Rewrites a source object to a destination object. Optionally overrides metadata.", + "parameters": { + "destinationBucket": { + "type": "string", + "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.", + "required": true, + "location": "path" + }, + "destinationKmsKeyName": { + "type": "string", + "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", + "location": "query" + }, + "destinationObject": { + "type": "string", + "description": "Name of the new object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "destinationPredefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to the destination object.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the destination object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the destination object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current generation matches the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current generation does not match the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifSourceMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "maxBytesRewrittenPerCall": { + "type": "string", + "description": "The maximum number of bytes that will be rewritten per rewrite request. Most callers shouldn't need to specify this parameter - it is primarily in place to support testing. If specified the value must be an integral multiple of 1 MiB (1048576). Also, this only applies to requests where the source and destination span locations and/or storage classes. Finally, this value must not change across rewrite calls else you'll get an error that the rewriteToken is invalid.", + "format": "int64", + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "rewriteToken": { + "type": "string", + "description": "Include this field (from the previous rewrite response) on each rewrite request after the first one, until the rewrite response 'done' flag is true. Calls that provide a rewriteToken can omit all other request fields, but if included those fields must match the values provided in the first rewrite request.", + "location": "query" + }, + "sourceBucket": { + "type": "string", + "description": "Name of the bucket in which to find the source object.", + "required": true, + "location": "path" + }, + "sourceGeneration": { + "type": "string", + "description": "If present, selects a specific revision of the source object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "sourceObject": { + "type": "string", + "description": "Name of the source object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "sourceBucket", + "sourceObject", + "destinationBucket", + "destinationObject" + ], + "request": { + "$ref": "Object" + }, + "response": { + "$ref": "RewriteResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "setIamPolicy": { + "id": "storage.objects.setIamPolicy", + "path": "b/{bucket}/o/{object}/iam", + "httpMethod": "PUT", + "description": "Updates an IAM policy for the specified object.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "request": { + "$ref": "Policy" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "testIamPermissions": { + "id": "storage.objects.testIamPermissions", + "path": "b/{bucket}/o/{object}/iam/testPermissions", + "httpMethod": "GET", + "description": "Tests a set of permissions on the given object to see which, if any, are held by the caller.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "permissions": { + "type": "string", + "description": "Permissions to test.", + "required": true, + "repeated": true, + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object", + "permissions" + ], + "response": { + "$ref": "TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "update": { + "id": "storage.objects.update", + "path": "b/{bucket}/o/{object}", + "httpMethod": "PUT", + "description": "Updates an object's metadata.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which the object resides.", + "required": true, + "location": "path" + }, + "generation": { + "type": "string", + "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", + "format": "int64", + "location": "query" + }, + "ifGenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", + "format": "int64", + "location": "query" + }, + "ifGenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", + "format": "int64", + "location": "query" + }, + "ifMetagenerationNotMatch": { + "type": "string", + "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", + "format": "int64", + "location": "query" + }, + "object": { + "type": "string", + "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", + "required": true, + "location": "path" + }, + "predefinedAcl": { + "type": "string", + "description": "Apply a predefined set of access controls to this object.", + "enum": [ + "authenticatedRead", + "bucketOwnerFullControl", + "bucketOwnerRead", + "private", + "projectPrivate", + "publicRead" + ], + "enumDescriptions": [ + "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", + "Object owner gets OWNER access, and project team owners get OWNER access.", + "Object owner gets OWNER access, and project team owners get READER access.", + "Object owner gets OWNER access.", + "Object owner gets OWNER access, and project team members get access according to their roles.", + "Object owner gets OWNER access, and allUsers get READER access." + ], + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to full.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket", + "object" + ], + "request": { + "$ref": "Object" + }, + "response": { + "$ref": "Object" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "watchAll": { + "id": "storage.objects.watchAll", + "path": "b/{bucket}/o/watch", + "httpMethod": "POST", + "description": "Watch for changes on all objects in a bucket.", + "parameters": { + "bucket": { + "type": "string", + "description": "Name of the bucket in which to look for objects.", + "required": true, + "location": "path" + }, + "delimiter": { + "type": "string", + "description": "Returns results in a directory-like mode. items will contain only objects whose names, aside from the prefix, do not contain delimiter. Objects whose names, aside from the prefix, contain delimiter will have their name, truncated after the delimiter, returned in prefixes. Duplicate prefixes are omitted.", + "location": "query" + }, + "includeTrailingDelimiter": { + "type": "boolean", + "description": "If true, objects that end in exactly one instance of delimiter will have their metadata included in items in addition to prefixes.", + "location": "query" + }, + "maxResults": { + "type": "integer", + "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", + "default": "1000", + "format": "uint32", + "minimum": "0", + "location": "query" + }, + "pageToken": { + "type": "string", + "description": "A previously-returned page token representing part of the larger set of results to view.", + "location": "query" + }, + "prefix": { + "type": "string", + "description": "Filter results to objects whose names begin with this prefix.", + "location": "query" + }, + "projection": { + "type": "string", + "description": "Set of properties to return. Defaults to noAcl.", + "enum": [ + "full", + "noAcl" + ], + "enumDescriptions": [ + "Include all properties.", + "Omit the owner, acl property." + ], + "location": "query" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request. Required for Requester Pays buckets.", + "location": "query" + }, + "versions": { + "type": "boolean", + "description": "If true, lists all versions of an object as distinct results. The default is false. For more information, see Object Versioning.", + "location": "query" + } + }, + "parameterOrder": [ + "bucket" + ], + "request": { + "$ref": "Channel", + "parameterName": "resource" + }, + "response": { + "$ref": "Channel" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ], + "supportsSubscription": true + } + } + }, + "projects": { + "resources": { + "hmacKeys": { "methods": { - "delete": { - "id": "storage.objectAccessControls.delete", - "path": "b/{bucket}/o/{object}/acl/{entity}", - "httpMethod": "DELETE", - "description": "Permanently deletes the ACL entry for the specified entity on the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object", - "entity" - ], - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "get": { - "id": "storage.objectAccessControls.get", - "path": "b/{bucket}/o/{object}/acl/{entity}", - "httpMethod": "GET", - "description": "Returns the ACL entry for the specified entity on the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object", - "entity" - ], - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "insert": { - "id": "storage.objectAccessControls.insert", - "path": "b/{bucket}/o/{object}/acl", - "httpMethod": "POST", - "description": "Creates a new ACL entry on the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "request": { - "$ref": "ObjectAccessControl" - }, - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "list": { - "id": "storage.objectAccessControls.list", - "path": "b/{bucket}/o/{object}/acl", - "httpMethod": "GET", - "description": "Retrieves ACL entries on the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "response": { - "$ref": "ObjectAccessControls" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "patch": { - "id": "storage.objectAccessControls.patch", - "path": "b/{bucket}/o/{object}/acl/{entity}", - "httpMethod": "PATCH", - "description": "Updates an ACL entry on the specified object. This method supports patch semantics.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object", - "entity" - ], - "request": { - "$ref": "ObjectAccessControl" - }, - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "update": { - "id": "storage.objectAccessControls.update", - "path": "b/{bucket}/o/{object}/acl/{entity}", - "httpMethod": "PUT", - "description": "Updates an ACL entry on the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of a bucket.", - "required": true, - "location": "path" - }, - "entity": { - "type": "string", - "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object", - "entity" - ], - "request": { - "$ref": "ObjectAccessControl" - }, - "response": { - "$ref": "ObjectAccessControl" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - } + "create": { + "id": "storage.projects.hmacKeys.create", + "path": "projects/{projectId}/hmacKeys", + "httpMethod": "POST", + "description": "Creates a new HMAC key for the specified service account.", + "parameters": { + "projectId": { + "type": "string", + "description": "Project ID owning the service account.", + "required": true, + "location": "path" + }, + "serviceAccountEmail": { + "type": "string", + "description": "Email address of the service account.", + "required": true, + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "projectId", + "serviceAccountEmail" + ], + "response": { + "$ref": "HmacKey" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + }, + "delete": { + "id": "storage.projects.hmacKeys.delete", + "path": "projects/{projectId}/hmacKeys/{accessId}", + "httpMethod": "DELETE", + "description": "Deletes an HMAC key.", + "parameters": { + "accessId": { + "type": "string", + "description": "Name of the HMAC key to be deleted.", + "required": true, + "location": "path" + }, + "projectId": { + "type": "string", + "description": "Project ID owning the requested key", + "required": true, + "location": "path" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "projectId", + "accessId" + ], + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + }, + "get": { + "id": "storage.projects.hmacKeys.get", + "path": "projects/{projectId}/hmacKeys/{accessId}", + "httpMethod": "GET", + "description": "Retrieves an HMAC key's metadata", + "parameters": { + "accessId": { + "type": "string", + "description": "Name of the HMAC key.", + "required": true, + "location": "path" + }, + "projectId": { + "type": "string", + "description": "Project ID owning the service account of the requested key.", + "required": true, + "location": "path" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "projectId", + "accessId" + ], + "response": { + "$ref": "HmacKeyMetadata" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only" + ] + }, + "list": { + "id": "storage.projects.hmacKeys.list", + "path": "projects/{projectId}/hmacKeys", + "httpMethod": "GET", + "description": "Retrieves a list of HMAC keys matching the criteria.", + "parameters": { + "maxResults": { + "type": "integer", + "description": "Maximum number of items to return in a single page of responses. The service uses this parameter or 250 items, whichever is smaller. The max number of items per page will also be limited by the number of distinct service accounts in the response. If the number of service accounts in a single response is too high, the page will truncated and a next page token will be returned.", + "default": "250", + "format": "uint32", + "minimum": "0", + "location": "query" + }, + "pageToken": { + "type": "string", + "description": "A previously-returned page token representing part of the larger set of results to view.", + "location": "query" + }, + "projectId": { + "type": "string", + "description": "Name of the project in which to look for HMAC keys.", + "required": true, + "location": "path" + }, + "serviceAccountEmail": { + "type": "string", + "description": "If present, only keys for the given service account are returned.", + "location": "query" + }, + "showDeletedKeys": { + "type": "boolean", + "description": "Whether or not to show keys in the DELETED state.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "projectId" + ], + "response": { + "$ref": "HmacKeysMetadata" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only" + ] + }, + "update": { + "id": "storage.projects.hmacKeys.update", + "path": "projects/{projectId}/hmacKeys/{accessId}", + "httpMethod": "PUT", + "description": "Updates the state of an HMAC key. See the HMAC Key resource descriptor for valid states.", + "parameters": { + "accessId": { + "type": "string", + "description": "Name of the HMAC key being updated.", + "required": true, + "location": "path" + }, + "projectId": { + "type": "string", + "description": "Project ID owning the service account of the updated key.", + "required": true, + "location": "path" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "projectId", + "accessId" + ], + "request": { + "$ref": "HmacKeyMetadata" + }, + "response": { + "$ref": "HmacKeyMetadata" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/devstorage.full_control" + ] + } } - }, - "objects": { + }, + "serviceAccount": { "methods": { - "compose": { - "id": "storage.objects.compose", - "path": "b/{destinationBucket}/o/{destinationObject}/compose", - "httpMethod": "POST", - "description": "Concatenates a list of existing objects into a new object in the same bucket.", - "parameters": { - "destinationBucket": { - "type": "string", - "description": "Name of the bucket in which to store the new object.", - "required": true, - "location": "path" - }, - "destinationObject": { - "type": "string", - "description": "Name of the new object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "destinationPredefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to the destination object.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "kmsKeyName": { - "type": "string", - "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "destinationBucket", - "destinationObject" - ], - "request": { - "$ref": "ComposeRequest" - }, - "response": { - "$ref": "Object" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "copy": { - "id": "storage.objects.copy", - "path": "b/{sourceBucket}/o/{sourceObject}/copyTo/b/{destinationBucket}/o/{destinationObject}", - "httpMethod": "POST", - "description": "Copies a source object to a destination object. Optionally overrides metadata.", - "parameters": { - "destinationBucket": { - "type": "string", - "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "destinationObject": { - "type": "string", - "description": "Name of the new object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any.", - "required": true, - "location": "path" - }, - "destinationPredefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to the destination object.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the destination object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the destination object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the destination object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the destination object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current generation matches the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current generation does not match the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "sourceBucket": { - "type": "string", - "description": "Name of the bucket in which to find the source object.", - "required": true, - "location": "path" - }, - "sourceGeneration": { - "type": "string", - "description": "If present, selects a specific revision of the source object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "sourceObject": { - "type": "string", - "description": "Name of the source object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "sourceBucket", - "sourceObject", - "destinationBucket", - "destinationObject" - ], - "request": { - "$ref": "Object" - }, - "response": { - "$ref": "Object" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "delete": { - "id": "storage.objects.delete", - "path": "b/{bucket}/o/{object}", - "httpMethod": "DELETE", - "description": "Deletes an object and its metadata. Deletions are permanent if versioning is not enabled for the bucket, or if the generation parameter is used.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, permanently deletes a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "get": { - "id": "storage.objects.get", - "path": "b/{bucket}/o/{object}", - "httpMethod": "GET", - "description": "Retrieves an object or its metadata.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "response": { - "$ref": "Object" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ], - "supportsMediaDownload": true, - "useMediaDownloadService": true - }, - "getIamPolicy": { - "id": "storage.objects.getIamPolicy", - "path": "b/{bucket}/o/{object}/iam", - "httpMethod": "GET", - "description": "Returns an IAM policy for the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "response": { - "$ref": "Policy" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "insert": { - "id": "storage.objects.insert", - "path": "b/{bucket}/o", - "httpMethod": "POST", - "description": "Stores a new object and metadata.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.", - "required": true, - "location": "path" - }, - "contentEncoding": { - "type": "string", - "description": "If set, sets the contentEncoding property of the final object to this value. Setting this parameter is equivalent to setting the contentEncoding metadata property. This can be useful when uploading an object with uploadType=media to indicate the encoding of the content being uploaded.", - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "kmsKeyName": { - "type": "string", - "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any. Limited availability; usable only by enabled projects.", - "location": "query" - }, - "name": { - "type": "string", - "description": "Name of the object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "location": "query" - }, - "predefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to this object.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "Object" - }, - "response": { - "$ref": "Object" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ], - "supportsMediaUpload": true, - "mediaUpload": { - "accept": [ - "*/*" - ], - "protocols": { - "simple": { - "multipart": true, - "path": "/upload/storage/v1/b/{bucket}/o" - }, - "resumable": { - "multipart": true, - "path": "/resumable/upload/storage/v1/b/{bucket}/o" - } - } - } - }, - "list": { - "id": "storage.objects.list", - "path": "b/{bucket}/o", - "httpMethod": "GET", - "description": "Retrieves a list of objects matching the criteria.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which to look for objects.", - "required": true, - "location": "path" - }, - "delimiter": { - "type": "string", - "description": "Returns results in a directory-like mode. items will contain only objects whose names, aside from the prefix, do not contain delimiter. Objects whose names, aside from the prefix, contain delimiter will have their name, truncated after the delimiter, returned in prefixes. Duplicate prefixes are omitted.", - "location": "query" - }, - "maxResults": { - "type": "integer", - "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", - "default": "1000", - "format": "uint32", - "minimum": "0", - "location": "query" - }, - "pageToken": { - "type": "string", - "description": "A previously-returned page token representing part of the larger set of results to view.", - "location": "query" - }, - "prefix": { - "type": "string", - "description": "Filter results to objects whose names begin with this prefix.", - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - }, - "versions": { - "type": "boolean", - "description": "If true, lists all versions of an object as distinct results. The default is false. For more information, see Object Versioning.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "response": { - "$ref": "Objects" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ], - "supportsSubscription": true - }, - "patch": { - "id": "storage.objects.patch", - "path": "b/{bucket}/o/{object}", - "httpMethod": "PATCH", - "description": "Patches an object's metadata.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "predefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to this object.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request, for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "request": { - "$ref": "Object" - }, - "response": { - "$ref": "Object" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "rewrite": { - "id": "storage.objects.rewrite", - "path": "b/{sourceBucket}/o/{sourceObject}/rewriteTo/b/{destinationBucket}/o/{destinationObject}", - "httpMethod": "POST", - "description": "Rewrites a source object to a destination object. Optionally overrides metadata.", - "parameters": { - "destinationBucket": { - "type": "string", - "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.", - "required": true, - "location": "path" - }, - "destinationKmsKeyName": { - "type": "string", - "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", - "location": "query" - }, - "destinationObject": { - "type": "string", - "description": "Name of the new object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "destinationPredefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to the destination object.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the destination object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the destination object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current generation matches the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current generation does not match the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifSourceMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "maxBytesRewrittenPerCall": { - "type": "string", - "description": "The maximum number of bytes that will be rewritten per rewrite request. Most callers shouldn't need to specify this parameter - it is primarily in place to support testing. If specified the value must be an integral multiple of 1 MiB (1048576). Also, this only applies to requests where the source and destination span locations and/or storage classes. Finally, this value must not change across rewrite calls else you'll get an error that the rewriteToken is invalid.", - "format": "int64", - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "rewriteToken": { - "type": "string", - "description": "Include this field (from the previous rewrite response) on each rewrite request after the first one, until the rewrite response 'done' flag is true. Calls that provide a rewriteToken can omit all other request fields, but if included those fields must match the values provided in the first rewrite request.", - "location": "query" - }, - "sourceBucket": { - "type": "string", - "description": "Name of the bucket in which to find the source object.", - "required": true, - "location": "path" - }, - "sourceGeneration": { - "type": "string", - "description": "If present, selects a specific revision of the source object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "sourceObject": { - "type": "string", - "description": "Name of the source object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "sourceBucket", - "sourceObject", - "destinationBucket", - "destinationObject" - ], - "request": { - "$ref": "Object" - }, - "response": { - "$ref": "RewriteResponse" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "setIamPolicy": { - "id": "storage.objects.setIamPolicy", - "path": "b/{bucket}/o/{object}/iam", - "httpMethod": "PUT", - "description": "Updates an IAM policy for the specified object.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "request": { - "$ref": "Policy" - }, - "response": { - "$ref": "Policy" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "testIamPermissions": { - "id": "storage.objects.testIamPermissions", - "path": "b/{bucket}/o/{object}/iam/testPermissions", - "httpMethod": "GET", - "description": "Tests a set of permissions on the given object to see which, if any, are held by the caller.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "permissions": { - "type": "string", - "description": "Permissions to test.", - "required": true, - "repeated": true, - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object", - "permissions" - ], - "response": { - "$ref": "TestIamPermissionsResponse" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - }, - "update": { - "id": "storage.objects.update", - "path": "b/{bucket}/o/{object}", - "httpMethod": "PUT", - "description": "Updates an object's metadata.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which the object resides.", - "required": true, - "location": "path" - }, - "generation": { - "type": "string", - "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - "format": "int64", - "location": "query" - }, - "ifGenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - "format": "int64", - "location": "query" - }, - "ifGenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - "format": "int64", - "location": "query" - }, - "ifMetagenerationNotMatch": { - "type": "string", - "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - "format": "int64", - "location": "query" - }, - "object": { - "type": "string", - "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - "required": true, - "location": "path" - }, - "predefinedAcl": { - "type": "string", - "description": "Apply a predefined set of access controls to this object.", - "enum": [ - "authenticatedRead", - "bucketOwnerFullControl", - "bucketOwnerRead", - "private", - "projectPrivate", - "publicRead" - ], - "enumDescriptions": [ - "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - "Object owner gets OWNER access, and project team owners get OWNER access.", - "Object owner gets OWNER access, and project team owners get READER access.", - "Object owner gets OWNER access.", - "Object owner gets OWNER access, and project team members get access according to their roles.", - "Object owner gets OWNER access, and allUsers get READER access." - ], - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to full.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket", - "object" - ], - "request": { - "$ref": "Object" - }, - "response": { - "$ref": "Object" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/devstorage.full_control" - ] - }, - "watchAll": { - "id": "storage.objects.watchAll", - "path": "b/{bucket}/o/watch", - "httpMethod": "POST", - "description": "Watch for changes on all objects in a bucket.", - "parameters": { - "bucket": { - "type": "string", - "description": "Name of the bucket in which to look for objects.", - "required": true, - "location": "path" - }, - "delimiter": { - "type": "string", - "description": "Returns results in a directory-like mode. items will contain only objects whose names, aside from the prefix, do not contain delimiter. Objects whose names, aside from the prefix, contain delimiter will have their name, truncated after the delimiter, returned in prefixes. Duplicate prefixes are omitted.", - "location": "query" - }, - "maxResults": { - "type": "integer", - "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", - "default": "1000", - "format": "uint32", - "minimum": "0", - "location": "query" - }, - "pageToken": { - "type": "string", - "description": "A previously-returned page token representing part of the larger set of results to view.", - "location": "query" - }, - "prefix": { - "type": "string", - "description": "Filter results to objects whose names begin with this prefix.", - "location": "query" - }, - "projection": { - "type": "string", - "description": "Set of properties to return. Defaults to noAcl.", - "enum": [ - "full", - "noAcl" - ], - "enumDescriptions": [ - "Include all properties.", - "Omit the owner, acl property." - ], - "location": "query" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request. Required for Requester Pays buckets.", - "location": "query" - }, - "versions": { - "type": "boolean", - "description": "If true, lists all versions of an object as distinct results. The default is false. For more information, see Object Versioning.", - "location": "query" - } - }, - "parameterOrder": [ - "bucket" - ], - "request": { - "$ref": "Channel", - "parameterName": "resource" - }, - "response": { - "$ref": "Channel" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ], - "supportsSubscription": true - } - } - }, - "projects": { - "resources": { - "serviceAccount": { - "methods": { - "get": { - "id": "storage.projects.serviceAccount.get", - "path": "projects/{projectId}/serviceAccount", - "httpMethod": "GET", - "description": "Get the email address of this project's Google Cloud Storage service account.", - "parameters": { - "projectId": { - "type": "string", - "description": "Project ID", - "required": true, - "location": "path" - }, - "userProject": { - "type": "string", - "description": "The project to be billed for this request.", - "location": "query" - } - }, - "parameterOrder": [ - "projectId" - ], - "response": { - "$ref": "ServiceAccount" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-platform.read-only", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" - ] - } - } - } + "get": { + "id": "storage.projects.serviceAccount.get", + "path": "projects/{projectId}/serviceAccount", + "httpMethod": "GET", + "description": "Get the email address of this project's Google Cloud Storage service account.", + "parameters": { + "projectId": { + "type": "string", + "description": "Project ID", + "required": true, + "location": "path" + }, + "provisionalUserProject": { + "type": "string", + "description": "The project to be billed for this request if the target bucket is requester-pays bucket.", + "location": "query" + }, + "userProject": { + "type": "string", + "description": "The project to be billed for this request.", + "location": "query" + } + }, + "parameterOrder": [ + "projectId" + ], + "response": { + "$ref": "ServiceAccount" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only", + "https://www.googleapis.com/auth/devstorage.full_control", + "https://www.googleapis.com/auth/devstorage.read_only", + "https://www.googleapis.com/auth/devstorage.read_write" + ] + } } + } } + } } -} + } diff --git a/vendor/Gcp/google/cloud-storage/src/CreatedHmacKey.php b/vendor/Gcp/google/cloud-storage/src/CreatedHmacKey.php new file mode 100644 index 00000000..a19c3ece --- /dev/null +++ b/vendor/Gcp/google/cloud-storage/src/CreatedHmacKey.php @@ -0,0 +1,82 @@ +createHmacKey($serviceAccountEmail); + * ``` + */ +class CreatedHmacKey +{ + /** + * @var HmacKey + */ + private $hmacKey; + /** + * @var string + */ + private $secret; + /** + * @param HmacKey $hmacKey The HMAC Key object. + * @param string $secret The HMAC key secret. + */ + public function __construct(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\HmacKey $hmacKey, $secret) + { + $this->hmacKey = $hmacKey; + $this->secret = $secret; + } + /** + * Get the HMAC key object. + * + * Example: + * ``` + * $key = $response->hmacKey(); + * ``` + * + * @return HmacKey + */ + public function hmacKey() + { + return $this->hmacKey; + } + /** + * Get the HMAC key secret. + * + * This value will never be returned from the API after first creation. Make + * sure to record it for later use immediately upon key creation. + * + * Example: + * ``` + * $secret = $response->secret(); + * ``` + * + * @return string + */ + public function secret() + { + return $this->secret; + } +} diff --git a/vendor/Gcp/google/cloud-storage/src/EncryptionTrait.php b/vendor/Gcp/google/cloud-storage/src/EncryptionTrait.php index 3a5669f2..1f183124 100644 --- a/vendor/Gcp/google/cloud-storage/src/EncryptionTrait.php +++ b/vendor/Gcp/google/cloud-storage/src/EncryptionTrait.php @@ -17,7 +17,6 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage; -use InvalidArgumentException; use DeliciousBrains\WP_Offload_Media\Gcp\phpseclib\Crypt\RSA; /** * Trait which provides helper methods for customer-supplied encryption. @@ -85,6 +84,10 @@ private function buildHeaders($key, $keySHA256, $useCopySourceHeaders) /** * Sign a string using a given private key. * + * @deprecated Please use the {@see Google\Auth\SignBlobInterface::signBlob()} + * and implementations for signing strings. + * This method will be removed in a future release. + * * @param string $privateKey The private key to use to sign the data. * @param string $data The data to sign. * @param bool $forceOpenssl If true, OpenSSL will be used regardless of diff --git a/vendor/Gcp/google/cloud-storage/src/HmacKey.php b/vendor/Gcp/google/cloud-storage/src/HmacKey.php new file mode 100644 index 00000000..0b596cb3 --- /dev/null +++ b/vendor/Gcp/google/cloud-storage/src/HmacKey.php @@ -0,0 +1,170 @@ +hmacKey($accessId); + * ``` + */ +class HmacKey +{ + /** + * @var ConnectionInterface + */ + private $connection; + /** + * @var string + */ + private $projectId; + /** + * @var string + */ + private $accessId; + /** + * @var array|null + */ + private $info; + /** + * @param ConnectionInterface $connection A connection to Cloud Storage. + * @param string $projectId The current project ID. + * @param string $accessId The key identifier. + * @param array|null $info The key metadata. + */ + public function __construct(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\Connection\ConnectionInterface $connection, $projectId, $accessId, array $info = []) + { + $this->connection = $connection; + $this->projectId = $projectId; + $this->accessId = $accessId; + $this->info = $info; + } + /** + * Get the HMAC Key Access ID. + * + * Example: + * ``` + * $accessId = $hmacKey->accessId(); + * ``` + * + * @return string + */ + public function accessId() + { + return $this->accessId; + } + /** + * Fetch the key metadata from Cloud Storage. + * + * Example: + * ``` + * $keyMetadata = $hmacKey->reload(); + * ``` + * + * @param array $options { + * Configuration Options + * + * @type string $userProject If set, this is the ID of the project which + * will be billed for the request. **NOTE**: This option is + * currently ignored by Cloud Storage. + * } + * @return array + */ + public function reload(array $options = []) + { + $this->info = $this->connection->getHmacKey(['projectId' => $this->projectId, 'accessId' => $this->accessId] + $options); + return $this->info; + } + /** + * Get the HMAC Key Metadata. + * + * If the metadata is not already available, it will be requested from Cloud + * Storage. + * + * Example: + * ``` + * $keyMetadata = $hmacKey->info(); + * ``` + * + * @param array $options { + * Configuration Options + * + * @type string $userProject If set, this is the ID of the project which + * will be billed for the request. **NOTE**: This option is + * currently ignored by Cloud Storage. + * } + * @return array + */ + public function info(array $options = []) + { + return $this->info ?: $this->reload($options); + } + /** + * Update the HMAC Key state. + * + * Example: + * ``` + * $hmacKey->update('INACTIVE'); + * ``` + * + * @param string $state The key state. Either `ACTIVE` or `INACTIVE`. + * @param array $options { + * Configuration Options + * + * @type string $userProject If set, this is the ID of the project which + * will be billed for the request. **NOTE**: This option is + * currently ignored by Cloud Storage. + * } + * @return array + */ + public function update($state, array $options = []) + { + $this->info = $this->connection->updateHmacKey(['accessId' => $this->accessId, 'projectId' => $this->projectId, 'state' => $state] + $options); + return $this->info; + } + /** + * Delete the HMAC Key. + * + * Key state must be set to `INACTIVE` prior to deletion. See + * {@see Google\Cloud\Storage\HmacKey::update()} for details. + * + * Example: + * ``` + * $hmacKey->delete(); + * ``` + * + * @param array $options { + * Configuration Options + * + * @type string $userProject If set, this is the ID of the project which + * will be billed for the request. **NOTE**: This option is + * currently ignored by Cloud Storage. + * } + * @return void + */ + public function delete(array $options = []) + { + $this->connection->deleteHmacKey(['accessId' => $this->accessId, 'projectId' => $this->projectId] + $options); + } +} diff --git a/vendor/Gcp/google/cloud-storage/src/Notification.php b/vendor/Gcp/google/cloud-storage/src/Notification.php index 8bd9358f..aa20abf9 100644 --- a/vendor/Gcp/google/cloud-storage/src/Notification.php +++ b/vendor/Gcp/google/cloud-storage/src/Notification.php @@ -173,7 +173,7 @@ public function id() * echo $notification->identity()['bucket']; * ``` * - * @return string + * @return array */ public function identity() { diff --git a/vendor/Gcp/google/cloud-storage/src/ObjectIterator.php b/vendor/Gcp/google/cloud-storage/src/ObjectIterator.php index c586a6b8..d4bdb633 100644 --- a/vendor/Gcp/google/cloud-storage/src/ObjectIterator.php +++ b/vendor/Gcp/google/cloud-storage/src/ObjectIterator.php @@ -32,6 +32,6 @@ class ObjectIterator implements \Iterator */ public function prefixes() { - return $this->pageIterator->prefixes(); + return method_exists($this->pageIterator, 'prefixes') ? $this->pageIterator->prefixes() : []; } } diff --git a/vendor/Gcp/google/cloud-storage/src/SigningHelper.php b/vendor/Gcp/google/cloud-storage/src/SigningHelper.php new file mode 100644 index 00000000..c59bd747 --- /dev/null +++ b/vendor/Gcp/google/cloud-storage/src/SigningHelper.php @@ -0,0 +1,452 @@ +getSigningCredentials($connection, $options); + $expires = $this->normalizeExpiration($expires); + $resource = $this->normalizeResource($resource); + $options = $this->normalizeOptions($options); + $headers = $this->normalizeHeaders($options['headers']); + // Make sure disallowed headers are not included. + $illegalHeaders = ['x-goog-encryption-key', 'x-goog-encryption-key-sha256']; + if ($illegal = array_intersect_key(array_flip($illegalHeaders), $headers)) { + throw new \InvalidArgumentException(sprintf('%s %s not allowed in Signed URL headers.', implode(' and ', array_keys($illegal)), count($illegal) === 1 ? 'is' : 'are')); + } + // Sort headers by name. + ksort($headers); + $toSign = [$options['method'], $options['contentMd5'], $options['contentType'], $expires]; + $signedHeaders = []; + foreach ($headers as $name => $value) { + $signedHeaders[] = $name . ':' . $value; + } + // Push the headers onto the end of the signing string. + if ($signedHeaders) { + $toSign = array_merge($toSign, $signedHeaders); + } + $toSign[] = $resource; + $stringToSign = $this->createV2CanonicalRequest($toSign); + $signature = $credentials->signBlob($stringToSign, ['forceOpenssl' => $options['forceOpenssl']]); + // Start with user-provided query params and add required parameters. + $params = $options['queryParams']; + $params['GoogleAccessId'] = $credentials->getClientName(); + $params['Expires'] = $expires; + $params['Signature'] = $signature; + $params = $this->addCommonParams($generation, $params, $options); + $queryString = $this->buildQueryString($params); + $resource = $this->normalizeUriPath($options['cname'], $resource); + return 'https://' . $options['cname'] . $resource . '?' . $queryString; + } + /** + * Sign a storage URL using Google Signed URLs v4. + * + * @param ConnectionInterface $connection A connection to the Cloud Storage + * API. + * @param Timestamp|\DateTimeInterface|int $expires The signed URL + * expiration. + * @param string $resource The URI to the storage resource, preceded by a + * leading slash. + * @param int|null $generation The resource generation. + * @param array $options Configuration options. See + * {@see Google\Cloud\Storage\StorageObject::signedUrl()} for + * details. + * @return string + * @throws \InvalidArgumentException + * @throws \RuntimeException If required data could not be gathered from + * credentials. + * @throws \RuntimeException If OpenSSL signing is required by user input + * and OpenSSL is not available. + */ + public function v4Sign(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\Connection\ConnectionInterface $connection, $expires, $resource, $generation, array $options) + { + list($credentials, $options) = $this->getSigningCredentials($connection, $options); + $expires = $this->normalizeExpiration($expires); + $resource = $this->normalizeResource($resource); + $options = $this->normalizeOptions($options); + $time = $options['timestamp']; + $requestTimestamp = $time->format(self::V4_TIMESTAMP_FORMAT); + $requestDatestamp = $time->format(self::V4_DATESTAMP_FORMAT); + $timeSeconds = $time->format('U'); + $expireLimit = $timeSeconds + 604800; + if ($expires > $expireLimit) { + throw new \InvalidArgumentException('V4 Signed URLs may not have an expiration greater than seven days in the future.'); + } + $clientEmail = $credentials->getClientName(); + $credentialScope = sprintf('%s/auto/storage/goog4_request', $requestDatestamp); + $credential = sprintf('%s/%s', $clientEmail, $credentialScope); + // Add headers and query params based on provided options. + $params = $options['queryParams']; + $headers = $options['headers'] + ['host' => $options['cname']]; + if ($options['contentType']) { + $headers['content-type'] = $options['contentType']; + } + if ($options['contentMd5']) { + $headers['content-md5'] = $options['contentMd5']; + } + $params = $this->addCommonParams($generation, $params, $options); + $headers = $this->normalizeHeaders($headers); + // sort headers by name + ksort($headers, SORT_NATURAL | SORT_FLAG_CASE); + // Canonical headers are a list, newline separated, of keys and values, + // comma separated. + // Signed headers are a list of keys, separated by a semicolon. + $canonicalHeaders = []; + $signedHeaders = []; + foreach ($headers as $key => $val) { + $canonicalHeaders[] = sprintf('%s:%s', $key, $val); + $signedHeaders[] = $key; + } + $canonicalHeaders = implode("\n", $canonicalHeaders) . "\n"; + $signedHeaders = implode(';', $signedHeaders); + // Add required query parameters. + $params['X-Goog-Algorithm'] = self::V4_ALGO_NAME; + $params['X-Goog-Credential'] = $credential; + $params['X-Goog-Date'] = $requestTimestamp; + $params['X-Goog-Expires'] = $expires - $timeSeconds; + $params['X-Goog-SignedHeaders'] = $signedHeaders; + // Sort query string params by name. + ksort($params, SORT_NATURAL | SORT_FLAG_CASE); + $canonicalQueryString = $this->buildQueryString($params); + $canonicalRequest = [$options['method'], $resource, $canonicalQueryString, $canonicalHeaders, $signedHeaders, 'UNSIGNED-PAYLOAD']; + $requestHash = $this->createV4CanonicalRequest($canonicalRequest); + // Construct the string to sign. + $stringToSign = implode("\n", [self::V4_ALGO_NAME, $requestTimestamp, $credentialScope, $requestHash]); + $signature = bin2hex(base64_decode($credentials->signBlob($stringToSign, ['forceOpenssl' => $options['forceOpenssl']]))); + // Construct the modified resource name. If a custom cname is provided, + // this will remove the bucket name from the resource. + $resource = $this->normalizeUriPath($options['cname'], $resource); + return sprintf('https://%s%s?%s&X-Goog-Signature=%s', $options['cname'], $resource, $canonicalQueryString, $signature); + } + /** + * Creates a canonical request hash for a V4 Signed URL. + * + * NOTE: While in most cases `PHP_EOL` is preferable to a system-specific + * character, in this case `\n` is required. + * + * @param array $canonicalRequest The canonical request, with each element + * representing a line in the request. + * @return string + */ + private function createV4CanonicalRequest(array $canonicalRequest) + { + return bin2hex(hash('sha256', implode("\n", $canonicalRequest), true)); + } + /** + * Creates a canonical request for a V2 Signed URL. + * + * NOTE: While in most cases `PHP_EOL` is preferable to a system-specific + * character, in this case `\n` is required. + * + * @param array $canonicalRequest The canonical request, with each element + * representing a line in the request. + * @return string + */ + private function createV2CanonicalRequest(array $canonicalRequest) + { + return implode("\n", $canonicalRequest); + } + /** + * Normalizes and validates an expiration. + * + * @param Timestamp|\DateTimeInterface|int $expires The expiration + * @return int + * @throws \InvalidArgumentException If an invalid value is given. + */ + private function normalizeExpiration($expires) + { + if ($expires instanceof Timestamp) { + $seconds = $expires->get()->format('U'); + } elseif ($expires instanceof \DateTimeInterface) { + $seconds = $expires->format('U'); + } elseif (is_numeric($expires)) { + $seconds = (int) $expires; + } else { + throw new \InvalidArgumentException('Invalid expiration.'); + } + return $seconds; + } + /** + * Normalizes and encodes the resource identifier. + * + * @param string $resource The resource identifier. In form + * `[/]$bucket/$object`. + * @return string The resource, with pieces encoded and prefixed with a + * forward slash. + */ + private function normalizeResource($resource) + { + $pieces = explode('/', trim($resource, '/')); + array_walk($pieces, function (&$piece) { + $piece = rawurlencode($piece); + }); + return '/' . implode('/', $pieces); + } + /** + * Fixes the user input options, filters and validates data. + * + * @param array $options Signed URL configuration options. + * @return array + * @throws \InvalidArgumentException + */ + private function normalizeOptions(array $options) + { + $options += ['method' => 'GET', 'cname' => self::DEFAULT_DOWNLOAD_HOST, 'contentMd5' => null, 'contentType' => null, 'headers' => [], 'saveAsName' => null, 'responseDisposition' => null, 'responseType' => null, 'keyFile' => null, 'keyFilePath' => null, 'allowPost' => false, 'forceOpenssl' => false, 'queryParams' => [], 'timestamp' => null]; + $allowedMethods = ['GET', 'PUT', 'POST', 'DELETE']; + $options['method'] = strtoupper($options['method']); + if (!in_array($options['method'], $allowedMethods)) { + throw new \InvalidArgumentException('$options.method must be one of `GET`, `PUT` or `DELETE`.'); + } + if ($options['method'] === 'POST' && !$options['allowPost']) { + throw new \InvalidArgumentException('Invalid method. To create an upload URI, use StorageObject::signedUploadUrl().'); + } + unset($options['allowPost']); + // For backwards compatibility, strip protocol from cname. + $cnameParts = explode('//', $options['cname']); + if (count($cnameParts) > 1) { + $options['cname'] = $cnameParts[1]; + } + $options['cname'] = trim($options['cname'], '/'); + // If a timestamp is provided, use it in place of `now` for v4 URLs only.. + // This option exists for testing purposes, and should not generally be provided by users. + if ($options['timestamp']) { + if (!$options['timestamp'] instanceof \DateTimeInterface) { + if (!is_string($options['timestamp'])) { + throw new \InvalidArgumentException('User-provided timestamps must be a string or instance of `\\DateTimeInterface`.'); + } + $options['timestamp'] = \DateTimeImmutable::createFromFormat(self::V4_TIMESTAMP_FORMAT, $options['timestamp'], new \DateTimeZone('UTC')); + if (!$options['timestamp']) { + throw new \InvalidArgumentException('Given timestamp string is in an invalid format. Provide timestamp formatted as follows: `' . self::V4_TIMESTAMP_FORMAT . '`. Note that timestamps MUST be in UTC.'); + } + } + } else { + $options['timestamp'] = new \DateTimeImmutable('now', new \DateTimeZone('UTC')); + } + return $options; + } + /** + * Cleans and normalizes header values. + * + * Arrays of values are collapsed into a comma-separated list, trailing and + * leading spaces are removed, newlines are replaced by empty strings, and + * multiple whitespace chars are replaced by a single space. + * + * @param array $headers Input headers + * @return array + */ + private function normalizeHeaders(array $headers) + { + $out = []; + foreach ($headers as $name => $value) { + $name = strtolower(trim($name)); + // collapse arrays of values into a comma-separated list. + if (!is_array($value)) { + $value = [$value]; + } + foreach ($value as &$headerValue) { + // strip trailing and leading spaces. + $headerValue = trim($headerValue); + // replace newlines with empty strings. + $headerValue = str_replace(PHP_EOL, '', $headerValue); + // collapse multiple whitespace chars to a single space. + $headerValue = preg_replace('/\\s+/', ' ', $headerValue); + } + $out[$name] = implode(', ', $value); + } + return $out; + } + /** + * Returns a resource formatted for use in a URI. + * + * If the cname is other than the default, will omit the bucket name. + * + * @param string $cname The cname provided by the user, or the default + * value. + * @param string $resource The GCS resource path (i.e. /bucket/object). + * @return string + */ + private function normalizeUriPath($cname, $resource) + { + if ($cname !== self::DEFAULT_DOWNLOAD_HOST) { + $resourceParts = explode('/', trim($resource, '/')); + array_shift($resourceParts); + // Resource is a Bucket. + if (empty($resourceParts)) { + $resource = '/'; + } else { + $resource = '/' . implode('/', $resourceParts); + } + } + return $resource; + } + /** + * Get the credentials for use with signing. + * + * @param ConnectionInterface $connection A Storage connection object. + * @param array $options Configuration options. + * @return array A list containing a credentials object at index 0 and the + * modified options at index 1. + * @throws \RuntimeException If the credentials type is not valid for signing. + * @throws \InvalidArgumentException If a keyfile is given and is not valid. + */ + private function getSigningCredentials(\DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\Connection\ConnectionInterface $connection, array $options) + { + $keyFilePath = isset($options['keyFilePath']) ? $options['keyFilePath'] : null; + if ($keyFilePath) { + if (!file_exists($keyFilePath)) { + throw new \InvalidArgumentException(sprintf('Keyfile path %s does not exist.', $keyFilePath)); + } + $options['keyFile'] = self::jsonDecode(file_get_contents($keyFilePath), true); + } + $rw = $connection->requestWrapper(); + $keyFile = isset($options['keyFile']) ? $options['keyFile'] : null; + if ($keyFile) { + $scopes = isset($options['scopes']) ? $options['scopes'] : $rw->scopes(); + $credentials = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Auth\CredentialsLoader::makeCredentials($scopes, $keyFile); + } else { + $credentials = $rw->getCredentialsFetcher(); + } + if (!$credentials instanceof SignBlobInterface) { + throw new \RuntimeException(sprintf('Credentials object is of type `%s` and is not valid for signing.', get_class($credentials))); + } + unset($options['keyFilePath'], $options['keyFile'], $options['scopes']); + return [$credentials, $options]; + } + /** + * Add parameters common to all signed URL versions. + * + * @param int|null $generation + * @param array $params + * @param array $options + * @return array + */ + private function addCommonParams($generation, array $params, array $options) + { + if ($options['responseType']) { + $params['response-content-type'] = $options['responseType']; + } + if ($options['responseDisposition']) { + $params['response-content-disposition'] = $options['responseDisposition']; + } elseif ($options['saveAsName']) { + $params['response-content-disposition'] = 'attachment; filename=' . '"' . $options['saveAsName'] . '"'; + } + if ($generation) { + $params['generation'] = $generation; + } + return $params; + } + /** + * Create a query string from an array, encoding spaces as `%20` rather than `+`. + * + * @param array $input + * @return string + */ + private function buildQueryString(array $input) + { + return http_build_query($input, '', '&', PHP_QUERY_RFC3986); + } +} diff --git a/vendor/Gcp/google/cloud-storage/src/StorageClient.php b/vendor/Gcp/google/cloud-storage/src/StorageClient.php index 8b40fe72..c702b721 100644 --- a/vendor/Gcp/google/cloud-storage/src/StorageClient.php +++ b/vendor/Gcp/google/cloud-storage/src/StorageClient.php @@ -45,7 +45,7 @@ class StorageClient { use ArrayTrait; use ClientTrait; - const VERSION = '1.10.0'; + const VERSION = '1.16.0'; const FULL_CONTROL_SCOPE = 'https://www.googleapis.com/auth/devstorage.full_control'; const READ_ONLY_SCOPE = 'https://www.googleapis.com/auth/devstorage.read_only'; const READ_WRITE_SCOPE = 'https://www.googleapis.com/auth/devstorage.read_write'; @@ -170,9 +170,7 @@ public function bucket($name, $userProject = false) */ public function buckets(array $options = []) { - if (!$this->projectId) { - throw new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\GoogleException('No project ID was provided, ' . 'and we were unable to detect a default project ID.'); - } + $this->requireProjectId(); $resultLimit = $this->pluck('resultLimit', $options, false); $bucketUserProject = $this->pluck('bucketUserProject', $options, false); $bucketUserProject = !is_null($bucketUserProject) ? $bucketUserProject : true; @@ -204,6 +202,7 @@ public function buckets(array $options = []) * @see https://cloud.google.com/storage/docs/json_api/v1/buckets/insert Buckets insert API documentation. * * @param string $name Name of the bucket to be created. + * @codingStandardsIgnoreStart * @param array $options [optional] { * Configuration options. * @@ -270,15 +269,25 @@ public function buckets(array $options = []) * period for objects in seconds. During the retention period an * object cannot be overwritten or deleted. Retention period must * be greater than zero and less than 100 years. + * @type array $iamConfiguration The bucket's IAM configuration. + * @type bool $iamConfiguration.bucketPolicyOnly.enabled this is an alias + * for $iamConfiguration.uniformBucketLevelAccess. + * @type bool $iamConfiguration.uniformBucketLevelAccess.enabled If set and + * true, access checks only use bucket-level IAM policies or + * above. When enabled, requests attempting to view or manipulate + * ACLs will fail with error code 400. **NOTE**: Before using + * Uniform bucket-level access, please review the + * [feature documentation](https://cloud.google.com/storage/docs/uniform-bucket-level-access), + * as well as + * [Should You Use uniform bucket-level access](https://cloud.google.com/storage/docs/uniform-bucket-level-access#should-you-use) * } + * @codingStandardsIgnoreEnd * @return Bucket * @throws GoogleException When a project ID has not been detected. */ public function createBucket($name, array $options = []) { - if (!$this->projectId) { - throw new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\GoogleException('No project ID was provided, ' . 'and we were unable to detect a default project ID.'); - } + $this->requireProjectId(); if (isset($options['lifecycle']) && $options['lifecycle'] instanceof Lifecycle) { $options['lifecycle'] = $options['lifecycle']->toArray(); } @@ -333,7 +342,7 @@ public function signedUrlUploader($uri, $data, array $options = []) * $timestamp = $storage->timestamp(new \DateTime('2003-02-05 11:15:02.421827Z')); * ``` * - * @param \DateTimeInterface $value The timestamp value. + * @param \DateTimeInterface $timestamp The timestamp value. * @param int $nanoSeconds [optional] The number of nanoseconds in the timestamp. * @return Timestamp */ @@ -362,4 +371,111 @@ public function getServiceAccount(array $options = []) $resp = $this->connection->getServiceAccount($options + ['projectId' => $this->projectId]); return $resp['email_address']; } + /** + * List Service Account HMAC keys in the project. + * + * Example: + * ``` + * $hmacKeys = $storage->hmacKeys(); + * ``` + * + * ``` + * // Get the HMAC keys associated with a Service Account email + * $hmacKeys = $storage->hmacKeys([ + * 'serviceAccountEmail' => $serviceAccountEmail + * ]); + * ``` + * + * @param array $options { + * Configuration Options + * + * @type string $serviceAccountEmail If present, only keys for the given + * service account are returned. + * @type bool $showDeletedKeys Whether or not to show keys in the + * DELETED state. + * @type string $userProject If set, this is the ID of the project which + * will be billed for the request. + * @type string $projectId The project ID to use, if different from that + * with which the client was created. + * } + * @return ItemIterator + */ + public function hmacKeys(array $options = []) + { + $options += ['projectId' => $this->projectId]; + if (!$options['projectId']) { + $this->requireProjectId(); + } + $resultLimit = $this->pluck('resultLimit', $options, false); + return new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Iterator\ItemIterator(new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Iterator\PageIterator(function (array $metadata) use($options) { + return $this->hmacKey($metadata['accessId'], $options['projectId'], $metadata); + }, [$this->connection, 'listHmacKeys'], $options, ['resultLimit' => $resultLimit])); + } + /** + * Lazily instantiate an HMAC Key instance using an Access ID. + * + * Example: + * ``` + * $hmacKey = $storage->hmacKey($accessId); + * ``` + * + * @param string $accessId The ID of the HMAC Key. + * @param string $projectId [optional] The project ID to use, if different + * from that with which the client was created. + * @param array $metadata [optional] HMAC key metadata. + * @return HmacKey + */ + public function hmacKey($accessId, $projectId = null, array $metadata = []) + { + if (!$projectId) { + $this->requireProjectId(); + } + return new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\HmacKey($this->connection, $projectId ?: $this->projectId, $accessId, $metadata); + } + /** + * Creates a new HMAC key for the specified service account. + * + * Please note that the HMAC secret is only available at creation. Make sure + * to note the secret after creation. + * + * Example: + * ``` + * $response = $storage->createHmacKey('account@myProject.iam.gserviceaccount.com'); + * $secret = $response->secret(); + * ``` + * + * @param string $serviceAccountEmail Email address of the service account. + * @param array $options { + * Configuration Options + * + * @type string $userProject If set, this is the ID of the project which + * will be billed for the request. **NOTE**: This option is + * currently ignored by Cloud Storage. + * @type string $projectId The project ID to use, if different from that + * with which the client was created. + * } + * @return CreatedHmacKey + */ + public function createHmacKey($serviceAccountEmail, array $options = []) + { + $options += ['projectId' => $this->projectId]; + if (!$options['projectId']) { + $this->requireProjectId(); + } + $res = $this->connection->createHmacKey(['projectId' => $options['projectId'], 'serviceAccountEmail' => $serviceAccountEmail] + $options); + $key = new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\HmacKey($this->connection, $options['projectId'], $res['metadata']['accessId'], $res['metadata']); + return new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\CreatedHmacKey($key, $res['secret']); + } + /** + * Throw an exception if no project ID available. + * + * @return void + * @throws GoogleException + */ + private function requireProjectId() + { + if (!$this->projectId) { + throw new \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Core\Exception\GoogleException('No project ID was provided, ' . 'and we were unable to detect a default project ID.'); + } + } } diff --git a/vendor/Gcp/google/cloud-storage/src/StorageObject.php b/vendor/Gcp/google/cloud-storage/src/StorageObject.php index 31616bd0..977fe4e1 100644 --- a/vendor/Gcp/google/cloud-storage/src/StorageObject.php +++ b/vendor/Gcp/google/cloud-storage/src/StorageObject.php @@ -43,7 +43,10 @@ class StorageObject { use ArrayTrait; use EncryptionTrait; - const DEFAULT_DOWNLOAD_URL = 'https://storage.googleapis.com'; + /** + * @deprecated + */ + const DEFAULT_DOWNLOAD_URL = \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\SigningHelper::DEFAULT_DOWNLOAD_HOST; /** * @var Acl ACL for the object. */ @@ -475,12 +478,18 @@ public function rename($name, array $options = []) /** * Download an object as a string. * + * For an example of setting the range header to download a subrange of the + * object please see {@see Google\Cloud\Storage\StorageObject::downloadAsStream()}. + * * Example: * ``` * $string = $object->downloadAsString(); * echo $string; * ``` * + * @see https://cloud.google.com/storage/docs/json_api/v1/objects/get Objects get API documentation. + * @see https://cloud.google.com/storage/docs/json_api/v1/parameters#range Learn more about the Range header. + * * @param array $options [optional] { * Configuration Options. * @@ -502,11 +511,17 @@ public function downloadAsString(array $options = []) /** * Download an object to a specified location. * + * For an example of setting the range header to download a subrange of the + * object please see {@see Google\Cloud\Storage\StorageObject::downloadAsStream()}. + * * Example: * ``` * $stream = $object->downloadToFile(__DIR__ . '/my-file.txt'); * ``` * + * @see https://cloud.google.com/storage/docs/json_api/v1/objects/get Objects get API documentation. + * @see https://cloud.google.com/storage/docs/json_api/v1/parameters#range Learn more about the Range header. + * * @param string $path Path to download the file to. * @param array $options [optional] { * Configuration Options. @@ -532,12 +547,35 @@ public function downloadToFile($path, array $options = []) /** * Download an object as a stream. * + * Please note Google Cloud Storage respects the Range header as specified + * by [RFC7233](https://tools.ietf.org/html/rfc7233#section-3.1). See below + * for an example of this in action. + * * Example: * ``` * $stream = $object->downloadAsStream(); * echo $stream->getContents(); * ``` * + * ``` + * // Set the Range header in order to download a subrange of the object. For more examples of + * // setting the Range header, please see [RFC7233](https://tools.ietf.org/html/rfc7233#section-3.1). + * $firstFiveBytes = '0-4'; // Get the first 5 bytes. + * $fromFifthByteToLastByte = '4-'; // Get the bytes starting with the 5th to the last. + * $lastFiveBytes = '-5'; // Get the last 5 bytes. + * + * $stream = $object->downloadAsStream([ + * 'restOptions' => [ + * 'headers' => [ + * 'Range' => "bytes=$firstFiveBytes" + * ] + * ] + * ]); + * ``` + * + * @see https://cloud.google.com/storage/docs/json_api/v1/objects/get Objects get API documentation. + * @see https://cloud.google.com/storage/docs/json_api/v1/parameters#range Learn more about the Range header. + * * @param array $options [optional] { * Configuration Options. * @@ -559,6 +597,9 @@ public function downloadAsStream(array $options = []) /** * Asynchronously download an object as a stream. * + * For an example of setting the range header to download a subrange of the + * object please see {@see Google\Cloud\Storage\StorageObject::downloadAsStream()}. + * * Example: * ``` * use Psr\Http\Message\StreamInterface; @@ -588,6 +629,8 @@ public function downloadAsStream(array $options = []) * Promise\unwrap($promises); * ``` * + * @see https://cloud.google.com/storage/docs/json_api/v1/objects/get Objects get API documentation. + * @see https://cloud.google.com/storage/docs/json_api/v1/parameters#range Learn more about the Range header. * @see https://github.com/guzzle/promises Learn more about Guzzle Promises * * @param array $options [optional] { @@ -618,18 +661,41 @@ public function downloadAsStreamAsync(array $options = []) * Signed URLs can be complex, and it is strongly recommended you read and * understand the [documentation](https://cloud.google.com/storage/docs/access-control/signed-urls). * + * In cases where a keyfile is available, signing is accomplished in the + * client using your Service Account private key. In Google Compute Engine, + * signing is accomplished using + * [IAM signBlob](https://cloud.google.com/iam/credentials/reference/rest/v1/projects.serviceAccounts/signBlob). + * Signing using IAM requires that your service account be granted the + * `iam.serviceAccounts.signBlob` permission, part of the "Service Account + * Token Creator" IAM role. + * + * Additionally, signing using IAM requires different scopes. When creating + * an instance of {@see Google\Cloud\Storage\StorageClient}, provide the + * `https://www.googleapis.com/auth/cloud-platform` scopein `$options.scopes`. + * This scope may be used entirely in place of the scopes provided in + * {@see Google\Cloud\Storage\StorageClient}. + * + * App Engine and Compute Engine will attempt to sign URLs using IAM. + * * Example: * ``` - * $url = $object->signedUrl(new Timestamp(new DateTime('tomorrow'))); + * $url = $object->signedUrl(new \DateTime('tomorrow')); * ``` * * ``` * // Create a signed URL allowing updates to the object. - * $url = $object->signedUrl(new Timestamp(new DateTime('tomorrow')), [ + * $url = $object->signedUrl(new \DateTime('tomorrow'), [ * 'method' => 'PUT' * ]); * ``` * + * ``` + * // Use Signed URLs v4 + * $url = $object->signedUrl(new \DateTime('tomorrow'), [ + * 'version' => 'v4' + * ]); + * ``` + * * @see https://cloud.google.com/storage/docs/access-control/signed-urls Signed URLs * * @param Timestamp|\DateTimeInterface|int $expires Specifies when the URL @@ -639,8 +705,6 @@ public function downloadAsStreamAsync(array $options = []) * @param array $options { * Configuration Options. * - * @type string $method One of `GET`, `PUT` or `DELETE`. - * **Defaults to** `GET`. * @type string $cname The CNAME for the bucket, for instance * `https://cdn.example.com`. **Defaults to** * `https://storage.googleapis.com`. @@ -648,136 +712,60 @@ public function downloadAsStreamAsync(array $options = []) * provide this, the client must provide this HTTP header with * this same value in its request. If provided, take care to * always provide this value as a base64 encoded string. - * @type array $headers If these headers are used, the server will check - * to make sure that the client provides matching values. Provide - * headers as a key/value array, where the key is the header name, - * and the value is an array of header values. Headers with multiple - * values may provide values as a simple array, or a - * comma-separated string. Headers names MUST begin with `x-goog-`. - * @type string $saveAsName The filename to prompt the user to save the - * file as when the signed url is accessed. This is ignored if - * `$options.responseDisposition` is set. - * @type string $responseDisposition The - * [`response-content-disposition`](http://www.iana.org/assignments/cont-disp/cont-disp.xhtml) - * parameter of the signed url. * @type string $contentType If you provide this value, the client must * provide this HTTP header set to the same value. - * @type string $responseType The `response-content-type` parameter of the - * signed url. When the server contentType is `null`, this option - * may be used to control the content type of the response. + * @type bool $forceOpenssl If true, OpenSSL will be used regardless of + * whether phpseclib is available. **Defaults to** `false`. + * @type array $headers If additional headers are provided, the server + * will check to make sure that the client provides matching + * values. Provide headers as a key/value array, where the key is + * the header name, and the value is an array of header values. + * Headers with multiple values may provide values as a simple + * array, or a comma-separated string. For a reference of allowed + * headers, see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers). + * Header values will be trimmed of leading and trailing spaces, + * multiple spaces within values will be collapsed to a single + * space, and line breaks will be replaced by an empty string. + * V2 Signed URLs may not provide `x-goog-encryption-key` or + * `x-goog-encryption-key-sha256` headers. * @type array $keyFile Keyfile data to use in place of the keyfile with * which the client was constructed. If `$options.keyFilePath` is * set, this option is ignored. * @type string $keyFilePath A path to a valid Keyfile to use in place * of the keyfile with which the client was constructed. - * @type bool $forceOpenssl If true, OpenSSL will be used regardless of - * whether phpseclib is available. **Defaults to** `false`. + * @type string $method One of `GET`, `PUT` or `DELETE`. + * **Defaults to** `GET`. + * @type string $responseDisposition The + * [`response-content-disposition`](http://www.iana.org/assignments/cont-disp/cont-disp.xhtml) + * parameter of the signed url. + * @type string $responseType The `response-content-type` parameter of the + * signed url. When the server contentType is `null`, this option + * may be used to control the content type of the response. + * @type string $saveAsName The filename to prompt the user to save the + * file as when the signed url is accessed. This is ignored if + * `$options.responseDisposition` is set. + * @type string|array $scopes One or more authentication scopes to be + * used with a key file. This option is ignored unless + * `$options.keyFile` or `$options.keyFilePath` is set. + * @type array $queryParams Additional query parameters to be included + * as part of the signed URL query string. For allowed values, + * see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers#query). + * @type string $version One of "v2" or "v4". **Defaults to** `"v2"`. * } * @return string * @throws \InvalidArgumentException If the given expiration is invalid or in the past. * @throws \InvalidArgumentException If the given `$options.method` is not valid. * @throws \InvalidArgumentException If the given `$options.keyFilePath` is not valid. * @throws \InvalidArgumentException If the given custom headers are invalid. - * @throws \RuntimeException If the keyfile does not contain the required information. + * @throws \InvalidArgumentException If the keyfile does not contain the required information. + * @throws \RuntimeException If the credentials provided cannot be used for signing strings. */ public function signedUrl($expires, array $options = []) { - $options += ['method' => 'GET', 'cname' => self::DEFAULT_DOWNLOAD_URL, 'contentMd5' => null, 'contentType' => null, 'headers' => [], 'saveAsName' => null, 'responseDisposition' => null, 'responseType' => null, 'keyFile' => null, 'keyFilePath' => null, 'allowPost' => false, 'forceOpenssl' => false]; - if ($expires instanceof Timestamp) { - $seconds = $expires->get()->format('U'); - } elseif ($expires instanceof \DateTimeInterface) { - $seconds = $expires->format('U'); - } elseif (is_numeric($expires)) { - $seconds = (int) $expires; - } else { - throw new \InvalidArgumentException('Invalid expiration.'); - } - if ($seconds < time()) { - throw new \InvalidArgumentException('Expiration cannot be in the past.'); - } - $allowedMethods = ['GET', 'PUT', 'POST', 'DELETE']; - $options['method'] = strtoupper($options['method']); - if (!in_array($options['method'], $allowedMethods)) { - throw new \InvalidArgumentException('$options.method must be one of `GET`, `PUT` or `DELETE`.'); - } - if ($options['method'] === 'POST' && !$options['allowPost']) { - throw new \InvalidArgumentException('Invalid method. To create an upload URI, use StorageObject::signedUploadUrl().'); - } - if ($options['keyFilePath']) { - if (!file_exists($options['keyFilePath'])) { - throw new \InvalidArgumentException(sprintf('Keyfile path %s does not exist.', $options['keyFilePath'])); - } - $keyFile = json_decode(file_get_contents($options['keyFilePath']), true); - if (json_last_error() !== JSON_ERROR_NONE) { - throw new \InvalidArgumentException(sprintf('Keyfile path %s does not contain valid json.', $options['keyFilePath'])); - } - } elseif ($options['keyFile']) { - $keyFile = $options['keyFile']; - } else { - $requestWrapper = $this->connection->requestWrapper(); - $keyFile = $requestWrapper->keyFile(); - } - if (!isset($keyFile['private_key']) || !isset($keyFile['client_email'])) { - throw new \RuntimeException('Keyfile does not provide required information. ' . 'Please ensure keyfile includes `private_key` and `client_email`.'); - } - // Make sure disallowed headers are not included. - $illegalHeaders = ['x-goog-encryption-key', 'x-goog-encryption-key-sha256']; - if ($illegal = array_intersect_key(array_flip($illegalHeaders), $options['headers'])) { - throw new \InvalidArgumentException(sprintf('%s %s not allowed in Signed URL headers.', implode(' and ', array_keys($illegal)), count($illegal) === 1 ? 'is' : 'are')); - } - // Sort headers by name. - ksort($options['headers']); - $headers = []; - foreach ($options['headers'] as $name => $value) { - $name = strtolower(trim($name)); - $value = is_array($value) ? implode(',', array_map('trim', $value)) : trim($value); - // Linebreaks are not allowed in headers. - // Rather than strip, we throw because we don't want to change the expected value without the user knowing. - if (strpos($value, PHP_EOL) !== false) { - throw new \InvalidArgumentException('Line endings are not allowed in header values. Replace line endings with a single space.'); - } - // Invalid header names throw exception. - if (strpos($name, 'x-goog-') !== 0) { - throw new \InvalidArgumentException('Header names must begin with `x-goog-`.'); - } - $headers[] = $name . ':' . $value; - } - if ($headers) { - $headers[] = ''; - } - $objectPieces = explode('/', $this->identity['object']); - array_walk($objectPieces, function (&$piece) { - $piece = rawurlencode($piece); - }); - $objectName = implode('/', $objectPieces); - $resource = sprintf('/%s/%s', $this->identity['bucket'], $objectName); - $toSign = [$options['method'], $options['contentMd5'], $options['contentType'], $seconds, implode("\n", $headers) . $resource]; - // NOTE: While in most cases `PHP_EOL` is preferable to a system-specific character, - // in this case `\n` is required. - $string = implode("\n", $toSign); - $signature = $this->signString($keyFile['private_key'], $string, $options['forceOpenssl']); - $encodedSignature = urlencode(base64_encode($signature)); - $query = []; - $query[] = 'GoogleAccessId=' . $keyFile['client_email']; - $query[] = 'Expires=' . $seconds; - $query[] = 'Signature=' . $encodedSignature; - if ($options['responseDisposition']) { - $query[] = 'response-content-disposition=' . urlencode($options['responseDisposition']); - } elseif ($options['saveAsName']) { - $query[] = 'response-content-disposition=attachment;filename="' . urlencode($options['saveAsName']) . '"'; - } - if ($options['responseType']) { - $query[] = 'response-content-type=' . urlencode($options['responseType']); - } - if ($this->identity['generation']) { - $query[] = 'generation=' . $this->identity['generation']; - } - $options['cname'] = trim($options['cname'], '/'); - // If a custom cname is used, then the resource is simply the objectName - if ($options['cname'] !== self::DEFAULT_DOWNLOAD_URL) { - $resource = '/' . $objectName; - } - return $options['cname'] . $resource . '?' . implode('&', $query); + // May be overridden for testing. + $signingHelper = $this->pluck('helper', $options, false) ?: \DeliciousBrains\WP_Offload_Media\Gcp\Google\Cloud\Storage\SigningHelper::getHelper(); + $resource = sprintf('/%s/%s', $this->identity['bucket'], $this->identity['object']); + return $signingHelper->sign($this->connection, $expires, $resource, $this->identity['generation'], $options); } /** * Create a Signed Upload URL for this object. @@ -800,8 +788,14 @@ public function signedUrl($expires, array $options = []) * * Example: * ``` - * $timestamp = new Timestamp(new \DateTime('tomorrow')); - * $url = $object->signedUploadUrl($timestamp); + * $url = $object->signedUploadUrl(new \DateTime('tomorrow')); + * ``` + * + * ``` + * // Use Signed URLs v4 + * $url = $object->signedUploadUrl(new \DateTime('tomorrow'), [ + * 'version' => 'v4' + * ]); * ``` * * @param Timestamp|\DateTimeInterface|int $expires Specifies when the URL @@ -811,35 +805,57 @@ public function signedUrl($expires, array $options = []) * @param array $options { * Configuration Options. * - * @type string $contentType If you provide this value, the client must - * provide this HTTP header set to the same value. + * @type string $cname The CNAME for the bucket, for instance + * `https://cdn.example.com`. **Defaults to** + * `https://storage.googleapis.com`. * @type string $contentMd5 The MD5 digest value in base64. If you * provide this, the client must provide this HTTP header with * this same value in its request. If provided, take care to * always provide this value as a base64 encoded string. - * @type array $headers If these headers are used, the server will check - * to make sure that the client provides matching values. Provide - * headers as a key/value array, where the key is the header name, - * and the value is an array of header values. Headers with multiple - * values may provide values as a simple array, or a - * comma-separated string. Headers names MUST begin with `x-goog-`. + * @type string $contentType If you provide this value, the client must + * provide this HTTP header set to the same value. + * @type bool $forceOpenssl If true, OpenSSL will be used regardless of + * whether phpseclib is available. **Defaults to** `false`. + * @type array $headers If additional headers are provided, the server + * will check to make sure that the client provides matching + * values. Provide headers as a key/value array, where the key is + * the header name, and the value is an array of header values. + * Headers with multiple values may provide values as a simple + * array, or a comma-separated string. For a reference of allowed + * headers, see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers). + * Header values will be trimmed of leading and trailing spaces, + * multiple spaces within values will be collapsed to a single + * space, and line breaks will be replaced by an empty string. + * V2 Signed URLs may not provide `x-goog-encryption-key` or + * `x-goog-encryption-key-sha256` headers. * @type array $keyFile Keyfile data to use in place of the keyfile with * which the client was constructed. If `$options.keyFilePath` is * set, this option is ignored. * @type string $keyFilePath A path to a valid Keyfile to use in place * of the keyfile with which the client was constructed. - * @type bool $forceOpenssl If true, OpenSSL will be used regardless of - * whether phpseclib is available. **Defaults to** `false`. + * @type string $responseDisposition The + * [`response-content-disposition`](http://www.iana.org/assignments/cont-disp/cont-disp.xhtml) + * parameter of the signed url. + * @type string $responseType The `response-content-type` parameter of the + * signed url. When the server contentType is `null`, this option + * may be used to control the content type of the response. + * @type string $saveAsName The filename to prompt the user to save the + * file as when the signed url is accessed. This is ignored if + * `$options.responseDisposition` is set. + * @type string|array $scopes One or more authentication scopes to be + * used with a key file. This option is ignored unless + * `$options.keyFile` or `$options.keyFilePath` is set. + * @type array $queryParams Additional query parameters to be included + * as part of the signed URL query string. For allowed values, + * see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers#query). + * @type string $version One of "v2" or "v4". **Defaults to** `"v2"`. * } * @return string */ public function signedUploadUrl($expires, array $options = []) { - $options += ['contentType' => null, 'contentMd5' => null]; - if (!isset($options['headers'])) { - $options['headers'] = []; - } - $options['headers']['x-goog-resumable'] = ['start']; + $options += ['headers' => []]; + $options['headers']['x-goog-resumable'] = 'start'; unset($options['cname'], $options['saveAsName'], $options['responseDisposition'], $options['responseType']); return $this->signedUrl($expires, ['method' => 'POST', 'allowPost' => true] + $options); } @@ -859,39 +875,59 @@ public function signedUploadUrl($expires, array $options = []) * $url = $object->beginSignedUploadSession(); * ``` * + * ``` + * // Use Signed URLs v4 + * $url = $object->beginSignedUploadSession([ + * 'version' => 'v4' + * ]); + * ``` + * * @see https://cloud.google.com/storage/docs/xml-api/resumable-upload#practices Resumable Upload Best Practices * * @param array $options { * Configuration Options. * - * @type string $contentType If you provide this value, the client must - * provide this HTTP header set to the same value. - * @type string $origin Value of CORS header - * "Access-Control-Allow-Origin". **Defaults to** `"*"`. * @type string $contentMd5 The MD5 digest value in base64. If you * provide this, the client must provide this HTTP header with * this same value in its request. If provided, take care to * always provide this value as a base64 encoded string. - * @type array $headers If these headers are used, the server will check - * to make sure that the client provides matching values. Provide - * headers as a key/value array, where the key is the header name, - * and the value is an array of header values. Headers with multiple - * values may provide values as a simple array, or a - * comma-separated string. Headers names MUST begin with `x-goog-`. + * @type string $contentType If you provide this value, the client must + * provide this HTTP header set to the same value. + * @type bool $forceOpenssl If true, OpenSSL will be used regardless of + * whether phpseclib is available. **Defaults to** `false`. + * @type array $headers If additional headers are provided, the server + * will check to make sure that the client provides matching + * values. Provide headers as a key/value array, where the key is + * the header name, and the value is an array of header values. + * Headers with multiple values may provide values as a simple + * array, or a comma-separated string. For a reference of allowed + * headers, see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers). + * Header values will be trimmed of leading and trailing spaces, + * multiple spaces within values will be collapsed to a single + * space, and line breaks will be replaced by an empty string. + * V2 Signed URLs may not provide `x-goog-encryption-key` or + * `x-goog-encryption-key-sha256` headers. * @type array $keyFile Keyfile data to use in place of the keyfile with * which the client was constructed. If `$options.keyFilePath` is * set, this option is ignored. * @type string $keyFilePath A path to a valid Keyfile to use in place * of the keyfile with which the client was constructed. - * @type bool $forceOpenssl If true, OpenSSL will be used regardless of - * whether phpseclib is available. **Defaults to** `false`. + * @type string $origin Value of CORS header + * "Access-Control-Allow-Origin". **Defaults to** `"*"`. + * @type string|array $scopes One or more authentication scopes to be + * used with a key file. This option is ignored unless + * `$options.keyFile` or `$options.keyFilePath` is set. + * @type array $queryParams Additional query parameters to be included + * as part of the signed URL query string. For allowed values, + * see [Reference Headers](https://cloud.google.com/storage/docs/xml-api/reference-headers#query). + * @type string $version One of "v2" or "v4". **Defaults to** `"v2"`. * } * @return string */ public function beginSignedUploadSession(array $options = []) { - $timestamp = new \DateTimeImmutable('+1 minute'); - $startUri = $this->signedUploadUrl($timestamp, $options); + $expires = new \DateTimeImmutable('+1 minute'); + $startUri = $this->signedUploadUrl($expires, $options); $uploaderOptions = $this->pluckArray(['contentType', 'origin'], $options); if (!isset($uploaderOptions['origin'])) { $uploaderOptions['origin'] = '*'; @@ -1011,7 +1047,7 @@ public function name() * echo $object->identity()['object']; * ``` * - * @return string + * @return array */ public function identity() { diff --git a/vendor/Gcp/google/cloud-storage/src/StreamWrapper.php b/vendor/Gcp/google/cloud-storage/src/StreamWrapper.php index 75a786e1..ec0989c1 100644 --- a/vendor/Gcp/google/cloud-storage/src/StreamWrapper.php +++ b/vendor/Gcp/google/cloud-storage/src/StreamWrapper.php @@ -40,7 +40,7 @@ class StreamWrapper const DIRECTORY_READABLE_MODE = 16676; // 40444 in octal /** - * @var resource Must be public according to the PHP documentation. + * @var resource|null Must be public according to the PHP documentation. */ public $context; /** @@ -66,7 +66,7 @@ class StreamWrapper */ private static $clients = []; /** - * @var ObjectsItemIterator Used for iterating through a directory + * @var ObjectIterator Used for iterating through a directory */ private $directoryIterator; /** @@ -336,7 +336,7 @@ public function rename($from, $to) $url = (array) parse_url($to) + ['path' => '', 'host' => '']; $destinationBucket = $url['host']; $destinationPath = substr($url['path'], 1); - $this->dir_opendir($from, []); + $this->dir_opendir($from, 0); foreach ($this->directoryIterator as $file) { $name = $file->name(); $newPath = str_replace($this->file, $destinationPath, $name); diff --git a/vendor/Gcp/google/crc32/CONTRIBUTING.md b/vendor/Gcp/google/crc32/CONTRIBUTING.md new file mode 100644 index 00000000..ae4e0432 --- /dev/null +++ b/vendor/Gcp/google/crc32/CONTRIBUTING.md @@ -0,0 +1,28 @@ +# How to Contribute + +We'd love to accept your patches and contributions to this project. There are +just a few small guidelines you need to follow. + +## Contributor License Agreement + +Contributions to this project must be accompanied by a Contributor License +Agreement. You (or your employer) retain the copyright to your contribution; +this simply gives us permission to use and redistribute your contributions as +part of the project. Head over to to see +your current agreements on file or to sign a new one. + +You generally only need to submit a CLA once, so if you've already submitted one +(even if it was for a different project), you probably don't need to do it +again. + +## Code reviews + +All submissions, including submissions by project members, require review. We +use GitHub pull requests for this purpose. Consult +[GitHub Help](https://help.github.com/articles/about-pull-requests/) for more +information on using pull requests. + +## Community Guidelines + +This project follows [Google's Open Source Community +Guidelines](https://opensource.google.com/conduct/). \ No newline at end of file diff --git a/vendor/Gcp/google/crc32/LICENSE b/vendor/Gcp/google/crc32/LICENSE new file mode 100644 index 00000000..261eeb9e --- /dev/null +++ b/vendor/Gcp/google/crc32/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + 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. diff --git a/vendor/Gcp/google/crc32/Makefile b/vendor/Gcp/google/crc32/Makefile new file mode 100644 index 00000000..8bd47ccc --- /dev/null +++ b/vendor/Gcp/google/crc32/Makefile @@ -0,0 +1,71 @@ +## +# Copyright 2019 Google Inc. All Rights Reserved. +# +# 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. +## + +.PHONY : all clean benchmark test test_all lint ext ext_test + +COMPOSER ?= composer +PHP_CS_FIXER ?= vendor/bin/php-cs-fixer +PHP_UNIT ?= vendor/bin/phpunit + +PHP_BIN ?= $(shell php-config --prefix)/bin +PHP ?= $(PHP_BIN)/php +PHP_CONFIG ?= $(PHP_BIN)/php-config +PHPIZE ?= $(PHP_BIN)/phpize + +all: lint test + +clean: + -rm -r .php_cs.cache + $(MAKE) -C ext clean + +vendor: composer.lock +composer.lock: composer.json + $(COMPOSER) update + touch composer.lock + +lint: vendor + $(PHP_CS_FIXER) fix --dry-run --diff src + $(PHP_CS_FIXER) fix --dry-run --diff crc32_benchmark.php + $(PHP_CS_FIXER) fix --dry-run --diff tests + $(PHP_CS_FIXER) fix --dry-run --diff ext/tests + +benchmark: ext vendor + $(PHP) -d extension=ext/modules/crc32c.so crc32_benchmark.php + +test: ext vendor + $(PHP) -v + $(PHP) -d extension=ext/modules/crc32c.so $(PHP_UNIT) tests/ + +# Test all the local versions of PHP +test_all: + for phpize in $$(ls $$(brew --prefix)/Cellar/php*/*/bin/phpize); do \ + NO_INTERACTION=1 \ + PHP_BIN=$$(dirname $$phpize) \ + $(MAKE) clean test; \ + done + +ext: ext/modules/crc32c.so + +ext_test: ext + NO_INTERACTION=1 $(MAKE) -C ext test + +ext/modules/crc32c.so: ext/hash_crc32c.c ext/php_crc32c.c ext/php_crc32c.h + cd ext && \ + ./install_crc32c.sh && \ + $(PHPIZE) && \ + ./configure \ + --with-php-config=$(PHP_CONFIG) && \ + $(MAKE) diff --git a/vendor/Gcp/google/crc32/README.md b/vendor/Gcp/google/crc32/README.md new file mode 100644 index 00000000..41b28bf1 --- /dev/null +++ b/vendor/Gcp/google/crc32/README.md @@ -0,0 +1,136 @@ +# php-crc32 + +[![Build Status](https://travis-ci.org/google/php-crc32.svg?branch=master)](https://travis-ci.org/google/php-crc32) + +by [Andrew Brampton](https://bramp.net) + +CRC32 implementations, that support all crc32 polynomials, as well as (if you +install the pecl extension) hardware accelerated versions of CRC32C (Castagnoli). + +Supports PHP 5.4 though PHP 7.4. + +# Usage + +```php +require 'vendor/autoload.php'; + +use Google\CRC32\CRC32; + +$crc = CRC32::create(CRC32::CASTAGNOLI); +$crc->update('hello'); +echo $crc->hash(); +``` + +Depending on the environment and the polynomial, `CRC32::create` will choose +the fastest available verison, and return one of the following classes: + +* `Google\CRC32\PHP` - A pure PHP implementation. +* `Google\CRC32\Builtin` - A [PHP Hash framework](http://php.net/manual/en/book.hash.php) implementation. +* `Google\CRC32\Google` - A hardware accelerated implementation (using [google/crc32c](https://github.com/google/crc32c)). + +When reading 1M byte chunks, using `CRC32::CASTAGNOLI` with PHP 7.4 on a 2014 Macbook Pro we get the following performance (higher is better): + +``` +Google\CRC32\PHP 12.27 MB/s +Google\CRC32\Builtin 468.74 MB/s (available since PHP 7.4) +Google\CRC32\Google 24,684.46 MB/s (using crc32c.so) +``` + +# Install + +```shell +$ composer require google/crc32 +``` + +# crc32c.so + +To use the hardware accelerated, a custom PHP extension must be installed. This makes use of [google/crc32c](https://github.com/google/crc32c) which provides a highly optomised `CRC32C` (Castagnoli) implementation using the SSE 4.2 instruction set of Intel CPUs. + +The extension can be installed from pecl, or compiled from stratch. + +```shell +TODO pecl install crc32c +``` + +Once installed or compiled, you'll need to add `extension=crc32c.so` to your php.ini file. + +## Compile (Linux / Mac) + +Ensure that [composer](https://getcomposer.org), build tools (e.g [build-essential](https://packages.debian.org/sid/devel/build-essential), [cmake](https://packages.debian.org/sid/devel/cmake), etc), and php dev headers (e.g [php-dev](https://packages.debian.org/sid/php/php-dev)) are installed. + +Simple (using Makefile): + +```shell +make test +``` + +Alternatively (manually): + +```shell +cd ext + +# Install the google/crc32c library +./install_crc32c.sh # From source (recommended) + +# or use your favorite package manager, e.g. +# brew install crc32c + +# Prepare the build environment +phpize +./configure + +# or if using a custom crc32c +# ./configure --with-crc32c=$(brew --prefix crc32c) + +## Build and test +make test +``` + +The extension will now be at `ext/modules/crc32c.so`. This file should be copied to your [extension directory](https://php.net/extension-dir) and reference in your php.ini. + +``` +# php.ini +extension=crc32c.so +``` + +## Testing + +`make test` will test with the current PHP. `make test_all` will search for available +PHP installs, and test with all of them. + +## Benchmark + +To compare the performance of the different `CRC32C` implementations, run `make benchmark`. + +# Related + +* https://bugs.php.net/bug.php?id=71890 + +# TODO + +- [ ] Test if this works on 32 bit machine. +- [x] Add php unit (or similar) testing. +- [x] Publish to packagist +- [ ] Publish to pecl (https://pecl.php.net/account-request.php) +- [x] Update instructions for linux. + + +# Licence (Apache 2) + +*This is not an official Google product (experimental or otherwise), it is just code that happens to be owned by Google.* + +``` +Copyright 2019 Google Inc. All Rights Reserved. + +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. +``` diff --git a/vendor/Gcp/google/crc32/composer.json b/vendor/Gcp/google/crc32/composer.json new file mode 100644 index 00000000..e9a2b39e --- /dev/null +++ b/vendor/Gcp/google/crc32/composer.json @@ -0,0 +1,26 @@ +{ + "name": "google\/crc32", + "description": "Various CRC32 implementations", + "homepage": "https:\/\/github.com\/google\/php-crc32", + "type": "library", + "license": "Apache-2.0", + "authors": [ + { + "name": "Andrew Brampton", + "email": "bramp@google.com" + } + ], + "require": { + "php": ">=5.4" + }, + "require-dev": { + "paragonie\/random_compat": ">=2", + "friendsofphp\/php-cs-fixer": "^1.13 || v2.14.2", + "phpunit\/phpunit": "^4" + }, + "autoload": { + "psr-4": { + "DeliciousBrains\\WP_Offload_Media\\Gcp\\Google\\CRC32\\": "src" + } + } +} \ No newline at end of file diff --git a/vendor/Gcp/google/crc32/crc32_benchmark.php b/vendor/Gcp/google/crc32/crc32_benchmark.php new file mode 100644 index 00000000..4817e017 --- /dev/null +++ b/vendor/Gcp/google/crc32/crc32_benchmark.php @@ -0,0 +1,96 @@ +update($chunk); + $i++; + $now = \microtime(\true); + $duration = $now - $start; + if ($duration >= \max_duration) { + break; + } + if ($duration >= \min_duration && $i >= \min_iterations) { + break; + } + } + // Very quick sanity check + if ($crc->hash() == '00000000') { + exit($name . ' crc check failed'); + } + $bytes = $i * $chunk_size; + echo \sprintf("%s\t%10d\t%5d\t%8.2f MB/s\n", $name, $chunk_size, $i, $bytes / ($now - $start) / 1000000); +} +foreach (array(256, 4096, 1048576, 16777216) as $chunk_size) { + \test(new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\PHP(\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::CASTAGNOLI), $chunk_size); + \test(new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\PHPSlicedBy4(\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::CASTAGNOLI), $chunk_size); + // Using IEEE, avoiding the CASTAGNOLI version crc32c.so adds. + \test(new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Builtin(\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::IEEE), $chunk_size); + \test(new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Google(), $chunk_size); +} diff --git a/vendor/Gcp/google/crc32/ext/config.m4 b/vendor/Gcp/google/crc32/ext/config.m4 new file mode 100644 index 00000000..c3d3d2e8 --- /dev/null +++ b/vendor/Gcp/google/crc32/ext/config.m4 @@ -0,0 +1,63 @@ +dnl Copyright 2019 Google Inc. All Rights Reserved. +dnl +dnl Licensed under the Apache License, Version 2.0 (the "License"); +dnl you may not use this file except in compliance with the License. +dnl You may obtain a copy of the License at +dnl +dnl http://www.apache.org/licenses/LICENSE-2.0 +dnl +dnl Unless required by applicable law or agreed to in writing, software +dnl distributed under the License is distributed on an "AS-IS" BASIS, +dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +dnl See the License for the specific language governing permissions and +dnl limitations under the License. +dnl + +PHP_ARG_WITH(crc32c, for crc32c support, +[ --with-crc32c[=DIR] Include crc32c support. File is the optional path to google/crc32c]) + +if test "$PHP_CRC32C" != "no"; then + PHP_REQUIRE_CXX() # The external crc32c library uses C++. + + if test -r $PHP_CRC32C/; then + SEARCH_PATH=$PHP_CRC32C + else + SEARCH_PATH="$PWD/crc32c/build /usr/local /usr" + fi + + + AC_MSG_CHECKING([for crc32c files]) + SEARCH_FOR="include/crc32c/crc32c.h" + + for i in $SEARCH_PATH ; do + if test -r $i/$SEARCH_FOR; then + CRC32C_DIR=$i + AC_MSG_RESULT(found in $i) + fi + done + + # --with-crc32c -> check with-path + if test -z "$CRC32C_DIR"; then + AC_MSG_RESULT([not found]) + AC_MSG_ERROR([Please install the google/crc32c package, and use --with-crc32c]) + fi + + # --with-crc32c -> add include path + PHP_ADD_INCLUDE($CRC32C_DIR/include) + + # --with-crc32c -> check for lib and symbol presence + LIBNAME=crc32c + LIBSYMBOL=crc32c_extend + + PHP_CHECK_LIBRARY($LIBNAME, $LIBSYMBOL, + [ + PHP_ADD_LIBRARY_WITH_PATH($LIBNAME, $CRC32C_DIR/$PHP_LIBDIR, CRC32C_SHARED_LIBADD) + ],[ + AC_MSG_FAILURE([wrong crc32c lib version or lib not found]) + ],[ + -L$CRC32C_DIR/$PHP_LIBDIR -lm + ]) + + PHP_SUBST(CRC32C_SHARED_LIBADD) + PHP_NEW_EXTENSION(crc32c, hash_crc32c.c php_crc32c.c, $ext_shared, , -Wall -Werror) +fi diff --git a/vendor/Gcp/google/crc32/ext/hash_crc32c.c b/vendor/Gcp/google/crc32/ext/hash_crc32c.c new file mode 100644 index 00000000..8483f799 --- /dev/null +++ b/vendor/Gcp/google/crc32/ext/hash_crc32c.c @@ -0,0 +1,63 @@ +/** + * Copyright 2019 Google Inc. All Rights Reserved. + * + * 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. + */ + +/** + * crc32c hash extension for PHP + * + * This file contains the crc32c hash function for + * http://php.net/manual/en/function.hash.php + */ +#include "php_crc32c.h" + +#include "ext/hash/php_hash.h" +#include "ext/hash/php_hash_crc32.h" + +#include "crc32c/crc32c.h" + +PHP_HASH_API void CRC32CInit(PHP_CRC32_CTX *context) +{ + context->state = 0; +} + +PHP_HASH_API void CRC32CUpdate(PHP_CRC32_CTX *context, const unsigned char *input, size_t len) +{ + context->state = crc32c_extend(context->state, input, len); +} + +PHP_HASH_API void CRC32CFinal(uint8_t crc[4], PHP_CRC32_CTX *context) +{ + int2byte(context->state, crc); + context->state = 0; +} + +PHP_HASH_API int CRC32CCopy(const php_hash_ops *ops, PHP_CRC32_CTX *orig_context, PHP_CRC32_CTX *copy_context) +{ + copy_context->state = orig_context->state; + return SUCCESS; +} + +const php_hash_ops crc32_ops = { + (php_hash_init_func_t) CRC32CInit, + (php_hash_update_func_t) CRC32CUpdate, + (php_hash_final_func_t) CRC32CFinal, + (php_hash_copy_func_t) CRC32CCopy, + 4, /* what to say here? */ + 4, + sizeof(PHP_CRC32_CTX), +#if PHP_API_VERSION >= 20170718 + 0 +#endif +}; \ No newline at end of file diff --git a/vendor/Gcp/google/crc32/ext/install_crc32c.sh b/vendor/Gcp/google/crc32/ext/install_crc32c.sh new file mode 100644 index 00000000..96b27c52 --- /dev/null +++ b/vendor/Gcp/google/crc32/ext/install_crc32c.sh @@ -0,0 +1,34 @@ +#!/bin/sh +# Used to build and install the google/crc32c library. + +## +# Copyright 2019 Google Inc. All Rights Reserved. +# +# 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. +## + +git clone https://github.com/google/crc32c + +cd crc32c +git submodule update --init --recursive + +mkdir build +cd build +cmake -DCRC32C_BUILD_TESTS=0 \ + -DCRC32C_BUILD_BENCHMARKS=0 \ + -DCRC32C_USE_GLOG=0 \ + -DBUILD_SHARED_LIBS=0 \ + -DCMAKE_POSITION_INDEPENDENT_CODE=TRUE \ + -DCMAKE_INSTALL_PREFIX:PATH=$PWD \ + .. +cmake --build . --target install diff --git a/vendor/Gcp/google/crc32/ext/php_crc32c.c b/vendor/Gcp/google/crc32/ext/php_crc32c.c new file mode 100644 index 00000000..ba08657b --- /dev/null +++ b/vendor/Gcp/google/crc32/ext/php_crc32c.c @@ -0,0 +1,174 @@ +/** + * Copyright 2019 Google Inc. All Rights Reserved. + * + * 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. + */ + +/** + * crc32c extension for PHP + * + * This file sets up the crc32c module, and provide the 'crc32c' function. + */ + +#include "php_crc32c.h" + +#include "ext/hash/php_hash.h" +#include "ext/standard/info.h" + +#include "crc32c/crc32c.h" + +extern const php_hash_ops crc32_ops; + +static uint32_t byte2int(const uint8_t hash[4]) { + return (hash[0] << 24) | (hash[1] << 16) | (hash[2] << 8) | hash[3]; +} + +/* {{{ int crc32c( string $data [, int $crc ] ) + */ +PHP_FUNCTION(crc32c) +{ + char *data_arg = NULL; + size_t data_len = 0; + char *crc_arg = NULL; + size_t crc_len = 0; + +#if PHP_API_VERSION >= 20151012 /* >= PHP 7.0 */ + // fast_zpp is a faster way to parse paramters. + ZEND_PARSE_PARAMETERS_START(1, 2) + Z_PARAM_STRING(data_arg, data_len) + Z_PARAM_OPTIONAL + Z_PARAM_STRING_EX(crc_arg, crc_len, /* check_null */ 1, 0) + ZEND_PARSE_PARAMETERS_END_EX(RETURN_FALSE); +#else + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s!", &data_arg, &data_len, &crc_arg, &crc_len) == FAILURE) { + RETURN_BOOL(false); + } +#endif + + uint32_t crc = 0; + + if (crc_len == 4) { + crc = byte2int((uint8_t *)crc_arg); + + } else if (crc_arg != NULL) { + zend_error(E_WARNING, "crc32c(): Supplied crc must be a 4 byte string"); + RETURN_BOOL(false); + } + + crc = crc32c_extend(crc, (const uint8_t *)data_arg, data_len); + + uint8_t hash[4]; + int2byte(crc, hash); + +#if PHP_API_VERSION >= 20151012 /* >= PHP 7.0 */ + RETURN_STRINGL((const char *)hash, sizeof(hash)); +#else + RETURN_STRINGL((const char *)hash, sizeof(hash), /* dup */ 1); +#endif +} +/* }}}*/ + + +/* {{{ PHP_RINIT_FUNCTION + */ +PHP_RINIT_FUNCTION(crc32c) +{ +#if PHP_VERSION_ID >= 70000 +# if defined(ZTS) && defined(COMPILE_DL_CRC32C) + ZEND_TSRMLS_CACHE_UPDATE(); +# endif +#endif + + return SUCCESS; +} +/* }}} */ + +/* {{{ PHP_MINIT_FUNCTION + */ +PHP_MINIT_FUNCTION(crc32c) +{ + php_hash_register_algo("crc32c", &crc32_ops); + return SUCCESS; +} +/* }}} */ + +/* {{{ PHP_MSHUTDOWN_FUNCTION + */ +PHP_MSHUTDOWN_FUNCTION(crc32c) +{ + // TODO Unregister php_hash_register_algo + return SUCCESS; +} +/* }}} */ + +/* {{{ PHP_MINFO_FUNCTION + */ +PHP_MINFO_FUNCTION(crc32c) +{ + php_info_print_table_start(); + php_info_print_table_header(2, "Google CRC32C support", "enabled"); + php_info_print_table_end(); +} +/* }}} */ + +/* {{{ arginfo + */ +ZEND_BEGIN_ARG_INFO_EX(arginfo_crc32c, 0, 0, 1) + ZEND_ARG_INFO(0, str) + ZEND_ARG_INFO(0, crc) +ZEND_END_ARG_INFO() +/* }}} */ + +/* {{{ crc32c_functions[] + */ +static const zend_function_entry crc32c_functions[] = { + PHP_FE(crc32c, arginfo_crc32c) + PHP_FE_END +}; +/* }}} */ + +/* {{{ crc32c_deps + */ +static const zend_module_dep crc32c_deps[] = { + ZEND_MOD_REQUIRED("hash") + ZEND_MOD_END +}; +/* }}} */ + +/* {{{ crc32c_module_entry + */ +zend_module_entry crc32c_module_entry = { + STANDARD_MODULE_HEADER_EX, NULL, + crc32c_deps, /* Module dependencies */ + "crc32c", /* Extension name */ + crc32c_functions, /* zend_function_entry */ + PHP_MINIT(crc32c), /* PHP_MINIT - Module initialization */ + PHP_MSHUTDOWN(crc32c), /* PHP_MSHUTDOWN - Module shutdown */ + PHP_RINIT(crc32c), /* PHP_RINIT - Request initialization */ + NULL, /* PHP_RSHUTDOWN - Request shutdown */ + PHP_MINFO(crc32c), /* PHP_MINFO - Module info */ + PHP_CRC32C_VERSION, /* Version */ + STANDARD_MODULE_PROPERTIES +}; +/* }}} */ + +#ifdef COMPILE_DL_CRC32C + +# if PHP_VERSION_ID >= 70000 +# ifdef ZTS +ZEND_TSRMLS_CACHE_DEFINE() +# endif +# endif /* PHP_VERSION_ID >= 70000 */ + +ZEND_GET_MODULE(crc32c) +#endif /* COMPILE_DL_CRC32C */ diff --git a/vendor/Gcp/google/crc32/ext/php_crc32c.h b/vendor/Gcp/google/crc32/ext/php_crc32c.h new file mode 100644 index 00000000..661d79f2 --- /dev/null +++ b/vendor/Gcp/google/crc32/ext/php_crc32c.h @@ -0,0 +1,53 @@ +/** + * Copyright 2019 Google Inc. All Rights Reserved. + * + * 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. + */ + +/** + * crc32c extension for PHP + */ +#ifndef PHP_CRC32C_H +# define PHP_CRC32C_H + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include "php.h" + +#include +#include + +#ifdef ZTS +# include "TSRM.h" +#endif + +extern zend_module_entry crc32c_module_entry; + +# define PHP_CRC32C_VERSION "1.0.0" + +# if PHP_VERSION_ID >= 70000 +# if defined(ZTS) && defined(COMPILE_DL_CRC32C) +ZEND_TSRMLS_CACHE_EXTERN() +# endif +# endif + +static void int2byte(uint32_t i, uint8_t b[4]) { + b[0] = (uint8_t) ((i >> 24) & 0xff); + b[1] = (uint8_t) ((i >> 16) & 0xff); + b[2] = (uint8_t) ((i >> 8) & 0xff); + b[3] = (uint8_t) (i & 0xff); +} + +#endif /* PHP_CRC32C_H */ diff --git a/vendor/Gcp/google/crc32/src/Builtin.php b/vendor/Gcp/google/crc32/src/Builtin.php new file mode 100644 index 00000000..ab88beb4 --- /dev/null +++ b/vendor/Gcp/google/crc32/src/Builtin.php @@ -0,0 +1,74 @@ + 'crc32b', \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\CRC32::CASTAGNOLI => 'crc32c']; + /** + * Returns true if this $polynomial is supported by the builtin PHP hash function. + * + * @param integer $polynomial The polynomial + * + * @return boolean + */ + public static function supports($polynomial) + { + if (!isset(self::$mapping[$polynomial])) { + return false; + } + $algo = self::$mapping[$polynomial]; + return in_array($algo, hash_algos()); + } + public function __construct($polynomial) + { + if (!self::supports($polynomial)) { + throw new \InvalidArgumentException("hash_algos() does not list this polynomial."); + } + $this->algo = self::$mapping[$polynomial]; + $this->reset(); + } + public function reset() + { + $this->hc = hash_init($this->algo); + } + public function update($data) + { + hash_update($this->hc, $data); + } + public function hash($raw_output = null) + { + // hash_final will destory the Hash Context resource, so operate on a copy. + $hc = hash_copy($this->hc); + return hash_final($hc, $raw_output); + } + public function version() + { + return $this->algo . ' PHP HASH'; + } + public function __clone() + { + $this->hc = hash_copy($this->hc); + } +} diff --git a/vendor/Gcp/google/crc32/src/CRC32.php b/vendor/Gcp/google/crc32/src/CRC32.php new file mode 100644 index 00000000..58e10785 --- /dev/null +++ b/vendor/Gcp/google/crc32/src/CRC32.php @@ -0,0 +1,97 @@ +update('hello'); + * + * echo $crc->hash(); + * ``` + */ +class CRC32 +{ + use CRCTrait; + /** + * IEEE polynomial as used by ethernet (IEEE 802.3), v.42, fddi, gzip, + * zip, png, ... + */ + const IEEE = 0xedb88320; + /** + * Castagnoli's polynomial, used in iSCSI, SCTP, Google Cloud Storage, + * Apache Kafka, and has hardware-accelerated in modern intel CPUs. + * https://doi.org/10.1109/26.231911 + */ + const CASTAGNOLI = 0x82f63b78; + /** + * Koopman's polynomial. + * https://doi.org/10.1109/DSN.2002.1028931 + */ + const KOOPMAN = 0xeb31d82e; + /** + * The size of the checksum in bytes. + */ + const SIZE = 4; + private static $mapping = [self::IEEE => 'IEEE', self::CASTAGNOLI => 'Castagnoli', self::KOOPMAN => 'Koopman']; + private function __construct() + { + // Prevent instantiation. + } + /** + * Returns the best CRC implementation available on this machine. + * + * @param integer $polynomial The CRC polynomial. Use a 32-bit number, + * or one of the supplied constants, CRC32::IEEE, + * CRC32::CASTAGNOLI, or CRC32::KOOPMAN. + * + * @return CRC32Interface + */ + public static function create($polynomial) + { + if (\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Google::supports($polynomial) && function_exists('crc32c')) { + return new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Google(); + } + if (\DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Builtin::supports($polynomial)) { + return new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Builtin($polynomial); + } + // Fallback to the pure PHP version + return new \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\PHP($polynomial); + } + /** + * Prints the human friendly name for this polynomial. + * + * @param integer $polynomial The CRC polynomial. + * + * @return string + */ + public static function string($polynomial) + { + if (isset(self::$mapping[$polynomial])) { + return self::$mapping[$polynomial]; + } + return '0x' . self::int2hex($polynomial); + } +} diff --git a/vendor/Gcp/google/crc32/src/CRCInterface.php b/vendor/Gcp/google/crc32/src/CRCInterface.php new file mode 100644 index 00000000..81b09e8a --- /dev/null +++ b/vendor/Gcp/google/crc32/src/CRCInterface.php @@ -0,0 +1,56 @@ +reset(); + } + public function reset() + { + $this->crc = hex2bin('00000000'); + } + public function update($data) + { + $this->crc = crc32c($data, $this->crc); + } + public function hash($raw_output = null) + { + if ($raw_output === true) { + return $this->crc; + } + return bin2hex($this->crc); + } + public function version() + { + return 'Hardware accelerated (https://github.com/google/crc32c)'; + } +} diff --git a/vendor/Gcp/google/crc32/src/PHP.php b/vendor/Gcp/google/crc32/src/PHP.php new file mode 100644 index 00000000..0b2ff882 --- /dev/null +++ b/vendor/Gcp/google/crc32/src/PHP.php @@ -0,0 +1,69 @@ +polynomial = $polynomial; + $this->table = \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Table::get($polynomial); + $this->reset(); + } + public function reset() + { + $this->crc = ~0; + } + public function update($data) + { + $crc = $this->crc; + $table = $this->table; + $len = strlen($data); + for ($i = 0; $i < $len; ++$i) { + $crc = $crc >> 8 & 0xffffff ^ $table[($crc ^ ord($data[$i])) & 0xff]; + } + $this->crc = $crc; + } + public function hash($raw_output = null) + { + return $this->crcHash(~$this->crc, $raw_output === true); + } + public function version() + { + return 'crc32(' . $this->int2hex($this->polynomial) . ') software version'; + } +} diff --git a/vendor/Gcp/google/crc32/src/PHPSlicedBy4.php b/vendor/Gcp/google/crc32/src/PHPSlicedBy4.php new file mode 100644 index 00000000..29d74c48 --- /dev/null +++ b/vendor/Gcp/google/crc32/src/PHPSlicedBy4.php @@ -0,0 +1,87 @@ +polynomial = $polynomial; + $this->table = \DeliciousBrains\WP_Offload_Media\Gcp\Google\CRC32\Table::create4($polynomial); + $this->reset(); + } + public function reset() + { + $this->crc = ~0; + } + public function update($data) + { + $crc = $this->crc; + $table0 = $this->table[0]; + $table1 = $this->table[1]; + $table2 = $this->table[2]; + $table3 = $this->table[3]; + $len = strlen($data); + $remain = $len % 4; + $len1 = $len - $remain; + for ($i = 0; $i < $len1; $i += 4) { + $b = ord($data[$i + 3]) << 24 | ord($data[$i + 2]) << 16 | ord($data[$i + 1]) << 8 | ord($data[$i]); + $crc = ($crc ^ $b) & 0xffffffff; + $crc = $table3[$crc & 0xff] ^ $table2[$crc >> 8 & 0xff] ^ $table1[$crc >> 16 & 0xff] ^ $table0[$crc >> 24 & 0xff]; + } + switch ($remain) { + case 3: + $crc = $crc >> 8 & 0xffffff ^ $table0[($crc ^ ord($data[$i])) & 0xff]; + $crc = $crc >> 8 & 0xffffff ^ $table0[($crc ^ ord($data[$i + 1])) & 0xff]; + $crc = $crc >> 8 & 0xffffff ^ $table0[($crc ^ ord($data[$i + 2])) & 0xff]; + break; + case 2: + $crc = $crc >> 8 & 0xffffff ^ $table0[($crc ^ ord($data[$i])) & 0xff]; + $crc = $crc >> 8 & 0xffffff ^ $table0[($crc ^ ord($data[$i + 1])) & 0xff]; + break; + case 1: + $crc = $crc >> 8 & 0xffffff ^ $table0[($crc ^ ord($data[$i])) & 0xff]; + break; + case 0: + } + $this->crc = $crc; + } + public function hash($raw_output = null) + { + return $this->crcHash(~$this->crc, $raw_output === true); + } + public function version() + { + return 'crc32(' . $this->int2hex($this->polynomial) . ') software version'; + } +} diff --git a/vendor/Gcp/google/crc32/src/Table.php b/vendor/Gcp/google/crc32/src/Table.php new file mode 100644 index 00000000..e4f18d61 --- /dev/null +++ b/vendor/Gcp/google/crc32/src/Table.php @@ -0,0 +1,104 @@ + $value) { + echo "0x" . int2hex($value) . ","; + if ($i % 4 == 3) { + echo "\n"; + } else { + echo " "; + } + } + echo "\n\n"; + } + /** + * Gets a CRC table, by creating it, or using a previously cached result. + * + * @param integer $polynomial The polynomial + * + * @return array The table + */ + public static function get($polynomial) + { + if (isset(self::$tables[$polynomial])) { + return self::$tables[$polynomial]; + } + self::$tables[$polynomial] = self::create($polynomial); + return self::$tables[$polynomial]; + } + /** + * Create a CRC table. + * + * @param integer $polynomial The polynomial. + * + * @return array The table. + */ + public static function create($polynomial) + { + $table = array_fill(0, 256, 0); + for ($i = 0; $i < 256; $i++) { + $crc = $i; + for ($j = 0; $j < 8; $j++) { + if ($crc & 1 == 1) { + $crc = $crc >> 1 ^ $polynomial; + } else { + $crc >>= 1; + } + } + $table[$i] = $crc; + } + return $table; + } + /** + * Create a CRC table sliced by 4. + * + * @param integer $polynomial The polynomial. + * + * @return array The table. + */ + public static function create4($polynomial) + { + $table = array_fill(0, 4, array_fill(0, 256, 0)); + $table[0] = self::create($polynomial); + for ($i = 0; $i < 256; $i++) { + // for Slicing-by-4 and Slicing-by-8 + $table[1][$i] = $table[0][$i] >> 8 ^ $table[0][$table[0][$i] & 0xff]; + $table[2][$i] = $table[1][$i] >> 8 ^ $table[0][$table[1][$i] & 0xff]; + $table[3][$i] = $table[2][$i] >> 8 ^ $table[0][$table[2][$i] & 0xff]; + /* + // only Slicing-by-8 + $table[4][$i] = ($table[3][$i] >> 8) ^ $table[0][$table[3][$i] & 0xFF]; + $table[5][$i] = ($table[4][$i] >> 8) ^ $table[0][$table[4][$i] & 0xFF]; + $table[6][$i] = ($table[5][$i] >> 8) ^ $table[0][$table[5][$i] & 0xFF]; + $table[7][$i] = ($table[6][$i] >> 8) ^ $table[0][$table[6][$i] & 0xFF]; + */ + } + return $table; + } +} diff --git a/vendor/Gcp/guzzlehttp/guzzle/CHANGELOG.md b/vendor/Gcp/guzzlehttp/guzzle/CHANGELOG.md index 17badd75..65557498 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/CHANGELOG.md +++ b/vendor/Gcp/guzzlehttp/guzzle/CHANGELOG.md @@ -1,5 +1,22 @@ # Change Log +## 6.4.1 - 2019-10-23 + +* No `guzzle.phar` was created in 6.4.0 due expired API token. This release will fix that +* Added `parent::__construct()` to `FileCookieJar` and `SessionCookieJar` + +## 6.4.0 - 2019-10-23 + +* Improvement: Improved error messages when using curl < 7.21.2 [#2108](https://github.com/guzzle/guzzle/pull/2108) +* Fix: Test if response is readable before returning a summary in `RequestException::getResponseBodySummary()` [#2081](https://github.com/guzzle/guzzle/pull/2081) +* Fix: Add support for GUZZLE_CURL_SELECT_TIMEOUT environment variable [#2161](https://github.com/guzzle/guzzle/pull/2161) +* Improvement: Added `GuzzleHttp\Exception\InvalidArgumentException` [#2163](https://github.com/guzzle/guzzle/pull/2163) +* Improvement: Added `GuzzleHttp\_current_time()` to use `hrtime()` if that function exists. [#2242](https://github.com/guzzle/guzzle/pull/2242) +* Improvement: Added curl's `appconnect_time` in `TransferStats` [#2284](https://github.com/guzzle/guzzle/pull/2284) +* Improvement: Make GuzzleException extend Throwable wherever it's available [#2273](https://github.com/guzzle/guzzle/pull/2273) +* Fix: Prevent concurrent writes to file when saving `CookieJar` [#2335](https://github.com/guzzle/guzzle/pull/2335) +* Improvement: Update `MockHandler` so we can test transfer time [#2362](https://github.com/guzzle/guzzle/pull/2362) + ## 6.3.3 - 2018-04-22 * Fix: Default headers when decode_content is specified diff --git a/vendor/Gcp/guzzlehttp/guzzle/Dockerfile b/vendor/Gcp/guzzlehttp/guzzle/Dockerfile new file mode 100644 index 00000000..f6a09523 --- /dev/null +++ b/vendor/Gcp/guzzlehttp/guzzle/Dockerfile @@ -0,0 +1,18 @@ +FROM composer:latest as setup + +RUN mkdir /guzzle + +WORKDIR /guzzle + +RUN set -xe \ + && composer init --name=guzzlehttp/test --description="Simple project for testing Guzzle scripts" --author="Márk Sági-Kazár " --no-interaction \ + && composer require guzzlehttp/guzzle + + +FROM php:7.3 + +RUN mkdir /guzzle + +WORKDIR /guzzle + +COPY --from=setup /guzzle /guzzle diff --git a/vendor/Gcp/guzzlehttp/guzzle/README.md b/vendor/Gcp/guzzlehttp/guzzle/README.md index bcd18b8e..a5ef18ae 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/README.md +++ b/vendor/Gcp/guzzlehttp/guzzle/README.md @@ -21,19 +21,18 @@ trivial to integrate with web services. ```php $client = new \GuzzleHttp\Client(); -$res = $client->request('GET', 'https://api.github.com/repos/guzzle/guzzle'); -echo $res->getStatusCode(); -// 200 -echo $res->getHeaderLine('content-type'); -// 'application/json; charset=utf8' -echo $res->getBody(); -// '{"id": 1420053, "name": "guzzle", ...}' - -// Send an asynchronous request. +$response = $client->request('GET', 'https://api.github.com/repos/guzzle/guzzle'); + +echo $response->getStatusCode(); # 200 +echo $response->getHeaderLine('content-type'); # 'application/json; charset=utf8' +echo $response->getBody(); # '{"id": 1420053, "name": "guzzle", ...}' + +# Send an asynchronous request. $request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org'); $promise = $client->sendAsync($request)->then(function ($response) { echo 'I completed! ' . $response->getBody(); }); + $promise->wait(); ``` @@ -57,7 +56,7 @@ curl -sS https://getcomposer.org/installer | php Next, run the Composer command to install the latest stable version of Guzzle: ```bash -php composer.phar require guzzlehttp/guzzle +composer require guzzlehttp/guzzle ``` After installing, you need to require Composer's autoloader: @@ -69,7 +68,7 @@ require 'vendor/autoload.php'; You can then later update Guzzle using composer: ```bash -composer.phar update +composer update ``` @@ -86,6 +85,6 @@ composer.phar update [guzzle-4-repo]: https://github.com/guzzle/guzzle/tree/4.x [guzzle-5-repo]: https://github.com/guzzle/guzzle/tree/5.3 [guzzle-6-repo]: https://github.com/guzzle/guzzle -[guzzle-3-docs]: http://guzzle3.readthedocs.org/en/latest/ +[guzzle-3-docs]: http://guzzle3.readthedocs.org [guzzle-5-docs]: http://guzzle.readthedocs.org/en/5.3/ [guzzle-6-docs]: http://guzzle.readthedocs.org/en/latest/ diff --git a/vendor/Gcp/guzzlehttp/guzzle/composer.json b/vendor/Gcp/guzzlehttp/guzzle/composer.json index 0ff7117a..d154cf91 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/composer.json +++ b/vendor/Gcp/guzzlehttp/guzzle/composer.json @@ -22,33 +22,37 @@ ], "require": { "php": ">=5.5", - "guzzlehttp\/psr7": "^1.4", - "guzzlehttp\/promises": "^1.0" + "ext-json": "*", + "guzzlehttp\/promises": "^1.0", + "guzzlehttp\/psr7": "^1.6.1" }, "require-dev": { "ext-curl": "*", "phpunit\/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr\/log": "^1.0" + "psr\/log": "^1.1" + }, + "suggest": { + "psr\/log": "Required for using the Log middleware" + }, + "config": { + "sort-packages": true + }, + "extra": { + "branch-alias": { + "dev-master": "6.3-dev" + } }, "autoload": { - "files": [ - "src\/functions_include.php" - ], "psr-4": { "DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\": "src\/" - } + }, + "files": [ + "src\/functions_include.php" + ] }, "autoload-dev": { "psr-4": { "DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Tests\\": "tests\/" } - }, - "suggest": { - "psr\/log": "Required for using the Log middleware" - }, - "extra": { - "branch-alias": { - "dev-master": "6.3-dev" - } } } \ No newline at end of file diff --git a/vendor/Gcp/guzzlehttp/guzzle/phpstan.neon.dist b/vendor/Gcp/guzzlehttp/guzzle/phpstan.neon.dist new file mode 100644 index 00000000..4ef4192d --- /dev/null +++ b/vendor/Gcp/guzzlehttp/guzzle/phpstan.neon.dist @@ -0,0 +1,9 @@ +parameters: + level: 1 + paths: + - src + + ignoreErrors: + - + message: '#Function uri_template not found#' + path: %currentWorkingDirectory%/src/functions.php diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Client.php b/vendor/Gcp/guzzlehttp/guzzle/src/Client.php index f3104ac6..b8f86eef 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Client.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Client.php @@ -172,7 +172,7 @@ private function configureDefaults(array $config) * * @return array */ - private function prepareDefaults($options) + private function prepareDefaults(array $options) { $defaults = $this->config; if (!empty($defaults['headers'])) { diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/ClientInterface.php b/vendor/Gcp/guzzlehttp/guzzle/src/ClientInterface.php index 0c837319..1b713cd9 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/ClientInterface.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/ClientInterface.php @@ -12,7 +12,7 @@ */ interface ClientInterface { - const VERSION = '6.3.3'; + const VERSION = '6.4.1'; /** * Send an HTTP request. * diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/CookieJar.php b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/CookieJar.php index 763493e3..3af2fa47 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/CookieJar.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/CookieJar.php @@ -100,7 +100,7 @@ public function clear($domain = null, $path = null, $name = null) $this->cookies = []; return; } elseif (!$path) { - $this->cookies = array_filter($this->cookies, function (\DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Cookie\SetCookie $cookie) use($path, $domain) { + $this->cookies = array_filter($this->cookies, function (\DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Cookie\SetCookie $cookie) use($domain) { return !$cookie->matchesDomain($domain); }); } elseif (!$name) { diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php index 3de270f8..31f54ee6 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php @@ -22,6 +22,7 @@ class FileCookieJar extends \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Coo */ public function __construct($cookieFile, $storeSessionCookies = false) { + parent::__construct(); $this->filename = $cookieFile; $this->storeSessionCookies = $storeSessionCookies; if (file_exists($cookieFile)) { @@ -51,7 +52,7 @@ public function save($filename) } } $jsonStr = \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\json_encode($json); - if (false === file_put_contents($filename, $jsonStr)) { + if (false === file_put_contents($filename, $jsonStr, LOCK_EX)) { throw new \RuntimeException("Unable to save file {$filename}"); } } diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php index 222ea4d2..31035ef5 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php @@ -21,6 +21,7 @@ class SessionCookieJar extends \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\ */ public function __construct($sessionKey, $storeSessionCookies = false) { + parent::__construct(); $this->sessionKey = $sessionKey; $this->storeSessionCookies = $storeSessionCookies; $this->load(); diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SetCookie.php b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SetCookie.php index 42f1b459..04e657d0 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SetCookie.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Cookie/SetCookie.php @@ -192,7 +192,7 @@ public function setExpires($timestamp) /** * Get whether or not this is a secure cookie * - * @return null|bool + * @return bool|null */ public function getSecure() { @@ -210,7 +210,7 @@ public function setSecure($secure) /** * Get whether or not this is a session cookie * - * @return null|bool + * @return bool|null */ public function getDiscard() { diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Exception/GuzzleException.php b/vendor/Gcp/guzzlehttp/guzzle/src/Exception/GuzzleException.php index ec960b85..30799178 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Exception/GuzzleException.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Exception/GuzzleException.php @@ -2,15 +2,22 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception; -/** - * @method string getMessage() - * @method \Throwable|null getPrevious() - * @method mixed getCode() - * @method string getFile() - * @method int getLine() - * @method array getTrace() - * @method string getTraceAsString() - */ -interface GuzzleException -{ +use Throwable; +if (interface_exists(\Throwable::class)) { + interface GuzzleException extends Throwable + { + } +} else { + /** + * @method string getMessage() + * @method \Throwable|null getPrevious() + * @method mixed getCode() + * @method string getFile() + * @method int getLine() + * @method array getTrace() + * @method string getTraceAsString() + */ + interface GuzzleException + { + } } diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php b/vendor/Gcp/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php new file mode 100644 index 00000000..719b34e9 --- /dev/null +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php @@ -0,0 +1,7 @@ +getBody(); - if (!$body->isSeekable()) { + if (!$body->isSeekable() || !$body->isReadable()) { return null; } $size = $body->getSize(); diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlFactory.php b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlFactory.php index b0f53cb5..21ec49ec 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlFactory.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlFactory.php @@ -14,6 +14,8 @@ */ class CurlFactory implements \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Handler\CurlFactoryInterface { + const CURL_VERSION_STR = 'curl_version'; + const LOW_CURL_VERSION_NUMBER = '7.21.2'; /** @var array */ private $handles = []; /** @var int Total number of idle handles to keep in cache */ @@ -97,13 +99,15 @@ public static function finish(callable $handler, \DeliciousBrains\WP_Offload_Med private static function invokeStats(\DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Handler\EasyHandle $easy) { $curlStats = curl_getinfo($easy->handle); + $curlStats['appconnect_time'] = curl_getinfo($easy->handle, CURLINFO_APPCONNECT_TIME); $stats = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\TransferStats($easy->request, $easy->response, $curlStats['total_time'], $easy->errno, $curlStats); call_user_func($easy->options['on_stats'], $stats); } private static function finishError(callable $handler, \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Handler\EasyHandle $easy, \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Handler\CurlFactoryInterface $factory) { // Get error information and release the handle to the factory. - $ctx = ['errno' => $easy->errno, 'error' => curl_error($easy->handle)] + curl_getinfo($easy->handle); + $ctx = ['errno' => $easy->errno, 'error' => curl_error($easy->handle), 'appconnect_time' => curl_getinfo($easy->handle, CURLINFO_APPCONNECT_TIME)] + curl_getinfo($easy->handle); + $ctx[self::CURL_VERSION_STR] = curl_version()['version']; $factory->release($easy); // Retry when nothing is present or when curl failed to rewind. if (empty($easy->options['_err_message']) && (!$easy->errno || $easy->errno == 65)) { @@ -119,7 +123,11 @@ private static function createRejection(\DeliciousBrains\WP_Offload_Media\Gcp\Gu if ($easy->onHeadersException) { return \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Promise\rejection_for(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\RequestException('An error was encountered during the on_headers event', $easy->request, $easy->response, $easy->onHeadersException, $ctx)); } - $message = sprintf('cURL error %s: %s (%s)', $ctx['errno'], $ctx['error'], 'see http://curl.haxx.se/libcurl/c/libcurl-errors.html'); + if (version_compare($ctx[self::CURL_VERSION_STR], self::LOW_CURL_VERSION_NUMBER)) { + $message = sprintf('cURL error %s: %s (%s)', $ctx['errno'], $ctx['error'], 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html'); + } else { + $message = sprintf('cURL error %s: %s (%s) for %s', $ctx['errno'], $ctx['error'], 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html', $easy->request->getUri()); + } // Create a connection exception if it was a specific error code. $error = isset($connectionErrors[$easy->errno]) ? new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\ConnectException($message, $easy->request, null, $ctx) : new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\RequestException($message, $easy->request, $easy->response, null, $ctx); return \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Promise\rejection_for($error); diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php index 08f30463..c1c6c2c5 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php @@ -35,7 +35,13 @@ class CurlMultiHandler public function __construct(array $options = []) { $this->factory = isset($options['handle_factory']) ? $options['handle_factory'] : new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Handler\CurlFactory(50); - $this->selectTimeout = isset($options['select_timeout']) ? $options['select_timeout'] : 1; + if (isset($options['select_timeout'])) { + $this->selectTimeout = $options['select_timeout']; + } elseif ($selectTimeout = getenv('GUZZLE_CURL_SELECT_TIMEOUT')) { + $this->selectTimeout = $selectTimeout; + } else { + $this->selectTimeout = 1; + } } public function __get($name) { @@ -68,7 +74,7 @@ public function tick() { // Add any delayed handles if needed. if ($this->delays) { - $currentTime = microtime(true); + $currentTime = \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\_current_time(); foreach ($this->delays as $id => $delay) { if ($currentTime >= $delay) { unset($this->delays[$id]); @@ -109,7 +115,7 @@ private function addRequest(array $entry) if (empty($easy->options['delay'])) { curl_multi_add_handle($this->_mh, $easy->handle); } else { - $this->delays[$id] = microtime(true) + $easy->options['delay'] / 1000; + $this->delays[$id] = \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\_current_time() + $easy->options['delay'] / 1000; } } /** @@ -148,7 +154,7 @@ private function processMessages() } private function timeToNext() { - $currentTime = microtime(true); + $currentTime = \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\_current_time(); $nextTime = PHP_INT_MAX; foreach ($this->delays as $time) { if ($time < $nextTime) { diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/MockHandler.php b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/MockHandler.php index 91862a06..d8e2883c 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/MockHandler.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/MockHandler.php @@ -145,7 +145,8 @@ public function count() private function invokeStats(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\RequestInterface $request, array $options, \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface $response = null, $reason = null) { if (isset($options['on_stats'])) { - $stats = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\TransferStats($request, $response, 0, $reason); + $transferTime = isset($options['transfer_time']) ? $options['transfer_time'] : 0; + $stats = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\TransferStats($request, $response, $transferTime, $reason); call_user_func($options['on_stats'], $stats); } } diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/StreamHandler.php b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/StreamHandler.php index e62e1e78..ce5d6052 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Handler/StreamHandler.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Handler/StreamHandler.php @@ -31,14 +31,14 @@ public function __invoke(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ if (isset($options['delay'])) { usleep($options['delay'] * 1000); } - $startTime = isset($options['on_stats']) ? microtime(true) : null; + $startTime = isset($options['on_stats']) ? \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\_current_time() : null; try { // Does not support the expect header. $request = $request->withoutHeader('Expect'); // Append a content-length header if body size is zero to match // cURL's behavior. if (0 === $request->getBody()->getSize()) { - $request = $request->withHeader('Content-Length', 0); + $request = $request->withHeader('Content-Length', '0'); } return $this->createResponse($request, $options, $this->createStream($request, $options), $startTime); } catch (\InvalidArgumentException $e) { @@ -58,7 +58,7 @@ public function __invoke(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ private function invokeStats(array $options, \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\RequestInterface $request, $startTime, \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface $response = null, $error = null) { if (isset($options['on_stats'])) { - $stats = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\TransferStats($request, $response, microtime(true) - $startTime, $error, []); + $stats = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\TransferStats($request, $response, \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\_current_time() - $startTime, $error, []); call_user_func($options['on_stats'], $stats); } } diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/HandlerStack.php b/vendor/Gcp/guzzlehttp/guzzle/src/HandlerStack.php index ab872742..797859cc 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/HandlerStack.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/HandlerStack.php @@ -180,7 +180,7 @@ public function resolve() return $this->cached; } /** - * @param $name + * @param string $name * @return int */ private function findByName($name) @@ -195,10 +195,10 @@ private function findByName($name) /** * Splices a function into the middleware list at a specific position. * - * @param $findName - * @param $withName + * @param string $findName + * @param string $withName * @param callable $middleware - * @param $before + * @param bool $before */ private function splice($findName, $withName, callable $middleware, $before) { diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Middleware.php b/vendor/Gcp/guzzlehttp/guzzle/src/Middleware.php index d3cd3fc3..ccca064c 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Middleware.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Middleware.php @@ -8,7 +8,6 @@ use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7; use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface; use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Log\LoggerInterface; -use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Log\LogLevel; /** * Functions used to create and wrap handlers with handler middleware. */ @@ -53,7 +52,7 @@ public static function httpErrors() if (empty($options['http_errors'])) { return $handler($request, $options); } - return $handler($request, $options)->then(function (\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface $response) use($request, $handler) { + return $handler($request, $options)->then(function (\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ResponseInterface $response) use($request) { $code = $response->getStatusCode(); if ($code < 400) { return $response; @@ -158,7 +157,7 @@ public static function retry(callable $decider, callable $delay = null) * * @return callable Returns a function that accepts the next handler. */ - public static function log(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Log\LoggerInterface $logger, \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\MessageFormatter $formatter, $logLevel = \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Log\LogLevel::INFO) + public static function log(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Log\LoggerInterface $logger, \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\MessageFormatter $formatter, $logLevel = 'info') { return function (callable $handler) use($logger, $formatter, $logLevel) { return function ($request, array $options) use($handler, $logger, $formatter, $logLevel) { diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/Pool.php b/vendor/Gcp/guzzlehttp/guzzle/src/Pool.php index 656be297..2fa27378 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/Pool.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/Pool.php @@ -6,7 +6,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\RequestInterface; use DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Promise\EachPromise; /** - * Sends and iterator of requests concurrently using a capped pool size. + * Sends an iterator of requests concurrently using a capped pool size. * * The pool will read from an iterator until it is cancelled or until the * iterator is consumed. When a request is yielded, the request is sent after diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/RedirectMiddleware.php b/vendor/Gcp/guzzlehttp/guzzle/src/RedirectMiddleware.php index ad434752..54f5e638 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/RedirectMiddleware.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/RedirectMiddleware.php @@ -128,7 +128,7 @@ public function modifyRequest(\DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Mes // Add the Referer header if it is told to do so and only // add the header if we are not redirecting from https to http. if ($options['allow_redirects']['referer'] && $modify['uri']->getScheme() === $request->getUri()->getScheme()) { - $uri = $request->getUri()->withUserInfo('', ''); + $uri = $request->getUri()->withUserInfo(''); $modify['set_headers']['Referer'] = (string) $uri; } else { $modify['remove_headers'][] = 'Referer'; diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/RequestOptions.php b/vendor/Gcp/guzzlehttp/guzzle/src/RequestOptions.php index 1b43c135..22fea379 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/RequestOptions.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/RequestOptions.php @@ -23,7 +23,7 @@ final class RequestOptions * - strict: (bool, default=false) Set to true to use strict redirects * meaning redirect POST requests with POST requests vs. doing what most * browsers do which is redirect POST requests with GET requests - * - referer: (bool, default=true) Set to false to disable the Referer + * - referer: (bool, default=false) Set to true to enable the Referer * header. * - protocols: (array, default=['http', 'https']) Allowed redirect * protocols. diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/RetryMiddleware.php b/vendor/Gcp/guzzlehttp/guzzle/src/RetryMiddleware.php index 1e919e33..688f3f81 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/RetryMiddleware.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/RetryMiddleware.php @@ -17,6 +17,8 @@ class RetryMiddleware private $nextHandler; /** @var callable */ private $decider; + /** @var callable */ + private $delay; /** * @param callable $decider Function that accepts the number of retries, * a request, [response], and [exception] and @@ -36,7 +38,7 @@ public function __construct(callable $decider, callable $nextHandler, callable $ /** * Default exponential backoff delay function. * - * @param $retries + * @param int $retries * * @return int */ diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/TransferStats.php b/vendor/Gcp/guzzlehttp/guzzle/src/TransferStats.php index e34d3db6..7e27e830 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/TransferStats.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/TransferStats.php @@ -19,7 +19,7 @@ final class TransferStats /** * @param RequestInterface $request Request that was sent. * @param ResponseInterface $response Response received (if any) - * @param null $transferTime Total handler transfer time. + * @param float|null $transferTime Total handler transfer time. * @param mixed $handlerErrorData Handler error data. * @param array $handlerStats Handler specific stats. */ diff --git a/vendor/Gcp/guzzlehttp/guzzle/src/functions.php b/vendor/Gcp/guzzlehttp/guzzle/src/functions.php index 2a9230b2..e369014c 100644 --- a/vendor/Gcp/guzzlehttp/guzzle/src/functions.php +++ b/vendor/Gcp/guzzlehttp/guzzle/src/functions.php @@ -262,14 +262,14 @@ function is_host_in_noproxy($host, array $noProxyArray) * @param int $options Bitmask of JSON decode options. * * @return mixed - * @throws \InvalidArgumentException if the JSON cannot be decoded. + * @throws Exception\InvalidArgumentException if the JSON cannot be decoded. * @link http://www.php.net/manual/en/function.json-decode.php */ function json_decode($json, $assoc = false, $depth = 512, $options = 0) { $data = \json_decode($json, $assoc, $depth, $options); if (JSON_ERROR_NONE !== json_last_error()) { - throw new \InvalidArgumentException('json_decode error: ' . json_last_error_msg()); + throw new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\InvalidArgumentException('json_decode error: ' . json_last_error_msg()); } return $data; } @@ -281,14 +281,25 @@ function json_decode($json, $assoc = false, $depth = 512, $options = 0) * @param int $depth Set the maximum depth. Must be greater than zero. * * @return string - * @throws \InvalidArgumentException if the JSON cannot be encoded. + * @throws Exception\InvalidArgumentException if the JSON cannot be encoded. * @link http://www.php.net/manual/en/function.json-encode.php */ function json_encode($value, $options = 0, $depth = 512) { $json = \json_encode($value, $options, $depth); if (JSON_ERROR_NONE !== json_last_error()) { - throw new \InvalidArgumentException('json_encode error: ' . json_last_error_msg()); + throw new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Exception\InvalidArgumentException('json_encode error: ' . json_last_error_msg()); } return $json; } +/** + * Wrapper for the hrtime() or microtime() functions + * (depending on the PHP version, one of the two is used) + * + * @return float|mixed UNIX timestamp + * @internal + */ +function _current_time() +{ + return function_exists('hrtime') ? hrtime(true) / 1000000000.0 : microtime(true); +} diff --git a/vendor/Gcp/guzzlehttp/psr7/CHANGELOG.md b/vendor/Gcp/guzzlehttp/psr7/CHANGELOG.md index 27b65f09..8a3743db 100644 --- a/vendor/Gcp/guzzlehttp/psr7/CHANGELOG.md +++ b/vendor/Gcp/guzzlehttp/psr7/CHANGELOG.md @@ -10,6 +10,26 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] +## [1.6.0] + +### Added + +- Allowed version `^3.0` of `ralouphie/getallheaders` dependency (#244) +- Added MIME type for WEBP image format (#246) +- Added more validation of values according to PSR-7 and RFC standards, e.g. status code range (#250, #272) + +### Changed + +- Tests don't pass with HHVM 4.0, so HHVM support got dropped. Other libraries like composer have done the same. (#262) +- Accept port number 0 to be valid (#270) + +### Fixed + +- Fixed subsequent reads from `php://input` in ServerRequest (#247) +- Fixed readable/writable detection for certain stream modes (#248) +- Fixed encoding of special characters in the `userInfo` component of an URI (#253) + + ## [1.5.2] - 2018-12-04 ### Fixed @@ -209,7 +229,8 @@ Currently unsupported: -[Unreleased]: https://github.com/guzzle/psr7/compare/1.5.2...HEAD +[Unreleased]: https://github.com/guzzle/psr7/compare/1.6.0...HEAD +[1.6.0]: https://github.com/guzzle/psr7/compare/1.5.2...1.6.0 [1.5.2]: https://github.com/guzzle/psr7/compare/1.5.1...1.5.2 [1.5.1]: https://github.com/guzzle/psr7/compare/1.5.0...1.5.1 [1.5.0]: https://github.com/guzzle/psr7/compare/1.4.2...1.5.0 diff --git a/vendor/Gcp/guzzlehttp/psr7/composer.json b/vendor/Gcp/guzzlehttp/psr7/composer.json index da7172ae..932cca5d 100644 --- a/vendor/Gcp/guzzlehttp/psr7/composer.json +++ b/vendor/Gcp/guzzlehttp/psr7/composer.json @@ -27,14 +27,18 @@ "require": { "php": ">=5.4.0", "psr\/http-message": "~1.0", - "ralouphie\/getallheaders": "^2.0.5" + "ralouphie\/getallheaders": "^2.0.5 || ^3.0.0" }, "require-dev": { - "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" + "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8", + "ext-zlib": "*" }, "provide": { "psr\/http-message-implementation": "1.0" }, + "suggest": { + "zendframework\/zend-httphandlerrunner": "Emit PSR-7 responses" + }, "autoload": { "psr-4": { "DeliciousBrains\\WP_Offload_Media\\Gcp\\GuzzleHttp\\Psr7\\": "src\/" @@ -50,7 +54,7 @@ }, "extra": { "branch-alias": { - "dev-master": "1.5-dev" + "dev-master": "1.6-dev" } } } \ No newline at end of file diff --git a/vendor/Gcp/guzzlehttp/psr7/src/LimitStream.php b/vendor/Gcp/guzzlehttp/psr7/src/LimitStream.php index 3565db38..789b45bf 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/LimitStream.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/LimitStream.php @@ -59,7 +59,7 @@ public function getSize() public function seek($offset, $whence = SEEK_SET) { if ($whence !== SEEK_SET || $offset < 0) { - throw new \RuntimeException(sprintf('Cannot seek to offset % with whence %s', $offset, $whence)); + throw new \RuntimeException(sprintf('Cannot seek to offset %s with whence %s', $offset, $whence)); } $offset += $this->offset; if ($this->limit !== -1) { diff --git a/vendor/Gcp/guzzlehttp/psr7/src/MessageTrait.php b/vendor/Gcp/guzzlehttp/psr7/src/MessageTrait.php index e912c00c..9c36c4f4 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/MessageTrait.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/MessageTrait.php @@ -52,10 +52,8 @@ public function getHeaderLine($header) } public function withHeader($header, $value) { - if (!is_array($value)) { - $value = [$value]; - } - $value = $this->trimHeaderValues($value); + $this->assertHeader($header); + $value = $this->normalizeHeaderValue($value); $normalized = strtolower($header); $new = clone $this; if (isset($new->headerNames[$normalized])) { @@ -67,10 +65,8 @@ public function withHeader($header, $value) } public function withAddedHeader($header, $value) { - if (!is_array($value)) { - $value = [$value]; - } - $value = $this->trimHeaderValues($value); + $this->assertHeader($header); + $value = $this->normalizeHeaderValue($value); $normalized = strtolower($header); $new = clone $this; if (isset($new->headerNames[$normalized])) { @@ -113,10 +109,13 @@ private function setHeaders(array $headers) { $this->headerNames = $this->headers = []; foreach ($headers as $header => $value) { - if (!is_array($value)) { - $value = [$value]; + if (is_int($header)) { + // Numeric array keys are converted to int by PHP but having a header name '123' is not forbidden by the spec + // and also allowed in withHeader(). So we need to cast it to string again for the following assertion to pass. + $header = (string) $header; } - $value = $this->trimHeaderValues($value); + $this->assertHeader($header); + $value = $this->normalizeHeaderValue($value); $normalized = strtolower($header); if (isset($this->headerNames[$normalized])) { $header = $this->headerNames[$normalized]; @@ -127,6 +126,16 @@ private function setHeaders(array $headers) } } } + private function normalizeHeaderValue($value) + { + if (!is_array($value)) { + return $this->trimHeaderValues([$value]); + } + if (count($value) === 0) { + throw new \InvalidArgumentException('Header value can not be an empty array.'); + } + return $this->trimHeaderValues($value); + } /** * Trims whitespace from the header values. * @@ -144,7 +153,19 @@ private function setHeaders(array $headers) private function trimHeaderValues(array $values) { return array_map(function ($value) { - return trim($value, " \t"); + if (!is_scalar($value) && null !== $value) { + throw new \InvalidArgumentException(sprintf('Header value must be scalar or null but %s provided.', is_object($value) ? get_class($value) : gettype($value))); + } + return trim((string) $value, " \t"); }, $values); } + private function assertHeader($header) + { + if (!is_string($header)) { + throw new \InvalidArgumentException(sprintf('Header name must be a string but %s provided.', is_object($header) ? get_class($header) : gettype($header))); + } + if ($header === '') { + throw new \InvalidArgumentException('Header name can not be empty.'); + } + } } diff --git a/vendor/Gcp/guzzlehttp/psr7/src/Request.php b/vendor/Gcp/guzzlehttp/psr7/src/Request.php index c4970801..03283acc 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/Request.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/Request.php @@ -27,6 +27,7 @@ class Request implements \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\ */ public function __construct($method, $uri, array $headers = [], $body = null, $version = '1.1') { + $this->assertMethod($method); if (!$uri instanceof UriInterface) { $uri = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\Uri($uri); } @@ -70,6 +71,7 @@ public function getMethod() } public function withMethod($method) { + $this->assertMethod($method); $new = clone $this; $new->method = strtoupper($method); return $new; @@ -109,4 +111,10 @@ private function updateHostFromUri() // See: http://tools.ietf.org/html/rfc7230#section-5.4 $this->headers = [$header => [$host]] + $this->headers; } + private function assertMethod($method) + { + if (!is_string($method) || $method === '') { + throw new \InvalidArgumentException('Method must be a non-empty string.'); + } + } } diff --git a/vendor/Gcp/guzzlehttp/psr7/src/Response.php b/vendor/Gcp/guzzlehttp/psr7/src/Response.php index 7876a70b..71e8bacb 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/Response.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/Response.php @@ -25,10 +25,10 @@ class Response implements \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message */ public function __construct($status = 200, array $headers = [], $body = null, $version = '1.1', $reason = null) { - if (filter_var($status, FILTER_VALIDATE_INT) === false) { - throw new \InvalidArgumentException('Status code must be an integer value.'); - } - $this->statusCode = (int) $status; + $this->assertStatusCodeIsInteger($status); + $status = (int) $status; + $this->assertStatusCodeRange($status); + $this->statusCode = $status; if ($body !== '' && $body !== null) { $this->stream = stream_for($body); } @@ -50,12 +50,27 @@ public function getReasonPhrase() } public function withStatus($code, $reasonPhrase = '') { + $this->assertStatusCodeIsInteger($code); + $code = (int) $code; + $this->assertStatusCodeRange($code); $new = clone $this; - $new->statusCode = (int) $code; + $new->statusCode = $code; if ($reasonPhrase == '' && isset(self::$phrases[$new->statusCode])) { $reasonPhrase = self::$phrases[$new->statusCode]; } $new->reasonPhrase = $reasonPhrase; return $new; } + private function assertStatusCodeIsInteger($statusCode) + { + if (filter_var($statusCode, FILTER_VALIDATE_INT) === false) { + throw new \InvalidArgumentException('Status code must be an integer value.'); + } + } + private function assertStatusCodeRange($statusCode) + { + if ($statusCode < 100 || $statusCode >= 600) { + throw new \InvalidArgumentException('Status code must be an integer value between 1xx and 5xx.'); + } + } } diff --git a/vendor/Gcp/guzzlehttp/psr7/src/ServerRequest.php b/vendor/Gcp/guzzlehttp/psr7/src/ServerRequest.php index 3ee460d2..00da01f4 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/ServerRequest.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/ServerRequest.php @@ -133,7 +133,7 @@ public static function fromGlobals() $method = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : 'GET'; $headers = getallheaders(); $uri = self::getUriFromGlobals(); - $body = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\LazyOpenStream('php://input', 'r+'); + $body = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\CachingStream(new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\LazyOpenStream('php://input', 'r+')); $protocol = isset($_SERVER['SERVER_PROTOCOL']) ? str_replace('HTTP/', '', $_SERVER['SERVER_PROTOCOL']) : '1.1'; $serverRequest = new \DeliciousBrains\WP_Offload_Media\Gcp\GuzzleHttp\Psr7\ServerRequest($method, $uri, $headers, $body, $protocol, $_SERVER); return $serverRequest->withCookieParams($_COOKIE)->withQueryParams($_GET)->withParsedBody($_POST)->withUploadedFiles(self::normalizeFiles($_FILES)); diff --git a/vendor/Gcp/guzzlehttp/psr7/src/Stream.php b/vendor/Gcp/guzzlehttp/psr7/src/Stream.php index 256b2b12..c7621358 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/Stream.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/Stream.php @@ -10,6 +10,16 @@ */ class Stream implements \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\StreamInterface { + /** + * Resource modes. + * + * @var string + * + * @see http://php.net/manual/function.fopen.php + * @see http://php.net/manual/en/function.gzopen.php + */ + const READABLE_MODES = '/r|a\\+|ab\\+|w\\+|wb\\+|x\\+|xb\\+|c\\+|cb\\+/'; + const WRITABLE_MODES = '/a|w|r\\+|rb\\+|rw|x|c/'; private $stream; private $size; private $seekable; @@ -17,8 +27,6 @@ class Stream implements \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Http\Message\S private $writable; private $uri; private $customMetadata; - /** @var array Hash of readable and writable stream types */ - private static $readWriteHash = ['read' => ['r' => true, 'w+' => true, 'r+' => true, 'x+' => true, 'c+' => true, 'rb' => true, 'w+b' => true, 'r+b' => true, 'x+b' => true, 'c+b' => true, 'rt' => true, 'w+t' => true, 'r+t' => true, 'x+t' => true, 'c+t' => true, 'a+' => true, 'rb+' => true], 'write' => ['w' => true, 'w+' => true, 'rw' => true, 'r+' => true, 'x+' => true, 'c+' => true, 'wb' => true, 'w+b' => true, 'r+b' => true, 'rb+' => true, 'x+b' => true, 'c+b' => true, 'w+t' => true, 'r+t' => true, 'x+t' => true, 'c+t' => true, 'a' => true, 'a+' => true]]; /** * This constructor accepts an associative array of options. * @@ -45,8 +53,8 @@ public function __construct($stream, $options = []) $this->stream = $stream; $meta = stream_get_meta_data($this->stream); $this->seekable = $meta['seekable']; - $this->readable = isset(self::$readWriteHash['read'][$meta['mode']]); - $this->writable = isset(self::$readWriteHash['write'][$meta['mode']]); + $this->readable = (bool) preg_match(self::READABLE_MODES, $meta['mode']); + $this->writable = (bool) preg_match(self::WRITABLE_MODES, $meta['mode']); $this->uri = $this->getMetadata('uri'); } /** @@ -151,6 +159,7 @@ public function rewind() } public function seek($offset, $whence = SEEK_SET) { + $whence = (int) $whence; if (!isset($this->stream)) { throw new \RuntimeException('Stream is detached'); } diff --git a/vendor/Gcp/guzzlehttp/psr7/src/Uri.php b/vendor/Gcp/guzzlehttp/psr7/src/Uri.php index a3e1d3e8..011f7770 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/Uri.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/Uri.php @@ -356,9 +356,9 @@ public function withScheme($scheme) } public function withUserInfo($user, $password = null) { - $info = $user; - if ($password != '') { - $info .= ':' . $password; + $info = $this->filterUserInfoComponent($user); + if ($password !== null) { + $info .= ':' . $this->filterUserInfoComponent($password); } if ($this->userInfo === $info) { return $this; @@ -430,14 +430,14 @@ public function withFragment($fragment) private function applyParts(array $parts) { $this->scheme = isset($parts['scheme']) ? $this->filterScheme($parts['scheme']) : ''; - $this->userInfo = isset($parts['user']) ? $parts['user'] : ''; + $this->userInfo = isset($parts['user']) ? $this->filterUserInfoComponent($parts['user']) : ''; $this->host = isset($parts['host']) ? $this->filterHost($parts['host']) : ''; $this->port = isset($parts['port']) ? $this->filterPort($parts['port']) : null; $this->path = isset($parts['path']) ? $this->filterPath($parts['path']) : ''; $this->query = isset($parts['query']) ? $this->filterQueryAndFragment($parts['query']) : ''; $this->fragment = isset($parts['fragment']) ? $this->filterQueryAndFragment($parts['fragment']) : ''; if (isset($parts['pass'])) { - $this->userInfo .= ':' . $parts['pass']; + $this->userInfo .= ':' . $this->filterUserInfoComponent($parts['pass']); } $this->removeDefaultPort(); } @@ -455,6 +455,20 @@ private function filterScheme($scheme) } return strtolower($scheme); } + /** + * @param string $component + * + * @return string + * + * @throws \InvalidArgumentException If the user info is invalid. + */ + private function filterUserInfoComponent($component) + { + if (!is_string($component)) { + throw new \InvalidArgumentException('User info must be a string'); + } + return preg_replace_callback('/(?:[^%' . self::$charUnreserved . self::$charSubDelims . ']+|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $component); + } /** * @param string $host * @@ -482,8 +496,8 @@ private function filterPort($port) return null; } $port = (int) $port; - if (1 > $port || 0xffff < $port) { - throw new \InvalidArgumentException(sprintf('Invalid port: %d. Must be between 1 and 65535', $port)); + if (0 > $port || 0xffff < $port) { + throw new \InvalidArgumentException(sprintf('Invalid port: %d. Must be between 0 and 65535', $port)); } return $port; } diff --git a/vendor/Gcp/guzzlehttp/psr7/src/functions.php b/vendor/Gcp/guzzlehttp/psr7/src/functions.php index 5fa46fb1..c7d43a08 100644 --- a/vendor/Gcp/guzzlehttp/psr7/src/functions.php +++ b/vendor/Gcp/guzzlehttp/psr7/src/functions.php @@ -533,7 +533,7 @@ function mimetype_from_filename($filename) */ function mimetype_from_extension($extension) { - static $mimetypes = ['3gp' => 'video/3gpp', '7z' => 'application/x-7z-compressed', 'aac' => 'audio/x-aac', 'ai' => 'application/postscript', 'aif' => 'audio/x-aiff', 'asc' => 'text/plain', 'asf' => 'video/x-ms-asf', 'atom' => 'application/atom+xml', 'avi' => 'video/x-msvideo', 'bmp' => 'image/bmp', 'bz2' => 'application/x-bzip2', 'cer' => 'application/pkix-cert', 'crl' => 'application/pkix-crl', 'crt' => 'application/x-x509-ca-cert', 'css' => 'text/css', 'csv' => 'text/csv', 'cu' => 'application/cu-seeme', 'deb' => 'application/x-debian-package', 'doc' => 'application/msword', 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'dvi' => 'application/x-dvi', 'eot' => 'application/vnd.ms-fontobject', 'eps' => 'application/postscript', 'epub' => 'application/epub+zip', 'etx' => 'text/x-setext', 'flac' => 'audio/flac', 'flv' => 'video/x-flv', 'gif' => 'image/gif', 'gz' => 'application/gzip', 'htm' => 'text/html', 'html' => 'text/html', 'ico' => 'image/x-icon', 'ics' => 'text/calendar', 'ini' => 'text/plain', 'iso' => 'application/x-iso9660-image', 'jar' => 'application/java-archive', 'jpe' => 'image/jpeg', 'jpeg' => 'image/jpeg', 'jpg' => 'image/jpeg', 'js' => 'text/javascript', 'json' => 'application/json', 'latex' => 'application/x-latex', 'log' => 'text/plain', 'm4a' => 'audio/mp4', 'm4v' => 'video/mp4', 'mid' => 'audio/midi', 'midi' => 'audio/midi', 'mov' => 'video/quicktime', 'mkv' => 'video/x-matroska', 'mp3' => 'audio/mpeg', 'mp4' => 'video/mp4', 'mp4a' => 'audio/mp4', 'mp4v' => 'video/mp4', 'mpe' => 'video/mpeg', 'mpeg' => 'video/mpeg', 'mpg' => 'video/mpeg', 'mpg4' => 'video/mp4', 'oga' => 'audio/ogg', 'ogg' => 'audio/ogg', 'ogv' => 'video/ogg', 'ogx' => 'application/ogg', 'pbm' => 'image/x-portable-bitmap', 'pdf' => 'application/pdf', 'pgm' => 'image/x-portable-graymap', 'png' => 'image/png', 'pnm' => 'image/x-portable-anymap', 'ppm' => 'image/x-portable-pixmap', 'ppt' => 'application/vnd.ms-powerpoint', 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation', 'ps' => 'application/postscript', 'qt' => 'video/quicktime', 'rar' => 'application/x-rar-compressed', 'ras' => 'image/x-cmu-raster', 'rss' => 'application/rss+xml', 'rtf' => 'application/rtf', 'sgm' => 'text/sgml', 'sgml' => 'text/sgml', 'svg' => 'image/svg+xml', 'swf' => 'application/x-shockwave-flash', 'tar' => 'application/x-tar', 'tif' => 'image/tiff', 'tiff' => 'image/tiff', 'torrent' => 'application/x-bittorrent', 'ttf' => 'application/x-font-ttf', 'txt' => 'text/plain', 'wav' => 'audio/x-wav', 'webm' => 'video/webm', 'wma' => 'audio/x-ms-wma', 'wmv' => 'video/x-ms-wmv', 'woff' => 'application/x-font-woff', 'wsdl' => 'application/wsdl+xml', 'xbm' => 'image/x-xbitmap', 'xls' => 'application/vnd.ms-excel', 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'xml' => 'application/xml', 'xpm' => 'image/x-xpixmap', 'xwd' => 'image/x-xwindowdump', 'yaml' => 'text/yaml', 'yml' => 'text/yaml', 'zip' => 'application/zip']; + static $mimetypes = ['3gp' => 'video/3gpp', '7z' => 'application/x-7z-compressed', 'aac' => 'audio/x-aac', 'ai' => 'application/postscript', 'aif' => 'audio/x-aiff', 'asc' => 'text/plain', 'asf' => 'video/x-ms-asf', 'atom' => 'application/atom+xml', 'avi' => 'video/x-msvideo', 'bmp' => 'image/bmp', 'bz2' => 'application/x-bzip2', 'cer' => 'application/pkix-cert', 'crl' => 'application/pkix-crl', 'crt' => 'application/x-x509-ca-cert', 'css' => 'text/css', 'csv' => 'text/csv', 'cu' => 'application/cu-seeme', 'deb' => 'application/x-debian-package', 'doc' => 'application/msword', 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'dvi' => 'application/x-dvi', 'eot' => 'application/vnd.ms-fontobject', 'eps' => 'application/postscript', 'epub' => 'application/epub+zip', 'etx' => 'text/x-setext', 'flac' => 'audio/flac', 'flv' => 'video/x-flv', 'gif' => 'image/gif', 'gz' => 'application/gzip', 'htm' => 'text/html', 'html' => 'text/html', 'ico' => 'image/x-icon', 'ics' => 'text/calendar', 'ini' => 'text/plain', 'iso' => 'application/x-iso9660-image', 'jar' => 'application/java-archive', 'jpe' => 'image/jpeg', 'jpeg' => 'image/jpeg', 'jpg' => 'image/jpeg', 'js' => 'text/javascript', 'json' => 'application/json', 'latex' => 'application/x-latex', 'log' => 'text/plain', 'm4a' => 'audio/mp4', 'm4v' => 'video/mp4', 'mid' => 'audio/midi', 'midi' => 'audio/midi', 'mov' => 'video/quicktime', 'mkv' => 'video/x-matroska', 'mp3' => 'audio/mpeg', 'mp4' => 'video/mp4', 'mp4a' => 'audio/mp4', 'mp4v' => 'video/mp4', 'mpe' => 'video/mpeg', 'mpeg' => 'video/mpeg', 'mpg' => 'video/mpeg', 'mpg4' => 'video/mp4', 'oga' => 'audio/ogg', 'ogg' => 'audio/ogg', 'ogv' => 'video/ogg', 'ogx' => 'application/ogg', 'pbm' => 'image/x-portable-bitmap', 'pdf' => 'application/pdf', 'pgm' => 'image/x-portable-graymap', 'png' => 'image/png', 'pnm' => 'image/x-portable-anymap', 'ppm' => 'image/x-portable-pixmap', 'ppt' => 'application/vnd.ms-powerpoint', 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation', 'ps' => 'application/postscript', 'qt' => 'video/quicktime', 'rar' => 'application/x-rar-compressed', 'ras' => 'image/x-cmu-raster', 'rss' => 'application/rss+xml', 'rtf' => 'application/rtf', 'sgm' => 'text/sgml', 'sgml' => 'text/sgml', 'svg' => 'image/svg+xml', 'swf' => 'application/x-shockwave-flash', 'tar' => 'application/x-tar', 'tif' => 'image/tiff', 'tiff' => 'image/tiff', 'torrent' => 'application/x-bittorrent', 'ttf' => 'application/x-font-ttf', 'txt' => 'text/plain', 'wav' => 'audio/x-wav', 'webm' => 'video/webm', 'webp' => 'image/webp', 'wma' => 'audio/x-ms-wma', 'wmv' => 'video/x-ms-wmv', 'woff' => 'application/x-font-woff', 'wsdl' => 'application/wsdl+xml', 'xbm' => 'image/x-xbitmap', 'xls' => 'application/vnd.ms-excel', 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'xml' => 'application/xml', 'xpm' => 'image/x-xpixmap', 'xwd' => 'image/x-xwindowdump', 'yaml' => 'text/yaml', 'yml' => 'text/yaml', 'zip' => 'application/zip']; $extension = strtolower($extension); return isset($mimetypes[$extension]) ? $mimetypes[$extension] : null; } diff --git a/vendor/Gcp/monolog/monolog/CHANGELOG.md b/vendor/Gcp/monolog/monolog/CHANGELOG.md index bcf679c4..a00c1ece 100644 --- a/vendor/Gcp/monolog/monolog/CHANGELOG.md +++ b/vendor/Gcp/monolog/monolog/CHANGELOG.md @@ -1,5 +1,32 @@ +### 1.25.2 (2019-11-13) + + * Fixed normalization of Traversables to avoid traversing them as not all of them are rewindable + * Fixed setFormatter/getFormatter to forward to the nested handler in FilterHandler, FingersCrossedHandler, BufferHandler and SamplingHandler + * Fixed BrowserConsoleHandler formatting when using multiple styles + * Fixed normalization of exception codes to be always integers even for PDOException which have them as numeric strings + * Fixed normalization of SoapFault objects containing non-strings as "detail" + * Fixed json encoding across all handlers to always attempt recovery of non-UTF-8 strings instead of failing the whole encoding + +### 1.25.1 (2019-09-06) + + * Fixed forward-compatible interfaces to be compatible with Monolog 1.x too. + +### 1.25.0 (2019-09-06) + + * Deprecated SlackbotHandler, use SlackWebhookHandler or SlackHandler instead + * Deprecated RavenHandler, use sentry/sentry 2.x and their Sentry\Monolog\Handler instead + * Deprecated HipChatHandler, migrate to Slack and use SlackWebhookHandler or SlackHandler instead + * Added forward-compatible interfaces and traits FormattableHandlerInterface, FormattableHandlerTrait, ProcessableHandlerInterface, ProcessableHandlerTrait. If you use modern PHP and want to make code compatible with Monolog 1 and 2 this can help. You will have to require at least Monolog 1.25 though. + * Added support for RFC3164 (outdated BSD syslog protocol) to SyslogUdpHandler + * Fixed issue in GroupHandler and WhatFailureGroupHandler where setting multiple processors would duplicate records + * Fixed issue in SignalHandler restarting syscalls functionality + * Fixed normalizers handling of exception backtraces to avoid serializing arguments in some cases + * Fixed ZendMonitorHandler to work with the latest Zend Server versions + * Fixed ChromePHPHandler to avoid sending more data than latest Chrome versions allow in headers (4KB down from 256KB). + ### 1.24.0 (2018-11-05) + * BC Notice: If you are extending any of the Monolog's Formatters' `normalize` method, make sure you add the new `$depth = 0` argument to your function signature to avoid strict PHP warnings. * Added a `ResettableInterface` in order to reset/reset/clear/flush handlers and processors * Added a `ProcessorInterface` as an optional way to label a class as being a processor (mostly useful for autowiring dependency containers) * Added a way to log signals being received using Monolog\SignalHandler diff --git a/vendor/Gcp/monolog/monolog/README.md b/vendor/Gcp/monolog/monolog/README.md index d7569446..a578eb22 100644 --- a/vendor/Gcp/monolog/monolog/README.md +++ b/vendor/Gcp/monolog/monolog/README.md @@ -90,5 +90,5 @@ Monolog is licensed under the MIT License - see the `LICENSE` file for details ### Acknowledgements -This library is heavily inspired by Python's [Logbook](http://packages.python.org/Logbook/) +This library is heavily inspired by Python's [Logbook](https://logbook.readthedocs.io/en/stable/) library, although most concepts have been adjusted to fit to the PHP world. diff --git a/vendor/Gcp/monolog/monolog/composer.json b/vendor/Gcp/monolog/monolog/composer.json index 08fc0c8b..55a79705 100644 --- a/vendor/Gcp/monolog/monolog/composer.json +++ b/vendor/Gcp/monolog/monolog/composer.json @@ -67,7 +67,7 @@ }, "scripts": { "test": [ - "parallel-lint . --exclude vendor", + "parallel-lint . --exclude vendor --exclude src\/Monolog\/Handler\/FormattableHandlerInterface.php --exclude src\/Monolog\/Handler\/FormattableHandlerTrait.php --exclude src\/Monolog\/Handler\/ProcessableHandlerInterface.php --exclude src\/Monolog\/Handler\/ProcessableHandlerTrait.php", "phpunit" ] } diff --git a/vendor/Gcp/monolog/monolog/doc/01-usage.md b/vendor/Gcp/monolog/monolog/doc/01-usage.md deleted file mode 100644 index 8e2551f3..00000000 --- a/vendor/Gcp/monolog/monolog/doc/01-usage.md +++ /dev/null @@ -1,231 +0,0 @@ -# Using Monolog - -- [Installation](#installation) -- [Core Concepts](#core-concepts) -- [Log Levels](#log-levels) -- [Configuring a logger](#configuring-a-logger) -- [Adding extra data in the records](#adding-extra-data-in-the-records) -- [Leveraging channels](#leveraging-channels) -- [Customizing the log format](#customizing-the-log-format) - -## Installation - -Monolog is available on Packagist ([monolog/monolog](http://packagist.org/packages/monolog/monolog)) -and as such installable via [Composer](http://getcomposer.org/). - -```bash -composer require monolog/monolog -``` - -If you do not use Composer, you can grab the code from GitHub, and use any -PSR-0 compatible autoloader (e.g. the [Symfony2 ClassLoader component](https://github.com/symfony/ClassLoader)) -to load Monolog classes. - -## Core Concepts - -Every `Logger` instance has a channel (name) and a stack of handlers. Whenever -you add a record to the logger, it traverses the handler stack. Each handler -decides whether it fully handled the record, and if so, the propagation of the -record ends there. - -This allows for flexible logging setups, for example having a `StreamHandler` at -the bottom of the stack that will log anything to disk, and on top of that add -a `MailHandler` that will send emails only when an error message is logged. -Handlers also have a `$bubble` property which defines whether they block the -record or not if they handled it. In this example, setting the `MailHandler`'s -`$bubble` argument to false means that records handled by the `MailHandler` will -not propagate to the `StreamHandler` anymore. - -You can create many `Logger`s, each defining a channel (e.g.: db, request, -router, ..) and each of them combining various handlers, which can be shared -or not. The channel is reflected in the logs and allows you to easily see or -filter records. - -Each Handler also has a Formatter, a default one with settings that make sense -will be created if you don't set one. The formatters normalize and format -incoming records so that they can be used by the handlers to output useful -information. - -Custom severity levels are not available. Only the eight -[RFC 5424](http://tools.ietf.org/html/rfc5424) levels (debug, info, notice, -warning, error, critical, alert, emergency) are present for basic filtering -purposes, but for sorting and other use cases that would require -flexibility, you should add Processors to the Logger that can add extra -information (tags, user ip, ..) to the records before they are handled. - -## Log Levels - -Monolog supports the logging levels described by [RFC 5424](http://tools.ietf.org/html/rfc5424). - -- **DEBUG** (100): Detailed debug information. - -- **INFO** (200): Interesting events. Examples: User logs in, SQL logs. - -- **NOTICE** (250): Normal but significant events. - -- **WARNING** (300): Exceptional occurrences that are not errors. Examples: - Use of deprecated APIs, poor use of an API, undesirable things that are not - necessarily wrong. - -- **ERROR** (400): Runtime errors that do not require immediate action but - should typically be logged and monitored. - -- **CRITICAL** (500): Critical conditions. Example: Application component - unavailable, unexpected exception. - -- **ALERT** (550): Action must be taken immediately. Example: Entire website - down, database unavailable, etc. This should trigger the SMS alerts and wake - you up. - -- **EMERGENCY** (600): Emergency: system is unusable. - -## Configuring a logger - -Here is a basic setup to log to a file and to firephp on the DEBUG level: - -```php -pushHandler(new StreamHandler(__DIR__.'/my_app.log', Logger::DEBUG)); -$logger->pushHandler(new FirePHPHandler()); - -// You can now use your logger -$logger->addInfo('My logger is now ready'); -``` - -Let's explain it. The first step is to create the logger instance which will -be used in your code. The argument is a channel name, which is useful when -you use several loggers (see below for more details about it). - -The logger itself does not know how to handle a record. It delegates it to -some handlers. The code above registers two handlers in the stack to allow -handling records in two different ways. - -Note that the FirePHPHandler is called first as it is added on top of the -stack. This allows you to temporarily add a logger with bubbling disabled if -you want to override other configured loggers. - -> If you use Monolog standalone and are looking for an easy way to -> configure many handlers, the [theorchard/monolog-cascade](https://github.com/theorchard/monolog-cascade) -> can help you build complex logging configs via PHP arrays, yaml or json configs. - -## Adding extra data in the records - -Monolog provides two different ways to add extra informations along the simple -textual message. - -### Using the logging context - -The first way is the context, allowing to pass an array of data along the -record: - -```php -addInfo('Adding a new user', array('username' => 'Seldaek')); -``` - -Simple handlers (like the StreamHandler for instance) will simply format -the array to a string but richer handlers can take advantage of the context -(FirePHP is able to display arrays in pretty way for instance). - -### Using processors - -The second way is to add extra data for all records by using a processor. -Processors can be any callable. They will get the record as parameter and -must return it after having eventually changed the `extra` part of it. Let's -write a processor adding some dummy data in the record: - -```php -pushProcessor(function ($record) { - $record['extra']['dummy'] = 'Hello world!'; - - return $record; -}); -``` - -Monolog provides some built-in processors that can be used in your project. -Look at the [dedicated chapter](https://github.com/Seldaek/monolog/blob/master/doc/02-handlers-formatters-processors.md#processors) for the list. - -> Tip: processors can also be registered on a specific handler instead of - the logger to apply only for this handler. - -## Leveraging channels - -Channels are a great way to identify to which part of the application a record -is related. This is useful in big applications (and is leveraged by -MonologBundle in Symfony2). - -Picture two loggers sharing a handler that writes to a single log file. -Channels would allow you to identify the logger that issued every record. -You can easily grep through the log files filtering this or that channel. - -```php -pushHandler($stream); -$logger->pushHandler($firephp); - -// Create a logger for the security-related stuff with a different channel -$securityLogger = new Logger('security'); -$securityLogger->pushHandler($stream); -$securityLogger->pushHandler($firephp); - -// Or clone the first one to only change the channel -$securityLogger = $logger->withName('security'); -``` - -## Customizing the log format - -In Monolog it's easy to customize the format of the logs written into files, -sockets, mails, databases and other handlers. Most of the handlers use the - -```php -$record['formatted'] -``` - -value to be automatically put into the log device. This value depends on the -formatter settings. You can choose between predefined formatter classes or -write your own (e.g. a multiline text file for human-readable output). - -To configure a predefined formatter class, just set it as the handler's field: - -```php -// the default date format is "Y-m-d H:i:s" -$dateFormat = "Y n j, g:i a"; -// the default output format is "[%datetime%] %channel%.%level_name%: %message% %context% %extra%\n" -$output = "%datetime% > %level_name% > %message% %context% %extra%\n"; -// finally, create a formatter -$formatter = new LineFormatter($output, $dateFormat); - -// Create a handler -$stream = new StreamHandler(__DIR__.'/my_app.log', Logger::DEBUG); -$stream->setFormatter($formatter); -// bind it to a logger object -$securityLogger = new Logger('security'); -$securityLogger->pushHandler($stream); -``` - -You may also reuse the same formatter between multiple handlers and share those -handlers between multiple loggers. - -[Handlers, Formatters and Processors](02-handlers-formatters-processors.md) → diff --git a/vendor/Gcp/monolog/monolog/doc/02-handlers-formatters-processors.md b/vendor/Gcp/monolog/monolog/doc/02-handlers-formatters-processors.md deleted file mode 100644 index af45913a..00000000 --- a/vendor/Gcp/monolog/monolog/doc/02-handlers-formatters-processors.md +++ /dev/null @@ -1,158 +0,0 @@ -# Handlers, Formatters and Processors - -- [Handlers](#handlers) - - [Log to files and syslog](#log-to-files-and-syslog) - - [Send alerts and emails](#send-alerts-and-emails) - - [Log specific servers and networked logging](#log-specific-servers-and-networked-logging) - - [Logging in development](#logging-in-development) - - [Log to databases](#log-to-databases) - - [Wrappers / Special Handlers](#wrappers--special-handlers) -- [Formatters](#formatters) -- [Processors](#processors) -- [Third Party Packages](#third-party-packages) - -## Handlers - -### Log to files and syslog - -- _StreamHandler_: Logs records into any PHP stream, use this for log files. -- _RotatingFileHandler_: Logs records to a file and creates one logfile per day. - It will also delete files older than `$maxFiles`. You should use - [logrotate](http://linuxcommand.org/man_pages/logrotate8.html) for high profile - setups though, this is just meant as a quick and dirty solution. -- _SyslogHandler_: Logs records to the syslog. -- _ErrorLogHandler_: Logs records to PHP's - [`error_log()`](http://docs.php.net/manual/en/function.error-log.php) function. - -### Send alerts and emails - -- _NativeMailerHandler_: Sends emails using PHP's - [`mail()`](http://php.net/manual/en/function.mail.php) function. -- _SwiftMailerHandler_: Sends emails using a [`Swift_Mailer`](http://swiftmailer.org/) instance. -- _PushoverHandler_: Sends mobile notifications via the [Pushover](https://www.pushover.net/) API. -- _HipChatHandler_: Logs records to a [HipChat](http://hipchat.com) chat room using its API. -- _FlowdockHandler_: Logs records to a [Flowdock](https://www.flowdock.com/) account. -- _SlackHandler_: Logs records to a [Slack](https://www.slack.com/) account using the Slack API. -- _SlackbotHandler_: Logs records to a [Slack](https://www.slack.com/) account using the Slackbot incoming hook. -- _SlackWebhookHandler_: Logs records to a [Slack](https://www.slack.com/) account using Slack Webhooks. -- _MandrillHandler_: Sends emails via the Mandrill API using a [`Swift_Message`](http://swiftmailer.org/) instance. -- _FleepHookHandler_: Logs records to a [Fleep](https://fleep.io/) conversation using Webhooks. -- _IFTTTHandler_: Notifies an [IFTTT](https://ifttt.com/maker) trigger with the log channel, level name and message. - -### Log specific servers and networked logging - -- _SocketHandler_: Logs records to [sockets](http://php.net/fsockopen), use this - for UNIX and TCP sockets. See an [example](sockets.md). -- _AmqpHandler_: Logs records to an [amqp](http://www.amqp.org/) compatible - server. Requires the [php-amqp](http://pecl.php.net/package/amqp) extension (1.0+). -- _GelfHandler_: Logs records to a [Graylog2](http://www.graylog2.org) server. -- _CubeHandler_: Logs records to a [Cube](http://square.github.com/cube/) server. -- _RavenHandler_: Logs records to a [Sentry](http://getsentry.com/) server using - [raven](https://packagist.org/packages/raven/raven). -- _ZendMonitorHandler_: Logs records to the Zend Monitor present in Zend Server. -- _NewRelicHandler_: Logs records to a [NewRelic](http://newrelic.com/) application. -- _LogglyHandler_: Logs records to a [Loggly](http://www.loggly.com/) account. -- _RollbarHandler_: Logs records to a [Rollbar](https://rollbar.com/) account. -- _SyslogUdpHandler_: Logs records to a remote [Syslogd](http://www.rsyslog.com/) server. -- _LogEntriesHandler_: Logs records to a [LogEntries](http://logentries.com/) account. -- _InsightOpsHandler_: Logs records to a [InsightOps](https://www.rapid7.com/products/insightops/) account. - -### Logging in development - -- _FirePHPHandler_: Handler for [FirePHP](http://www.firephp.org/), providing - inline `console` messages within [FireBug](http://getfirebug.com/). -- _ChromePHPHandler_: Handler for [ChromePHP](http://www.chromephp.com/), providing - inline `console` messages within Chrome. -- _BrowserConsoleHandler_: Handler to send logs to browser's Javascript `console` with - no browser extension required. Most browsers supporting `console` API are supported. -- _PHPConsoleHandler_: Handler for [PHP Console](https://chrome.google.com/webstore/detail/php-console/nfhmhhlpfleoednkpnnnkolmclajemef), providing - inline `console` and notification popup messages within Chrome. - -### Log to databases - -- _RedisHandler_: Logs records to a [redis](http://redis.io) server. -- _MongoDBHandler_: Handler to write records in MongoDB via a - [Mongo](http://pecl.php.net/package/mongo) extension connection. -- _CouchDBHandler_: Logs records to a CouchDB server. -- _DoctrineCouchDBHandler_: Logs records to a CouchDB server via the Doctrine CouchDB ODM. -- _ElasticSearchHandler_: Logs records to an Elastic Search server. -- _DynamoDbHandler_: Logs records to a DynamoDB table with the [AWS SDK](https://github.com/aws/aws-sdk-php). - -### Wrappers / Special Handlers - -- _FingersCrossedHandler_: A very interesting wrapper. It takes a logger as - parameter and will accumulate log records of all levels until a record - exceeds the defined severity level. At which point it delivers all records, - including those of lower severity, to the handler it wraps. This means that - until an error actually happens you will not see anything in your logs, but - when it happens you will have the full information, including debug and info - records. This provides you with all the information you need, but only when - you need it. -- _DeduplicationHandler_: Useful if you are sending notifications or emails - when critical errors occur. It takes a logger as parameter and will - accumulate log records of all levels until the end of the request (or - `flush()` is called). At that point it delivers all records to the handler - it wraps, but only if the records are unique over a given time period - (60seconds by default). If the records are duplicates they are simply - discarded. The main use of this is in case of critical failure like if your - database is unreachable for example all your requests will fail and that - can result in a lot of notifications being sent. Adding this handler reduces - the amount of notifications to a manageable level. -- _WhatFailureGroupHandler_: This handler extends the _GroupHandler_ ignoring - exceptions raised by each child handler. This allows you to ignore issues - where a remote tcp connection may have died but you do not want your entire - application to crash and may wish to continue to log to other handlers. -- _BufferHandler_: This handler will buffer all the log records it receives - until `close()` is called at which point it will call `handleBatch()` on the - handler it wraps with all the log messages at once. This is very useful to - send an email with all records at once for example instead of having one mail - for every log record. -- _GroupHandler_: This handler groups other handlers. Every record received is - sent to all the handlers it is configured with. -- _FilterHandler_: This handler only lets records of the given levels through - to the wrapped handler. -- _SamplingHandler_: Wraps around another handler and lets you sample records - if you only want to store some of them. -- _NullHandler_: Any record it can handle will be thrown away. This can be used - to put on top of an existing handler stack to disable it temporarily. -- _PsrHandler_: Can be used to forward log records to an existing PSR-3 logger -- _TestHandler_: Used for testing, it records everything that is sent to it and - has accessors to read out the information. -- _HandlerWrapper_: A simple handler wrapper you can inherit from to create - your own wrappers easily. - -## Formatters - -- _LineFormatter_: Formats a log record into a one-line string. -- _HtmlFormatter_: Used to format log records into a human readable html table, mainly suitable for emails. -- _NormalizerFormatter_: Normalizes objects/resources down to strings so a record can easily be serialized/encoded. -- _ScalarFormatter_: Used to format log records into an associative array of scalar values. -- _JsonFormatter_: Encodes a log record into json. -- _WildfireFormatter_: Used to format log records into the Wildfire/FirePHP protocol, only useful for the FirePHPHandler. -- _ChromePHPFormatter_: Used to format log records into the ChromePHP format, only useful for the ChromePHPHandler. -- _GelfMessageFormatter_: Used to format log records into Gelf message instances, only useful for the GelfHandler. -- _LogstashFormatter_: Used to format log records into [logstash](http://logstash.net/) event json, useful for any handler listed under inputs [here](http://logstash.net/docs/latest). -- _ElasticaFormatter_: Used to format log records into an Elastica\Document object, only useful for the ElasticSearchHandler. -- _LogglyFormatter_: Used to format log records into Loggly messages, only useful for the LogglyHandler. -- _FlowdockFormatter_: Used to format log records into Flowdock messages, only useful for the FlowdockHandler. -- _MongoDBFormatter_: Converts \DateTime instances to \MongoDate and objects recursively to arrays, only useful with the MongoDBHandler. - -## Processors - -- _PsrLogMessageProcessor_: Processes a log record's message according to PSR-3 rules, replacing `{foo}` with the value from `$context['foo']`. -- _IntrospectionProcessor_: Adds the line/file/class/method from which the log call originated. -- _WebProcessor_: Adds the current request URI, request method and client IP to a log record. -- _MemoryUsageProcessor_: Adds the current memory usage to a log record. -- _MemoryPeakUsageProcessor_: Adds the peak memory usage to a log record. -- _ProcessIdProcessor_: Adds the process id to a log record. -- _UidProcessor_: Adds a unique identifier to a log record. -- _GitProcessor_: Adds the current git branch and commit to a log record. -- _TagProcessor_: Adds an array of predefined tags to a log record. - -## Third Party Packages - -Third party handlers, formatters and processors are -[listed in the wiki](https://github.com/Seldaek/monolog/wiki/Third-Party-Packages). You -can also add your own there if you publish one. - -← [Usage](01-usage.md) | [Utility classes](03-utilities.md) → diff --git a/vendor/Gcp/monolog/monolog/doc/03-utilities.md b/vendor/Gcp/monolog/monolog/doc/03-utilities.md deleted file mode 100644 index fd3fd0e7..00000000 --- a/vendor/Gcp/monolog/monolog/doc/03-utilities.md +++ /dev/null @@ -1,15 +0,0 @@ -# Utilities - -- _Registry_: The `Monolog\Registry` class lets you configure global loggers that you - can then statically access from anywhere. It is not really a best practice but can - help in some older codebases or for ease of use. -- _ErrorHandler_: The `Monolog\ErrorHandler` class allows you to easily register - a Logger instance as an exception handler, error handler or fatal error handler. -- _SignalHandler_: The `Monolog\SignalHandler` class allows you to easily register - a Logger instance as a POSIX signal handler. -- _ErrorLevelActivationStrategy_: Activates a FingersCrossedHandler when a certain log - level is reached. -- _ChannelLevelActivationStrategy_: Activates a FingersCrossedHandler when a certain - log level is reached, depending on which channel received the log record. - -← [Handlers, Formatters and Processors](02-handlers-formatters-processors.md) | [Extending Monolog](04-extending.md) → diff --git a/vendor/Gcp/monolog/monolog/doc/04-extending.md b/vendor/Gcp/monolog/monolog/doc/04-extending.md deleted file mode 100644 index ebd9104d..00000000 --- a/vendor/Gcp/monolog/monolog/doc/04-extending.md +++ /dev/null @@ -1,76 +0,0 @@ -# Extending Monolog - -Monolog is fully extensible, allowing you to adapt your logger to your needs. - -## Writing your own handler - -Monolog provides many built-in handlers. But if the one you need does not -exist, you can write it and use it in your logger. The only requirement is -to implement `Monolog\Handler\HandlerInterface`. - -Let's write a PDOHandler to log records to a database. We will extend the -abstract class provided by Monolog to keep things DRY. - -```php -pdo = $pdo; - parent::__construct($level, $bubble); - } - - protected function write(array $record) - { - if (!$this->initialized) { - $this->initialize(); - } - - $this->statement->execute(array( - 'channel' => $record['channel'], - 'level' => $record['level'], - 'message' => $record['formatted'], - 'time' => $record['datetime']->format('U'), - )); - } - - private function initialize() - { - $this->pdo->exec( - 'CREATE TABLE IF NOT EXISTS monolog ' - .'(channel VARCHAR(255), level INTEGER, message LONGTEXT, time INTEGER UNSIGNED)' - ); - $this->statement = $this->pdo->prepare( - 'INSERT INTO monolog (channel, level, message, time) VALUES (:channel, :level, :message, :time)' - ); - - $this->initialized = true; - } -} -``` - -You can now use this handler in your logger: - -```php -pushHandler(new PDOHandler(new PDO('sqlite:logs.sqlite'))); - -// You can now use your logger -$logger->addInfo('My logger is now ready'); -``` - -The `Monolog\Handler\AbstractProcessingHandler` class provides most of the -logic needed for the handler, including the use of processors and the formatting -of the record (which is why we use ``$record['formatted']`` instead of ``$record['message']``). - -← [Utility classes](03-utilities.md) diff --git a/vendor/Gcp/monolog/monolog/doc/sockets.md b/vendor/Gcp/monolog/monolog/doc/sockets.md deleted file mode 100644 index ea9cf0ea..00000000 --- a/vendor/Gcp/monolog/monolog/doc/sockets.md +++ /dev/null @@ -1,39 +0,0 @@ -Sockets Handler -=============== - -This handler allows you to write your logs to sockets using [fsockopen](http://php.net/fsockopen) -or [pfsockopen](http://php.net/pfsockopen). - -Persistent sockets are mainly useful in web environments where you gain some performance not closing/opening -the connections between requests. - -You can use a `unix://` prefix to access unix sockets and `udp://` to open UDP sockets instead of the default TCP. - -Basic Example -------------- - -```php -setPersistent(true); - -// Now add the handler -$logger->pushHandler($handler, Logger::DEBUG); - -// You can now use your logger -$logger->addInfo('My logger is now ready'); - -``` - -In this example, using syslog-ng, you should see the log on the log server: - - cweb1 [2012-02-26 00:12:03] my_logger.INFO: My logger is now ready [] [] - diff --git a/vendor/Gcp/monolog/monolog/phpunit.xml.dist b/vendor/Gcp/monolog/monolog/phpunit.xml.dist deleted file mode 100644 index 20d82b63..00000000 --- a/vendor/Gcp/monolog/monolog/phpunit.xml.dist +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - tests/Monolog/ - - - - - - src/Monolog/ - - - - - - - diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php index fcc99fea..9b496f88 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/FluentdFormatter.php @@ -10,6 +10,7 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; /** * Class FluentdFormatter * @@ -59,7 +60,7 @@ public function format(array $record) $message['level'] = $record['level']; $message['level_name'] = $record['level_name']; } - return json_encode(array($tag, $record['datetime']->getTimestamp(), $message)); + return \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode(array($tag, $record['datetime']->getTimestamp(), $message)); } public function formatBatch(array $records) { diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php index 07d796aa..646e14d4 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; /** * Formats incoming records into an HTML table * @@ -111,8 +112,8 @@ protected function convertToString($data) } $data = $this->normalize($data); if (version_compare(PHP_VERSION, '5.4.0', '>=')) { - return json_encode($data, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE); + return \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($data, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE, true); } - return str_replace('\\/', '/', json_encode($data)); + return str_replace('\\/', '/', \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($data, null, true)); } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php index 813cecab..b5915e09 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php @@ -128,7 +128,7 @@ protected function normalize($data, $depth = 0) if ($depth > 9) { return 'Over 9 levels deep, aborting normalization'; } - if (is_array($data) || $data instanceof \Traversable) { + if (is_array($data)) { $normalized = array(); $count = 1; foreach ($data as $key => $value) { @@ -159,18 +159,12 @@ protected function normalizeException($e) if (!$e instanceof Exception && !$e instanceof Throwable) { throw new \InvalidArgumentException('Exception/Throwable expected, got ' . gettype($e) . ' / ' . \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($e)); } - $data = array('class' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($e), 'message' => $e->getMessage(), 'code' => $e->getCode(), 'file' => $e->getFile() . ':' . $e->getLine()); + $data = array('class' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($e), 'message' => $e->getMessage(), 'code' => (int) $e->getCode(), 'file' => $e->getFile() . ':' . $e->getLine()); if ($this->includeStacktraces) { $trace = $e->getTrace(); foreach ($trace as $frame) { if (isset($frame['file'])) { $data['trace'][] = $frame['file'] . ':' . $frame['line']; - } elseif (isset($frame['function']) && $frame['function'] === '{closure}') { - // We should again normalize the frames, because it might contain invalid items - $data['trace'][] = $frame['function']; - } else { - // We should again normalize the frames, because it might contain invalid items - $data['trace'][] = $this->normalize($frame); } } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/LineFormatter.php b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/LineFormatter.php index 1d494492..62d38430 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/LineFormatter.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/LineFormatter.php @@ -135,7 +135,7 @@ protected function convertToString($data) if (version_compare(PHP_VERSION, '5.4.0', '>=')) { return $this->toJson($data, true); } - return str_replace('\\/', '/', @json_encode($data)); + return str_replace('\\/', '/', $this->toJson($data, true)); } protected function replaceNewlines($str) { diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php index 5f6fde7d..35d2947b 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/MongoDBFormatter.php @@ -73,7 +73,7 @@ protected function formatObject($value, $nestingLevel) } protected function formatException(\Exception $exception, $nestingLevel) { - $formattedException = array('class' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($exception), 'message' => $exception->getMessage(), 'code' => $exception->getCode(), 'file' => $exception->getFile() . ':' . $exception->getLine()); + $formattedException = array('class' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($exception), 'message' => $exception->getMessage(), 'code' => (int) $exception->getCode(), 'file' => $exception->getFile() . ':' . $exception->getLine()); if ($this->exceptionTraceAsString === true) { $formattedException['trace'] = $exception->getTraceAsString(); } else { diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php index 8e1f8242..2ce69370 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php @@ -104,7 +104,7 @@ protected function normalizeException($e) if (!$e instanceof Exception && !$e instanceof \Throwable) { throw new \InvalidArgumentException('Exception/Throwable expected, got ' . gettype($e) . ' / ' . \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($e)); } - $data = array('class' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($e), 'message' => $e->getMessage(), 'code' => $e->getCode(), 'file' => $e->getFile() . ':' . $e->getLine()); + $data = array('class' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($e), 'message' => $e->getMessage(), 'code' => (int) $e->getCode(), 'file' => $e->getFile() . ':' . $e->getLine()); if ($e instanceof \SoapFault) { if (isset($e->faultcode)) { $data['faultcode'] = $e->faultcode; @@ -112,30 +112,14 @@ protected function normalizeException($e) if (isset($e->faultactor)) { $data['faultactor'] = $e->faultactor; } - if (isset($e->detail)) { - $data['detail'] = $e->detail; + if (isset($e->detail) && (is_string($e->detail) || is_object($e->detail) || is_array($e->detail))) { + $data['detail'] = is_string($e->detail) ? $e->detail : reset($e->detail); } } $trace = $e->getTrace(); foreach ($trace as $frame) { if (isset($frame['file'])) { $data['trace'][] = $frame['file'] . ':' . $frame['line']; - } elseif (isset($frame['function']) && $frame['function'] === '{closure}') { - // Simplify closures handling - $data['trace'][] = $frame['function']; - } else { - if (isset($frame['args'])) { - // Make sure that objects present as arguments are not serialized nicely but rather only - // as a class name to avoid any unexpected leak of sensitive information - $frame['args'] = array_map(function ($arg) { - if (is_object($arg) && !($arg instanceof \DateTime || $arg instanceof \DateTimeInterface)) { - return sprintf("[object] (%s)", \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::getClass($arg)); - } - return $arg; - }, $frame['args']); - } - // We should again normalize the frames, because it might contain invalid items - $data['trace'][] = $this->toJson($this->normalize($frame), true); } } if ($previous = $e->getPrevious()) { @@ -153,108 +137,6 @@ protected function normalizeException($e) */ protected function toJson($data, $ignoreErrors = false) { - // suppress json_encode errors since it's twitchy with some inputs - if ($ignoreErrors) { - return @$this->jsonEncode($data); - } - $json = $this->jsonEncode($data); - if ($json === false) { - $json = $this->handleJsonError(json_last_error(), $data); - } - return $json; - } - /** - * @param mixed $data - * @return string JSON encoded data or null on failure - */ - private function jsonEncode($data) - { - if (version_compare(PHP_VERSION, '5.4.0', '>=')) { - return json_encode($data, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE); - } - return json_encode($data); - } - /** - * Handle a json_encode failure. - * - * If the failure is due to invalid string encoding, try to clean the - * input and encode again. If the second encoding attempt fails, the - * inital error is not encoding related or the input can't be cleaned then - * raise a descriptive exception. - * - * @param int $code return code of json_last_error function - * @param mixed $data data that was meant to be encoded - * @throws \RuntimeException if failure can't be corrected - * @return string JSON encoded data after error correction - */ - private function handleJsonError($code, $data) - { - if ($code !== JSON_ERROR_UTF8) { - $this->throwEncodeError($code, $data); - } - if (is_string($data)) { - $this->detectAndCleanUtf8($data); - } elseif (is_array($data)) { - array_walk_recursive($data, array($this, 'detectAndCleanUtf8')); - } else { - $this->throwEncodeError($code, $data); - } - $json = $this->jsonEncode($data); - if ($json === false) { - $this->throwEncodeError(json_last_error(), $data); - } - return $json; - } - /** - * Throws an exception according to a given code with a customized message - * - * @param int $code return code of json_last_error function - * @param mixed $data data that was meant to be encoded - * @throws \RuntimeException - */ - private function throwEncodeError($code, $data) - { - switch ($code) { - case JSON_ERROR_DEPTH: - $msg = 'Maximum stack depth exceeded'; - break; - case JSON_ERROR_STATE_MISMATCH: - $msg = 'Underflow or the modes mismatch'; - break; - case JSON_ERROR_CTRL_CHAR: - $msg = 'Unexpected control character found'; - break; - case JSON_ERROR_UTF8: - $msg = 'Malformed UTF-8 characters, possibly incorrectly encoded'; - break; - default: - $msg = 'Unknown error'; - } - throw new \RuntimeException('JSON encoding failed: ' . $msg . '. Encoding: ' . var_export($data, true)); - } - /** - * Detect invalid UTF-8 string characters and convert to valid UTF-8. - * - * Valid UTF-8 input will be left unmodified, but strings containing - * invalid UTF-8 codepoints will be reencoded as UTF-8 with an assumed - * original encoding of ISO-8859-15. This conversion may result in - * incorrect output if the actual encoding was not ISO-8859-15, but it - * will be clean UTF-8 output and will not rely on expensive and fragile - * detection algorithms. - * - * Function converts the input in place in the passed variable so that it - * can be used as a callback for array_walk_recursive. - * - * @param mixed &$data Input to check and convert if needed - * @private - */ - public function detectAndCleanUtf8(&$data) - { - if (is_string($data) && !preg_match('//u', $data)) { - $data = preg_replace_callback('/[\\x80-\\xFF]+/', function ($m) { - return utf8_encode($m[0]); - }, $data); - $data = str_replace(array('¤', '¦', '¨', '´', '¸', '¼', '½', '¾'), array('€', 'Š', 'š', 'Ž', 'ž', 'Œ', 'œ', 'Ÿ'), $data); - } + return \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($data, null, $ignoreErrors); } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php index 9aa0102b..857f81c2 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BrowserConsoleHandler.php @@ -141,17 +141,18 @@ private static function generateScript() } private static function handleStyles($formatted) { - $args = array(static::quote('font-weight: normal')); + $args = array(); $format = '%c' . $formatted; preg_match_all('/\\[\\[(.*?)\\]\\]\\{([^}]*)\\}/s', $format, $matches, PREG_OFFSET_CAPTURE | PREG_SET_ORDER); foreach (array_reverse($matches) as $match) { - $args[] = static::quote(static::handleCustomStyles($match[2][0], $match[1][0])); $args[] = '"font-weight: normal"'; + $args[] = static::quote(static::handleCustomStyles($match[2][0], $match[1][0])); $pos = $match[0][1]; $format = substr($format, 0, $pos) . '%c' . $match[1][0] . '%c' . substr($format, $pos + strlen($match[0][0])); } - array_unshift($args, static::quote($format)); - return $args; + $args[] = static::quote('font-weight: normal'); + $args[] = static::quote($format); + return array_reverse($args); } private static function handleCustomStyles($style, $string) { diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BufferHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BufferHandler.php index f62373a6..2209ca59 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BufferHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/BufferHandler.php @@ -12,6 +12,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\ResettableInterface; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; /** * Buffers all records until closing the handler and then pass them as batch. * @@ -109,4 +110,19 @@ public function reset() $this->handler->reset(); } } + /** + * {@inheritdoc} + */ + public function setFormatter(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface $formatter) + { + $this->handler->setFormatter($formatter); + return $this; + } + /** + * {@inheritdoc} + */ + public function getFormatter() + { + return $this->handler->getFormatter(); + } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php index 7607977e..9d44fc57 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php @@ -12,6 +12,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\ChromePHPFormatter; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; /** * Handler sending logs to the ChromePHP extension (http://www.chromephp.com/) * @@ -37,7 +38,7 @@ class ChromePHPHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Han /** * Tracks whether we sent too much data * - * Chrome limits the headers to 256KB, so when we sent 240KB we stop sending + * Chrome limits the headers to 4KB, so when we sent 3KB we stop sending * * @var bool */ @@ -110,13 +111,13 @@ protected function send() } self::$json['request_uri'] = isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : ''; } - $json = @json_encode(self::$json); + $json = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode(self::$json, null, true); $data = base64_encode(utf8_encode($json)); - if (strlen($data) > 240 * 1024) { + if (strlen($data) > 3 * 1024) { self::$overflowed = true; $record = array('message' => 'Incomplete logs, chrome header size limit reached', 'context' => array(), 'level' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::WARNING, 'level_name' => \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::getLevelName(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::WARNING), 'channel' => 'monolog', 'datetime' => new \DateTime(), 'extra' => array()); self::$json['rows'][count(self::$json['rows']) - 1] = $this->getFormatter()->format($record); - $json = @json_encode(self::$json); + $json = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode(self::$json, null, true); $data = base64_encode(utf8_encode($json)); } if (trim($data) !== '') { diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/CubeHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/CubeHandler.php index 9823d85e..cbcf8221 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/CubeHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/CubeHandler.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; /** * Logs to Cube. * @@ -98,9 +99,9 @@ protected function write(array $record) $data['data'] = $record['context']; $data['data']['level'] = $record['level']; if ($this->scheme === 'http') { - $this->writeHttp(json_encode($data)); + $this->writeHttp(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($data)); } else { - $this->writeUdp(json_encode($data)); + $this->writeUdp(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($data)); } } private function writeUdp($data) diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FilterHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FilterHandler.php index aedda478..d07fa762 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FilterHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FilterHandler.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; /** * Simple handler wrapper that filters records based on a list of levels * @@ -40,7 +41,7 @@ class FilterHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handle */ protected $bubble; /** - * @param callable|HandlerInterface $handler Handler or factory callable($record, $this). + * @param callable|HandlerInterface $handler Handler or factory callable($record|null, $filterHandler). * @param int|array $minLevelOrList A list of levels to accept or a minimum level if maxLevel is provided * @param int $maxLevel Maximum level to accept, only used if $minLevelOrList is not an array * @param bool $bubble Whether the messages that are handled can bubble up the stack or not @@ -93,19 +94,12 @@ public function handle(array $record) if (!$this->isHandling($record)) { return false; } - // The same logic as in FingersCrossedHandler - if (!$this->handler instanceof HandlerInterface) { - $this->handler = call_user_func($this->handler, $record, $this); - if (!$this->handler instanceof HandlerInterface) { - throw new \RuntimeException("The factory callable should return a HandlerInterface"); - } - } if ($this->processors) { foreach ($this->processors as $processor) { $record = call_user_func($processor, $record); } } - $this->handler->handle($record); + $this->getHandler($record)->handle($record); return false === $this->bubble; } /** @@ -119,6 +113,38 @@ public function handleBatch(array $records) $filtered[] = $record; } } - $this->handler->handleBatch($filtered); + $this->getHandler($filtered[count($filtered) - 1])->handleBatch($filtered); + } + /** + * Return the nested handler + * + * If the handler was provided as a factory callable, this will trigger the handler's instantiation. + * + * @return HandlerInterface + */ + public function getHandler(array $record = null) + { + if (!$this->handler instanceof HandlerInterface) { + $this->handler = call_user_func($this->handler, $record, $this); + if (!$this->handler instanceof HandlerInterface) { + throw new \RuntimeException("The factory callable should return a HandlerInterface"); + } + } + return $this->handler; + } + /** + * {@inheritdoc} + */ + public function setFormatter(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface $formatter) + { + $this->getHandler()->setFormatter($formatter); + return $this; + } + /** + * {@inheritdoc} + */ + public function getFormatter() + { + return $this->getHandler()->getFormatter(); } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php index 5b8f3607..39e3364a 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php @@ -14,6 +14,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\FingersCrossed\ActivationStrategyInterface; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\ResettableInterface; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; /** * Buffers all records until a certain level is reached * @@ -36,7 +37,7 @@ class FingersCrossedHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolo protected $stopBuffering; protected $passthruLevel; /** - * @param callable|HandlerInterface $handler Handler or factory callable($record, $fingersCrossedHandler). + * @param callable|HandlerInterface $handler Handler or factory callable($record|null, $fingersCrossedHandler). * @param int|ActivationStrategyInterface $activationStrategy Strategy which determines when this handler takes action * @param int $bufferSize How many entries should be buffered at most, beyond that the oldest items are removed from the buffer. * @param bool $bubble Whether the messages that are handled can bubble up the stack or not @@ -79,14 +80,7 @@ public function activate() if ($this->stopBuffering) { $this->buffering = false; } - if (!$this->handler instanceof HandlerInterface) { - $record = end($this->buffer) ?: null; - $this->handler = call_user_func($this->handler, $record, $this); - if (!$this->handler instanceof HandlerInterface) { - throw new \RuntimeException("The factory callable should return a HandlerInterface"); - } - } - $this->handler->handleBatch($this->buffer); + $this->getHandler(end($this->buffer) ?: null)->handleBatch($this->buffer); $this->buffer = array(); } /** @@ -108,7 +102,7 @@ public function handle(array $record) $this->activate(); } } else { - $this->handler->handle($record); + $this->getHandler($record)->handle($record); } return false === $this->bubble; } @@ -123,8 +117,8 @@ public function reset() { $this->flushBuffer(); parent::reset(); - if ($this->handler instanceof ResettableInterface) { - $this->handler->reset(); + if ($this->getHandler() instanceof ResettableInterface) { + $this->getHandler()->reset(); } } /** @@ -148,10 +142,42 @@ private function flushBuffer() return $record['level'] >= $level; }); if (count($this->buffer) > 0) { - $this->handler->handleBatch($this->buffer); + $this->getHandler(end($this->buffer) ?: null)->handleBatch($this->buffer); } } $this->buffer = array(); $this->buffering = true; } + /** + * Return the nested handler + * + * If the handler was provided as a factory callable, this will trigger the handler's instantiation. + * + * @return HandlerInterface + */ + public function getHandler(array $record = null) + { + if (!$this->handler instanceof HandlerInterface) { + $this->handler = call_user_func($this->handler, $record, $this); + if (!$this->handler instanceof HandlerInterface) { + throw new \RuntimeException("The factory callable should return a HandlerInterface"); + } + } + return $this->handler; + } + /** + * {@inheritdoc} + */ + public function setFormatter(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface $formatter) + { + $this->getHandler()->setFormatter($formatter); + return $this; + } + /** + * {@inheritdoc} + */ + public function getFormatter() + { + return $this->getHandler()->getFormatter(); + } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php index e6f2dbe3..ac8a6f4e 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FlowdockFormatter; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; /** @@ -93,7 +94,7 @@ protected function generateDataStream($record) */ private function buildContent($record) { - return json_encode($record['formatted']['flowdock']); + return \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($record['formatted']['flowdock']); } /** * Builds the header of the API Call diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FormattableHandlerInterface.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FormattableHandlerInterface.php new file mode 100644 index 00000000..8e740b85 --- /dev/null +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FormattableHandlerInterface.php @@ -0,0 +1,37 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; + +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; +/** + * Interface to describe loggers that have a formatter + * + * This interface is present in monolog 1.x to ease forward compatibility. + * + * @author Jordi Boggiano + */ +interface FormattableHandlerInterface +{ + /** + * Sets the formatter. + * + * @param FormatterInterface $formatter + * @return HandlerInterface self + */ + public function setFormatter(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface $formatter) : HandlerInterface; + /** + * Gets the formatter. + * + * @return FormatterInterface + */ + public function getFormatter() : FormatterInterface; +} diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FormattableHandlerTrait.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FormattableHandlerTrait.php new file mode 100644 index 00000000..22c2dce2 --- /dev/null +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/FormattableHandlerTrait.php @@ -0,0 +1,57 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; + +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\LineFormatter; +/** + * Helper trait for implementing FormattableInterface + * + * This trait is present in monolog 1.x to ease forward compatibility. + * + * @author Jordi Boggiano + */ +trait FormattableHandlerTrait +{ + /** + * @var FormatterInterface + */ + protected $formatter; + /** + * {@inheritdoc} + * @suppress PhanTypeMismatchReturn + */ + public function setFormatter(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface $formatter) : HandlerInterface + { + $this->formatter = $formatter; + return $this; + } + /** + * {@inheritdoc} + */ + public function getFormatter() : FormatterInterface + { + if (!$this->formatter) { + $this->formatter = $this->getDefaultFormatter(); + } + return $this->formatter; + } + /** + * Gets the default formatter. + * + * Overwrite this if the LineFormatter is not a good default for your handler. + */ + protected function getDefaultFormatter() : FormatterInterface + { + return new \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\LineFormatter(); + } +} diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/GroupHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/GroupHandler.php index 17745f66..0d713f0c 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/GroupHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/GroupHandler.php @@ -70,8 +70,9 @@ public function handleBatch(array $records) $processed = array(); foreach ($records as $record) { foreach ($this->processors as $processor) { - $processed[] = call_user_func($processor, $record); + $record = call_user_func($processor, $record); } + $processed[] = $record; } $records = $processed; } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/HipChatHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/HipChatHandler.php index a52b1e87..7533ca0f 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/HipChatHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/HipChatHandler.php @@ -84,6 +84,7 @@ class HipChatHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handl */ public function __construct($token, $room, $name = 'Monolog', $notify = false, $level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::CRITICAL, $bubble = true, $useSSL = true, $format = 'text', $host = 'api.hipchat.com', $version = self::API_V1) { + @trigger_error('The Monolog\\Handler\\HipChatHandler class is deprecated. You should migrate to Slack and the SlackWebhookHandler / SlackbotHandler, see https://www.atlassian.com/partnerships/slack', E_USER_DEPRECATED); if ($version == self::API_V1 && !$this->validateStringLength($name, static::MAXIMUM_NAME_LENGTH)) { throw new \InvalidArgumentException('The supplied name is too long. HipChat\'s v1 API supports names up to 15 UTF-8 characters.'); } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php index 4a790c9c..f5094711 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/IFTTTHandler.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; /** * IFTTTHandler uses cURL to trigger IFTTT Maker actions * @@ -44,7 +45,7 @@ public function __construct($eventName, $secretKey, $level = \DeliciousBrains\WP public function write(array $record) { $postData = array("value1" => $record["channel"], "value2" => $record["level_name"], "value3" => $record["message"]); - $postString = json_encode($postData); + $postString = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($postData); $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "https://maker.ifttt.com/trigger/" . $this->eventName . "/with/key/" . $this->secretKey); curl_setopt($ch, CURLOPT_POST, true); diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php index 11fa38ea..ba74aa89 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/InsightOpsHandler.php @@ -35,7 +35,7 @@ class InsightOpsHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Ha public function __construct($token, $region = 'us', $useSSL = true, $level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG, $bubble = true) { if ($useSSL && !extension_loaded('openssl')) { - throw new \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\MissingExtensionException('The OpenSSL PHP plugin is required to use SSL encrypted connection for LogEntriesHandler'); + throw new \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\MissingExtensionException('The OpenSSL PHP plugin is required to use SSL encrypted connection for InsightOpsHandler'); } $endpoint = $useSSL ? 'ssl://' . $region . '.data.logs.insight.rapid7.com:443' : $region . '.data.logs.insight.rapid7.com:80'; parent::__construct($endpoint, $level, $bubble); diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php index aece43da..416c7de6 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\NormalizerFormatter; /** * Class to record a log on a NewRelic application. @@ -165,7 +166,7 @@ protected function setNewRelicParameter($key, $value) if (null === $value || is_scalar($value)) { newrelic_add_custom_parameter($key, $value); } else { - newrelic_add_custom_parameter($key, @json_encode($value)); + newrelic_add_custom_parameter($key, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($value, null, true)); } } /** diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php index d6d717cd..175595a1 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/PHPConsoleHandler.php @@ -13,6 +13,7 @@ use Exception; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\LineFormatter; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; use DeliciousBrains\WP_Offload_Media\Gcp\PhpConsole\Connector; use DeliciousBrains\WP_Offload_Media\Gcp\PhpConsole\Handler; use DeliciousBrains\WP_Offload_Media\Gcp\PhpConsole\Helper; @@ -191,7 +192,7 @@ private function handleDebugRecord(array $record) $tags = $this->getRecordTags($record); $message = $record['message']; if ($record['context']) { - $message .= ' ' . json_encode($this->connector->getDumper()->dump(array_filter($record['context']))); + $message .= ' ' . \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($this->connector->getDumper()->dump(array_filter($record['context'])), null, true); } $this->connector->getDebugDispatcher()->dispatchDebug($message, $tags, $this->options['classesPartialsTraceIgnore']); } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ProcessableHandlerInterface.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ProcessableHandlerInterface.php new file mode 100644 index 00000000..2045846a --- /dev/null +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ProcessableHandlerInterface.php @@ -0,0 +1,38 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; + +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Processor\ProcessorInterface; +/** + * Interface to describe loggers that have processors + * + * This interface is present in monolog 1.x to ease forward compatibility. + * + * @author Jordi Boggiano + */ +interface ProcessableHandlerInterface +{ + /** + * Adds a processor in the stack. + * + * @param ProcessorInterface|callable $callback + * @return HandlerInterface self + */ + public function pushProcessor($callback) : HandlerInterface; + /** + * Removes the processor on top of the stack and returns it. + * + * @throws \LogicException In case the processor stack is empty + * @return callable + */ + public function popProcessor() : callable; +} diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ProcessableHandlerTrait.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ProcessableHandlerTrait.php new file mode 100644 index 00000000..0d8a249c --- /dev/null +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ProcessableHandlerTrait.php @@ -0,0 +1,65 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; + +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\ResettableInterface; +/** + * Helper trait for implementing ProcessableInterface + * + * This trait is present in monolog 1.x to ease forward compatibility. + * + * @author Jordi Boggiano + */ +trait ProcessableHandlerTrait +{ + /** + * @var callable[] + */ + protected $processors = []; + /** + * {@inheritdoc} + * @suppress PhanTypeMismatchReturn + */ + public function pushProcessor($callback) : HandlerInterface + { + array_unshift($this->processors, $callback); + return $this; + } + /** + * {@inheritdoc} + */ + public function popProcessor() : callable + { + if (!$this->processors) { + throw new \LogicException('You tried to pop from an empty processor stack.'); + } + return array_shift($this->processors); + } + /** + * Processes a record. + */ + protected function processRecord(array $record) : array + { + foreach ($this->processors as $processor) { + $record = $processor($record); + } + return $record; + } + protected function resetProcessors() : void + { + foreach ($this->processors as $processor) { + if ($processor instanceof ResettableInterface) { + $processor->reset(); + } + } + } +} diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/RavenHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/RavenHandler.php index 24afa214..9c602a8d 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/RavenHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/RavenHandler.php @@ -46,6 +46,7 @@ class RavenHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler */ public function __construct(\Raven_Client $ravenClient, $level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG, $bubble = true) { + @trigger_error('The Monolog\\Handler\\RavenHandler class is deprecated. You should rather upgrade to the sentry/sentry 2.x and use Sentry\\Monolog\\Handler, see https://github.com/getsentry/sentry-php/blob/master/src/Monolog/Handler.php', E_USER_DEPRECATED); parent::__construct($level, $bubble); $this->ravenClient = $ravenClient; } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SamplingHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SamplingHandler.php index 372b6fe8..501b3e39 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SamplingHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SamplingHandler.php @@ -10,6 +10,7 @@ */ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; /** * Sampling handler * @@ -35,7 +36,7 @@ class SamplingHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Hand */ protected $factor; /** - * @param callable|HandlerInterface $handler Handler or factory callable($record, $fingersCrossedHandler). + * @param callable|HandlerInterface $handler Handler or factory callable($record|null, $samplingHandler). * @param int $factor Sample factor */ public function __construct($handler, $factor) @@ -49,25 +50,50 @@ public function __construct($handler, $factor) } public function isHandling(array $record) { - return $this->handler->isHandling($record); + return $this->getHandler($record)->isHandling($record); } public function handle(array $record) { if ($this->isHandling($record) && mt_rand(1, $this->factor) === 1) { - // The same logic as in FingersCrossedHandler - if (!$this->handler instanceof HandlerInterface) { - $this->handler = call_user_func($this->handler, $record, $this); - if (!$this->handler instanceof HandlerInterface) { - throw new \RuntimeException("The factory callable should return a HandlerInterface"); - } - } if ($this->processors) { foreach ($this->processors as $processor) { $record = call_user_func($processor, $record); } } - $this->handler->handle($record); + $this->getHandler($record)->handle($record); } return false === $this->bubble; } + /** + * Return the nested handler + * + * If the handler was provided as a factory callable, this will trigger the handler's instantiation. + * + * @return HandlerInterface + */ + public function getHandler(array $record = null) + { + if (!$this->handler instanceof HandlerInterface) { + $this->handler = call_user_func($this->handler, $record, $this); + if (!$this->handler instanceof HandlerInterface) { + throw new \RuntimeException("The factory callable should return a HandlerInterface"); + } + } + return $this->handler; + } + /** + * {@inheritdoc} + */ + public function setFormatter(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface $formatter) + { + $this->getHandler()->setFormatter($formatter); + return $this; + } + /** + * {@inheritdoc} + */ + public function getFormatter() + { + return $this->getHandler()->getFormatter(); + } } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php index 81b756bd..7b888af2 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/Slack/SlackRecord.php @@ -11,6 +11,7 @@ namespace DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\Slack; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\NormalizerFormatter; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; /** @@ -164,9 +165,13 @@ public function stringify($fields) { $normalized = $this->normalizerFormatter->format($fields); $prettyPrintFlag = defined('JSON_PRETTY_PRINT') ? JSON_PRETTY_PRINT : 128; + $flags = 0; + if (PHP_VERSION_ID >= 50400) { + $flags = JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE; + } $hasSecondDimension = count(array_filter($normalized, 'is_array')); $hasNonNumericKeys = !count(array_filter(array_keys($normalized), 'is_numeric')); - return $hasSecondDimension || $hasNonNumericKeys ? json_encode($normalized, $prettyPrintFlag) : json_encode($normalized); + return $hasSecondDimension || $hasNonNumericKeys ? \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($normalized, $prettyPrintFlag | $flags) : \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($normalized, $flags); } /** * Sets the formatter diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackHandler.php index 65255b3a..8204debe 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackHandler.php @@ -12,6 +12,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\Slack\SlackRecord; /** * Sends notifications through Slack API @@ -94,7 +95,7 @@ protected function prepareContentData($record) $dataArray = $this->slackRecord->getSlackData($record); $dataArray['token'] = $this->token; if (!empty($dataArray['attachments'])) { - $dataArray['attachments'] = json_encode($dataArray['attachments']); + $dataArray['attachments'] = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($dataArray['attachments']); } return $dataArray; } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php index 8c4c6bbe..164ecf07 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackWebhookHandler.php @@ -12,6 +12,7 @@ use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Formatter\FormatterInterface; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger; +use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils; use DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\Slack\SlackRecord; /** * Sends notifications through Slack Webhooks @@ -65,7 +66,7 @@ public function getWebhookUrl() protected function write(array $record) { $postData = $this->slackRecord->getSlackData($record); - $postString = json_encode($postData); + $postString = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Utils::jsonEncode($postData); $ch = curl_init(); $options = array(CURLOPT_URL => $this->webhookUrl, CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => array('Content-type: application/json'), CURLOPT_POSTFIELDS => $postString); if (defined('CURLOPT_SAFE_UPLOAD')) { diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php index b94e2553..38163a69 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SlackbotHandler.php @@ -14,8 +14,11 @@ /** * Sends notifications through Slack's Slackbot * - * @author Haralan Dobrev - * @see https://slack.com/apps/A0F81R8ET-slackbot + * @author Haralan Dobrev + * @see https://slack.com/apps/A0F81R8ET-slackbot + * @deprecated According to Slack the API used on this handler it is deprecated. + * Therefore this handler will be removed on 2.x + * Slack suggests to use webhooks instead. Please contact slack for more information. */ class SlackbotHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\AbstractProcessingHandler { @@ -43,6 +46,7 @@ class SlackbotHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Hand */ public function __construct($slackTeam, $token, $channel, $level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::CRITICAL, $bubble = true) { + @trigger_error('SlackbotHandler is deprecated and will be removed on 2.x', E_USER_DEPRECATED); parent::__construct($level, $bubble); $this->slackTeam = $slackTeam; $this->token = $token; diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/StreamHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/StreamHandler.php index 56f575c8..f4efda4d 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/StreamHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/StreamHandler.php @@ -58,6 +58,7 @@ public function close() fclose($this->stream); } $this->stream = null; + $this->dirCreated = null; } /** * Return the currently active stream if it is open diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php index 734b1a45..d006ff61 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/SyslogUdpHandler.php @@ -16,11 +16,16 @@ * A Handler for logging to a remote syslogd server. * * @author Jesper Skovgaard Nielsen + * @author Dominik Kukacka */ class SyslogUdpHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\AbstractSyslogHandler { + const RFC3164 = 0; + const RFC5424 = 1; + private $dateFormats = array(self::RFC3164 => 'M d H:i:s', self::RFC5424 => \DateTime::RFC3339); protected $socket; protected $ident; + protected $rfc; /** * @param string $host * @param int $port @@ -28,11 +33,13 @@ class SyslogUdpHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Han * @param int $level The minimum logging level at which this handler will be triggered * @param bool $bubble Whether the messages that are handled can bubble up the stack or not * @param string $ident Program name or tag for each log message. + * @param int $rfc RFC to format the message for. */ - public function __construct($host, $port = 514, $facility = LOG_USER, $level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG, $bubble = true, $ident = 'php') + public function __construct($host, $port = 514, $facility = LOG_USER, $level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG, $bubble = true, $ident = 'php', $rfc = self::RFC5424) { parent::__construct($facility, $level, $bubble); $this->ident = $ident; + $this->rfc = $rfc; $this->socket = new \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\SyslogUdp\UdpSocket($host, $port ?: 514); } protected function write(array $record) @@ -55,7 +62,7 @@ private function splitMessageIntoLines($message) return preg_split('/$\\R?^/m', $message, -1, PREG_SPLIT_NO_EMPTY); } /** - * Make common syslog header (see rfc5424) + * Make common syslog header (see rfc5424 or rfc3164) */ protected function makeCommonSyslogHeader($severity) { @@ -66,11 +73,16 @@ protected function makeCommonSyslogHeader($severity) if (!($hostname = gethostname())) { $hostname = '-'; } - return "<{$priority}>1 " . $this->getDateTime() . " " . $hostname . " " . $this->ident . " " . $pid . " - - "; + $date = $this->getDateTime(); + if ($this->rfc === self::RFC3164) { + return "<{$priority}>" . $date . " " . $hostname . " " . $this->ident . "[" . $pid . "]: "; + } else { + return "<{$priority}>1 " . $date . " " . $hostname . " " . $this->ident . " " . $pid . " - - "; + } } protected function getDateTime() { - return date(\DateTime::RFC3339); + return date($this->dateFormats[$this->rfc]); } /** * Inject your own socket, mainly used for testing diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/TestHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/TestHandler.php index 209699c5..60377f3c 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/TestHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/TestHandler.php @@ -66,6 +66,7 @@ class TestHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\ { protected $records = array(); protected $recordsByLevel = array(); + private $skipReset = false; public function getRecords() { return $this->records; @@ -75,6 +76,16 @@ public function clear() $this->records = array(); $this->recordsByLevel = array(); } + public function reset() + { + if (!$this->skipReset) { + $this->clear(); + } + } + public function setSkipReset($skipReset) + { + $this->skipReset = $skipReset; + } public function hasRecords($level) { return isset($this->recordsByLevel[$level]); diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php index d0c3ce4b..f3463cd2 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/WhatFailureGroupHandler.php @@ -48,8 +48,9 @@ public function handleBatch(array $records) $processed = array(); foreach ($records as $record) { foreach ($this->processors as $processor) { - $processed[] = call_user_func($processor, $record); + $record = call_user_func($processor, $record); } + $processed[] = $record; } $records = $processed; } diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php index 456ae691..c6e615d2 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php @@ -16,6 +16,7 @@ * Handler sending logs to Zend Monitor * * @author Christian Bergau + * @author Jason Davis */ class ZendMonitorHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\AbstractProcessingHandler { @@ -24,7 +25,7 @@ class ZendMonitorHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\H * * @var array */ - protected $levelMap = array(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG => 1, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::INFO => 2, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::NOTICE => 3, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::WARNING => 4, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::ERROR => 5, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::CRITICAL => 6, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::ALERT => 7, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::EMERGENCY => 0); + protected $levelMap = array(); /** * Construct * @@ -35,8 +36,10 @@ class ZendMonitorHandler extends \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\H public function __construct($level = \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG, $bubble = true) { if (!function_exists('zend_monitor_custom_event')) { - throw new \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\MissingExtensionException('You must have Zend Server installed in order to use this handler'); + throw new \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Handler\MissingExtensionException('You must have Zend Server installed with Zend Monitor enabled in order to use this handler'); } + //zend monitor constants are not defined if zend monitor is not enabled. + $this->levelMap = array(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::DEBUG => \ZEND_MONITOR_EVENT_SEVERITY_INFO, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::INFO => \ZEND_MONITOR_EVENT_SEVERITY_INFO, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::NOTICE => \ZEND_MONITOR_EVENT_SEVERITY_INFO, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::WARNING => \ZEND_MONITOR_EVENT_SEVERITY_WARNING, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::ERROR => \ZEND_MONITOR_EVENT_SEVERITY_ERROR, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::CRITICAL => \ZEND_MONITOR_EVENT_SEVERITY_ERROR, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::ALERT => \ZEND_MONITOR_EVENT_SEVERITY_ERROR, \DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::EMERGENCY => \ZEND_MONITOR_EVENT_SEVERITY_ERROR); parent::__construct($level, $bubble); } /** @@ -44,18 +47,18 @@ public function __construct($level = \DeliciousBrains\WP_Offload_Media\Gcp\Monol */ protected function write(array $record) { - $this->writeZendMonitorCustomEvent($this->levelMap[$record['level']], $record['message'], $record['formatted']); + $this->writeZendMonitorCustomEvent(\DeliciousBrains\WP_Offload_Media\Gcp\Monolog\Logger::getLevelName($record['level']), $record['message'], $record['formatted'], $this->levelMap[$record['level']]); } /** - * Write a record to Zend Monitor - * - * @param int $level - * @param string $message - * @param array $formatted + * Write to Zend Monitor Events + * @param string $type Text displayed in "Class Name (custom)" field + * @param string $message Text displayed in "Error String" + * @param mixed $formatted Displayed in Custom Variables tab + * @param int $severity Set the event severity level (-1,0,1) */ - protected function writeZendMonitorCustomEvent($level, $message, $formatted) + protected function writeZendMonitorCustomEvent($type, $message, $formatted, $severity) { - zend_monitor_custom_event($level, $message, $formatted); + zend_monitor_custom_event($type, $message, $formatted, $severity); } /** * {@inheritdoc} diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/SignalHandler.php b/vendor/Gcp/monolog/monolog/src/Monolog/SignalHandler.php index 1558833d..b7b220d2 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/SignalHandler.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/SignalHandler.php @@ -81,7 +81,7 @@ public function handleSignal($signo, array $siginfo = null) } if ($this->previousSignalHandler[$signo] === true || $this->previousSignalHandler[$signo] === SIG_DFL) { if (extension_loaded('pcntl') && function_exists('pcntl_signal') && function_exists('pcntl_sigprocmask') && function_exists('pcntl_signal_dispatch') && extension_loaded('posix') && function_exists('posix_getpid') && function_exists('posix_kill')) { - $restartSyscalls = isset($this->restartSyscalls[$signo]) ? $this->restartSyscalls[$signo] : true; + $restartSyscalls = isset($this->signalRestartSyscalls[$signo]) ? $this->signalRestartSyscalls[$signo] : true; pcntl_signal($signo, SIG_DFL, $restartSyscalls); pcntl_sigprocmask(SIG_UNBLOCK, array($signo), $oldset); posix_kill(posix_getpid(), $signo); diff --git a/vendor/Gcp/monolog/monolog/src/Monolog/Utils.php b/vendor/Gcp/monolog/monolog/src/Monolog/Utils.php index 9f99c0f4..55a0bf88 100644 --- a/vendor/Gcp/monolog/monolog/src/Monolog/Utils.php +++ b/vendor/Gcp/monolog/monolog/src/Monolog/Utils.php @@ -20,4 +20,118 @@ public static function getClass($object) $class = \get_class($object); return 'c' === $class[0] && 0 === strpos($class, "class@anonymous\0") ? get_parent_class($class) . '@anonymous' : $class; } + /** + * Return the JSON representation of a value + * + * @param mixed $data + * @param int $encodeFlags flags to pass to json encode, defaults to JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE + * @param bool $ignoreErrors whether to ignore encoding errors or to throw on error, when ignored and the encoding fails, "null" is returned which is valid json for null + * @throws \RuntimeException if encoding fails and errors are not ignored + * @return string + */ + public static function jsonEncode($data, $encodeFlags = null, $ignoreErrors = false) + { + if (null === $encodeFlags && version_compare(PHP_VERSION, '5.4.0', '>=')) { + $encodeFlags = JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE; + } + if ($ignoreErrors) { + $json = @json_encode($data, $encodeFlags); + if (false === $json) { + return 'null'; + } + return $json; + } + $json = json_encode($data, $encodeFlags); + if (false === $json) { + $json = self::handleJsonError(json_last_error(), $data); + } + return $json; + } + /** + * Handle a json_encode failure. + * + * If the failure is due to invalid string encoding, try to clean the + * input and encode again. If the second encoding attempt fails, the + * inital error is not encoding related or the input can't be cleaned then + * raise a descriptive exception. + * + * @param int $code return code of json_last_error function + * @param mixed $data data that was meant to be encoded + * @param int $encodeFlags flags to pass to json encode, defaults to JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE + * @throws \RuntimeException if failure can't be corrected + * @return string JSON encoded data after error correction + */ + public static function handleJsonError($code, $data, $encodeFlags = null) + { + if ($code !== JSON_ERROR_UTF8) { + self::throwEncodeError($code, $data); + } + if (is_string($data)) { + self::detectAndCleanUtf8($data); + } elseif (is_array($data)) { + array_walk_recursive($data, array('DeliciousBrains\\WP_Offload_Media\\Gcp\\Monolog\\Utils', 'detectAndCleanUtf8')); + } else { + self::throwEncodeError($code, $data); + } + if (null === $encodeFlags && version_compare(PHP_VERSION, '5.4.0', '>=')) { + $encodeFlags = JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE; + } + $json = json_encode($data, $encodeFlags); + if ($json === false) { + self::throwEncodeError(json_last_error(), $data); + } + return $json; + } + /** + * Throws an exception according to a given code with a customized message + * + * @param int $code return code of json_last_error function + * @param mixed $data data that was meant to be encoded + * @throws \RuntimeException + */ + private static function throwEncodeError($code, $data) + { + switch ($code) { + case JSON_ERROR_DEPTH: + $msg = 'Maximum stack depth exceeded'; + break; + case JSON_ERROR_STATE_MISMATCH: + $msg = 'Underflow or the modes mismatch'; + break; + case JSON_ERROR_CTRL_CHAR: + $msg = 'Unexpected control character found'; + break; + case JSON_ERROR_UTF8: + $msg = 'Malformed UTF-8 characters, possibly incorrectly encoded'; + break; + default: + $msg = 'Unknown error'; + } + throw new \RuntimeException('JSON encoding failed: ' . $msg . '. Encoding: ' . var_export($data, true)); + } + /** + * Detect invalid UTF-8 string characters and convert to valid UTF-8. + * + * Valid UTF-8 input will be left unmodified, but strings containing + * invalid UTF-8 codepoints will be reencoded as UTF-8 with an assumed + * original encoding of ISO-8859-15. This conversion may result in + * incorrect output if the actual encoding was not ISO-8859-15, but it + * will be clean UTF-8 output and will not rely on expensive and fragile + * detection algorithms. + * + * Function converts the input in place in the passed variable so that it + * can be used as a callback for array_walk_recursive. + * + * @param mixed &$data Input to check and convert if needed + * @private + */ + public static function detectAndCleanUtf8(&$data) + { + if (is_string($data) && !preg_match('//u', $data)) { + $data = preg_replace_callback('/[\\x80-\\xFF]+/', function ($m) { + return utf8_encode($m[0]); + }, $data); + $data = str_replace(array('¤', '¦', '¨', '´', '¸', '¼', '½', '¾'), array('€', 'Š', 'š', 'Ž', 'ž', 'Œ', 'œ', 'Ÿ'), $data); + } + } } diff --git a/vendor/Gcp/psr/log/Psr/Log/LoggerInterface.php b/vendor/Gcp/psr/log/Psr/Log/LoggerInterface.php index b65af1c9..dce4816b 100644 --- a/vendor/Gcp/psr/log/Psr/Log/LoggerInterface.php +++ b/vendor/Gcp/psr/log/Psr/Log/LoggerInterface.php @@ -110,6 +110,8 @@ public function debug($message, array $context = array()); * @param array $context * * @return void + * + * @throws \Psr\Log\InvalidArgumentException */ public function log($level, $message, array $context = array()); } diff --git a/vendor/Gcp/psr/log/Psr/Log/LoggerTrait.php b/vendor/Gcp/psr/log/Psr/Log/LoggerTrait.php index 9160aac3..bf70cc33 100644 --- a/vendor/Gcp/psr/log/Psr/Log/LoggerTrait.php +++ b/vendor/Gcp/psr/log/Psr/Log/LoggerTrait.php @@ -127,6 +127,8 @@ public function debug($message, array $context = array()) * @param array $context * * @return void + * + * @throws \Psr\Log\InvalidArgumentException */ public abstract function log($level, $message, array $context = array()); } diff --git a/vendor/Gcp/psr/log/Psr/Log/NullLogger.php b/vendor/Gcp/psr/log/Psr/Log/NullLogger.php index 8b6fdefd..318b707b 100644 --- a/vendor/Gcp/psr/log/Psr/Log/NullLogger.php +++ b/vendor/Gcp/psr/log/Psr/Log/NullLogger.php @@ -20,6 +20,8 @@ class NullLogger extends \DeliciousBrains\WP_Offload_Media\Gcp\Psr\Log\AbstractL * @param array $context * * @return void + * + * @throws \Psr\Log\InvalidArgumentException */ public function log($level, $message, array $context = array()) { diff --git a/vendor/Gcp/psr/log/README.md b/vendor/Gcp/psr/log/README.md index 5571a25e..a9f20c43 100644 --- a/vendor/Gcp/psr/log/README.md +++ b/vendor/Gcp/psr/log/README.md @@ -38,6 +38,12 @@ class Foo if ($this->logger) { $this->logger->info('Doing work'); } + + try { + $this->doSomethingElse(); + } catch (Exception $exception) { + $this->logger->error('Oh no!', array('exception' => $exception)); + } // do something useful } diff --git a/vendor/Gcp/psr/log/composer.json b/vendor/Gcp/psr/log/composer.json index e90cf143..3f08ce6b 100644 --- a/vendor/Gcp/psr/log/composer.json +++ b/vendor/Gcp/psr/log/composer.json @@ -24,7 +24,7 @@ }, "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.1.x-dev" } } } \ No newline at end of file diff --git a/vendor/Gcp/ralouphie/getallheaders/README.md b/vendor/Gcp/ralouphie/getallheaders/README.md index f3329d66..9430d76b 100644 --- a/vendor/Gcp/ralouphie/getallheaders/README.md +++ b/vendor/Gcp/ralouphie/getallheaders/README.md @@ -14,6 +14,14 @@ This is a simple polyfill for [`getallheaders()`](http://www.php.net/manual/en/f ## Install +For PHP version **`>= 5.6`**: + ``` composer require ralouphie/getallheaders ``` + +For PHP version **`< 5.6`**: + +``` +composer require ralouphie/getallheaders "^2" +``` diff --git a/vendor/Gcp/ralouphie/getallheaders/composer.json b/vendor/Gcp/ralouphie/getallheaders/composer.json index 7892a0fe..455e35bb 100644 --- a/vendor/Gcp/ralouphie/getallheaders/composer.json +++ b/vendor/Gcp/ralouphie/getallheaders/composer.json @@ -9,15 +9,20 @@ } ], "require": { - "php": ">=5.3" + "php": ">=5.6" }, "require-dev": { - "phpunit\/phpunit": "~3.7.0", - "satooshi\/php-coveralls": ">=1.0" + "phpunit\/phpunit": "^5 || ^6.5", + "php-coveralls\/php-coveralls": "^2.1" }, "autoload": { "files": [ "src\/getallheaders.php" ] + }, + "autoload-dev": { + "psr-4": { + "DeliciousBrains\\WP_Offload_Media\\Gcp\\getallheaders\\Tests\\": "tests\/" + } } } \ No newline at end of file diff --git a/vendor/Gcp/ralouphie/getallheaders/phpunit.xml b/vendor/Gcp/ralouphie/getallheaders/phpunit.xml deleted file mode 100644 index 7255b23d..00000000 --- a/vendor/Gcp/ralouphie/getallheaders/phpunit.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - ./tests - - - - - src - - - - - - - - \ No newline at end of file diff --git a/wordpress-s3.php b/wordpress-s3.php index 074100f0..1881818a 100644 --- a/wordpress-s3.php +++ b/wordpress-s3.php @@ -4,7 +4,7 @@ Plugin URI: http://wordpress.org/extend/plugins/amazon-s3-and-cloudfront/ Description: Automatically copies media uploads to Amazon S3, DigitalOcean Spaces or Google Cloud Storage for storage and delivery. Optionally configure Amazon CloudFront or another CDN for even faster delivery. Author: Delicious Brains -Version: 2.3.1 +Version: 2.3.2 Author URI: https://deliciousbrains.com/ Network: True Text Domain: amazon-s3-and-cloudfront @@ -26,7 +26,7 @@ // Then completely rewritten. */ -$GLOBALS['aws_meta']['amazon-s3-and-cloudfront']['version'] = '2.3.1'; +$GLOBALS['aws_meta']['amazon-s3-and-cloudfront']['version'] = '2.3.2'; require_once dirname( __FILE__ ) . '/classes/as3cf-compatibility-check.php';