diff --git a/.gitignore b/.gitignore index e9418d0..009e077 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ build/ vendor/ +.idea +composer.lock diff --git a/README.md b/README.md index 9f82b12..4b4536c 100644 --- a/README.md +++ b/README.md @@ -80,7 +80,18 @@ interface NonceServiceInterface * * @return NonceEntity */ - public function createNonce(NonceOwnerInterface $owner, $namespace = 'default', DateInterval $expiresIn = null, $length = 10); + public function create(NonceOwnerInterface $owner, $namespace = 'default', DateInterval $expiresIn = null, $length = 10); + + /** + * Create a new nonce without an associated owner + * + * @param string $namespace + * @param DateInterval|null $expiresIn + * @param int $length + * + * @return NonceEntity + */ + public function createUnassociated($namespace = 'default', DateInterval $expiresIn = null, $length = 10); /** * Consume a nonce @@ -97,5 +108,16 @@ interface NonceServiceInterface * @return void */ public function consume(NonceOwnerInterface $owner, $nonce, $namespace = 'default', RequestInterface $request = null); + + /** + * Consume a nonce without an associated owner + * + * @param $nonce + * @param string $namespace + * @param RequestInterface|null $request + * + * @return void + */ + public function consumeUnassociated($nonce ,$namespace = 'default', RequestInterface $request = null); } ``` diff --git a/composer.lock b/composer.lock deleted file mode 100644 index 652f855..0000000 --- a/composer.lock +++ /dev/null @@ -1,2516 +0,0 @@ -{ - "_readme": [ - "This file locks the dependencies of your project to a known state", - "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", - "This file is @generated automatically" - ], - "hash": "62e6a15c79b5ca0766e291d7fd62863a", - "packages": [ - { - "name": "doctrine/annotations", - "version": "v1.2.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/annotations.git", - "reference": "d9b1a37e9351ddde1f19f09a02e3d6ee92e82efd" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/d9b1a37e9351ddde1f19f09a02e3d6ee92e82efd", - "reference": "d9b1a37e9351ddde1f19f09a02e3d6ee92e82efd", - "shasum": "" - }, - "require": { - "doctrine/lexer": "1.*", - "php": ">=5.3.2" - }, - "require-dev": { - "doctrine/cache": "1.*", - "phpunit/phpunit": "4.*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\Annotations\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com", - "homepage": "http://www.jwage.com/", - "role": "Creator" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com", - "homepage": "http://www.instaclick.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com", - "homepage": "https://github.com/schmittjoh", - "role": "Developer of wrapped JMSSerializerBundle" - } - ], - "description": "Docblock Annotations Parser", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "docblock", - "parser" - ], - "time": "2014-07-06 15:52:21" - }, - { - "name": "doctrine/cache", - "version": "v1.3.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/cache.git", - "reference": "e16d7adf45664a50fa86f515b6d5e7f670130449" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/e16d7adf45664a50fa86f515b6d5e7f670130449", - "reference": "e16d7adf45664a50fa86f515b6d5e7f670130449", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "conflict": { - "doctrine/common": ">2.2,<2.4" - }, - "require-dev": { - "phpunit/phpunit": ">=3.7", - "satooshi/php-coveralls": "~0.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\Cache\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com", - "homepage": "http://www.jwage.com/", - "role": "Creator" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com", - "homepage": "http://www.instaclick.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com", - "homepage": "https://github.com/schmittjoh", - "role": "Developer of wrapped JMSSerializerBundle" - } - ], - "description": "Caching library offering an object-oriented API for many cache backends", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "cache", - "caching" - ], - "time": "2013-10-25 19:04:14" - }, - { - "name": "doctrine/collections", - "version": "v1.2", - "source": { - "type": "git", - "url": "https://github.com/doctrine/collections.git", - "reference": "b99c5c46c87126201899afe88ec490a25eedd6a2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/b99c5c46c87126201899afe88ec490a25eedd6a2", - "reference": "b99c5c46c87126201899afe88ec490a25eedd6a2", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\Collections\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com", - "homepage": "http://www.jwage.com/", - "role": "Creator" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com", - "homepage": "http://www.instaclick.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com", - "homepage": "https://github.com/schmittjoh", - "role": "Developer of wrapped JMSSerializerBundle" - } - ], - "description": "Collections Abstraction library", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "array", - "collections", - "iterator" - ], - "time": "2014-02-03 23:07:43" - }, - { - "name": "doctrine/common", - "version": "v2.4.2", - "source": { - "type": "git", - "url": "https://github.com/doctrine/common.git", - "reference": "5db6ab40e4c531f14dad4ca96a394dfce5d4255b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/5db6ab40e4c531f14dad4ca96a394dfce5d4255b", - "reference": "5db6ab40e4c531f14dad4ca96a394dfce5d4255b", - "shasum": "" - }, - "require": { - "doctrine/annotations": "1.*", - "doctrine/cache": "1.*", - "doctrine/collections": "1.*", - "doctrine/inflector": "1.*", - "doctrine/lexer": "1.*", - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "~3.7" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.4.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com", - "homepage": "http://www.jwage.com/", - "role": "Creator" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com", - "homepage": "http://www.instaclick.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com", - "homepage": "https://github.com/schmittjoh", - "role": "Developer of wrapped JMSSerializerBundle" - } - ], - "description": "Common Library for Doctrine projects", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "collections", - "eventmanager", - "persistence", - "spl" - ], - "time": "2014-05-21 19:28:51" - }, - { - "name": "doctrine/doctrine-module", - "version": "0.8.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/DoctrineModule.git", - "reference": "a1be11c78d62b880f4e21ff9a107d6e37bed3133" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/DoctrineModule/zipball/a1be11c78d62b880f4e21ff9a107d6e37bed3133", - "reference": "a1be11c78d62b880f4e21ff9a107d6e37bed3133", - "shasum": "" - }, - "require": { - "doctrine/common": ">=2.4,<2.6-dev", - "php": ">=5.3.3", - "symfony/console": "~2.2", - "zendframework/zend-authentication": "~2.2", - "zendframework/zend-cache": "~2.2", - "zendframework/zend-mvc": "~2.2", - "zendframework/zend-paginator": "~2.2", - "zendframework/zend-servicemanager": "~2.2", - "zendframework/zend-stdlib": "~2.2", - "zendframework/zend-validator": "~2.2" - }, - "require-dev": { - "phpunit/phpunit": "~3.7", - "squizlabs/php_codesniffer": "1.4.*", - "zendframework/zendframework": "~2.2" - }, - "suggest": { - "doctrine/data-fixtures": "Data Fixtures if you want to generate test data or bootstrap data for your deployments" - }, - "bin": [ - "bin/doctrine-module" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "0.8.x-dev" - } - }, - "autoload": { - "psr-0": { - "DoctrineModule\\": "src/", - "DoctrineModuleTest\\": "tests/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Kyle Spraggs", - "email": "theman@spiffyjr.me", - "homepage": "http://www.spiffyjr.me/" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/", - "role": "Developer" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@hotmail.com" - }, - { - "name": "Michaël Gallego", - "email": "mic.gallego@gmail.com", - "homepage": "http://michaelgallego.fr" - } - ], - "description": "Zend Framework 2 Module that provides Doctrine basic functionality required for ORM and ODM modules", - "homepage": "http://www.doctrine-project.org/", - "keywords": [ - "doctrine", - "module", - "zf2" - ], - "time": "2014-01-24 17:30:36" - }, - { - "name": "doctrine/inflector", - "version": "v1.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/inflector.git", - "reference": "54b8333d2a5682afdc690060c1cf384ba9f47f08" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/inflector/zipball/54b8333d2a5682afdc690060c1cf384ba9f47f08", - "reference": "54b8333d2a5682afdc690060c1cf384ba9f47f08", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "type": "library", - "autoload": { - "psr-0": { - "Doctrine\\Common\\Inflector\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com", - "homepage": "http://www.jwage.com/", - "role": "Creator" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com", - "homepage": "http://www.instaclick.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com", - "homepage": "https://github.com/schmittjoh", - "role": "Developer of wrapped JMSSerializerBundle" - } - ], - "description": "Common String Manipulations with regard to casing and singular/plural rules.", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "inflection", - "pluarlize", - "singuarlize", - "string" - ], - "time": "2013-01-10 21:49:15" - }, - { - "name": "doctrine/lexer", - "version": "v1.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "2f708a85bb3aab5d99dab8be435abd73e0b18acb" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/2f708a85bb3aab5d99dab8be435abd73e0b18acb", - "reference": "2f708a85bb3aab5d99dab8be435abd73e0b18acb", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "type": "library", - "autoload": { - "psr-0": { - "Doctrine\\Common\\Lexer\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com", - "homepage": "http://www.instaclick.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com", - "homepage": "https://github.com/schmittjoh", - "role": "Developer of wrapped JMSSerializerBundle" - } - ], - "description": "Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers.", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "lexer", - "parser" - ], - "time": "2013-01-12 18:59:04" - }, - { - "name": "symfony/console", - "version": "v2.5.3", - "target-dir": "Symfony/Component/Console", - "source": { - "type": "git", - "url": "https://github.com/symfony/Console.git", - "reference": "cd2d1e4bac2206b337326b0140ff475fe9ad5f63" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/Console/zipball/cd2d1e4bac2206b337326b0140ff475fe9ad5f63", - "reference": "cd2d1e4bac2206b337326b0140ff475fe9ad5f63", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/event-dispatcher": "~2.1" - }, - "suggest": { - "psr/log": "For using the console logger", - "symfony/event-dispatcher": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\Console\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony Console Component", - "homepage": "http://symfony.com", - "time": "2014-08-05 09:00:40" - }, - { - "name": "zendframework/zend-authentication", - "version": "2.3.0", - "target-dir": "Zend/Authentication", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendAuthentication.git", - "reference": "13771a1738ebed55b9e9ed3f4c3871576a37d847" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendAuthentication/zipball/13771a1738ebed55b9e9ed3f4c3871576a37d847", - "reference": "13771a1738ebed55b9e9ed3f4c3871576a37d847", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-stdlib": "self.version" - }, - "require-dev": { - "zendframework/zend-crypt": "self.version", - "zendframework/zend-db": "self.version", - "zendframework/zend-http": "self.version", - "zendframework/zend-ldap": "self.version", - "zendframework/zend-session": "self.version", - "zendframework/zend-uri": "self.version", - "zendframework/zend-validator": "self.version" - }, - "suggest": { - "zendframework/zend-crypt": "Zend\\Crypt component", - "zendframework/zend-db": "Zend\\Db component", - "zendframework/zend-http": "Zend\\Http component", - "zendframework/zend-ldap": "Zend\\Ldap component", - "zendframework/zend-session": "Zend\\Session component", - "zendframework/zend-uri": "Zend\\Uri component", - "zendframework/zend-validator": "Zend\\Validator component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Authentication\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides an API for authentication and includes concrete authentication adapters for common use case scenarios", - "keywords": [ - "Authentication", - "zf2" - ], - "time": "2014-03-14 16:20:28" - }, - { - "name": "zendframework/zend-cache", - "version": "2.3.0", - "target-dir": "Zend/Cache", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendCache.git", - "reference": "00ab70f3bcbc9d9d2a925a1221410de8a941f3e8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendCache/zipball/00ab70f3bcbc9d9d2a925a1221410de8a941f3e8", - "reference": "00ab70f3bcbc9d9d2a925a1221410de8a941f3e8", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-eventmanager": "self.version", - "zendframework/zend-servicemanager": "self.version", - "zendframework/zend-stdlib": "self.version" - }, - "require-dev": { - "zendframework/zend-serializer": "self.version", - "zendframework/zend-session": "self.version" - }, - "suggest": { - "ext-apc": "APC >= 3.1.6 to use the APC storage adapter", - "ext-dba": "DBA, to use the DBA storage adapter", - "ext-memcached": "Memcached >= 1.0.0 to use the Memcached storage adapter", - "ext-wincache": "WinCache, to use the WinCache storage adapter", - "zendframework/zend-serializer": "Zend\\Serializer component", - "zendframework/zend-session": "Zend\\Session component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Cache\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides a generic way to cache any data", - "keywords": [ - "cache", - "zf2" - ], - "time": "2014-03-14 16:20:37" - }, - { - "name": "zendframework/zend-escaper", - "version": "2.3.0", - "target-dir": "Zend/Escaper", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendEscaper.git", - "reference": "ec2614db2ea860c5765a0adba687eacb365ad355" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendEscaper/zipball/ec2614db2ea860c5765a0adba687eacb365ad355", - "reference": "ec2614db2ea860c5765a0adba687eacb365ad355", - "shasum": "" - }, - "require": { - "php": ">=5.3.23" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Escaper\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "escaper", - "zf2" - ], - "time": "2014-03-14 16:21:02" - }, - { - "name": "zendframework/zend-eventmanager", - "version": "2.3.0", - "target-dir": "Zend/EventManager", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendEventManager.git", - "reference": "048164ee81854942667ffdda3030ce06caa79bb5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendEventManager/zipball/048164ee81854942667ffdda3030ce06caa79bb5", - "reference": "048164ee81854942667ffdda3030ce06caa79bb5", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-stdlib": "self.version" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\EventManager\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "eventmanager", - "zf2" - ], - "time": "2014-03-14 16:21:05" - }, - { - "name": "zendframework/zend-http", - "version": "2.3.0", - "target-dir": "Zend/Http", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendHttp.git", - "reference": "6d4314b1e3309071f3ab958186911296d70fe5fe" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendHttp/zipball/6d4314b1e3309071f3ab958186911296d70fe5fe", - "reference": "6d4314b1e3309071f3ab958186911296d70fe5fe", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-loader": "self.version", - "zendframework/zend-stdlib": "self.version", - "zendframework/zend-uri": "self.version", - "zendframework/zend-validator": "self.version" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Http\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides an easy interface for performing Hyper-Text Transfer Protocol (HTTP) requests", - "keywords": [ - "http", - "zf2" - ], - "time": "2014-03-14 16:21:21" - }, - { - "name": "zendframework/zend-loader", - "version": "2.3.0", - "target-dir": "Zend/Loader", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendLoader.git", - "reference": "517f39de5c547d438556e86c270b384c9dee5b18" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendLoader/zipball/517f39de5c547d438556e86c270b384c9dee5b18", - "reference": "517f39de5c547d438556e86c270b384c9dee5b18", - "shasum": "" - }, - "require": { - "php": ">=5.3.23" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Loader\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "loader", - "zf2" - ], - "time": "2014-03-14 16:21:32" - }, - { - "name": "zendframework/zend-math", - "version": "2.3.1", - "target-dir": "Zend/Math", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendMath.git", - "reference": "be6de5ba3d47e3f9a6732badea8bc724c49d0552" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendMath/zipball/be6de5ba3d47e3f9a6732badea8bc724c49d0552", - "reference": "be6de5ba3d47e3f9a6732badea8bc724c49d0552", - "shasum": "" - }, - "require": { - "php": ">=5.3.23" - }, - "suggest": { - "ext-bcmath": "If using the bcmath functionality", - "ext-gmp": "If using the gmp functionality", - "ircmaxell/random-lib": "Fallback random byte generator for Zend\\Math\\Rand if OpenSSL/Mcrypt extensions are unavailable", - "zendframework/zend-servicemanager": ">= current version, if using the BigInteger::factory functionality" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev", - "dev-develop": "2.4-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Math\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "math", - "zf2" - ], - "time": "2014-04-15 15:29:09" - }, - { - "name": "zendframework/zend-mvc", - "version": "2.3.0", - "target-dir": "Zend/Mvc", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendMvc.git", - "reference": "9171841f8b2cdb914dba972878ec78b9885352d0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendMvc/zipball/9171841f8b2cdb914dba972878ec78b9885352d0", - "reference": "9171841f8b2cdb914dba972878ec78b9885352d0", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-eventmanager": "self.version", - "zendframework/zend-servicemanager": "self.version", - "zendframework/zend-stdlib": "self.version" - }, - "require-dev": { - "zendframework/zend-authentication": "self.version", - "zendframework/zend-console": "self.version", - "zendframework/zend-di": "self.version", - "zendframework/zend-filter": "self.version", - "zendframework/zend-form": "self.version", - "zendframework/zend-http": "self.version", - "zendframework/zend-i18n": "self.version", - "zendframework/zend-inputfilter": "self.version", - "zendframework/zend-json": "self.version", - "zendframework/zend-modulemanager": "self.version", - "zendframework/zend-serializer": "self.version", - "zendframework/zend-session": "self.version", - "zendframework/zend-text": "self.version", - "zendframework/zend-uri": "self.version", - "zendframework/zend-validator": "self.version", - "zendframework/zend-version": "self.version", - "zendframework/zend-view": "self.version" - }, - "suggest": { - "zendframework/zend-authentication": "Zend\\Authentication component for Identity plugin", - "zendframework/zend-config": "Zend\\Config component", - "zendframework/zend-console": "Zend\\Console component", - "zendframework/zend-di": "Zend\\Di component", - "zendframework/zend-filter": "Zend\\Filter component", - "zendframework/zend-form": "Zend\\Form component", - "zendframework/zend-http": "Zend\\Http component", - "zendframework/zend-i18n": "Zend\\I18n component for translatable segments", - "zendframework/zend-inputfilter": "Zend\\Inputfilter component", - "zendframework/zend-json": "Zend\\Json component", - "zendframework/zend-modulemanager": "Zend\\ModuleManager component", - "zendframework/zend-serializer": "Zend\\Serializer component", - "zendframework/zend-session": "Zend\\Session component for FlashMessenger, PRG, and FPRG plugins", - "zendframework/zend-stdlib": "Zend\\Stdlib component", - "zendframework/zend-text": "Zend\\Text component", - "zendframework/zend-uri": "Zend\\Uri component", - "zendframework/zend-validator": "Zend\\Validator component", - "zendframework/zend-version": "Zend\\Version component", - "zendframework/zend-view": "Zend\\View component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Mvc\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "mvc", - "zf2" - ], - "time": "2014-03-12 17:04:30" - }, - { - "name": "zendframework/zend-paginator", - "version": "2.3.0", - "target-dir": "Zend/Paginator", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendPaginator.git", - "reference": "aec346c8de27300024c7b3b43b6a3e9bc0aeccb0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendPaginator/zipball/aec346c8de27300024c7b3b43b6a3e9bc0aeccb0", - "reference": "aec346c8de27300024c7b3b43b6a3e9bc0aeccb0", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-stdlib": "self.version" - }, - "require-dev": { - "zendframework/zend-cache": "self.version", - "zendframework/zend-db": "self.version", - "zendframework/zend-filter": "self.version", - "zendframework/zend-json": "self.version", - "zendframework/zend-servicemanager": "self.version", - "zendframework/zend-view": "self.version" - }, - "suggest": { - "zendframework/zend-cache": "Zend\\Cache component to support cache features", - "zendframework/zend-db": "Zend\\Db component", - "zendframework/zend-filter": "Zend\\Filter component", - "zendframework/zend-json": "Zend\\Json component", - "zendframework/zend-servicemanager": "Zend\\ServiceManager component", - "zendframework/zend-view": "Zend\\View component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Paginator\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "paginator", - "zf2" - ], - "time": "2014-03-14 16:21:52" - }, - { - "name": "zendframework/zend-servicemanager", - "version": "2.3.0", - "target-dir": "Zend/ServiceManager", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendServiceManager.git", - "reference": "310187f89fe830ed4484499f78338631f29d25c7" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendServiceManager/zipball/310187f89fe830ed4484499f78338631f29d25c7", - "reference": "310187f89fe830ed4484499f78338631f29d25c7", - "shasum": "" - }, - "require": { - "php": ">=5.3.23" - }, - "require-dev": { - "zendframework/zend-di": "self.version" - }, - "suggest": { - "zendframework/zend-di": "Zend\\Di component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\ServiceManager\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "servicemanager", - "zf2" - ], - "time": "2014-03-14 16:22:14" - }, - { - "name": "zendframework/zend-stdlib", - "version": "2.3.0", - "target-dir": "Zend/Stdlib", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendStdlib.git", - "reference": "d1c481b8a43f2f079b16d3567960ba539e9dacaa" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendStdlib/zipball/d1c481b8a43f2f079b16d3567960ba539e9dacaa", - "reference": "d1c481b8a43f2f079b16d3567960ba539e9dacaa", - "shasum": "" - }, - "require": { - "php": ">=5.3.23" - }, - "require-dev": { - "zendframework/zend-eventmanager": "self.version", - "zendframework/zend-serializer": "self.version", - "zendframework/zend-servicemanager": "self.version" - }, - "suggest": { - "zendframework/zend-eventmanager": "To support aggregate hydrator usage", - "zendframework/zend-serializer": "Zend\\Serializer component", - "zendframework/zend-servicemanager": "To support hydrator plugin manager usage" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Stdlib\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "keywords": [ - "stdlib", - "zf2" - ], - "time": "2014-03-14 16:22:22" - }, - { - "name": "zendframework/zend-uri", - "version": "2.3.0", - "target-dir": "Zend/Uri", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendUri.git", - "reference": "83e617b6273625eeb771c8fb3e886a728fd9dfa4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendUri/zipball/83e617b6273625eeb771c8fb3e886a728fd9dfa4", - "reference": "83e617b6273625eeb771c8fb3e886a728fd9dfa4", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-escaper": "self.version", - "zendframework/zend-validator": "self.version" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Uri\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "a component that aids in manipulating and validating » Uniform Resource Identifiers (URIs)", - "keywords": [ - "uri", - "zf2" - ], - "time": "2014-03-14 16:22:34" - }, - { - "name": "zendframework/zend-validator", - "version": "2.3.0", - "target-dir": "Zend/Validator", - "source": { - "type": "git", - "url": "https://github.com/zendframework/Component_ZendValidator.git", - "reference": "1d4526a1f7db36d725a3a526d8951c1a6d0d69b3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/Component_ZendValidator/zipball/1d4526a1f7db36d725a3a526d8951c1a6d0d69b3", - "reference": "1d4526a1f7db36d725a3a526d8951c1a6d0d69b3", - "shasum": "" - }, - "require": { - "php": ">=5.3.23", - "zendframework/zend-stdlib": "self.version" - }, - "require-dev": { - "zendframework/zend-db": "self.version", - "zendframework/zend-filter": "self.version", - "zendframework/zend-i18n": "self.version", - "zendframework/zend-math": "self.version", - "zendframework/zend-servicemanager": "self.version", - "zendframework/zend-session": "self.version", - "zendframework/zend-uri": "self.version" - }, - "suggest": { - "zendframework/zend-db": "Zend\\Db component", - "zendframework/zend-filter": "Zend\\Filter component, required by the Digits validator", - "zendframework/zend-i18n": "Zend\\I18n component to allow translation of validation error messages as well as to use the various Date validators", - "zendframework/zend-math": "Zend\\Math component", - "zendframework/zend-resources": "Translations of validator messages", - "zendframework/zend-servicemanager": "Zend\\ServiceManager component to allow using the ValidatorPluginManager and validator chains", - "zendframework/zend-session": "Zend\\Session component", - "zendframework/zend-uri": "Zend\\Uri component, required by the Uri and Sitemap\\Loc validators" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2-dev", - "dev-develop": "2.3-dev" - } - }, - "autoload": { - "psr-0": { - "Zend\\Validator\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides a set of commonly needed validators", - "keywords": [ - "validator", - "zf2" - ], - "time": "2014-03-14 16:22:37" - } - ], - "packages-dev": [ - { - "name": "guzzle/guzzle", - "version": "v3.9.1", - "source": { - "type": "git", - "url": "https://github.com/guzzle/guzzle3.git", - "reference": "92d9934f2fca1da15178c91239576ae26e505e60" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle3/zipball/92d9934f2fca1da15178c91239576ae26e505e60", - "reference": "92d9934f2fca1da15178c91239576ae26e505e60", - "shasum": "" - }, - "require": { - "ext-curl": "*", - "php": ">=5.3.3", - "symfony/event-dispatcher": "~2.1" - }, - "replace": { - "guzzle/batch": "self.version", - "guzzle/cache": "self.version", - "guzzle/common": "self.version", - "guzzle/http": "self.version", - "guzzle/inflection": "self.version", - "guzzle/iterator": "self.version", - "guzzle/log": "self.version", - "guzzle/parser": "self.version", - "guzzle/plugin": "self.version", - "guzzle/plugin-async": "self.version", - "guzzle/plugin-backoff": "self.version", - "guzzle/plugin-cache": "self.version", - "guzzle/plugin-cookie": "self.version", - "guzzle/plugin-curlauth": "self.version", - "guzzle/plugin-error-response": "self.version", - "guzzle/plugin-history": "self.version", - "guzzle/plugin-log": "self.version", - "guzzle/plugin-md5": "self.version", - "guzzle/plugin-mock": "self.version", - "guzzle/plugin-oauth": "self.version", - "guzzle/service": "self.version", - "guzzle/stream": "self.version" - }, - "require-dev": { - "doctrine/cache": "~1.3", - "monolog/monolog": "~1.0", - "phpunit/phpunit": "3.7.*", - "psr/log": "~1.0", - "symfony/class-loader": "~2.1", - "zendframework/zend-cache": "2.*,<2.3", - "zendframework/zend-log": "2.*,<2.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.8-dev" - } - }, - "autoload": { - "psr-0": { - "Guzzle": "src/", - "Guzzle\\Tests": "tests/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - }, - { - "name": "Guzzle Community", - "homepage": "https://github.com/guzzle/guzzle/contributors" - } - ], - "description": "Guzzle is a PHP HTTP client library and framework for building RESTful web service clients", - "homepage": "http://guzzlephp.org/", - "keywords": [ - "client", - "curl", - "framework", - "http", - "http client", - "rest", - "web service" - ], - "time": "2014-05-07 17:04:22" - }, - { - "name": "ocramius/instantiator", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/Ocramius/Instantiator.git", - "reference": "cc754c2289ffd4483c319f6ed6ee88ce21676f64" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Ocramius/Instantiator/zipball/cc754c2289ffd4483c319f6ed6ee88ce21676f64", - "reference": "cc754c2289ffd4483c319f6ed6ee88ce21676f64", - "shasum": "" - }, - "require": { - "ocramius/lazy-map": "1.0.*", - "php": "~5.3" - }, - "require-dev": { - "athletic/athletic": "~0.1.8", - "ext-phar": "*", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "2.0.*@ALPHA" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "Instantiator\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/", - "role": "Developer" - } - ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://github.com/Ocramius/Instantiator", - "keywords": [ - "constructor", - "instantiate" - ], - "time": "2014-06-15 11:44:46" - }, - { - "name": "ocramius/lazy-map", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/Ocramius/LazyMap.git", - "reference": "7fe3d347f5e618bcea7d39345ff83f3651d8b752" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Ocramius/LazyMap/zipball/7fe3d347f5e618bcea7d39345ff83f3651d8b752", - "reference": "7fe3d347f5e618bcea7d39345ff83f3651d8b752", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "athletic/athletic": "~0.1.6", - "phpmd/phpmd": "1.5.*", - "phpunit/phpunit": ">=3.7", - "satooshi/php-coveralls": "~0.6", - "squizlabs/php_codesniffer": "1.4.*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "LazyMap\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/", - "role": "Developer" - } - ], - "description": "A library that provides lazy instantiation logic for a map of objects", - "homepage": "https://github.com/Ocramius/LazyMap", - "keywords": [ - "lazy", - "lazy instantiation", - "lazy loading", - "map", - "service location" - ], - "time": "2013-11-09 22:30:54" - }, - { - "name": "phpunit/php-code-coverage", - "version": "2.0.10", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "6d196af48e8c100a3ae881940123e693da5a9217" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/6d196af48e8c100a3ae881940123e693da5a9217", - "reference": "6d196af48e8c100a3ae881940123e693da5a9217", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "phpunit/php-file-iterator": "~1.3.1", - "phpunit/php-text-template": "~1.2.0", - "phpunit/php-token-stream": "~1.2.2", - "sebastian/environment": "~1.0.0", - "sebastian/version": "~1.0.3" - }, - "require-dev": { - "ext-xdebug": ">=2.1.4", - "phpunit/phpunit": "~4.0.14" - }, - "suggest": { - "ext-dom": "*", - "ext-xdebug": ">=2.2.1", - "ext-xmlwriter": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", - "homepage": "https://github.com/sebastianbergmann/php-code-coverage", - "keywords": [ - "coverage", - "testing", - "xunit" - ], - "time": "2014-08-06 06:39:42" - }, - { - "name": "phpunit/php-file-iterator", - "version": "1.3.4", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/acd690379117b042d1c8af1fafd61bde001bf6bb", - "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "File/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "FilterIterator implementation that filters files based on a list of suffixes.", - "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", - "keywords": [ - "filesystem", - "iterator" - ], - "time": "2013-10-10 15:34:57" - }, - { - "name": "phpunit/php-text-template", - "version": "1.2.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/206dfefc0ffe9cebf65c413e3d0e809c82fbf00a", - "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "Text/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", - "keywords": [ - "template" - ], - "time": "2014-01-30 17:20:04" - }, - { - "name": "phpunit/php-timer", - "version": "1.0.5", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/19689d4354b295ee3d8c54b4f42c3efb69cbc17c", - "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "PHP/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", - "keywords": [ - "timer" - ], - "time": "2013-08-02 07:42:54" - }, - { - "name": "phpunit/php-token-stream", - "version": "1.2.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "ad4e1e23ae01b483c16f600ff1bebec184588e32" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/ad4e1e23ae01b483c16f600ff1bebec184588e32", - "reference": "ad4e1e23ae01b483c16f600ff1bebec184588e32", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2-dev" - } - }, - "autoload": { - "classmap": [ - "PHP/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "time": "2014-03-03 05:10:30" - }, - { - "name": "phpunit/phpunit", - "version": "4.1.4", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "a71c4842c5fb836d8b200624583b859ec34e8a26" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a71c4842c5fb836d8b200624583b859ec34e8a26", - "reference": "a71c4842c5fb836d8b200624583b859ec34e8a26", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-json": "*", - "ext-pcre": "*", - "ext-reflection": "*", - "ext-spl": "*", - "php": ">=5.3.3", - "phpunit/php-code-coverage": "~2.0", - "phpunit/php-file-iterator": "~1.3.1", - "phpunit/php-text-template": "~1.2", - "phpunit/php-timer": "~1.0.2", - "phpunit/phpunit-mock-objects": "~2.1", - "sebastian/comparator": "~1.0", - "sebastian/diff": "~1.1", - "sebastian/environment": "~1.0", - "sebastian/exporter": "~1.0", - "sebastian/version": "~1.0", - "symfony/yaml": "~2.0" - }, - "suggest": { - "phpunit/php-invoker": "~1.1" - }, - "bin": [ - "phpunit" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.1.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "", - "../../symfony/yaml/" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "The PHP Unit Testing framework.", - "homepage": "http://www.phpunit.de/", - "keywords": [ - "phpunit", - "testing", - "xunit" - ], - "time": "2014-07-18 07:15:58" - }, - { - "name": "phpunit/phpunit-mock-objects", - "version": "2.2.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "42e589e08bc86e3e9bdf20d385e948347788505b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/42e589e08bc86e3e9bdf20d385e948347788505b", - "reference": "42e589e08bc86e3e9bdf20d385e948347788505b", - "shasum": "" - }, - "require": { - "ocramius/instantiator": "~1.0", - "php": ">=5.3.3", - "phpunit/php-text-template": "~1.2" - }, - "require-dev": { - "phpunit/phpunit": "4.2.*@dev" - }, - "suggest": { - "ext-soap": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.2.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Mock Object library for PHPUnit", - "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", - "keywords": [ - "mock", - "xunit" - ], - "time": "2014-08-02 13:50:58" - }, - { - "name": "psr/log", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "fe0936ee26643249e916849d48e3a51d5f5e278b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/fe0936ee26643249e916849d48e3a51d5f5e278b", - "reference": "fe0936ee26643249e916849d48e3a51d5f5e278b", - "shasum": "" - }, - "type": "library", - "autoload": { - "psr-0": { - "Psr\\Log\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for logging libraries", - "keywords": [ - "log", - "psr", - "psr-3" - ], - "time": "2012-12-21 11:40:51" - }, - { - "name": "satooshi/php-coveralls", - "version": "v0.6.1", - "source": { - "type": "git", - "url": "https://github.com/satooshi/php-coveralls.git", - "reference": "dd0df95bd37a7cf5c5c50304dfe260ffe4b50760" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/satooshi/php-coveralls/zipball/dd0df95bd37a7cf5c5c50304dfe260ffe4b50760", - "reference": "dd0df95bd37a7cf5c5c50304dfe260ffe4b50760", - "shasum": "" - }, - "require": { - "ext-curl": "*", - "ext-json": "*", - "ext-simplexml": "*", - "guzzle/guzzle": ">=3.0", - "php": ">=5.3", - "psr/log": "1.0.0", - "symfony/config": ">=2.0", - "symfony/console": ">=2.0", - "symfony/stopwatch": ">=2.2", - "symfony/yaml": ">=2.0" - }, - "require-dev": { - "apigen/apigen": "2.8.*@stable", - "pdepend/pdepend": "dev-master", - "phpmd/phpmd": "dev-master", - "phpunit/php-invoker": ">=1.1.0,<1.2.0", - "phpunit/phpunit": "3.7.*@stable", - "sebastian/finder-facade": "dev-master", - "sebastian/phpcpd": "1.4.*@stable", - "squizlabs/php_codesniffer": "1.4.*@stable", - "theseer/fdomdocument": "dev-master" - }, - "bin": [ - "composer/bin/coveralls" - ], - "type": "library", - "autoload": { - "psr-0": { - "Contrib\\Component": "src/", - "Contrib\\Bundle": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Kitamura Satoshi", - "email": "with.no.parachute@gmail.com", - "homepage": "https://www.facebook.com/satooshi.jp" - } - ], - "description": "PHP client library for Coveralls API", - "homepage": "https://github.com/satooshi/php-coveralls", - "keywords": [ - "ci", - "coverage", - "github", - "test" - ], - "time": "2013-05-04 08:07:33" - }, - { - "name": "sebastian/comparator", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "f7069ee51fa9fb6c038e16a9d0e3439f5449dcf2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/f7069ee51fa9fb6c038e16a9d0e3439f5449dcf2", - "reference": "f7069ee51fa9fb6c038e16a9d0e3439f5449dcf2", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "sebastian/diff": "~1.1", - "sebastian/exporter": "~1.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - }, - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - } - ], - "description": "Provides the functionality to compare PHP values for equality", - "homepage": "http://www.github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" - ], - "time": "2014-05-02 07:05:58" - }, - { - "name": "sebastian/diff", - "version": "1.1.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "1e091702a5a38e6b4c1ba9ca816e3dd343df2e2d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/1e091702a5a38e6b4c1ba9ca816e3dd343df2e2d", - "reference": "1e091702a5a38e6b4c1ba9ca816e3dd343df2e2d", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - }, - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - } - ], - "description": "Diff implementation", - "homepage": "http://www.github.com/sebastianbergmann/diff", - "keywords": [ - "diff" - ], - "time": "2013-08-03 16:46:33" - }, - { - "name": "sebastian/environment", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "79517609ec01139cd7e9fded0dd7ce08c952ef6a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/79517609ec01139cd7e9fded0dd7ce08c952ef6a", - "reference": "79517609ec01139cd7e9fded0dd7ce08c952ef6a", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "4.0.*@dev" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", - "keywords": [ - "Xdebug", - "environment", - "hhvm" - ], - "time": "2014-02-18 16:17:19" - }, - { - "name": "sebastian/exporter", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "1f9a98e6f5dfe0524cb8c6166f7c82f3e9ae1529" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/1f9a98e6f5dfe0524cb8c6166f7c82f3e9ae1529", - "reference": "1f9a98e6f5dfe0524cb8c6166f7c82f3e9ae1529", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "4.0.*@dev" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - }, - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net", - "role": "Lead" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - } - ], - "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", - "keywords": [ - "export", - "exporter" - ], - "time": "2014-02-16 08:26:31" - }, - { - "name": "sebastian/version", - "version": "1.0.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43", - "reference": "b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43", - "shasum": "" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Library that helps with managing the version number of Git-hosted PHP projects", - "homepage": "https://github.com/sebastianbergmann/version", - "time": "2014-03-07 15:35:33" - }, - { - "name": "squizlabs/php_codesniffer", - "version": "1.5.4", - "source": { - "type": "git", - "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "4097e2c106e4a32bc234ae880e5585a19137e435" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/4097e2c106e4a32bc234ae880e5585a19137e435", - "reference": "4097e2c106e4a32bc234ae880e5585a19137e435", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.1.2" - }, - "suggest": { - "phpunit/php-timer": "dev-master" - }, - "bin": [ - "scripts/phpcs" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-phpcs-fixer": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "CodeSniffer.php", - "CodeSniffer/CLI.php", - "CodeSniffer/Exception.php", - "CodeSniffer/File.php", - "CodeSniffer/Report.php", - "CodeSniffer/Reporting.php", - "CodeSniffer/Sniff.php", - "CodeSniffer/Tokens.php", - "CodeSniffer/Reports/", - "CodeSniffer/CommentParser/", - "CodeSniffer/Tokenizers/", - "CodeSniffer/DocGenerators/", - "CodeSniffer/Standards/AbstractPatternSniff.php", - "CodeSniffer/Standards/AbstractScopeSniff.php", - "CodeSniffer/Standards/AbstractVariableSniff.php", - "CodeSniffer/Standards/IncorrectPatternException.php", - "CodeSniffer/Standards/Generic/Sniffs/", - "CodeSniffer/Standards/MySource/Sniffs/", - "CodeSniffer/Standards/PEAR/Sniffs/", - "CodeSniffer/Standards/PSR1/Sniffs/", - "CodeSniffer/Standards/PSR2/Sniffs/", - "CodeSniffer/Standards/Squiz/Sniffs/", - "CodeSniffer/Standards/Zend/Sniffs/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Greg Sherwood", - "role": "lead" - } - ], - "description": "PHP_CodeSniffer tokenises PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", - "homepage": "http://www.squizlabs.com/php-codesniffer", - "keywords": [ - "phpcs", - "standards" - ], - "time": "2014-08-05 23:54:05" - }, - { - "name": "symfony/config", - "version": "v2.5.3", - "target-dir": "Symfony/Component/Config", - "source": { - "type": "git", - "url": "https://github.com/symfony/Config.git", - "reference": "8d044668c7ccb4ade684e368d910e3aadcff6f6c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/Config/zipball/8d044668c7ccb4ade684e368d910e3aadcff6f6c", - "reference": "8d044668c7ccb4ade684e368d910e3aadcff6f6c", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "symfony/filesystem": "~2.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\Config\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony Config Component", - "homepage": "http://symfony.com", - "time": "2014-08-05 09:00:40" - }, - { - "name": "symfony/event-dispatcher", - "version": "v2.5.3", - "target-dir": "Symfony/Component/EventDispatcher", - "source": { - "type": "git", - "url": "https://github.com/symfony/EventDispatcher.git", - "reference": "8faf5cc7e80fde74a650a36e60d32ce3c3e0457b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/EventDispatcher/zipball/8faf5cc7e80fde74a650a36e60d32ce3c3e0457b", - "reference": "8faf5cc7e80fde74a650a36e60d32ce3c3e0457b", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~2.0", - "symfony/dependency-injection": "~2.0", - "symfony/stopwatch": "~2.2" - }, - "suggest": { - "symfony/dependency-injection": "", - "symfony/http-kernel": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\EventDispatcher\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony EventDispatcher Component", - "homepage": "http://symfony.com", - "time": "2014-07-28 13:20:46" - }, - { - "name": "symfony/filesystem", - "version": "v2.5.3", - "target-dir": "Symfony/Component/Filesystem", - "source": { - "type": "git", - "url": "https://github.com/symfony/Filesystem.git", - "reference": "c1309b0ee195ad264a4314435bdaecdfacb8ae9c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/Filesystem/zipball/c1309b0ee195ad264a4314435bdaecdfacb8ae9c", - "reference": "c1309b0ee195ad264a4314435bdaecdfacb8ae9c", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\Filesystem\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony Filesystem Component", - "homepage": "http://symfony.com", - "time": "2014-07-09 09:05:48" - }, - { - "name": "symfony/stopwatch", - "version": "v2.5.3", - "target-dir": "Symfony/Component/Stopwatch", - "source": { - "type": "git", - "url": "https://github.com/symfony/Stopwatch.git", - "reference": "086c8c98c3016f59f5e6e7b15b751c2384b311e5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/Stopwatch/zipball/086c8c98c3016f59f5e6e7b15b751c2384b311e5", - "reference": "086c8c98c3016f59f5e6e7b15b751c2384b311e5", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\Stopwatch\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony Stopwatch Component", - "homepage": "http://symfony.com", - "time": "2014-08-06 06:44:37" - }, - { - "name": "symfony/yaml", - "version": "v2.5.3", - "target-dir": "Symfony/Component/Yaml", - "source": { - "type": "git", - "url": "https://github.com/symfony/Yaml.git", - "reference": "5a75366ae9ca8b4792cd0083e4ca4dff9fe96f1f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/Yaml/zipball/5a75366ae9ca8b4792cd0083e4ca4dff9fe96f1f", - "reference": "5a75366ae9ca8b4792cd0083e4ca4dff9fe96f1f", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\Yaml\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony Yaml Component", - "homepage": "http://symfony.com", - "time": "2014-08-05 09:00:40" - } - ], - "aliases": [], - "minimum-stability": "stable", - "stability-flags": [], - "prefer-stable": false, - "platform": { - "php": ">=5.5.0" - }, - "platform-dev": [] -} diff --git a/config/doctrine/Roave.NonceUtility.Entity.NonceEntity.dcm.xml b/config/doctrine/Roave.NonceUtility.Entity.NonceEntity.dcm.xml index 15dd00e..f81edfe 100644 --- a/config/doctrine/Roave.NonceUtility.Entity.NonceEntity.dcm.xml +++ b/config/doctrine/Roave.NonceUtility.Entity.NonceEntity.dcm.xml @@ -19,7 +19,7 @@ - + diff --git a/src/Roave/NonceUtility/Entity/NonceEntity.php b/src/Roave/NonceUtility/Entity/NonceEntity.php index 2033382..a71d53c 100644 --- a/src/Roave/NonceUtility/Entity/NonceEntity.php +++ b/src/Roave/NonceUtility/Entity/NonceEntity.php @@ -192,7 +192,7 @@ public function getOwner() /** * @param NonceOwnerInterface $owner */ - public function setOwner(NonceOwnerInterface $owner) + public function setOwner(NonceOwnerInterface $owner = null) { $this->owner = $owner; } diff --git a/src/Roave/NonceUtility/Factory/Service/NonceServiceFactory.php b/src/Roave/NonceUtility/Factory/Service/NonceServiceFactory.php index 41f04f9..ad77070 100644 --- a/src/Roave/NonceUtility/Factory/Service/NonceServiceFactory.php +++ b/src/Roave/NonceUtility/Factory/Service/NonceServiceFactory.php @@ -52,7 +52,7 @@ class NonceServiceFactory implements FactoryInterface * * @param ServiceLocatorInterface $serviceLocator * - * @return mixed + * @return NonceService */ public function createService(ServiceLocatorInterface $serviceLocator) { diff --git a/src/Roave/NonceUtility/Repository/NonceRepository.php b/src/Roave/NonceUtility/Repository/NonceRepository.php index cc0d59c..3bf3097 100644 --- a/src/Roave/NonceUtility/Repository/NonceRepository.php +++ b/src/Roave/NonceUtility/Repository/NonceRepository.php @@ -71,6 +71,18 @@ public function get(NonceOwnerInterface $owner, $nonce, $namespace = 'default') ]); } + /** + * {@inheritdoc} + */ + public function getUnassociated($nonce, $namespace = 'default') + { + return $this->objectRepository->findOneBy([ + 'owner' => null, + 'nonce' => $nonce, + 'namespace' => $namespace + ]); + } + /** * {@Inheritdoc} */ @@ -79,6 +91,14 @@ public function has(NonceOwnerInterface $owner, $nonce, $namespace = 'default') return $this->get($owner, $nonce, $namespace) !== null; } + /** + * {@inheritdoc} + */ + public function hasUnassociated($nonce, $namespace = 'default') + { + return $this->getUnassociated($nonce, $namespace) !== null; + } + /** * {@Inheritdoc} */ diff --git a/src/Roave/NonceUtility/Repository/NonceRepositoryInterface.php b/src/Roave/NonceUtility/Repository/NonceRepositoryInterface.php index 6ad2a6f..cd65f0d 100644 --- a/src/Roave/NonceUtility/Repository/NonceRepositoryInterface.php +++ b/src/Roave/NonceUtility/Repository/NonceRepositoryInterface.php @@ -55,6 +55,16 @@ interface NonceRepositoryInterface */ public function get(NonceOwnerInterface $owner, $nonce, $namespace = 'default'); + /** + * Retrieve a nonce entity without an associated owner by token and namespace + * + * @param $nonce + * @param string $namespace + * + * @return NonceEntity|null + */ + public function getUnassociated($nonce, $namespace = 'default'); + /** * Check if a token exists within the given namespace * @@ -66,6 +76,16 @@ public function get(NonceOwnerInterface $owner, $nonce, $namespace = 'default'); */ public function has(NonceOwnerInterface $owner, $nonce, $namespace = 'default'); + /** + * Check if a nonce entity without an associated owner exists within the given namespace + * + * @param $nonce + * @param string $namespace + * + * @return bool + */ + public function hasUnassociated($nonce, $namespace = 'default'); + /** * Remove all the expired tokens * diff --git a/src/Roave/NonceUtility/Service/NonceService.php b/src/Roave/NonceUtility/Service/NonceService.php index 056320d..48ab192 100644 --- a/src/Roave/NonceUtility/Service/NonceService.php +++ b/src/Roave/NonceUtility/Service/NonceService.php @@ -76,18 +76,20 @@ public function __construct(ObjectManager $objectManager, NonceRepositoryInterfa } /** - * {@Inheritdoc} + * Creates and persists a nonce entity + * + * @param string $nonce + * @param NonceOwnerInterface|null $owner + * @param DateInterval|null $expiresIn + * @param string $namespace + * @return NonceEntity */ - public function createNonce( - NonceOwnerInterface $owner, - $namespace = 'default', + private function createNonce( + $nonce, + NonceOwnerInterface $owner = null, DateInterval $expiresIn = null, - $length = 10 + $namespace = 'default' ) { - do { - $nonce = strtr(Rand::getString($length), '+/', '-_'); - } while ($this->repository->has($owner, $nonce, $namespace)); - $entity = new NonceEntity(); $entity->setOwner($owner); $entity->setNonce($nonce); @@ -108,15 +110,24 @@ public function createNonce( } /** - * {@inheritdoc} + * Consume a nonce entity + * + * @param $nonce + * @param NonceOwnerInterface|null $owner + * @param string $namespace + * @param RequestInterface|null $request */ - public function consume( - NonceOwnerInterface $owner, + private function consumeNonce( $nonce, + NonceOwnerInterface $owner = null, $namespace = 'default', RequestInterface $request = null ) { - $nonce = $this->repository->get($owner, $nonce, $namespace); + if ($owner) { + $nonce = $this->repository->get($owner, $nonce, $namespace); + } else { + $nonce = $this->repository->getUnassociated($nonce, $namespace); + } if (! $nonce) { throw new Exception\NonceNotFoundException; @@ -146,4 +157,52 @@ public function consume( $this->objectManager->flush(); } + + /** + * {@Inheritdoc} + */ + public function create( + NonceOwnerInterface $owner, + $namespace = 'default', + DateInterval $expiresIn = null, + $length = 10 + ) { + do { + $nonce = strtr(Rand::getString($length), '+/', '-_'); + } while ($this->repository->has($owner, $nonce, $namespace)); + + return $this->createNonce($nonce, $owner, $expiresIn, $namespace); + } + + /** + * {@inheritdoc} + */ + public function createUnassociated($namespace = 'default', DateInterval $expiresIn = null, $length = 10) + { + do { + $nonce = strtr(Rand::getString($length), '+/', '-_'); + } while ($this->repository->hasUnassociated($nonce, $namespace)); + + return $this->createNonce($nonce, null, $expiresIn, $namespace); + } + + /** + * {@inheritdoc} + */ + public function consume( + NonceOwnerInterface $owner, + $nonce, + $namespace = 'default', + RequestInterface $request = null + ) { + $this->consumeNonce($nonce, $owner, $namespace, $request); + } + + /** + * {@inheritdoc} + */ + public function consumeUnassociated($nonce, $namespace = 'default', RequestInterface $request = null) + { + $this->consumeNonce($nonce, null, $namespace, $request); + } } diff --git a/src/Roave/NonceUtility/Service/NonceServiceInterface.php b/src/Roave/NonceUtility/Service/NonceServiceInterface.php index c896afb..e5e686a 100644 --- a/src/Roave/NonceUtility/Service/NonceServiceInterface.php +++ b/src/Roave/NonceUtility/Service/NonceServiceInterface.php @@ -57,13 +57,24 @@ interface NonceServiceInterface * * @return NonceEntity */ - public function createNonce( + public function create( NonceOwnerInterface $owner, $namespace = 'default', DateInterval $expiresIn = null, $length = 10 ); + /** + * Create a new nonce without an associated owner + * + * @param string $namespace + * @param DateInterval|null $expiresIn + * @param int $length + * + * @return NonceEntity + */ + public function createUnassociated($namespace = 'default', DateInterval $expiresIn = null, $length = 10); + /** * Consume a nonce * @@ -84,4 +95,15 @@ public function consume( $namespace = 'default', RequestInterface $request = null ); + + /** + * Consume a nonce without an associated owner + * + * @param string $nonce + * @param string $namespace + * @param RequestInterface|null $request + * + * @return void + */ + public function consumeUnassociated($nonce, $namespace = 'default', RequestInterface $request = null); } diff --git a/test/Roave/NonceUtilityTest/Repository/NonceRepositoryTest.php b/test/Roave/NonceUtilityTest/Repository/NonceRepositoryTest.php index 971690e..648b13f 100644 --- a/test/Roave/NonceUtilityTest/Repository/NonceRepositoryTest.php +++ b/test/Roave/NonceUtilityTest/Repository/NonceRepositoryTest.php @@ -109,4 +109,64 @@ public function testHasWithTrueResponse() $this->assertTrue($repository->has($owner, 'testCase')); } + + /** + * @covers ::getUnassociated + */ + public function testGetUnassociated() + { + $nonce = 'roaveIsAwesome'; + $namespace = 'partyRoom'; + + $nonceObject = new NonceEntity(); + + $this->objectRepository + ->expects($this->once()) + ->method('findOneBy') + ->with(['owner' => null, 'nonce' => $nonce, 'namespace' => $namespace]) + ->will($this->returnValue($nonceObject)); + + $result = $this->repository->getUnassociated($nonce, $namespace); + $this->assertSame($nonceObject, $result); + } + + /** + * @covers ::hasUnassociated + */ + public function testHasUnassociatedWithFalseResponse() + { + $builder = $this->getMockBuilder(NonceRepository::class); + $builder + ->setMethods(['getUnassociated']) + ->disableOriginalConstructor(); + + /** @var NonceRepository|PHPUnit_Framework_MockObject_MockObject $repository */ + $repository = $builder->getMock(); + $repository + ->expects($this->once()) + ->method('getUnassociated') + ->will($this->returnValue(null)); + + $this->assertFalse($repository->hasUnassociated('testCase')); + } + + /** + * @covers ::hasUnassociated + */ + public function testHasUnassociatedWithTrueResponse() + { + $builder = $this->getMockBuilder(NonceRepository::class); + $builder + ->setMethods(['getUnassociated']) + ->disableOriginalConstructor(); + + /** @var NonceRepository|PHPUnit_Framework_MockObject_MockObject $repository */ + $repository = $builder->getMock(); + $repository + ->expects($this->once()) + ->method('getUnassociated') + ->will($this->returnValue(new NonceEntity())); + + $this->assertTrue($repository->hasUnassociated('testCase')); + } } diff --git a/test/Roave/NonceUtilityTest/Service/NonceServiceTest.php b/test/Roave/NonceUtilityTest/Service/NonceServiceTest.php index 1caf35c..5b15ce2 100644 --- a/test/Roave/NonceUtilityTest/Service/NonceServiceTest.php +++ b/test/Roave/NonceUtilityTest/Service/NonceServiceTest.php @@ -64,7 +64,7 @@ protected function setUp() } /** - * @covers ::createNonce + * @covers ::create */ public function testCreateNonceTestUniqueToken() { @@ -87,13 +87,13 @@ public function testCreateNonceTestUniqueToken() ->expects($this->once()) ->method('flush'); - $nonce = $this->service->createNonce($this->owner); + $nonce = $this->service->create($this->owner); $this->assertInstanceOf(NonceEntity::class, $nonce); } /** - * @covers ::createNonce + * @covers ::create */ public function testCreateWithExpirationDate() { @@ -111,14 +111,14 @@ public function testCreateWithExpirationDate() ->method('persist') ->with($this->isInstanceOf(NonceEntity::class)); - $nonce = $this->service->createNonce($this->owner, 'default', $interval); + $nonce = $this->service->create($this->owner, 'default', $interval); $this->assertInstanceOf(NonceEntity::class, $nonce); $this->assertEquals($expectedDateTime, $nonce->getExpiresAt()); } /** - * @covers ::createNonce + * @covers ::create */ public function testCreateWithLength() { @@ -134,7 +134,7 @@ public function testCreateWithLength() ->method('persist') ->with($this->isInstanceOf(NonceEntity::class)); - $nonce = $this->service->createNonce($this->owner, 'default', null, $length); + $nonce = $this->service->create($this->owner, 'default', null, $length); $this->assertEquals($length, strlen($nonce->getNonce())); } @@ -242,4 +242,184 @@ public function testConsume() $this->service->consume($this->owner, ''); } + + /** + * @covers ::createUnassociated + */ + public function testCreateUnassociatedNonceTestUniqueToken() + { + $this->repository + ->expects($this->at(0)) + ->method('hasUnassociated') + ->will($this->returnValue(true)); + + $this->repository + ->expects($this->at(1)) + ->method('hasUnassociated') + ->will($this->returnValue(false)); + + $this->objectManager + ->expects($this->once()) + ->method('persist') + ->with($this->isInstanceOf(NonceEntity::class)); + + $this->objectManager + ->expects($this->once()) + ->method('flush'); + + $nonce = $this->service->createUnassociated(); + + $this->assertInstanceOf(NonceEntity::class, $nonce); + } + + /** + * @covers ::create + */ + public function testCreateUnassociatedWithExpirationDate() + { + $interval = new DateInterval('PT10M'); + $expectedDateTime = new DateTime(); + $expectedDateTime->add($interval); + + $this->repository + ->expects($this->once()) + ->method('hasUnassociated') + ->will($this->returnValue(false)); + + $this->objectManager + ->expects($this->once()) + ->method('persist') + ->with($this->isInstanceOf(NonceEntity::class)); + + $nonce = $this->service->createUnassociated('default', $interval); + + $this->assertInstanceOf(NonceEntity::class, $nonce); + $this->assertEquals($expectedDateTime, $nonce->getExpiresAt()); + } + + /** + * @covers ::create + */ + public function testCreateUnassociatedWithLength() + { + $length = 20; + + $this->repository + ->expects($this->once()) + ->method('hasUnassociated') + ->will($this->returnValue(false)); + + $this->objectManager + ->expects($this->once()) + ->method('persist') + ->with($this->isInstanceOf(NonceEntity::class)); + + $nonce = $this->service->createUnassociated('default', null, $length); + + $this->assertEquals($length, strlen($nonce->getNonce())); + } + + /** + * @covers ::consumeUnassociated + */ + public function testConsumeUnassociatedWithMissingNonce() + { + $this->setExpectedException(NonceNotFoundException::class); + $this->service->consumeUnassociated(''); + } + + /** + * @covers ::consumeUnassociated + */ + public function testConsumeUnassociatedWithAlreadyConsumedNonce() + { + $nonce = new NonceEntity(); + $nonce->setConsumedAt(new DateTime()); + + $this->repository + ->expects($this->once()) + ->method('getUnassociated') + ->will($this->returnValue($nonce)); + + $this->setExpectedException(NonceAlreadyConsumedException::class); + $this->service->consumeUnassociated('nonce'); + } + + /** + * @covers ::consumeUnassociated + */ + public function testConsumeUnassociatedWithExpiredNonce() + { + $yesterday = new DateTime(); + $yesterday->modify('-1 days'); + + $nonce = new NonceEntity(); + $nonce->setExpiresAt($yesterday); + + $this->repository + ->expects($this->once()) + ->method('getUnassociated') + ->will($this->returnValue($nonce)); + + $this->setExpectedException(NonceHasExpiredException::class); + $this->service->consumeUnassociated('nonce'); + } + + /** + * @covers ::consumeUnassociated + */ + public function testConsumeUnassociatedWithHttpRequest() + { + $nonce = $this->getMock(NonceEntity::class); + $nonce + ->expects($this->once()) + ->method('setConsumedAt') + ->with($this->isInstanceOf(DateTime::class)); + + $nonce + ->expects($this->once()) + ->method('setHttpUserAgent') + ->with('awesome'); + + $this->repository + ->expects($this->once()) + ->method('getUnassociated') + ->will($this->returnValue($nonce)); + + $this->objectManager + ->expects($this->once()) + ->method('flush'); + + $request = new HttpRequest(); + $request->getHeaders()->addHeaderLine('User-Agent', 'awesome'); + + $this->service->consumeUnassociated('', 'default', $request); + } + + /** + * @covers ::consume + */ + public function testConsumeUnassociated() + { + $nonce = $this->getMock(NonceEntity::class); + $nonce + ->expects($this->once()) + ->method('setConsumedAt') + ->with($this->isInstanceOf(DateTime::class)); + + $nonce + ->expects($this->never()) + ->method('setHttpUserAgent'); + + $this->repository + ->expects($this->once()) + ->method('getUnassociated') + ->will($this->returnValue($nonce)); + + $this->objectManager + ->expects($this->once()) + ->method('flush'); + + $this->service->consumeUnassociated(''); + } }