Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix BUG Digest Auth #1346

Merged
merged 2 commits into from
Oct 8, 2013
Merged

Fix BUG Digest Auth #1346

merged 2 commits into from
Oct 8, 2013

Conversation

dreamsxin
Copy link
Contributor

No description provided.

phalcon pushed a commit that referenced this pull request Oct 8, 2013
@phalcon phalcon merged commit cd6fd6f into phalcon:1.3.0 Oct 8, 2013
@phalcon
Copy link
Collaborator

phalcon commented Oct 8, 2013

Is there a example about the usage of this functionality?

@dreamsxin
Copy link
Contributor Author

@phalcon Examples should be placed where?
Can see http://www.php.net/manual/en/features.http-auth.php Digest HTTP Authentication example

$auth = $this->request->getDigestAuth(); 
if (empty($auth)) {
    $this->response->setStatusCode('401', 'Unauthorized');
    $this->response->setHeader('WWW-Authenticate', 'Digest realm="'.$realm. '" qop="auth" nonce="'.uniqid().'" opaque="'.md5($realm).'"');

    $this->response->setContent('Text to send if user hits Cancel button');
}

@dreamsxin dreamsxin deleted the http_request branch August 20, 2014 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants