php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #70679 Driver not accepting authMechanism
Submitted: 2015-10-09 14:26 UTC Modified: -
Votes:5
Avg. Score:4.2 ± 1.0
Reproduced:4 of 5 (80.0%)
Same Version:3 (75.0%)
Same OS:1 (25.0%)
From: jfha73 at gmail dot com Assigned:
Status: Open Package: mongo (PECL)
PHP Version: 5.6.14 OS: Windows
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: jfha73 at gmail dot com
New email:
PHP Version: OS:

 

 [2015-10-09 14:26 UTC] jfha73 at gmail dot com
Description:
------------
Hey guys

I'm trying to connect to Mongolab using your driver, according to their docs, with the latest version they enabled Authentication Mechanism to use SCRAM-SHA-1

But when I add it to the options, it doesn't take it.

---
From manual page: http://www.php.net/mongo.connecting.auth
---


Test script:
---------------
new MongoClient("mongodb://username:password!@ds012634.mongolab.com:12634/mydb", array ("authMechanism" => "SCRAM-SHA-1"));

Expected result:
----------------
Connect

Actual result:
--------------
Authentication failed

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-05-10 09:42 UTC] php at genjo dot fr
I think SCRAM-SHA-1 mechanism is not yet supported by PHP, and previous MongoDB-CR authentication method has been removed in Mongo 3.0.0 version.

http://php.net/manual/en/mongoclient.construct.php (PECL deprecated extension)
http://php.net/manual/en/mongodb-driver-manager.construct.php
https://jira.mongodb.org/browse/SERVER-17459

You have to add MONGODB-CR to credentials or to downgrade to previous version 3 : https://jira.mongodb.org/browse/SERVER-17459
 [2016-05-10 09:48 UTC] php at genjo dot fr
This mechanism is supported with 1.6 PHP driver :
http://pecl.php.net/package/mongo
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Nov 29 03:01:28 2024 UTC