Bug #70217 [Fbk->NoF]: cURL Malformed URL Exception with OAuth

From: Date: Sun, 30 Aug 2015 04:22:16 +0000
Subject: Bug #70217 [Fbk->NoF]: cURL Malformed URL Exception with OAuth
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-195616@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=70217&edit=1 ID: 70217 Updated by: php-bugs@lists.php.net Reported by: twOauth at mailinator dot com Summary: cURL Malformed URL Exception with OAuth -Status: Feedback +Status: No Feedback Type: Bug Package: *General Issues Operating System: OSX 10.10.5 PHP Version: 5.5.28 Private report: N New Comment: No feedback was provided. The bug is being suspended because we assume that you are no longer experiencing the problem. If this is not the case and you are able to provide the information that was requested earlier, please do so and change the status of the bug back to "Re-Opened". Thank you. Previous Comments: ------------------------------------------------------------------------ [2015-08-18 19:53:55] cmb@php.net Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with <?php and ends with ?>, is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. ------------------------------------------------------------------------ [2015-08-08 23:13:40] twOauth at mailinator dot com Description: ------------ On OSX 10.10.5, I created a clean install of Twitter OAuth using composer https://github.com/abraham/twitteroauth and ran the test script below with a valid CONSUMER_KEY, CONSUMER_SECRET (validated using the Twitter OAuth tool that returns the expected result). php -S localhost:1234 PHP version is PHP 5.5.27 (cli) (built: Jul 23 2015 00:21:59) Test script: --------------- <?php require "vendor/autoload.php"; use Abraham\TwitterOAuth\TwitterOAuth; define('CONSUMER_KEY', '...'); define('CONSUMER_SECRET', '..'); define('OAUTH_CALLBACK', 'test2.php'); $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET); $request_token = $connection->oauth('oauth/request_token', array('oauth_callback' => OAUTH_CALLBACK)); ?> Expected result: ---------------- The script should above should return an oauth token. Actual result: -------------- /test.php - Uncaught exception 'Abraham\TwitterOAuth\TwitterOAuthException' in /Users/username/Dev/twitter/vendor/abraham/twitteroauth/src/TwitterOAuth.php:141 Stack trace: #0 /Users/username/Dev/twitter/test.php(12): Abraham\TwitterOAuth\TwitterOAuth->oauth('oauth/request_t...', Array) #1 {main} thrown in /Users/username/Dev/twitter/vendor/abraham/twitteroauth/src/TwitterOAuth.php on line 141 $curlErrno = curl_errno($curlHandle); var_dump($curlErrno); results in int(3), which from http://php.net/manual/en/function.curl-errno.php is [3] => 'CURLE_URL_MALFORMAT'. Note this issue does not occur on PHP 5.6.11 (cli) (built: Jul 10 2015 22:36:04). ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=70217&edit=1

« previous php.bugs (#195616) next »