Skip to content

Commit

Permalink
Revert "Merge branch 'superdweebie-rand-bugfix'"
Browse files Browse the repository at this point in the history
This reverts commit 002ce3d, reversing
changes made to 0023a96.

Note: we will need to revert this revert when merging develop to master for the
2.3.0 release. See http://git-scm.com/blog/2010/03/02/undoing-merges.html - the
section on "Reverting the Revert," for details.
  • Loading branch information
weierophinney committed Aug 19, 2013
1 parent 3b8013f commit b0ae468
Show file tree
Hide file tree
Showing 159 changed files with 2,080 additions and 6,488 deletions.
1 change: 0 additions & 1 deletion .coveralls.yml

This file was deleted.

3 changes: 0 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ before_install:
script:
- ant travis -keep-going

after_script:
- php vendor/bin/coveralls

notifications:
irc: "irc.freenode.org#zftalk.dev"
email: false
18 changes: 7 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,17 @@
### Welcome to the *Zend Framework 2.3* Release!
### Welcome to the *Zend Framework 2.2* Release!

Master:
[![Build Status](https://secure.travis-ci.org/zendframework/zf2.png?branch=master)](http://travis-ci.org/zendframework/zf2)
[![Coverage Status](https://coveralls.io/repos/zendframework/zf2/badge.png?branch=master)](https://coveralls.io/r/zendframework/zf2)
Develop:
[![Build Status](https://secure.travis-ci.org/zendframework/zf2.png?branch=develop)](http://travis-ci.org/zendframework/zf2)
[![Coverage Status](https://coveralls.io/repos/zendframework/zf2/badge.png?branch=develop)](https://coveralls.io/r/zendframework/zf2)
Master: [![Build Status](https://secure.travis-ci.org/zendframework/zf2.png?branch=master)](http://travis-ci.org/zendframework/zf2)
Develop: [![Build Status](https://secure.travis-ci.org/zendframework/zf2.png?branch=develop)](http://travis-ci.org/zendframework/zf2)

## RELEASE INFORMATION

*Zend Framework 2.3.0dev*
*Zend Framework 2.2.3dev*

This is the third minor (feature) release for the version 2 series.
This is the third maintenance release for the 2.2 series.

DD MMM YYY
DD MMM YYYY

### UPDATES IN 2.3.0
### UPDATES IN 2.2.3

Please see [CHANGELOG.md](CHANGELOG.md).

Expand Down
24 changes: 2 additions & 22 deletions build.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="ZF2" default="build">
<target name="travis" depends="tests-parallel,merge-clover,show-test-results" />
<target name="travis" depends="tests-parallel,show-test-results" />

<target name="clean" description="Cleanup build artifacts">
<delete dir="${basedir}/build"/>
Expand All @@ -9,8 +9,6 @@
<target name="prepare" depends="clean" description="Prepare for build">
<mkdir dir="${basedir}/build/test-results"/>
<mkdir dir="${basedir}/build/cs-results"/>
<mkdir dir="${basedir}/build/coverage"/>
<mkdir dir="${basedir}/build/logs"/>
</target>

<target name="get-cs-fixer" depends="clean" description="Get coding standards fixer">
Expand All @@ -26,30 +24,14 @@
<arg value="--version" />
</exec>
<exec executable="composer" failonerror="true">
<env key="COMPOSER_ROOT_VERSION" value="dev-develop"/>
<env key="COMPOSER_ROOT_VERSION" value="dev-master"/>
<arg value="install" />
<arg value="--dev" />
<arg value="--prefer-source" />
</exec>
</sequential>
</target>

<target name="merge-clover" description="Merges the individual clover reports of each component into a single clover.xml">
<sequential>
<exec executable="php" failonerror="true">
<arg value="-d" />
<arg value="memory_limit=-1" />
<arg value="vendor/bin/phpcov.php" />
<arg value="--merge" />
<arg value="--clover" />
<arg value="${basedir}/build/logs/clover.xml" />
<arg value="--whitelist" />
<arg value="${basedir}/library" />
<arg value="${basedir}/build/coverage" />
</exec>
</sequential>
</target>

<target
name="tests-parallel"
depends="prepare,composer-install,get-cs-fixer"
Expand Down Expand Up @@ -137,8 +119,6 @@
>
<arg value="-c" />
<arg value="${basedir}/tests/phpunit.xml.dist" />
<arg value="--coverage-php" />
<arg value="${basedir}/build/coverage/coverage-@{component}.cov" />
<arg value="${basedir}/tests/ZendTest/@{component}" />
</exec>
</sequential>
Expand Down
25 changes: 1 addition & 24 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,6 @@
],
"homepage": "http://framework.zend.com/",
"license": "BSD-3-Clause",
"repositories": [
{
"type": "package",
"package": {
"name": "sebastianbergmann/phpcov",
"version": "1.1.0",
"dist": {
"url": "https://github.com/sebastianbergmann/phpcov/archive/1.1.0.zip",
"type": "zip"
},
"source": {
"url": "https://github.com/sebastianbergmann/phpcov.git",
"type": "git",
"reference": "1.1.0"
},
"bin": [
"phpcov.php"
]
}
}
],
"require": {
"php": ">=5.3.3"
},
Expand All @@ -37,9 +16,7 @@
"ircmaxell/random-lib": "dev-master",
"ircmaxell/security-lib": "dev-master",
"ocramius/proxy-manager": "0.4.*",
"phpunit/PHPUnit": "3.7.*",
"satooshi/php-coveralls": "dev-master",
"sebastianbergmann/phpcov": "1.1.0"
"phpunit/PHPUnit": "3.7.*"
},
"suggest": {
"ext-intl": "ext/intl for i18n features (included in default builds of PHP)",
Expand Down
41 changes: 12 additions & 29 deletions library/Zend/Authentication/Adapter/Http.php
Original file line number Diff line number Diff line change
Expand Up @@ -336,11 +336,11 @@ public function authenticate()

$headers = $this->request->getHeaders();
if (!$headers->has($getHeader)) {
return $this->challengeClient();
return $this->_challengeClient();
}
$authHeader = $headers->get($getHeader)->getFieldValue();
if (!$authHeader) {
return $this->challengeClient();
return $this->_challengeClient();
}

list($clientScheme) = explode(' ', $authHeader);
Expand All @@ -360,7 +360,7 @@ public function authenticate()
// client sent a scheme that is not the one required
if (!in_array($clientScheme, $this->acceptSchemes)) {
// challenge again the client
return $this->challengeClient();
return $this->_challengeClient();
}

switch ($clientScheme) {
Expand All @@ -377,23 +377,6 @@ public function authenticate()
return $result;
}

/**
* @deprecated
* @see Http::challengeClient()
* @return Authentication\Result Always returns a non-identity Auth result
*/
protected function _challengeClient()
{
trigger_error(sprintf(
'The method "%s" is deprecated and will be removed in the future; '
. 'please use the public method "%s::challengeClient()" instead',
__METHOD__,
__CLASS__
), E_USER_DEPRECATED);

return $this->challengeClient();
}

/**
* Challenge Client
*
Expand All @@ -402,7 +385,7 @@ protected function _challengeClient()
*
* @return Authentication\Result Always returns a non-identity Auth result
*/
public function challengeClient()
protected function _challengeClient()
{
if ($this->imaProxy) {
$statusCode = 407;
Expand Down Expand Up @@ -491,12 +474,12 @@ protected function _basicAuth($header)
// implementation does. If invalid credentials are detected,
// re-challenge the client.
if (!ctype_print($auth)) {
return $this->challengeClient();
return $this->_challengeClient();
}
// Fix for ZF-1515: Now re-challenges on empty username or password
$creds = array_filter(explode(':', $auth));
if (count($creds) != 2) {
return $this->challengeClient();
return $this->_challengeClient();
}

$result = $this->basicResolver->resolve($creds[0], $this->realm, $creds[1]);
Expand All @@ -515,7 +498,7 @@ protected function _basicAuth($header)
return new Authentication\Result(Authentication\Result::SUCCESS, $result);
}

return $this->challengeClient();
return $this->_challengeClient();
}

/**
Expand Down Expand Up @@ -547,17 +530,17 @@ protected function _digestAuth($header)
// See ZF-1052. This code was a bit too unforgiving of invalid
// usernames. Now, if the username is bad, we re-challenge the client.
if ('::invalid::' == $data['username']) {
return $this->challengeClient();
return $this->_challengeClient();
}

// Verify that the client sent back the same nonce
if ($this->_calcNonce() != $data['nonce']) {
return $this->challengeClient();
return $this->_challengeClient();
}
// The opaque value is also required to match, but of course IE doesn't
// play ball.
if (!$this->ieNoOpaque && $this->_calcOpaque() != $data['opaque']) {
return $this->challengeClient();
return $this->_challengeClient();
}

// Look up the user's password hash. If not found, deny access.
Expand All @@ -566,7 +549,7 @@ protected function _digestAuth($header)
// to be recreatable with the current settings of this object.
$ha1 = $this->digestResolver->resolve($data['username'], $data['realm']);
if ($ha1 === false) {
return $this->challengeClient();
return $this->_challengeClient();
}

// If MD5-sess is used, a1 value is made of the user's password
Expand Down Expand Up @@ -605,7 +588,7 @@ protected function _digestAuth($header)
return new Authentication\Result(Authentication\Result::SUCCESS, $identity);
}

return $this->challengeClient();
return $this->_challengeClient();
}

/**
Expand Down
14 changes: 1 addition & 13 deletions library/Zend/Authentication/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,23 +16,11 @@
"php": ">=5.3.3",
"zendframework/zend-stdlib": "self.version"
},
"require-dev": {
"zendframework/zend-db": "self.version",
"zendframework/zend-crypt": "self.version",
"zendframework/zend-http": "self.version",
"zendframework/zend-ldap": "self.version",
"zendframework/zend-session": "self.version",
"zendframework/zend-validator": "self.version",
"zendframework/zend-uri": "self.version"
},
"suggest": {
"zendframework/zend-db": "Zend\\Db component",
"zendframework/zend-crypt": "Zend\\Crypt 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"
"zendframework/zend-session": "Zend\\Session component"
},
"extra": {
"branch-alias": {
Expand Down
3 changes: 0 additions & 3 deletions library/Zend/Barcode/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,9 @@
"zendframework/zend-stdlib": "self.version"
},
"require-dev": {
"zendframework/zend-servicemanager": "self.version",
"zendframework/zend-validator": "self.version",
"zendframework/zendpdf": "*"
},
"suggest": {
"zendframework/zend-servicemanager": "Zend\\ServiceManager component",
"zendframework/zend-validator": "Zend\\Validator component",
"zendframework/zendpdf": "ZendPdf component"
},
Expand Down
15 changes: 0 additions & 15 deletions library/Zend/Cache/Storage/Adapter/Apc.php
Original file line number Diff line number Diff line change
Expand Up @@ -734,19 +734,4 @@ protected function normalizeMetadata(array & $metadata)
$metadata['num_hits']
);
}

/**
* Internal method to set an item only if token matches
*
* @param mixed $token
* @param string $normalizedKey
* @param mixed $value
* @return bool
* @see getItem()
* @see setItem()
*/
protected function internalCheckAndSetItem(& $token, & $normalizedKey, & $value)
{
return apc_cas($normalizedKey, $token, $value);
}
}
Loading

0 comments on commit b0ae468

Please sign in to comment.