Skip to content

query string isn't url encoded #3

Description

@rvisintine

So after banging my head against the wall for a couple hours I finally figured out why I couldn't get my code to auth. It looks like the library does not pass the query string through as urlencoded. So when my password of password123!@# goes through it breaks. If I urlencode my password before passing it through then there is no problem, or if I change the password to just be numbers/letters than no problem.

Here is a var dump showing what happens in each case.

Without urlencoding

string(117) "https://api.viddler.com/api/v2/viddler.users.auth.php?key=myApiKey&user=me&password=password123!@#"

Array(
  [error] => Array(
    [code] => 100
    [description] => not found
    [details] => me
  )
)

With urlencoding

string(121) "https://api.viddler.com/api/v2/viddler.users.auth.php?key=myApiKey&user=me&password=password123!%40%23"

Array(
  [auth] => Array(
    [sessionid] => 3273d413fc17d707d52564953494e54494e45310
  )
)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions