Created
August 21, 2011 01:18
-
-
Save kiall/1159941 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ($request->method() == Request::GET) | |
{ | |
// Basic Request Validation | |
$params = $this->_get_authorize_params($request); | |
$validation = Validation::factory($params) | |
->rule('client_id', 'not_empty') | |
->rule('client_id', 'regex', array(':value', OAuth2::CLIENT_ID_REGEXP)) | |
->rule('response_type', 'not_empty') | |
->rule('response_type', 'regex', array(':value', OAuth2::RESPONSE_TYPE_REGEXP)) | |
->rule('redirect_uri', 'url'); | |
if ( ! $validation->check()) | |
{ | |
} | |
echo "YES!"; | |
exit; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment